"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../node_modules/tslib/tslib.es6.js"),s=require("../node_modules/@rematch/core/dist/core.esm.js").createModel()({state:{data:{browser_permissions:{active:!1,break:!0,message:"No microphone or camera permissions.",type:"browser_permissions"},user_permissions:{active:!1,break:!0,message:"You must accept audio and video permissions.",type:"user_permissions"},unknown_media_permissions:{active:!1,break:!0,message:"Unknown audio or camera permissions.",type:"unknown_media_permissions"},webrtc_down:{active:!1,break:!0,message:"Click icon to reconnect",type:"webrtc_down"},socket_down:{active:!1,break:!1,message:"Click icon to reconnect",type:"socket_down"},busy_camera:{active:!1,message:"Camera is already used.",type:"busy_camera"},call_transfered:{active:!1,success:!0,message:"Call transferred successfully.",type:"call_transfered"}},status:{activeAlertsCount:0,breakActiveAlertsCount:0}},reducers:{setAlert:function(s,t){var a;if(!s.data[t].active){var r=s.status.activeAlertsCount+1,i=s.data[t].break?s.status.breakActiveAlertsCount+1:s.status.breakActiveAlertsCount;return e.__assign(e.__assign({},s),{data:e.__assign(e.__assign({},s.data),(a={},a[t]=e.__assign(e.__assign({},s.data[t]),{active:!0}),a)),status:e.__assign(e.__assign({},s.status),{activeAlertsCount:r,breakActiveAlertsCount:i})})}},removeAlert:function(s,t){var a;if(s.data[t].active){var r=s.status.activeAlertsCount-1,i=s.data[t].break?s.status.breakActiveAlertsCount-1:s.status.breakActiveAlertsCount;return{data:e.__assign(e.__assign({},s.data),(a={},a[t]=e.__assign(e.__assign({},s.data[t]),{active:!1,activeAlertsCount:r,breakActiveAlertsCount:i}),a)),status:e.__assign(e.__assign({},s.status),{activeAlertsCount:r,breakActiveAlertsCount:i})}}},removeAllAlerts:function(e){for(var s in e.data)e.data[s].active=!1;e.status.activeAlertsCount=0,e.status.breakActiveAlertsCount=0}}});exports.alerts=s;
//# sourceMappingURL=alerts.js.map
