Нет описания
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

outlook-web-16.01.js 273KB

123456789101112131415161718
  1. /* Outlook web application specific API library */
  2. /* Version: 16.0.7511.3000 */
  3. /*
  4. Copyright (c) Microsoft Corporation. All rights reserved.
  5. */
  6. /*
  7. Your use of this file is governed by the Microsoft Services Agreement http://go.microsoft.com/fwlink/?LinkId=266419.
  8. */
  9. /*!
  10. Copyright (c) Microsoft Corporation. All rights reserved.
  11. */
  12. /*!
  13. Your use of this file is governed by the Microsoft Services Agreement http://go.microsoft.com/fwlink/?LinkId=266419.
  14. */
  15. var __extends=this&&this.__extends||function(n,t){for(var i in t)t.hasOwnProperty(i)&&(n[i]=t[i]);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)},OfficeExt;(function(n){var t=function(){var i=null,n=!0;function t(){}t.prototype.isMsAjaxLoaded=function(){var t="function",i="undefined";return typeof Sys!==i&&typeof Type!==i&&Sys.StringBuilder&&typeof Sys.StringBuilder===t&&Type.registerNamespace&&typeof Type.registerNamespace===t&&Type.registerClass&&typeof Type.registerClass===t&&typeof Function._validateParams===t&&Sys.Serialization&&Sys.Serialization.JavaScriptSerializer&&typeof Sys.Serialization.JavaScriptSerializer.serialize===t?n:!1};t.prototype.loadMsAjaxFull=function(n){var t=(window.location.protocol.toLowerCase()==="https:"?"https:":"http:")+"//ajax.aspnetcdn.com/ajax/3.5/MicrosoftAjax.js";OSF.OUtil.loadScript(t,n)};Object.defineProperty(t.prototype,"msAjaxError",{get:function(){var n=this;n._msAjaxError==i&&n.isMsAjaxLoaded()&&(n._msAjaxError=Error);return n._msAjaxError},set:function(n){this._msAjaxError=n},enumerable:n,configurable:n});Object.defineProperty(t.prototype,"msAjaxSerializer",{get:function(){var n=this;n._msAjaxSerializer==i&&n.isMsAjaxLoaded()&&(n._msAjaxSerializer=Sys.Serialization.JavaScriptSerializer);return n._msAjaxSerializer},set:function(n){this._msAjaxSerializer=n},enumerable:n,configurable:n});Object.defineProperty(t.prototype,"msAjaxString",{get:function(){var n=this;n._msAjaxString==i&&n.isMsAjaxLoaded()&&(n._msAjaxSerializer=String);return n._msAjaxString},set:function(n){this._msAjaxString=n},enumerable:n,configurable:n});Object.defineProperty(t.prototype,"msAjaxDebug",{get:function(){var n=this;n._msAjaxDebug==i&&n.isMsAjaxLoaded()&&(n._msAjaxDebug=Sys.Debug);return n._msAjaxDebug},set:function(n){this._msAjaxDebug=n},enumerable:n,configurable:n});return t}();n.MicrosoftAjaxFactory=t})(OfficeExt||(OfficeExt={}));var OsfMsAjaxFactory=new OfficeExt.MicrosoftAjaxFactory,OSF=OSF||{},OfficeExt;(function(n){var t=function(){function n(n){this._internalStorage=n}n.prototype.getItem=function(n){try{return this._internalStorage&&this._internalStorage.getItem(n)}catch(t){return null}};n.prototype.setItem=function(n,t){try{this._internalStorage&&this._internalStorage.setItem(n,t)}catch(i){}};n.prototype.clear=function(){try{this._internalStorage&&this._internalStorage.clear()}catch(n){}};n.prototype.removeItem=function(n){try{this._internalStorage&&this._internalStorage.removeItem(n)}catch(t){}};n.prototype.getKeysWithPrefix=function(n){var i=[];try{for(var u=this._internalStorage&&this._internalStorage.length||0,t=0;t<u;t++){var r=this._internalStorage.key(t);r.indexOf(n)===0&&i.push(r)}}catch(f){}return i};return n}();n.SafeStorage=t})(OfficeExt||(OfficeExt={}));OSF.XdmFieldName={ConversationUrl:"ConversationUrl",AppId:"AppId"};OSF.WindowNameItemKeys={BaseFrameName:"baseFrameName",HostInfo:"hostInfo",XdmInfo:"xdmInfo",SerializerVersion:"serializerVersion",AppContext:"appContext"};OSF.OUtil=function(){var f="focus",s="on",nt="configurable",tt="writable",o="enumerable",h="undefined",i=!0,t=!1,y=2147483647,n=null,r=-1,w=r,d="&_xdm_Info=",g="&_serializer_version=",rt="_xdm_",ut="_serializer_version=",c="#",it="&",e="class",v={},ft=3e4,a=n,l=n,u=+new Date;function b(){var n=y*Math.random();n^=u^(new Date).getMilliseconds()<<Math.floor(Math.random()*21);return n.toString(16)}function p(){if(!a){try{var t=window.sessionStorage}catch(i){t=n}a=new OfficeExt.SafeStorage(t)}return a}function k(n){for(var u=[],i=[],f=n.length,t,r=0;r<f;r++){t=n[r];t.tabIndex?t.tabIndex>0?i.push(t):t.tabIndex===0&&u.push(t):u.push(t)}i=i.sort(function(n,t){var r=n.tabIndex-t.tabIndex;r===0&&(r=i.indexOf(n)-i.indexOf(t));return r});return[].concat(i,u)}return{set_entropy:function(n){if(typeof n=="string")for(var i=0;i<n.length;i+=4){for(var r=0,t=0;t<4&&i+t<n.length;t++)r=(r<<8)+n.charCodeAt(i+t);u^=r}else u^=typeof n=="number"?n:y*Math.random();u&=y},extend:function(n,t){var i=function(){};i.prototype=t.prototype;n.prototype=new i;n.prototype.constructor=n;n.uber=t.prototype;t.prototype.constructor===Object.prototype.constructor&&(t.prototype.constructor=t)},setNamespace:function(n,t){t&&n&&!t[n]&&(t[n]={})},unsetNamespace:function(n,t){t&&n&&t[n]&&delete t[n]},loadScript:function(r,u,f){if(r&&u){var c=window.document,e=v[r];if(e)e.loaded?u():e.pendingCallbacks.push(u);else{var o=c.createElement("script");o.type="text/javascript";e={loaded:t,pendingCallbacks:[u],timer:n};v[r]=e;var h=function(){if(e.timer!=n){clearTimeout(e.timer);delete e.timer}e.loaded=i;for(var u=e.pendingCallbacks.length,t=0;t<u;t++){var r=e.pendingCallbacks.shift();r()}},s=function(){delete v[r];if(e.timer!=n){clearTimeout(e.timer);delete e.timer}for(var u=e.pendingCallbacks.length,t=0;t<u;t++){var i=e.pendingCallbacks.shift();i()}};o.readyState?o.onreadystatechange=function(){if(o.readyState=="loaded"||o.readyState=="complete"){o.onreadystatechange=n;h()}}:o.onload=h;o.onerror=s;f=f||ft;e.timer=setTimeout(s,f);o.src=r;c.getElementsByTagName("head")[0].appendChild(o)}}},loadCSS:function(n){if(n){var i=window.document,t=i.createElement("link");t.type="text/css";t.rel="stylesheet";t.href=n;i.getElementsByTagName("head")[0].appendChild(t)}},parseEnum:function(n,t){var i=t[n.trim()];if(typeof i==h){OsfMsAjaxFactory.msAjaxDebug.trace("invalid enumeration string:"+n);throw OsfMsAjaxFactory.msAjaxError.argument("str");}return i},delayExecutionAndCache:function(){var n={calc:arguments[0]};return function(){if(n.calc){n.val=n.calc.apply(this,arguments);delete n.calc}return n.val}},getUniqueId:function(){w=w+1;return w.toString()},formatString:function(){var n=arguments,t=n[0];return t.replace(/{(\d+)}/gm,function(t,i){var r=parseInt(i,10)+1;return n[r]===undefined?"{"+i+"}":n[r]})},generateConversationId:function(){return[b(),b(),(+new Date).toString()].join("_")},getFrameName:function(n){return rt+n+this.generateConversationId()},addXdmInfoAsHash:function(n,i){return OSF.OUtil.addInfoAsHash(n,d,i,t)},addSerializerVersionAsHash:function(n,t){return OSF.OUtil.addInfoAsHash(n,g,t,i)},addInfoAsHash:function(n,t,i,r){n=n.trim()||"";var e=n.split(c),o=e.shift(),f=e.join(c),u;u=r?[t,encodeURIComponent(i),f].join(""):[f,t,i].join("");return[o,c,u].join("")},parseHostInfoFromWindowName:function(n,t){return OSF.OUtil.parseInfoFromWindowName(n,t,OSF.WindowNameItemKeys.HostInfo)},parseXdmInfo:function(n){var t=OSF.OUtil.parseXdmInfoWithGivenFragment(n,window.location.hash);t||(t=OSF.OUtil.parseXdmInfoFromWindowName(n,window.name));return t},parseXdmInfoFromWindowName:function(n,t){return OSF.OUtil.parseInfoFromWindowName(n,t,OSF.WindowNameItemKeys.XdmInfo)},parseXdmInfoWithGivenFragment:function(n,i){return OSF.OUtil.parseInfoWithGivenFragment(d,rt,t,n,i)},parseSerializerVersion:function(n){var t=OSF.OUtil.parseSerializerVersionWithGivenFragment(n,window.location.hash);isNaN(t)&&(t=OSF.OUtil.parseSerializerVersionFromWindowName(n,window.name));return t},parseSerializerVersionFromWindowName:function(n,t){return parseInt(OSF.OUtil.parseInfoFromWindowName(n,t,OSF.WindowNameItemKeys.SerializerVersion))},parseSerializerVersionWithGivenFragment:function(n,t){return parseInt(OSF.OUtil.parseInfoWithGivenFragment(g,ut,i,n,t))},parseInfoFromWindowName:function(t,i,r){try{var f=JSON.parse(i),u=f!=n?f[r]:n,e=p();if(!t&&e&&f!=n){var o=f[OSF.WindowNameItemKeys.BaseFrameName]+r;u?e.setItem(o,u):u=e.getItem(o)}return u}catch(s){return n}},parseInfoWithGivenFragment:function(t,i,u,f,e){var c=e.split(t),o=c.length>1?c[c.length-1]:n;if(u&&o!=n){o.indexOf(it)>=0&&(o=o.split(it)[0]);o=decodeURIComponent(o)}var l=p();if(!f&&l){var s=window.name.indexOf(i);if(s>r){var h=window.name.indexOf(";",s);h==r&&(h=window.name.length);var a=window.name.substring(s,h);o?l.setItem(a,o):o=l.getItem(a)}}return o},getConversationId:function(){var i=window.location.search,t=n;if(i){var r=i.indexOf("&");t=r>0?i.substring(1,r):i.substr(1);if(t&&t.charAt(t.length-1)==="="){t=t.substring(0,t.length-1);t&&(t=decodeURIComponent(t))}}return t},getInfoItems:function(n){var t=n.split("$");typeof t[1]==h&&(t=n.split("|"));typeof t[1]==h&&(t=n.split("%7C"));return t},getXdmFieldValue:function(n,t){var r="",u=OSF.OUtil.parseXdmInfo(t);if(u){var i=OSF.OUtil.getInfoItems(u);if(i!=undefined&&i.length>=3)switch(n){case OSF.XdmFieldName.ConversationUrl:r=i[2];break;case OSF.XdmFieldName.AppId:r=i[1]}}return r},validateParamObject:function(n,r){var u=Function._validateParams(arguments,[{name:"params",type:Object,mayBeNull:t},{name:"expectedProperties",type:Object,mayBeNull:t},{name:"callback",type:Function,mayBeNull:i}]);if(u)throw u;for(var f in r){u=Function._validateParameter(n[f],r[f],f);if(u)throw u;}},writeProfilerMark:function(n){if(window.msWriteProfilerMark){window.msWriteProfilerMark(n);OsfMsAjaxFactory.msAjaxDebug.trace(n)}},outputDebug:function(n){typeof OsfMsAjaxFactory!==h&&OsfMsAjaxFactory.msAjaxDebug&&OsfMsAjaxFactory.msAjaxDebug.trace&&OsfMsAjaxFactory.msAjaxDebug.trace(n)},defineNondefaultProperty:function(n,t,r,u){r=r||{};for(var e in u){var f=u[e];r[f]==undefined&&(r[f]=i)}Object.defineProperty(n,t,r);return n},defineNondefaultProperties:function(n,t,i){t=t||{};for(var r in t)OSF.OUtil.defineNondefaultProperty(n,r,t[r],i);return n},defineEnumerableProperty:function(n,t,i){return OSF.OUtil.defineNondefaultProperty(n,t,i,[o])},defineEnumerableProperties:function(n,t){return OSF.OUtil.defineNondefaultProperties(n,t,[o])},defineMutableProperty:function(n,t,i){return OSF.OUtil.defineNondefaultProperty(n,t,i,[tt,o,nt])},defineMutableProperties:function(n,t){return OSF.OUtil.defineNondefaultProperties(n,t,[tt,o,nt])},finalizeProperties:function(n,r){r=r||{};for(var o=Object.getOwnPropertyNames(n),s=o.length,f=0;f<s;f++){var e=o[f],u=Object.getOwnPropertyDescriptor(n,e);u.get||u.set||(u.writable=r.writable||t);u.configurable=r.configurable||t;u.enumerable=r.enumerable||i;Object.defineProperty(n,e,u)}return n},mapList:function(n,t){var i=[];if(n)for(var r in n)i.push(t(n[r]));return i},listContainsKey:function(n,r){for(var u in n)if(r==u)return i;return t},listContainsValue:function(n,r){for(var u in n)if(r==n[u])return i;return t},augmentList:function(n,t){var r=n.push?function(t,i){n.push(i)}:function(t,i){n[t]=i};for(var i in t)r(i,t[i])},redefineList:function(n,t){for(var r in n)delete n[r];for(var i in t)n[i]=t[i]},isArray:function(n){return Object.prototype.toString.apply(n)==="[object Array]"},isFunction:function(n){return Object.prototype.toString.apply(n)==="[object Function]"},isDate:function(n){return Object.prototype.toString.apply(n)==="[object Date]"},addEventListener:function(n,i,r){n.addEventListener?n.addEventListener(i,r,t):Sys.Browser.agent===Sys.Browser.InternetExplorer&&n.attachEvent?n.attachEvent(s+i,r):n[s+i]=r},removeEventListener:function(i,r,u){i.removeEventListener?i.removeEventListener(r,u,t):Sys.Browser.agent===Sys.Browser.InternetExplorer&&i.detachEvent?i.detachEvent(s+r,u):i[s+r]=n},getCookieValue:function(n){var t=RegExp(n+"[^;]+").exec(document.cookie);return t.toString().replace(/^[^=]+./,"")},xhrGet:function(n,t,r){var u;try{u=new XMLHttpRequest;u.onreadystatechange=function(){u.readyState==4&&(u.status==200?t(u.responseText):r(u.status))};u.open("GET",n,i);u.send()}catch(f){r(f)}},xhrGetFull:function(n,t,r,u){var f,e=t;try{f=new XMLHttpRequest;f.onreadystatechange=function(){f.readyState==4&&(f.status==200?r(f,e):u(f.status))};f.open("GET",n,i);f.send()}catch(o){u(o)}},encodeBase64:function(n){if(!n)return n;var a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",l=[],i=[],o=0,c,e,s,r,u,f,t,v=n.length;do{c=n.charCodeAt(o++);e=n.charCodeAt(o++);s=n.charCodeAt(o++);t=0;r=c&255;u=c>>8;f=e&255;i[t++]=r>>2;i[t++]=(r&3)<<4|u>>4;i[t++]=(u&15)<<2|f>>6;i[t++]=f&63;if(!isNaN(e)){r=e>>8;u=s&255;f=s>>8;i[t++]=r>>2;i[t++]=(r&3)<<4|u>>4;i[t++]=(u&15)<<2|f>>6;i[t++]=f&63}if(isNaN(e))i[t-1]=64;else if(isNaN(s)){i[t-2]=64;i[t-1]=64}for(var h=0;h<t;h++)l.push(a.charAt(i[h]))}while(o<v);return l.join("")},getSessionStorage:function(){return p()},getLocalStorage:function(){if(!l){try{var t=window.localStorage}catch(i){t=n}l=new OfficeExt.SafeStorage(t)}return l},convertIntToCssHexColor:function(n){return"#"+(Number(n)+16777216).toString(16).slice(-6)},attachClickHandler:function(n,t){n.onclick=function(){t()};n.ontouchend=function(n){t();n.preventDefault()}},getQueryStringParamValue:function(n,i){var u=Function._validateParams(arguments,[{name:"queryString",type:String,mayBeNull:t},{name:"paramName",type:String,mayBeNull:t}]);if(u){OsfMsAjaxFactory.msAjaxDebug.trace("OSF_Outil_getQueryStringParamValue: Parameters cannot be null.");return""}var r=new RegExp("[\\?&]"+i+"=([^&#]*)","i");if(!r.test(n)){OsfMsAjaxFactory.msAjaxDebug.trace("OSF_Outil_getQueryStringParamValue: The parameter is not found.");return""}return r.exec(n)[1]},isiOS:function(){return window.navigator.userAgent.match(/(iPad|iPhone|iPod)/g)?i:t},isChrome:function(){return window.navigator.userAgent.indexOf("Chrome")>0&&!OSF.OUtil.isEdge()},isEdge:function(){return window.navigator.userAgent.indexOf("Edge")>0},isIE:function(){return window.navigator.userAgent.indexOf("Trident")>0},isFirefox:function(){return window.navigator.userAgent.indexOf("Firefox")>0},shallowCopy:function(n){var i=n.constructor();for(var t in n)n.hasOwnProperty(t)&&(i[t]=n[t]);return i},createObject:function(t){var r=n;if(t){r={};for(var u=t.length,i=0;i<u;i++)r[t[i].name]=t[i].value}return r},addClass:function(n,t){if(!OSF.OUtil.hasClass(n,t)){var i=n.getAttribute(e);i?n.setAttribute(e,i+" "+t):n.setAttribute(e,t)}},hasClass:function(n,t){var i=n.getAttribute(e);return i&&i.match(new RegExp("(\\s|^)"+t+"(\\s|$)"))},focusToFirstTabbable:function(u,e){var s,h=t,o,c=function(){h=i},l=function(n,t,i){if(t<0||t>n)return r;else if(t===0&&i)return r;else if(t===n-1&&!i)return r;return i?t-1:t+1};u=k(u);s=e?u.length-1:0;if(u.length===0)return n;while(!h&&s>=0&&s<u.length){o=u[s];window.focus();o.addEventListener(f,c);o.focus();o.removeEventListener(f,c);s=l(u.length,s,e);h||o!==document.activeElement||(h=i)}return h?o:n},focusToNextTabbable:function(u,e,o){var v,s,c=t,h,a=function(){c=i},y=function(n,t){for(var i=0;i<n.length;i++)if(n[i]===t)return i;return r},l=function(n,t,i){if(t<0||t>n)return r;else if(t===0&&i)return r;else if(t===n-1&&!i)return r;return i?t-1:t+1};u=k(u);v=y(u,e);s=l(u.length,v,o);if(s<0)return n;while(!c&&s>=0&&s<u.length){h=u[s];h.addEventListener(f,a);h.focus();h.removeEventListener(f,a);s=l(u.length,s,o);c||h!==document.activeElement||(c=i)}return c?h:n}}}();OSF.OUtil.Guid=function(){var n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];return{generateNewGuid:function(){for(var i="",r=+new Date,t=0;t<32&&r>0;t++){(t==8||t==12||t==16||t==20)&&(i+="-");i+=n[r%16];r=Math.floor(r/16)}for(;t<32;t++){(t==8||t==12||t==16||t==20)&&(i+="-");i+=n[Math.floor(Math.random()*16)]}return i}}}();window.OSF=OSF;OSF.OUtil.setNamespace("OSF",window);OSF.AppName={Unsupported:0,Excel:1,Word:2,PowerPoint:4,Outlook:8,ExcelWebApp:16,WordWebApp:32,OutlookWebApp:64,Project:128,AccessWebApp:256,PowerpointWebApp:512,ExcelIOS:1024,Sway:2048,WordIOS:4096,PowerPointIOS:8192,Access:16384,Lync:32768,OutlookIOS:65536,OneNoteWebApp:131072,OneNote:262144,ExcelWinRT:524288,WordWinRT:1048576,PowerpointWinRT:2097152,OutlookAndroid:4194304,OneNoteWinRT:8388608,ExcelAndroid:8388609,VisioWebApp:8388610};OSF.InternalPerfMarker={DataCoercionBegin:"Agave.HostCall.CoerceDataStart",DataCoercionEnd:"Agave.HostCall.CoerceDataEnd"};OSF.HostCallPerfMarker={IssueCall:"Agave.HostCall.IssueCall",ReceiveResponse:"Agave.HostCall.ReceiveResponse",RuntimeExceptionRaised:"Agave.HostCall.RuntimeExecptionRaised"};OSF.AgaveHostAction={Select:0,UnSelect:1,CancelDialog:2,InsertAgave:3,CtrlF6In:4,CtrlF6Exit:5,CtrlF6ExitShift:6,SelectWithError:7,NotifyHostError:8,RefreshAddinCommands:9,PageIsReady:10,TabIn:11,TabInShift:12,TabExit:13,TabExitShift:14,EscExit:15,F2Exit:16,ExitNoFocusable:17,ExitNoFocusableShift:18};OSF.SharedConstants={NotificationConversationIdSuffix:"_ntf"};OSF.DialogMessageType={DialogMessageReceived:0,DialogParentMessageReceived:1,DialogClosed:12006};OSF.OfficeAppContext=function(n,t,i,r,u,f,e,o,s,h,c,l,a,v,y,p,w,b,k,d,g,nt,tt){var it=this;it._id=n;it._appName=t;it._appVersion=i;it._appUILocale=r;it._dataLocale=u;it._docUrl=f;it._clientMode=e;it._settings=o;it._reason=s;it._osfControlType=h;it._eToken=c;it._correlationId=l;it._appInstanceId=a;it._touchEnabled=v;it._commerceAllowed=y;it._appMinorVersion=p;it._requirementMatrix=w;it._hostCustomMessage=b;it._hostFullVersion=k;it._isDialog=!1;it._clientWindowHeight=d;it._clientWindowWidth=g;it._addinName=nt;it._appDomains=tt;it.get_id=function(){return this._id};it.get_appName=function(){return this._appName};it.get_appVersion=function(){return this._appVersion};it.get_appUILocale=function(){return this._appUILocale};it.get_dataLocale=function(){return this._dataLocale};it.get_docUrl=function(){return this._docUrl};it.get_clientMode=function(){return this._clientMode};it.get_bindings=function(){return this._bindings};it.get_settings=function(){return this._settings};it.get_reason=function(){return this._reason};it.get_osfControlType=function(){return this._osfControlType};it.get_eToken=function(){return this._eToken};it.get_correlationId=function(){return this._correlationId};it.get_appInstanceId=function(){return this._appInstanceId};it.get_touchEnabled=function(){return this._touchEnabled};it.get_commerceAllowed=function(){return this._commerceAllowed};it.get_appMinorVersion=function(){return this._appMinorVersion};it.get_requirementMatrix=function(){return this._requirementMatrix};it.get_hostCustomMessage=function(){return this._hostCustomMessage};it.get_hostFullVersion=function(){return this._hostFullVersion};it.get_isDialog=function(){return this._isDialog};it.get_clientWindowHeight=function(){return this._clientWindowHeight};it.get_clientWindowWidth=function(){return this._clientWindowWidth};it.get_addinName=function(){return this._addinName};it.get_appDomains=function(){return this._appDomains}};OSF.OsfControlType={DocumentLevel:0,ContainerLevel:1};OSF.ClientMode={ReadOnly:0,ReadWrite:1};OSF.OUtil.setNamespace("Microsoft",window);OSF.OUtil.setNamespace("Office",Microsoft);OSF.OUtil.setNamespace("Client",Microsoft.Office);OSF.OUtil.setNamespace("WebExtension",Microsoft.Office);Microsoft.Office.WebExtension.InitializationReason={Inserted:"inserted",DocumentOpened:"documentOpened"};Microsoft.Office.WebExtension.ValueFormat={Unformatted:"unformatted",Formatted:"formatted"};Microsoft.Office.WebExtension.FilterType={All:"all"};Microsoft.Office.WebExtension.Parameters={BindingType:"bindingType",CoercionType:"coercionType",ValueFormat:"valueFormat",FilterType:"filterType",Columns:"columns",SampleData:"sampleData",GoToType:"goToType",SelectionMode:"selectionMode",Id:"id",PromptText:"promptText",ItemName:"itemName",FailOnCollision:"failOnCollision",StartRow:"startRow",StartColumn:"startColumn",RowCount:"rowCount",ColumnCount:"columnCount",Callback:"callback",AsyncContext:"asyncContext",Data:"data",Rows:"rows",OverwriteIfStale:"overwriteIfStale",FileType:"fileType",EventType:"eventType",Handler:"handler",SliceSize:"sliceSize",SliceIndex:"sliceIndex",ActiveView:"activeView",Status:"status",Xml:"xml",Namespace:"namespace",Prefix:"prefix",XPath:"xPath",Text:"text",ImageLeft:"imageLeft",ImageTop:"imageTop",ImageWidth:"imageWidth",ImageHeight:"imageHeight",TaskId:"taskId",FieldId:"fieldId",FieldValue:"fieldValue",ServerUrl:"serverUrl",ListName:"listName",ResourceId:"resourceId",ViewType:"viewType",ViewName:"viewName",GetRawValue:"getRawValue",CellFormat:"cellFormat",TableOptions:"tableOptions",TaskIndex:"taskIndex",ResourceIndex:"resourceIndex",CustomFieldId:"customFieldId",Url:"url",MessageHandler:"messageHandler",Width:"width",Height:"height",RequireHTTPs:"requireHTTPS",MessageToParent:"messageToParent",DisplayInIframe:"displayInIframe",MessageContent:"messageContent"};OSF.OUtil.setNamespace("DDA",OSF);OSF.DDA.DocumentMode={ReadOnly:1,ReadWrite:0};OSF.DDA.PropertyDescriptors={AsyncResultStatus:"AsyncResultStatus"};OSF.DDA.EventDescriptors={};OSF.DDA.ListDescriptors={};OSF.DDA.UI={};OSF.DDA.getXdmEventName=function(n,t){return t==Microsoft.Office.WebExtension.EventType.BindingSelectionChanged||t==Microsoft.Office.WebExtension.EventType.BindingDataChanged||t==Microsoft.Office.WebExtension.EventType.DataNodeDeleted||t==Microsoft.Office.WebExtension.EventType.DataNodeInserted||t==Microsoft.Office.WebExtension.EventType.DataNodeReplaced?n+"_"+t:t};OSF.DDA.MethodDispId={dispidMethodMin:64,dispidGetSelectedDataMethod:64,dispidSetSelectedDataMethod:65,dispidAddBindingFromSelectionMethod:66,dispidAddBindingFromPromptMethod:67,dispidGetBindingMethod:68,dispidReleaseBindingMethod:69,dispidGetBindingDataMethod:70,dispidSetBindingDataMethod:71,dispidAddRowsMethod:72,dispidClearAllRowsMethod:73,dispidGetAllBindingsMethod:74,dispidLoadSettingsMethod:75,dispidSaveSettingsMethod:76,dispidGetDocumentCopyMethod:77,dispidAddBindingFromNamedItemMethod:78,dispidAddColumnsMethod:79,dispidGetDocumentCopyChunkMethod:80,dispidReleaseDocumentCopyMethod:81,dispidNavigateToMethod:82,dispidGetActiveViewMethod:83,dispidGetDocumentThemeMethod:84,dispidGetOfficeThemeMethod:85,dispidGetFilePropertiesMethod:86,dispidClearFormatsMethod:87,dispidSetTableOptionsMethod:88,dispidSetFormatsMethod:89,dispidExecuteRichApiRequestMethod:93,dispidAppCommandInvocationCompletedMethod:94,dispidCloseContainerMethod:97,dispidAddDataPartMethod:128,dispidGetDataPartByIdMethod:129,dispidGetDataPartsByNamespaceMethod:130,dispidGetDataPartXmlMethod:131,dispidGetDataPartNodesMethod:132,dispidDeleteDataPartMethod:133,dispidGetDataNodeValueMethod:134,dispidGetDataNodeXmlMethod:135,dispidGetDataNodesMethod:136,dispidSetDataNodeValueMethod:137,dispidSetDataNodeXmlMethod:138,dispidAddDataNamespaceMethod:139,dispidGetDataUriByPrefixMethod:140,dispidGetDataPrefixByUriMethod:141,dispidGetDataNodeTextMethod:142,dispidSetDataNodeTextMethod:143,dispidMessageParentMethod:144,dispidSendMessageMethod:145,dispidMethodMax:145,dispidGetSelectedTaskMethod:110,dispidGetSelectedResourceMethod:111,dispidGetTaskMethod:112,dispidGetResourceFieldMethod:113,dispidGetWSSUrlMethod:114,dispidGetTaskFieldMethod:115,dispidGetProjectFieldMethod:116,dispidGetSelectedViewMethod:117,dispidGetTaskByIndexMethod:118,dispidGetResourceByIndexMethod:119,dispidSetTaskFieldMethod:120,dispidSetResourceFieldMethod:121,dispidGetMaxTaskIndexMethod:122,dispidGetMaxResourceIndexMethod:123,dispidCreateTaskMethod:124};OSF.DDA.EventDispId={dispidEventMin:0,dispidInitializeEvent:0,dispidSettingsChangedEvent:1,dispidDocumentSelectionChangedEvent:2,dispidBindingSelectionChangedEvent:3,dispidBindingDataChangedEvent:4,dispidDocumentOpenEvent:5,dispidDocumentCloseEvent:6,dispidActiveViewChangedEvent:7,dispidDocumentThemeChangedEvent:8,dispidOfficeThemeChangedEvent:9,dispidDialogMessageReceivedEvent:10,dispidDialogNotificationShownInAddinEvent:11,dispidDialogParentMessageReceivedEvent:12,dispidActivationStatusChangedEvent:32,dispidAppCommandInvokedEvent:39,dispidOlkItemSelectedChangedEvent:46,dispidTaskSelectionChangedEvent:56,dispidResourceSelectionChangedEvent:57,dispidViewSelectionChangedEvent:58,dispidDataNodeAddedEvent:60,dispidDataNodeReplacedEvent:61,dispidDataNodeDeletedEvent:62,dispidEventMax:63};OSF.DDA.ErrorCodeManager=function(){var n={};return{getErrorArgs:function(t){var i=n[t];if(i){i.name||(i.name=n[this.errorCodes.ooeInternalError].name);i.message||(i.message=n[this.errorCodes.ooeInternalError].message)}else i=n[this.errorCodes.ooeInternalError];return i},addErrorMessage:function(t,i){n[t]=i},errorCodes:{ooeSuccess:0,ooeChunkResult:1,ooeCoercionTypeNotSupported:1e3,ooeGetSelectionNotMatchDataType:1001,ooeCoercionTypeNotMatchBinding:1002,ooeInvalidGetRowColumnCounts:1003,ooeSelectionNotSupportCoercionType:1004,ooeInvalidGetStartRowColumn:1005,ooeNonUniformPartialGetNotSupported:1006,ooeGetDataIsTooLarge:1008,ooeFileTypeNotSupported:1009,ooeGetDataParametersConflict:1010,ooeInvalidGetColumns:1011,ooeInvalidGetRows:1012,ooeInvalidReadForBlankRow:1013,ooeUnsupportedDataObject:2e3,ooeCannotWriteToSelection:2001,ooeDataNotMatchSelection:2002,ooeOverwriteWorksheetData:2003,ooeDataNotMatchBindingSize:2004,ooeInvalidSetStartRowColumn:2005,ooeInvalidDataFormat:2006,ooeDataNotMatchCoercionType:2007,ooeDataNotMatchBindingType:2008,ooeSetDataIsTooLarge:2009,ooeNonUniformPartialSetNotSupported:2010,ooeInvalidSetColumns:2011,ooeInvalidSetRows:2012,ooeSetDataParametersConflict:2013,ooeCellDataAmountBeyondLimits:2014,ooeSelectionCannotBound:3e3,ooeBindingNotExist:3002,ooeBindingToMultipleSelection:3003,ooeInvalidSelectionForBindingType:3004,ooeOperationNotSupportedOnThisBindingType:3005,ooeNamedItemNotFound:3006,ooeMultipleNamedItemFound:3007,ooeInvalidNamedItemForBindingType:3008,ooeUnknownBindingType:3009,ooeOperationNotSupportedOnMatrixData:3010,ooeInvalidColumnsForBinding:3011,ooeSettingNameNotExist:4e3,ooeSettingsCannotSave:4001,ooeSettingsAreStale:4002,ooeOperationNotSupported:5e3,ooeInternalError:5001,ooeDocumentReadOnly:5002,ooeEventHandlerNotExist:5003,ooeInvalidApiCallInContext:5004,ooeShuttingDown:5005,ooeUnsupportedEnumeration:5007,ooeIndexOutOfRange:5008,ooeBrowserAPINotSupported:5009,ooeInvalidParam:5010,ooeRequestTimeout:5011,ooeTooManyIncompleteRequests:5100,ooeRequestTokenUnavailable:5101,ooeActivityLimitReached:5102,ooeCustomXmlNodeNotFound:6e3,ooeCustomXmlError:6100,ooeCustomXmlExceedQuota:6101,ooeCustomXmlOutOfDate:6102,ooeNoCapability:7e3,ooeCannotNavTo:7001,ooeSpecifiedIdNotExist:7002,ooeNavOutOfBound:7004,ooeElementMissing:8e3,ooeProtectedError:8001,ooeInvalidCellsValue:8010,ooeInvalidTableOptionValue:8011,ooeInvalidFormatValue:8012,ooeRowIndexOutOfRange:8020,ooeColIndexOutOfRange:8021,ooeFormatValueOutOfRange:8022,ooeCellFormatAmountBeyondLimits:8023,ooeMemoryFileLimit:11e3,ooeNetworkProblemRetrieveFile:11001,ooeInvalidSliceSize:11002,ooeInvalidCallback:11101,ooeInvalidWidth:12e3,ooeInvalidHeight:12001,ooeNavigationError:12002,ooeInvalidScheme:12003,ooeAppDomains:12004,ooeRequireHTTPS:12005,ooeWebDialogClosed:12006,ooeDialogAlreadyOpened:12007,ooeEndUserAllow:12008,ooeEndUserIgnore:12009,ooeNotUILessDialog:12010},initializeErrorMessages:function(t){n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCoercionTypeNotSupported]={name:t.L_InvalidCoercion,message:t.L_CoercionTypeNotSupported};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeGetSelectionNotMatchDataType]={name:t.L_DataReadError,message:t.L_GetSelectionNotSupported};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCoercionTypeNotMatchBinding]={name:t.L_InvalidCoercion,message:t.L_CoercionTypeNotMatchBinding};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidGetRowColumnCounts]={name:t.L_DataReadError,message:t.L_InvalidGetRowColumnCounts};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeSelectionNotSupportCoercionType]={name:t.L_DataReadError,message:t.L_SelectionNotSupportCoercionType};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidGetStartRowColumn]={name:t.L_DataReadError,message:t.L_InvalidGetStartRowColumn};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeNonUniformPartialGetNotSupported]={name:t.L_DataReadError,message:t.L_NonUniformPartialGetNotSupported};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeGetDataIsTooLarge]={name:t.L_DataReadError,message:t.L_GetDataIsTooLarge};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeFileTypeNotSupported]={name:t.L_DataReadError,message:t.L_FileTypeNotSupported};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeGetDataParametersConflict]={name:t.L_DataReadError,message:t.L_GetDataParametersConflict};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidGetColumns]={name:t.L_DataReadError,message:t.L_InvalidGetColumns};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidGetRows]={name:t.L_DataReadError,message:t.L_InvalidGetRows};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidReadForBlankRow]={name:t.L_DataReadError,message:t.L_InvalidReadForBlankRow};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeUnsupportedDataObject]={name:t.L_DataWriteError,message:t.L_UnsupportedDataObject};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCannotWriteToSelection]={name:t.L_DataWriteError,message:t.L_CannotWriteToSelection};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeDataNotMatchSelection]={name:t.L_DataWriteError,message:t.L_DataNotMatchSelection};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeOverwriteWorksheetData]={name:t.L_DataWriteError,message:t.L_OverwriteWorksheetData};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeDataNotMatchBindingSize]={name:t.L_DataWriteError,message:t.L_DataNotMatchBindingSize};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidSetStartRowColumn]={name:t.L_DataWriteError,message:t.L_InvalidSetStartRowColumn};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidDataFormat]={name:t.L_InvalidFormat,message:t.L_InvalidDataFormat};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeDataNotMatchCoercionType]={name:t.L_InvalidDataObject,message:t.L_DataNotMatchCoercionType};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeDataNotMatchBindingType]={name:t.L_InvalidDataObject,message:t.L_DataNotMatchBindingType};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeSetDataIsTooLarge]={name:t.L_DataWriteError,message:t.L_SetDataIsTooLarge};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeNonUniformPartialSetNotSupported]={name:t.L_DataWriteError,message:t.L_NonUniformPartialSetNotSupported};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidSetColumns]={name:t.L_DataWriteError,message:t.L_InvalidSetColumns};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidSetRows]={name:t.L_DataWriteError,message:t.L_InvalidSetRows};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeSetDataParametersConflict]={name:t.L_DataWriteError,message:t.L_SetDataParametersConflict};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeSelectionCannotBound]={name:t.L_BindingCreationError,message:t.L_SelectionCannotBound};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeBindingNotExist]={name:t.L_InvalidBindingError,message:t.L_BindingNotExist};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeBindingToMultipleSelection]={name:t.L_BindingCreationError,message:t.L_BindingToMultipleSelection};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidSelectionForBindingType]={name:t.L_BindingCreationError,message:t.L_InvalidSelectionForBindingType};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeOperationNotSupportedOnThisBindingType]={name:t.L_InvalidBindingOperation,message:t.L_OperationNotSupportedOnThisBindingType};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeNamedItemNotFound]={name:t.L_BindingCreationError,message:t.L_NamedItemNotFound};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeMultipleNamedItemFound]={name:t.L_BindingCreationError,message:t.L_MultipleNamedItemFound};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidNamedItemForBindingType]={name:t.L_BindingCreationError,message:t.L_InvalidNamedItemForBindingType};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeUnknownBindingType]={name:t.L_InvalidBinding,message:t.L_UnknownBindingType};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeOperationNotSupportedOnMatrixData]={name:t.L_InvalidBindingOperation,message:t.L_OperationNotSupportedOnMatrixData};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidColumnsForBinding]={name:t.L_InvalidBinding,message:t.L_InvalidColumnsForBinding};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeSettingNameNotExist]={name:t.L_ReadSettingsError,message:t.L_SettingNameNotExist};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeSettingsCannotSave]={name:t.L_SaveSettingsError,message:t.L_SettingsCannotSave};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeSettingsAreStale]={name:t.L_SettingsStaleError,message:t.L_SettingsAreStale};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeOperationNotSupported]={name:t.L_HostError,message:t.L_OperationNotSupported};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError]={name:t.L_InternalError,message:t.L_InternalErrorDescription};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeDocumentReadOnly]={name:t.L_PermissionDenied,message:t.L_DocumentReadOnly};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeEventHandlerNotExist]={name:t.L_EventRegistrationError,message:t.L_EventHandlerNotExist};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidApiCallInContext]={name:t.L_InvalidAPICall,message:t.L_InvalidApiCallInContext};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeShuttingDown]={name:t.L_ShuttingDown,message:t.L_ShuttingDown};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeUnsupportedEnumeration]={name:t.L_UnsupportedEnumeration,message:t.L_UnsupportedEnumerationMessage};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeIndexOutOfRange]={name:t.L_IndexOutOfRange,message:t.L_IndexOutOfRange};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeBrowserAPINotSupported]={name:t.L_APINotSupported,message:t.L_BrowserAPINotSupported};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeRequestTimeout]={name:t.L_APICallFailed,message:t.L_RequestTimeout};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeTooManyIncompleteRequests]={name:t.L_APICallFailed,message:t.L_TooManyIncompleteRequests};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeRequestTokenUnavailable]={name:t.L_APICallFailed,message:t.L_RequestTokenUnavailable};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeActivityLimitReached]={name:t.L_APICallFailed,message:t.L_ActivityLimitReached};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCustomXmlNodeNotFound]={name:t.L_InvalidNode,message:t.L_CustomXmlNodeNotFound};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCustomXmlError]={name:t.L_CustomXmlError,message:t.L_CustomXmlError};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCustomXmlExceedQuota]={name:t.L_CustomXmlExceedQuotaName,message:t.L_CustomXmlExceedQuotaMessage};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCustomXmlOutOfDate]={name:t.L_CustomXmlOutOfDateName,message:t.L_CustomXmlOutOfDateMessage};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeNoCapability]={name:t.L_PermissionDenied,message:t.L_NoCapability};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCannotNavTo]={name:t.L_CannotNavigateTo,message:t.L_CannotNavigateTo};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeSpecifiedIdNotExist]={name:t.L_SpecifiedIdNotExist,message:t.L_SpecifiedIdNotExist};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeNavOutOfBound]={name:t.L_NavOutOfBound,message:t.L_NavOutOfBound};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCellDataAmountBeyondLimits]={name:t.L_DataWriteReminder,message:t.L_CellDataAmountBeyondLimits};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeElementMissing]={name:t.L_MissingParameter,message:t.L_ElementMissing};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeProtectedError]={name:t.L_PermissionDenied,message:t.L_NoCapability};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidCellsValue]={name:t.L_InvalidValue,message:t.L_InvalidCellsValue};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidTableOptionValue]={name:t.L_InvalidValue,message:t.L_InvalidTableOptionValue};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidFormatValue]={name:t.L_InvalidValue,message:t.L_InvalidFormatValue};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeRowIndexOutOfRange]={name:t.L_OutOfRange,message:t.L_RowIndexOutOfRange};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeColIndexOutOfRange]={name:t.L_OutOfRange,message:t.L_ColIndexOutOfRange};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeFormatValueOutOfRange]={name:t.L_OutOfRange,message:t.L_FormatValueOutOfRange};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeCellFormatAmountBeyondLimits]={name:t.L_FormattingReminder,message:t.L_CellFormatAmountBeyondLimits};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeMemoryFileLimit]={name:t.L_MemoryLimit,message:t.L_CloseFileBeforeRetrieve};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeNetworkProblemRetrieveFile]={name:t.L_NetworkProblem,message:t.L_NetworkProblemRetrieveFile};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidSliceSize]={name:t.L_InvalidValue,message:t.L_SliceSizeNotSupported};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeDialogAlreadyOpened]={name:t.L_DisplayDialogError,message:t.L_DialogAlreadyOpened};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidWidth]={name:t.L_IndexOutOfRange,message:t.L_IndexOutOfRange};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidHeight]={name:t.L_IndexOutOfRange,message:t.L_IndexOutOfRange};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeNavigationError]={name:t.L_DisplayDialogError,message:t.L_NetworkProblem};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidScheme]={name:t.L_DialogNavigateError,message:t.L_DialogAddressNotTrusted};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeAppDomains]={name:t.L_DisplayDialogError,message:t.L_DialogAddressNotTrusted};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeRequireHTTPS]={name:t.L_DisplayDialogError,message:t.L_DialogAddressNotTrusted};n[OSF.DDA.ErrorCodeManager.errorCodes.ooeEndUserIgnore]={name:t.L_DisplayDialogError,message:t.L_UserClickIgnore}}}}();var OfficeExt;(function(n){var t;(function(n){var t=1.1,r=function(){function n(n){var t=this;t.isSetSupported=function(n,t){if(n==undefined)return!1;t==undefined&&(t=0);var u=this._setMap,i=u._sets;if(i.hasOwnProperty(n.toLowerCase())){var r=i[n.toLowerCase()];return r>0&&r>=t}else return!1};t._setMap=n;t.isSetSupported=t.isSetSupported.bind(t)}return n}();n.RequirementMatrix=r;var i=function(){function n(n){this._addSetMap=function(n){for(var t in n)this._sets[t]=n[t]};this._sets=n}return n}();n.DefaultSetRequirement=i;var s=function(n){__extends(i,n);function i(){n.call(this,{bindingevents:t,documentevents:t,excelapi:t,matrixbindings:t,matrixcoercion:t,selection:t,settings:t,tablebindings:t,tablecoercion:t,textbindings:t,textcoercion:t})}return i}(i);n.ExcelClientDefaultSetRequirement=s;var b=function(n){__extends(i,n);function i(){n.call(this);this._addSetMap({imagecoercion:t})}return i}(s);n.ExcelClientV1DefaultSetRequirement=b;var k=function(n){__extends(t,n);function t(){n.call(this,{mailbox:1.3})}return t}(i);n.OutlookClientDefaultSetRequirement=k;var o=function(n){__extends(i,n);function i(){n.call(this,{bindingevents:t,compressedfile:t,customxmlparts:t,documentevents:t,file:t,htmlcoercion:t,matrixbindings:t,matrixcoercion:t,ooxmlcoercion:t,pdffile:t,selection:t,settings:t,tablebindings:t,tablecoercion:t,textbindings:t,textcoercion:t,textfile:t,wordapi:t})}return i}(i);n.WordClientDefaultSetRequirement=o;var p=function(n){__extends(i,n);function i(){n.call(this);this._addSetMap({customxmlparts:1.2,wordapi:1.2,imagecoercion:t})}return i}(o);n.WordClientV1DefaultSetRequirement=p;var u=function(n){__extends(i,n);function i(){n.call(this,{activeview:t,compressedfile:t,documentevents:t,file:t,pdffile:t,selection:t,settings:t,textcoercion:t})}return i}(i);n.PowerpointClientDefaultSetRequirement=u;var w=function(n){__extends(i,n);function i(){n.call(this);this._addSetMap({imagecoercion:t})}return i}(u);n.PowerpointClientV1DefaultSetRequirement=w;var nt=function(n){__extends(i,n);function i(){n.call(this,{selection:t,textcoercion:t})}return i}(i);n.ProjectClientDefaultSetRequirement=nt;var tt=function(n){__extends(i,n);function i(){n.call(this,{bindingevents:t,dialogapi:t,documentevents:t,matrixbindings:t,matrixcoercion:t,selection:t,settings:t,tablebindings:t,tablecoercion:t,textbindings:t,textcoercion:t,file:t})}return i}(i);n.ExcelWebDefaultSetRequirement=tt;var d=function(n){__extends(i,n);function i(){n.call(this,{bindingevents:t,compressedfile:t,customxmlparts:t,dialogapi:t,documentevents:t,file:t,htmlcoercion:t,imagecoercion:t,matrixbindings:t,matrixcoercion:t,ooxmlcoercion:t,pdffile:t,selection:t,settings:t,tablebindings:t,tablecoercion:t,textbindings:t,textcoercion:t,textfile:t,wordapi:1.2})}return i}(i);n.WordWebDefaultSetRequirement=d;var g=function(n){__extends(i,n);function i(){n.call(this,{activeview:t,dialogapi:t,settings:t})}return i}(i);n.PowerpointWebDefaultSetRequirement=g;var e=function(n){__extends(t,n);function t(){n.call(this,{mailbox:1.3})}return t}(i);n.OutlookWebDefaultSetRequirement=e;var c=function(n){__extends(i,n);function i(){n.call(this,{activeview:t,documentevents:t,selection:t,settings:t,textcoercion:t})}return i}(i);n.SwayWebDefaultSetRequirement=c;var h=function(n){__extends(i,n);function i(){n.call(this,{bindingevents:t,partialtablebindings:t,settings:t,tablebindings:t,tablecoercion:t})}return i}(i);n.AccessWebDefaultSetRequirement=h;var y=function(n){__extends(i,n);function i(){n.call(this,{bindingevents:t,documentevents:t,matrixbindings:t,matrixcoercion:t,selection:t,settings:t,tablebindings:t,tablecoercion:t,textbindings:t,textcoercion:t})}return i}(i);n.ExcelIOSDefaultSetRequirement=y;var f=function(n){__extends(i,n);function i(){n.call(this,{bindingevents:t,compressedfile:t,customxmlparts:t,documentevents:t,file:t,htmlcoercion:t,matrixbindings:t,matrixcoercion:t,ooxmlcoercion:t,pdffile:t,selection:t,settings:t,tablebindings:t,tablecoercion:t,textbindings:t,textcoercion:t,textfile:t})}return i}(i);n.WordIOSDefaultSetRequirement=f;var l=function(n){__extends(t,n);function t(){n.call(this);this._addSetMap({customxmlparts:1.2,wordapi:1.2})}return t}(f);n.WordIOSV1DefaultSetRequirement=l;var a=function(n){__extends(i,n);function i(){n.call(this,{activeview:t,compressedfile:t,documentevents:t,file:t,pdffile:t,selection:t,settings:t,textcoercion:t})}return i}(i);n.PowerpointIOSDefaultSetRequirement=a;var v=function(n){__extends(i,n);function i(){n.call(this,{mailbox:t})}return i}(i);n.OutlookIOSDefaultSetRequirement=v;var it=function(){function n(){}n.initializeOsfDda=function(){OSF.OUtil.setNamespace("Requirement",OSF.DDA)};n.getDefaultRequirementMatrix=function(t){this.initializeDefaultSetMatrix();var u=undefined,e=t.get_requirementMatrix();if(e!=undefined&&e.length>0&&typeof JSON!="undefined"){var o=JSON.parse(t.get_requirementMatrix().toLowerCase());u=new r(new i(o))}else{var f=n.getClientFullVersionString(t);u=n.DefaultSetArrayMatrix!=undefined&&n.DefaultSetArrayMatrix[f]!=undefined?new r(n.DefaultSetArrayMatrix[f]):new r(new i({}))}return u};n.getClientFullVersionString=function(n){var r=n.get_appMinorVersion(),u="",i="",t=n.get_appName(),f=t==1024||t==4096||t==8192||t==65536;if(f&&n.get_appVersion()==1)i=t==4096&&r>=15?"16.00.01":"16.00";else if(n.get_appName()==64)i=n.get_appVersion();else{u=r<10?"0"+r:""+r;i=n.get_appVersion()+"."+u}return n.get_appName()+"-"+i};n.initializeDefaultSetMatrix=function(){n.DefaultSetArrayMatrix[n.Excel_RCLIENT_1600]=new s;n.DefaultSetArrayMatrix[n.Word_RCLIENT_1600]=new o;n.DefaultSetArrayMatrix[n.PowerPoint_RCLIENT_1600]=new u;n.DefaultSetArrayMatrix[n.Excel_RCLIENT_1601]=new b;n.DefaultSetArrayMatrix[n.Word_RCLIENT_1601]=new p;n.DefaultSetArrayMatrix[n.PowerPoint_RCLIENT_1601]=new w;n.DefaultSetArrayMatrix[n.Outlook_RCLIENT_1600]=new k;n.DefaultSetArrayMatrix[n.Excel_WAC_1600]=new tt;n.DefaultSetArrayMatrix[n.Word_WAC_1600]=new d;n.DefaultSetArrayMatrix[n.Outlook_WAC_1600]=new e;n.DefaultSetArrayMatrix[n.Outlook_WAC_1601]=new e;n.DefaultSetArrayMatrix[n.Project_RCLIENT_1600]=new nt;n.DefaultSetArrayMatrix[n.Access_WAC_1600]=new h;n.DefaultSetArrayMatrix[n.PowerPoint_WAC_1600]=new g;n.DefaultSetArrayMatrix[n.Excel_IOS_1600]=new y;n.DefaultSetArrayMatrix[n.SWAY_WAC_1600]=new c;n.DefaultSetArrayMatrix[n.Word_IOS_1600]=new f;n.DefaultSetArrayMatrix[n.Word_IOS_16001]=new l;n.DefaultSetArrayMatrix[n.PowerPoint_IOS_1600]=new a;n.DefaultSetArrayMatrix[n.Outlook_IOS_1600]=new v};n.Excel_RCLIENT_1600="1-16.00";n.Excel_RCLIENT_1601="1-16.01";n.Word_RCLIENT_1600="2-16.00";n.Word_RCLIENT_1601="2-16.01";n.PowerPoint_RCLIENT_1600="4-16.00";n.PowerPoint_RCLIENT_1601="4-16.01";n.Outlook_RCLIENT_1600="8-16.00";n.Excel_WAC_1600="16-16.00";n.Word_WAC_1600="32-16.00";n.Outlook_WAC_1600="64-16.00";n.Outlook_WAC_1601="64-16.01";n.Project_RCLIENT_1600="128-16.00";n.Access_WAC_1600="256-16.00";n.PowerPoint_WAC_1600="512-16.00";n.Excel_IOS_1600="1024-16.00";n.SWAY_WAC_1600="2048-16.00";n.Word_IOS_1600="4096-16.00";n.Word_IOS_16001="4096-16.00.01";n.PowerPoint_IOS_1600="8192-16.00";n.Outlook_IOS_1600="65536-16.00";n.DefaultSetArrayMatrix={};return n}();n.RequirementsMatrixFactory=it})(t=n.Requirement||(n.Requirement={}))})(OfficeExt||(OfficeExt={}));OfficeExt.Requirement.RequirementsMatrixFactory.initializeOsfDda();Microsoft.Office.WebExtension.ApplicationMode={WebEditor:"webEditor",WebViewer:"webViewer",Client:"client"};Microsoft.Office.WebExtension.DocumentMode={ReadOnly:"readOnly",ReadWrite:"readWrite"};OSF.NamespaceManager=function(){var t,n=!1;return{enableShortcut:function(){if(!n){window.Office?t=window.Office:OSF.OUtil.setNamespace("Office",window);window.Office=Microsoft.Office.WebExtension;n=!0}},disableShortcut:function(){if(n){t?window.Office=t:OSF.OUtil.unsetNamespace("Office",window);n=!1}}}}();OSF.NamespaceManager.enableShortcut();Microsoft.Office.WebExtension.useShortNamespace=function(n){n?OSF.NamespaceManager.enableShortcut():OSF.NamespaceManager.disableShortcut()};Microsoft.Office.WebExtension.select=function(n,t){var i;if(n&&typeof n=="string"){var r=n.indexOf("#");if(r!=-1){var o=n.substring(0,r),e=n.substring(r+1);switch(o){case"binding":case"bindings":e&&(i=new OSF.DDA.BindingPromise(e))}}}if(i){i.onFail=t;return i}else if(t){var u=typeof t;if(u=="function"){var f={};f[Microsoft.Office.WebExtension.Parameters.Callback]=t;OSF.DDA.issueAsyncResult(f,OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidApiCallInContext,OSF.DDA.ErrorCodeManager.getErrorArgs(OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidApiCallInContext))}else throw OSF.OUtil.formatString(Strings.OfficeOM.L_CallbackNotAFunction,u);}};OSF.DDA.Context=function(n,t,i,r,u){var f=this;OSF.OUtil.defineEnumerableProperties(f,{contentLanguage:{value:n.get_dataLocale()},displayLanguage:{value:n.get_appUILocale()},touchEnabled:{value:n.get_touchEnabled()},commerceAllowed:{value:n.get_commerceAllowed()}});i&&OSF.OUtil.defineEnumerableProperty(f,"license",{value:i});n.ui&&OSF.OUtil.defineEnumerableProperty(f,"ui",{value:n.ui});if(!n.get_isDialog()){t&&OSF.OUtil.defineEnumerableProperty(f,"document",{value:t});if(r){var o=r.displayName||"appOM";delete r.displayName;OSF.OUtil.defineEnumerableProperty(f,o,{value:r})}u&&OSF.OUtil.defineEnumerableProperty(f,"officeTheme",{get:function(){return u()}});var e=OfficeExt.Requirement.RequirementsMatrixFactory.getDefaultRequirementMatrix(n);OSF.OUtil.defineEnumerableProperty(f,"requirements",{value:e})}};OSF.DDA.OutlookContext=function(n,t,i,r,u){OSF.DDA.OutlookContext.uber.constructor.call(this,n,null,i,r,u);t&&OSF.OUtil.defineEnumerableProperty(this,"roamingSettings",{value:t})};OSF.OUtil.extend(OSF.DDA.OutlookContext,OSF.DDA.Context);OSF.DDA.OutlookAppOm=function(){};OSF.DDA.Document=function(n,t){var i;switch(n.get_clientMode()){case OSF.ClientMode.ReadOnly:i=Microsoft.Office.WebExtension.DocumentMode.ReadOnly;break;case OSF.ClientMode.ReadWrite:i=Microsoft.Office.WebExtension.DocumentMode.ReadWrite}t&&OSF.OUtil.defineEnumerableProperty(this,"settings",{value:t});OSF.OUtil.defineMutableProperties(this,{mode:{value:i},url:{value:n.get_docUrl()}})};OSF.DDA.JsomDocument=function(n,t,i){var r=this;OSF.DDA.JsomDocument.uber.constructor.call(r,n,i);t&&OSF.OUtil.defineEnumerableProperty(r,"bindings",{get:function(){return t}});var u=OSF.DDA.AsyncMethodNames;OSF.DDA.DispIdHost.addAsyncMethods(r,[u.GetSelectedDataAsync,u.SetSelectedDataAsync]);OSF.DDA.DispIdHost.addEventSupport(r,new OSF.EventDispatch([Microsoft.Office.WebExtension.EventType.DocumentSelectionChanged]))};OSF.OUtil.extend(OSF.DDA.JsomDocument,OSF.DDA.Document);OSF.OUtil.defineEnumerableProperty(Microsoft.Office.WebExtension,"context",{get:function(){var n;OSF&&OSF._OfficeAppFactory&&(n=OSF._OfficeAppFactory.getContext());return n}});OSF.DDA.License=function(n){OSF.OUtil.defineEnumerableProperty(this,"value",{value:n})};OSF.DDA.ApiMethodCall=function(n,t,i,r,u){var f=this,o=n.length,e=OSF.OUtil.delayExecutionAndCache(function(){return OSF.OUtil.formatString(Strings.OfficeOM.L_InvalidParameters,u)});f.verifyArguments=function(n,t){for(var u in n){var i=n[u],r=t[u];if(i["enum"])switch(typeof r){case"string":if(OSF.OUtil.listContainsValue(i["enum"],r))break;case"undefined":throw OSF.DDA.ErrorCodeManager.errorCodes.ooeUnsupportedEnumeration;default:throw e();}if(i.types&&!OSF.OUtil.listContainsValue(i.types,typeof r))throw e();}};f.extractRequiredArguments=function(t,i,r){if(t.length<o)throw OsfMsAjaxFactory.msAjaxError.parameterCount(Strings.OfficeOM.L_MissingRequiredArguments);for(var s=[],u=0;u<o;u++)s.push(t[u]);this.verifyArguments(n,s);var c={};for(u=0;u<o;u++){var f=n[u],h=s[u];if(f.verify){var l=f.verify(h,i,r);if(!l)throw e();}c[f.name]=h}return c},f.fillOptions=function(n,i,r,u){n=n||{};for(var o in t)if(!OSF.OUtil.listContainsKey(n,o)){var e=undefined,f=t[o];f.calculate&&i&&(e=f.calculate(i,r,u));e||f.defaultValue===undefined||(e=f.defaultValue);n[o]=e}return n};f.constructCallArgs=function(n,t,u,f){var e={};for(var h in n)e[h]=n[h];for(var s in t)e[s]=t[s];for(var o in i)e[o]=i[o](u,f);r&&(e=r(e,u,f));return e}};OSF.OUtil.setNamespace("AsyncResultEnum",OSF.DDA);OSF.DDA.AsyncResultEnum.Properties={Context:"Context",Value:"Value",Status:"Status",Error:"Error"};Microsoft.Office.WebExtension.AsyncResultStatus={Succeeded:"succeeded",Failed:"failed"};OSF.DDA.AsyncResultEnum.ErrorCode={Success:0,Failed:1};OSF.DDA.AsyncResultEnum.ErrorProperties={Name:"Name",Message:"Message",Code:"Code"};OSF.DDA.AsyncMethodNames={};OSF.DDA.AsyncMethodNames.addNames=function(n){for(var t in n){var i={};OSF.OUtil.defineEnumerableProperties(i,{id:{value:t},displayName:{value:n[t]}});OSF.DDA.AsyncMethodNames[t]=i}};OSF.DDA.AsyncMethodCall=function(n,t,i,r,u,f,e){var h="function",s=n.length,o=new OSF.DDA.ApiMethodCall(n,t,i,f,e);function c(n,i,r,u){if(n.length>s+2)throw OsfMsAjaxFactory.msAjaxError.parameterCount(Strings.OfficeOM.L_TooManyArguments);for(var f,e,l=n.length-1;l>=s;l--){var c=n[l];switch(typeof c){case"object":if(f)throw OsfMsAjaxFactory.msAjaxError.parameterCount(Strings.OfficeOM.L_TooManyOptionalObjects);else f=c;break;case h:if(e)throw OsfMsAjaxFactory.msAjaxError.parameterCount(Strings.OfficeOM.L_TooManyOptionalFunction);else e=c;break;default:throw OsfMsAjaxFactory.msAjaxError.argument(Strings.OfficeOM.L_InValidOptionalArgument);}}f=o.fillOptions(f,i,r,u);if(e)if(f[Microsoft.Office.WebExtension.Parameters.Callback])throw Strings.OfficeOM.L_RedundantCallbackSpecification;else f[Microsoft.Office.WebExtension.Parameters.Callback]=e;o.verifyArguments(t,f);return f}this.verifyAndExtractCall=function(n,t,i){var r=o.extractRequiredArguments(n,t,i),f=c(n,r,t,i);return o.constructCallArgs(r,f,t,i)};this.processResponse=function(n,t,i,f){var e;e=n==OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess?r?r(t,i,f):t:u?u(n,t):OSF.DDA.ErrorCodeManager.getErrorArgs(n);return e};this.getCallArgs=function(n){for(var t,u,r=n.length-1;r>=s;r--){var i=n[r];switch(typeof i){case"object":t=i;break;case h:u=i}}t=t||{};u&&(t[Microsoft.Office.WebExtension.Parameters.Callback]=u);return t}};OSF.DDA.AsyncMethodCallFactory=function(){return{manufacture:function(n){var i=n.supportedOptions?OSF.OUtil.createObject(n.supportedOptions):[],t=n.privateStateCallbacks?OSF.OUtil.createObject(n.privateStateCallbacks):[];return new OSF.DDA.AsyncMethodCall(n.requiredArguments||[],i,t,n.onSucceeded,n.onFailed,n.checkCallArgs,n.method.displayName)}}}();OSF.DDA.AsyncMethodCalls={};OSF.DDA.AsyncMethodCalls.define=function(n){OSF.DDA.AsyncMethodCalls[n.method.id]=OSF.DDA.AsyncMethodCallFactory.manufacture(n)};OSF.DDA.Error=function(n,t,i){OSF.OUtil.defineEnumerableProperties(this,{name:{value:n},message:{value:t},code:{value:i}})};OSF.DDA.AsyncResult=function(n,t){OSF.OUtil.defineEnumerableProperties(this,{value:{value:n[OSF.DDA.AsyncResultEnum.Properties.Value]},status:{value:t?Microsoft.Office.WebExtension.AsyncResultStatus.Failed:Microsoft.Office.WebExtension.AsyncResultStatus.Succeeded}});n[OSF.DDA.AsyncResultEnum.Properties.Context]&&OSF.OUtil.defineEnumerableProperty(this,"asyncContext",{value:n[OSF.DDA.AsyncResultEnum.Properties.Context]});t&&OSF.OUtil.defineEnumerableProperty(this,"error",{value:new OSF.DDA.Error(t[OSF.DDA.AsyncResultEnum.ErrorProperties.Name],t[OSF.DDA.AsyncResultEnum.ErrorProperties.Message],t[OSF.DDA.AsyncResultEnum.ErrorProperties.Code])})};OSF.DDA.issueAsyncResult=function(n,t,i){var f=n[Microsoft.Office.WebExtension.Parameters.Callback];if(f){var u={};u[OSF.DDA.AsyncResultEnum.Properties.Context]=n[Microsoft.Office.WebExtension.Parameters.AsyncContext];var r;if(t==OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess)u[OSF.DDA.AsyncResultEnum.Properties.Value]=i;else{r={};i=i||OSF.DDA.ErrorCodeManager.getErrorArgs(OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError);r[OSF.DDA.AsyncResultEnum.ErrorProperties.Code]=t||OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError;r[OSF.DDA.AsyncResultEnum.ErrorProperties.Name]=i.name||i;r[OSF.DDA.AsyncResultEnum.ErrorProperties.Message]=i.message||i}f(new OSF.DDA.AsyncResult(u,r))}};OSF.DDA.SyncMethodNames={};OSF.DDA.SyncMethodNames.addNames=function(n){for(var t in n){var i={};OSF.OUtil.defineEnumerableProperties(i,{id:{value:t},displayName:{value:n[t]}});OSF.DDA.SyncMethodNames[t]=i}};OSF.DDA.SyncMethodCall=function(n,t,i,r,u){var e=n.length,f=new OSF.DDA.ApiMethodCall(n,t,i,r,u);function o(n,i,r,u){if(n.length>e+1)throw OsfMsAjaxFactory.msAjaxError.parameterCount(Strings.OfficeOM.L_TooManyArguments);for(var o,c,s=n.length-1;s>=e;s--){var h=n[s];switch(typeof h){case"object":if(o)throw OsfMsAjaxFactory.msAjaxError.parameterCount(Strings.OfficeOM.L_TooManyOptionalObjects);else o=h;break;default:throw OsfMsAjaxFactory.msAjaxError.argument(Strings.OfficeOM.L_InValidOptionalArgument);}}o=f.fillOptions(o,i,r,u);f.verifyArguments(t,o);return o}this.verifyAndExtractCall=function(n,t,i){var r=f.extractRequiredArguments(n,t,i),e=o(n,r,t,i);return f.constructCallArgs(r,e,t,i)}};OSF.DDA.SyncMethodCallFactory=function(){return{manufacture:function(n){var t=n.supportedOptions?OSF.OUtil.createObject(n.supportedOptions):[];return new OSF.DDA.SyncMethodCall(n.requiredArguments||[],t,n.privateStateCallbacks,n.checkCallArgs,n.method.displayName)}}}();OSF.DDA.SyncMethodCalls={};OSF.DDA.SyncMethodCalls.define=function(n){OSF.DDA.SyncMethodCalls[n.method.id]=OSF.DDA.SyncMethodCallFactory.manufacture(n)};OSF.DDA.ListType=function(){var n={};return{setListType:function(t,i){n[t]=i},isListType:function(t){return OSF.OUtil.listContainsKey(n,t)},getDescriptor:function(t){return n[t]}}}();OSF.DDA.HostParameterMap=function(n,t){var l="fromHost",i=this,o="toHost",f=l,a="sourceData",u="self",r={};r[Microsoft.Office.WebExtension.Parameters.Data]={toHost:function(n){if(n!=null&&n.rows!==undefined){var t={};t[OSF.DDA.TableDataProperties.TableRows]=n.rows;t[OSF.DDA.TableDataProperties.TableHeaders]=n.headers;n=t}return n},fromHost:function(n){return n}};r[Microsoft.Office.WebExtension.Parameters.SampleData]=r[Microsoft.Office.WebExtension.Parameters.Data];function e(i,u){var a=i?{}:undefined;for(var h in i){var s=i[h],o;if(OSF.DDA.ListType.isListType(h)){o=[];for(var v in s)o.push(e(s[v],u))}else if(OSF.OUtil.listContainsKey(r,h))o=r[h][u](s);else if(u==f&&n.preserveNesting(h))o=e(s,u);else{var c=t[h];if(c){var l=c[u];if(l){o=l[s];o===undefined&&(o=s)}}else o=s}a[h]=o}return a}function c(i,r){var s;for(var f in r){var e;e=n.isComplexType(f)?c(i,t[f][o]):i[f];if(e!=undefined){s||(s={});var h=r[f];h==u&&(h=f);s[h]=n.pack(f,e)}}return s}function s(i,r,e){e||(e={});for(var h in r){var l=r[h],o;if(l==u)o=i;else if(l==a){e[h]=i.toArray();continue}else o=i[l];if(o===null||o===undefined)e[h]=undefined;else{o=n.unpack(h,o);var c;if(n.isComplexType(h)){c=t[h][f];n.preserveNesting(h)?e[h]=s(o,c):s(o,c,e)}else if(OSF.DDA.ListType.isListType(h)){c={};var p=OSF.DDA.ListType.getDescriptor(h);c[p]=u;var v=new Array(o.length);for(var y in o)v[y]=s(o[y],c);e[h]=v}else e[h]=o}}return e}function h(n,i,r){var f=t[n][r],u;if(r=="toHost"){var h=e(i,r);u=c(h,f)}else if(r==l){var o=s(i,f);u=e(o,r)}return u}t||(t={});i.addMapping=function(n,i){var e,s;if(i.map){e=i.map;s={};for(var c in e){var l=e[c];l==u&&(l=c);s[l]=c}}else{e=i.toHost;s=i.fromHost}var r=t[n];if(r){var h=r[o];for(var v in h)e[v]=h[v];h=r[f];for(var a in h)s[a]=h[a]}else r=t[n]={};r[o]=e;r[f]=s};i.toHost=function(n,t){return h(n,t,o)};i.fromHost=function(n,t){return h(n,t,f)};i.self=u;i.sourceData=a;i.addComplexType=function(t){n.addComplexType(t)};i.getDynamicType=function(t){return n.getDynamicType(t)};i.setDynamicType=function(t,i){n.setDynamicType(t,i)};i.dynamicTypes=r;i.doMapValues=function(n,t){return e(n,t)}};OSF.DDA.SpecialProcessor=function(n,t){var i=this;i.addComplexType=function(t){n.push(t)};i.getDynamicType=function(n){return t[n]};i.setDynamicType=function(n,i){t[n]=i};i.isComplexType=function(t){return OSF.OUtil.listContainsValue(n,t)};i.isDynamicType=function(n){return OSF.OUtil.listContainsKey(t,n)};i.preserveNesting=function(n){var t=[];OSF.DDA.PropertyDescriptors&&t.push(OSF.DDA.PropertyDescriptors.Subset);OSF.DDA.DataNodeEventProperties&&(t=t.concat([OSF.DDA.DataNodeEventProperties.OldNode,OSF.DDA.DataNodeEventProperties.NewNode,OSF.DDA.DataNodeEventProperties.NextSiblingNode]));return OSF.OUtil.listContainsValue(t,n)};i.pack=function(n,i){var r;r=this.isDynamicType(n)?t[n].toHost(i):i;return r};i.unpack=function(n,i){var r;r=this.isDynamicType(n)?t[n].fromHost(i):i;return r}};OSF.DDA.getDecoratedParameterMap=function(n,t){var i=new OSF.DDA.HostParameterMap(n),f=i.self;function r(n){var i=null;if(n){i={};for(var r=n.length,t=0;t<r;t++)i[n[t].name]=n[t].value}return i}i.define=function(n){var t={},u=r(n.toHost);if(n.invertible)t.map=u;else if(n.canonical)t.toHost=t.fromHost=u;else{t.toHost=u;t.fromHost=r(n.fromHost)}i.addMapping(n.type,t);n.isComplexType&&i.addComplexType(n.type)};for(var u in t)i.define(t[u]);return i};OSF.OUtil.setNamespace("DispIdHost",OSF.DDA);OSF.DDA.DispIdHost.Methods={InvokeMethod:"invokeMethod",AddEventHandler:"addEventHandler",RemoveEventHandler:"removeEventHandler",OpenDialog:"openDialog",CloseDialog:"closeDialog",MessageParent:"messageParent",SendMessage:"sendMessage"};OSF.DDA.DispIdHost.Delegates={ExecuteAsync:"executeAsync",RegisterEventAsync:"registerEventAsync",UnregisterEventAsync:"unregisterEventAsync",ParameterMap:"parameterMap",OpenDialog:"openDialog",CloseDialog:"closeDialog",MessageParent:"messageParent",SendMessage:"sendMessage"};OSF.DDA.DispIdHost.Facade=function(n,t){var s=null,f=this,r={},u=OSF.DDA.AsyncMethodNames,i=OSF.DDA.MethodDispId,c={GoToByIdAsync:i.dispidNavigateToMethod,GetSelectedDataAsync:i.dispidGetSelectedDataMethod,SetSelectedDataAsync:i.dispidSetSelectedDataMethod,GetDocumentCopyChunkAsync:i.dispidGetDocumentCopyChunkMethod,ReleaseDocumentCopyAsync:i.dispidReleaseDocumentCopyMethod,GetDocumentCopyAsync:i.dispidGetDocumentCopyMethod,AddFromSelectionAsync:i.dispidAddBindingFromSelectionMethod,AddFromPromptAsync:i.dispidAddBindingFromPromptMethod,AddFromNamedItemAsync:i.dispidAddBindingFromNamedItemMethod,GetAllAsync:i.dispidGetAllBindingsMethod,GetByIdAsync:i.dispidGetBindingMethod,ReleaseByIdAsync:i.dispidReleaseBindingMethod,GetDataAsync:i.dispidGetBindingDataMethod,SetDataAsync:i.dispidSetBindingDataMethod,AddRowsAsync:i.dispidAddRowsMethod,AddColumnsAsync:i.dispidAddColumnsMethod,DeleteAllDataValuesAsync:i.dispidClearAllRowsMethod,RefreshAsync:i.dispidLoadSettingsMethod,SaveAsync:i.dispidSaveSettingsMethod,GetActiveViewAsync:i.dispidGetActiveViewMethod,GetFilePropertiesAsync:i.dispidGetFilePropertiesMethod,GetOfficeThemeAsync:i.dispidGetOfficeThemeMethod,GetDocumentThemeAsync:i.dispidGetDocumentThemeMethod,ClearFormatsAsync:i.dispidClearFormatsMethod,SetTableOptionsAsync:i.dispidSetTableOptionsMethod,SetFormatsAsync:i.dispidSetFormatsMethod,ExecuteRichApiRequestAsync:i.dispidExecuteRichApiRequestMethod,AppCommandInvocationCompletedAsync:i.dispidAppCommandInvocationCompletedMethod,CloseContainerAsync:i.dispidCloseContainerMethod,AddDataPartAsync:i.dispidAddDataPartMethod,GetDataPartByIdAsync:i.dispidGetDataPartByIdMethod,GetDataPartsByNameSpaceAsync:i.dispidGetDataPartsByNamespaceMethod,GetPartXmlAsync:i.dispidGetDataPartXmlMethod,GetPartNodesAsync:i.dispidGetDataPartNodesMethod,DeleteDataPartAsync:i.dispidDeleteDataPartMethod,GetNodeValueAsync:i.dispidGetDataNodeValueMethod,GetNodeXmlAsync:i.dispidGetDataNodeXmlMethod,GetRelativeNodesAsync:i.dispidGetDataNodesMethod,SetNodeValueAsync:i.dispidSetDataNodeValueMethod,SetNodeXmlAsync:i.dispidSetDataNodeXmlMethod,AddDataPartNamespaceAsync:i.dispidAddDataNamespaceMethod,GetDataPartNamespaceAsync:i.dispidGetDataUriByPrefixMethod,GetDataPartPrefixAsync:i.dispidGetDataPrefixByUriMethod,GetNodeTextAsync:i.dispidGetDataNodeTextMethod,SetNodeTextAsync:i.dispidSetDataNodeTextMethod,GetSelectedTask:i.dispidGetSelectedTaskMethod,GetTask:i.dispidGetTaskMethod,GetWSSUrl:i.dispidGetWSSUrlMethod,GetTaskField:i.dispidGetTaskFieldMethod,GetSelectedResource:i.dispidGetSelectedResourceMethod,GetResourceField:i.dispidGetResourceFieldMethod,GetProjectField:i.dispidGetProjectFieldMethod,GetSelectedView:i.dispidGetSelectedViewMethod,GetTaskByIndex:i.dispidGetTaskByIndexMethod,GetResourceByIndex:i.dispidGetResourceByIndexMethod,SetTaskField:i.dispidSetTaskFieldMethod,SetResourceField:i.dispidSetResourceFieldMethod,GetMaxTaskIndex:i.dispidGetMaxTaskIndexMethod,GetMaxResourceIndex:i.dispidGetMaxResourceIndexMethod,CreateTask:i.dispidCreateTaskMethod};for(var e in c)u[e]&&(r[u[e].id]=c[e]);u=OSF.DDA.SyncMethodNames;i=OSF.DDA.MethodDispId;var l={MessageParent:i.dispidMessageParentMethod,SendMessage:i.dispidSendMessageMethod};for(var e in l)u[e]&&(r[u[e].id]=l[e]);u=Microsoft.Office.WebExtension.EventType;i=OSF.DDA.EventDispId;var a={SettingsChanged:i.dispidSettingsChangedEvent,DocumentSelectionChanged:i.dispidDocumentSelectionChangedEvent,BindingSelectionChanged:i.dispidBindingSelectionChangedEvent,BindingDataChanged:i.dispidBindingDataChangedEvent,ActiveViewChanged:i.dispidActiveViewChangedEvent,OfficeThemeChanged:i.dispidOfficeThemeChangedEvent,DocumentThemeChanged:i.dispidDocumentThemeChangedEvent,AppCommandInvoked:i.dispidAppCommandInvokedEvent,DialogMessageReceived:i.dispidDialogMessageReceivedEvent,DialogParentMessageReceived:i.dispidDialogParentMessageReceivedEvent,OlkItemSelectedChanged:i.dispidOlkItemSelectedChangedEvent,TaskSelectionChanged:i.dispidTaskSelectionChangedEvent,ResourceSelectionChanged:i.dispidResourceSelectionChangedEvent,ViewSelectionChanged:i.dispidViewSelectionChangedEvent,DataNodeInserted:i.dispidDataNodeAddedEvent,DataNodeReplaced:i.dispidDataNodeReplacedEvent,DataNodeDeleted:i.dispidDataNodeDeletedEvent};for(var h in a)u[h]&&(r[u[h]]=a[h]);function o(n,t,i,r){if(typeof n=="number"){r||(r=t.getCallArgs(i));OSF.DDA.issueAsyncResult(r,n,OSF.DDA.ErrorCodeManager.getErrorArgs(n))}else throw n;}f[OSF.DDA.DispIdHost.Methods.InvokeMethod]=function(i,u,f,e){var h;try{var l=i.id,v=OSF.DDA.AsyncMethodCalls[l];h=v.verifyAndExtractCall(u,f,e);var y=r[l],b=n(l),c=s;window.Excel&&window.Office.context.requirements.isSetSupported("RedirectV1Api")&&(window.Excel._RedirectV1APIs=!0);if(window.Excel&&window.Excel._RedirectV1APIs&&(c=window.Excel._V1APIMap[l])){c.preprocess&&(h=c.preprocess(h));var p=new window.Excel.RequestContext,w=c.call(p,h);p.sync().then(function(){var n=w.value,t=n.status;delete n.status;delete n["@odata.type"];c.postprocess&&(n=c.postprocess(n,h));t!=0&&(n=OSF.DDA.ErrorCodeManager.getErrorArgs(t));OSF.DDA.issueAsyncResult(h,t,n)})["catch"](function(){OSF.DDA.issueAsyncResult(h,OSF.DDA.ErrorCodeManager.errorCodes.ooeFailure,s)})}else{var a;a=t.toHost?t.toHost(y,h):h;b[OSF.DDA.DispIdHost.Delegates.ExecuteAsync]({dispId:y,hostCallArgs:a,onCalling:function(){},onReceiving:function(){},onComplete:function(n,i){var r;r=n==OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess?t.fromHost?t.fromHost(y,i):i:i;var u=v.processResponse(n,r,f,h);OSF.DDA.issueAsyncResult(h,n,u)}})}}catch(k){o(k,v,u,h)}};f[OSF.DDA.DispIdHost.Methods.AddEventHandler]=function(i,u,f){var s,e,l;function a(n){if(n==OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess){var i=u.addEventHandler(e,l);i||(n=OSF.DDA.ErrorCodeManager.errorCodes.ooeEventHandlerAdditionFailed)}var t;n!=OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess&&(t=OSF.DDA.ErrorCodeManager.getErrorArgs(n));OSF.DDA.issueAsyncResult(s,n,t)}try{var h=OSF.DDA.AsyncMethodCalls[OSF.DDA.AsyncMethodNames.AddHandlerAsync.id];s=h.verifyAndExtractCall(i,f,u);e=s[Microsoft.Office.WebExtension.Parameters.EventType];l=s[Microsoft.Office.WebExtension.Parameters.Handler];if(u.getEventHandlerCount(e)==0){var c=r[e],v=n(e)[OSF.DDA.DispIdHost.Delegates.RegisterEventAsync];v({eventType:e,dispId:c,targetId:f.id||"",onCalling:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.IssueCall)},onReceiving:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.ReceiveResponse)},onComplete:a,onEvent:function(n){var i=t.fromHost(c,n);u.fireEvent(OSF.DDA.OMFactory.manufactureEventArgs(e,f,i))}})}else a(OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess)}catch(y){o(y,h,i,s)}};f[OSF.DDA.DispIdHost.Methods.RemoveEventHandler]=function(t,i,u){var e,f,l;function a(n){var t;n!=OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess&&(t=OSF.DDA.ErrorCodeManager.getErrorArgs(n));OSF.DDA.issueAsyncResult(e,n,t)}try{var v=OSF.DDA.AsyncMethodCalls[OSF.DDA.AsyncMethodNames.RemoveHandlerAsync.id];e=v.verifyAndExtractCall(t,u,i);f=e[Microsoft.Office.WebExtension.Parameters.EventType];l=e[Microsoft.Office.WebExtension.Parameters.Handler];var c,h;if(l===s){h=i.clearEventHandlers(f);c=OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess}else{h=i.removeEventHandler(f,l);c=h?OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess:OSF.DDA.ErrorCodeManager.errorCodes.ooeEventHandlerNotExist}if(h&&i.getEventHandlerCount(f)==0){var p=r[f],y=n(f)[OSF.DDA.DispIdHost.Delegates.UnregisterEventAsync];y({eventType:f,dispId:p,targetId:u.id||"",onCalling:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.IssueCall)},onReceiving:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.ReceiveResponse)},onComplete:a})}else a(c)}catch(w){o(w,v,t,e)}};f[OSF.DDA.DispIdHost.Methods.OpenDialog]=function(i,u,f){var h,v,e=Microsoft.Office.WebExtension.EventType.DialogMessageReceived,c=Microsoft.Office.WebExtension.EventType.DialogEventReceived;function y(n){var i;if(n!=OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess)i=OSF.DDA.ErrorCodeManager.getErrorArgs(n);else{var t={};t[Microsoft.Office.WebExtension.Parameters.Id]=v;t[Microsoft.Office.WebExtension.Parameters.Data]=u;var i=l.processResponse(n,t,f,h);OSF.DialogShownStatus.hasDialogShown=!0;u.clearEventHandlers(e);u.clearEventHandlers(c)}OSF.DDA.issueAsyncResult(h,n,i)}try{(e==undefined||c==undefined)&&y(OSF.DDA.ErrorCodeManager.ooeOperationNotSupported);if(OSF.DDA.AsyncMethodNames.DisplayDialogAsync==s){y(OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError);return}var l=OSF.DDA.AsyncMethodCalls[OSF.DDA.AsyncMethodNames.DisplayDialogAsync.id];h=l.verifyAndExtractCall(i,f,u);var p=r[e],a=n(e),w=a[OSF.DDA.DispIdHost.Delegates.OpenDialog]!=undefined?a[OSF.DDA.DispIdHost.Delegates.OpenDialog]:a[OSF.DDA.DispIdHost.Delegates.RegisterEventAsync];v=JSON.stringify(h);w({eventType:e,dispId:p,targetId:v,onCalling:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.IssueCall)},onReceiving:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.ReceiveResponse)},onComplete:y,onEvent:function(n){var s=t.fromHost(p,n),r=OSF.DDA.OMFactory.manufactureEventArgs(e,f,s);if(r.type==c){var o=OSF.DDA.ErrorCodeManager.getErrorArgs(r.error),i={};i[OSF.DDA.AsyncResultEnum.ErrorProperties.Code]=status||OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError;i[OSF.DDA.AsyncResultEnum.ErrorProperties.Name]=o.name||o;i[OSF.DDA.AsyncResultEnum.ErrorProperties.Message]=o.message||o;r.error=new OSF.DDA.Error(i[OSF.DDA.AsyncResultEnum.ErrorProperties.Name],i[OSF.DDA.AsyncResultEnum.ErrorProperties.Message],i[OSF.DDA.AsyncResultEnum.ErrorProperties.Code])}u.fireOrQueueEvent(r);if(s[OSF.DDA.PropertyDescriptors.MessageType]==OSF.DialogMessageType.DialogClosed){u.clearEventHandlers(e);u.clearEventHandlers(c);u.clearEventHandlers(Microsoft.Office.WebExtension.EventType.DialogParentMessageReceived);OSF.DialogShownStatus.hasDialogShown=!1}}})}catch(b){o(b,l,i,h)}};f[OSF.DDA.DispIdHost.Methods.CloseDialog]=function(t,i,u,f){var l,e,a,s=OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess;function y(n){s=n;OSF.DialogShownStatus.hasDialogShown=!1}try{var c=OSF.DDA.AsyncMethodCalls[OSF.DDA.AsyncMethodNames.CloseAsync.id];l=c.verifyAndExtractCall(t,f,u);e=Microsoft.Office.WebExtension.EventType.DialogMessageReceived;a=Microsoft.Office.WebExtension.EventType.DialogEventReceived;u.clearEventHandlers(e);u.clearEventHandlers(a);var p=r[e],h=n(e),v=h[OSF.DDA.DispIdHost.Delegates.CloseDialog]!=undefined?h[OSF.DDA.DispIdHost.Delegates.CloseDialog]:h[OSF.DDA.DispIdHost.Delegates.UnregisterEventAsync];v({eventType:e,dispId:p,targetId:i,onCalling:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.IssueCall)},onReceiving:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.ReceiveResponse)},onComplete:y})}catch(w){o(w,c,t,l)}if(s!=OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess)throw OSF.OUtil.formatString(Strings.OfficeOM.L_FunctionCallFailed,OSF.DDA.AsyncMethodNames.CloseAsync.displayName,s);};f[OSF.DDA.DispIdHost.Methods.MessageParent]=function(t,i){var o={},s=OSF.DDA.SyncMethodCalls[OSF.DDA.SyncMethodNames.MessageParent.id],h=s.verifyAndExtractCall(t,i,o),u=n(OSF.DDA.SyncMethodNames.MessageParent.id),f=u[OSF.DDA.DispIdHost.Delegates.MessageParent],e=r[OSF.DDA.SyncMethodNames.MessageParent.id];return f({dispId:e,hostCallArgs:h,onCalling:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.IssueCall)},onReceiving:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.ReceiveResponse)}})};f[OSF.DDA.DispIdHost.Methods.SendMessage]=function(t,i,u){var s={},h=OSF.DDA.SyncMethodCalls[OSF.DDA.SyncMethodNames.SendMessage.id],c=h.verifyAndExtractCall(t,u,s),f=n(OSF.DDA.SyncMethodNames.SendMessage.id),e=f[OSF.DDA.DispIdHost.Delegates.SendMessage],o=r[OSF.DDA.SyncMethodNames.SendMessage.id];return e({dispId:o,hostCallArgs:c,onCalling:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.IssueCall)},onReceiving:function(){OSF.OUtil.writeProfilerMark(OSF.HostCallPerfMarker.ReceiveResponse)}})}};OSF.DDA.DispIdHost.addAsyncMethods=function(n,t,i){for(var f in t){var u=t[f],r=u.displayName;n[r]||OSF.OUtil.defineEnumerableProperty(n,r,{value:function(t){return function(){var r=OSF._OfficeAppFactory.getHostFacade()[OSF.DDA.DispIdHost.Methods.InvokeMethod];r(t,arguments,n,i)}}(u)})}};OSF.DDA.DispIdHost.addEventSupport=function(n,t){var r=OSF.DDA.AsyncMethodNames.AddHandlerAsync.displayName,i=OSF.DDA.AsyncMethodNames.RemoveHandlerAsync.displayName;n[r]||OSF.OUtil.defineEnumerableProperty(n,r,{value:function(){var i=OSF._OfficeAppFactory.getHostFacade()[OSF.DDA.DispIdHost.Methods.AddEventHandler];i(arguments,t,n)}});n[i]||OSF.OUtil.defineEnumerableProperty(n,i,{value:function(){var i=OSF._OfficeAppFactory.getHostFacade()[OSF.DDA.DispIdHost.Methods.RemoveEventHandler];i(arguments,t,n)}})};OSF.ShowWindowDialogParameterKeys={Url:"url",Width:"width",Height:"height",DisplayInIframe:"displayInIframe"};OSF.HostThemeButtonStyleKeys={ButtonBorderColor:"buttonBorderColor",ButtonBackgroundColor:"buttonBackgroundColor"};var OfficeExt;(function(n){var t;(function(n){var r="^https://[a-zA-Z0-9]+.(officeapps.live|officeapps-df.live|partner.officewebapps).com/";function u(n,t){return OSF.OUtil.parseInfoFromWindowName(n,t,OSF.WindowNameItemKeys.AppContext)}n.parseAppContextFromWindowName=u;function t(n){if(typeof JSON!="undefined")try{return JSON.stringify(n)}catch(t){}return""}n.serializeObjectToString=t;function i(){return new RegExp(r).test(OSF.getClientEndPoint()._targetUrl)}n.isHostTrusted=i})(t=n.WACUtils||(n.WACUtils={}))})(OfficeExt||(OfficeExt={}));OSF.OUtil.setNamespace("Microsoft",window);OSF.OUtil.setNamespace("Office",Microsoft);OSF.OUtil.setNamespace("Common",Microsoft.Office);OSF.SerializerVersion={MsAjax:0,Browser:1};var OfficeExt;(function(n){function t(){return!0}n.appSpecificCheckOrigin=t})(OfficeExt||(OfficeExt={}));(function(n){"use strict";var h=new RegExp('"(\\\\.|[^"\\\\])*"',"g"),c=new RegExp("\\b(true|false|null)\\b","g"),s=new RegExp("-?(0|([1-9]\\d*))(\\.\\d+)?([eE][+-]?\\d+)?","g"),o=new RegExp("[^{:,\\[\\s](?=\\s*\\[)"),f=new RegExp("[^\\s\\[\\]{}:,]"),t="Cannot deserialize. The data does not correspond to valid JSON.";function u(n,t,i){n.addEventListener?n.addEventListener(t,i,!1):n.attachEvent&&n.attachEvent("on"+t,i)}function r(){return OsfMsAjaxFactory.msAjaxSerializer?OsfMsAjaxFactory.msAjaxSerializer:null}function e(i,r,u){var e;if(!r)return u(i);if(n.JSON&&n.JSON.parse)return n.JSON.parse(i);e=i.replace(h,"[]");e=e.replace(c,"[]");e=e.replace(s,"[]");if(o.test(e))throw t;if(f.test(e))throw t;try{eval("("+i+")")}catch(l){throw t;}}function i(){var n=r(),t;if(n===null||typeof n.deserialize!="function")return!1;if(n.__patchVersion>=1)return!0;t=n.deserialize;n.deserialize=function(n){return e(n,!0,t)};n.__patchVersion=1;return!0}i()||u(n,"load",function(){i()})})(window);Microsoft.Office.Common.InvokeType={async:0,sync:1,asyncRegisterEvent:2,asyncUnregisterEvent:3,syncRegisterEvent:4,syncUnregisterEvent:5};Microsoft.Office.Common.InvokeResultCode={noError:0,errorInRequest:-1,errorHandlingRequest:-2,errorInResponse:-3,errorHandlingResponse:-4,errorHandlingRequestAccessDenied:-5,errorHandlingMethodCallTimedout:-6};Microsoft.Office.Common.MessageType={request:0,response:1};Microsoft.Office.Common.ActionType={invoke:0,registerEvent:1,unregisterEvent:2};Microsoft.Office.Common.ResponseType={forCalling:0,forEventing:1};Microsoft.Office.Common.MethodObject=function(n,t,i){this._method=n;this._invokeType=t;this._blockingOthers=i};Microsoft.Office.Common.MethodObject.prototype={getMethod:function(){return this._method},getInvokeType:function(){return this._invokeType},getBlockingFlag:function(){return this._blockingOthers}};Microsoft.Office.Common.EventMethodObject=function(n,t){this._registerMethodObject=n;this._unregisterMethodObject=t};Microsoft.Office.Common.EventMethodObject.prototype={getRegisterMethodObject:function(){return this._registerMethodObject},getUnregisterMethodObject:function(){return this._unregisterMethodObject}};Microsoft.Office.Common.ServiceEndPoint=function(n){var t=this,i=Function._validateParams(arguments,[{name:"serviceEndPointId",type:String,mayBeNull:!1}]);if(i)throw i;t._methodObjectList={};t._eventHandlerProxyList={};t._Id=n;t._conversations={};t._policyManager=null;t._appDomains={};t._onHandleRequestError=null};Microsoft.Office.Common.ServiceEndPoint.prototype={registerMethod:function(n,t,i,r){var e="invokeType",u=!1,f=Function._validateParams(arguments,[{name:"methodName",type:String,mayBeNull:u},{name:"method",type:Function,mayBeNull:u},{name:e,type:Number,mayBeNull:u},{name:"blockingOthers",type:Boolean,mayBeNull:u}]);if(f)throw f;if(i!==Microsoft.Office.Common.InvokeType.async&&i!==Microsoft.Office.Common.InvokeType.sync)throw OsfMsAjaxFactory.msAjaxError.argument(e);var o=new Microsoft.Office.Common.MethodObject(t,i,r);this._methodObjectList[n]=o},unregisterMethod:function(n){var t=Function._validateParams(arguments,[{name:"methodName",type:String,mayBeNull:!1}]);if(t)throw t;delete this._methodObjectList[n]},registerEvent:function(n,t,i){var r=!1,u=Function._validateParams(arguments,[{name:"eventName",type:String,mayBeNull:r},{name:"registerMethod",type:Function,mayBeNull:r},{name:"unregisterMethod",type:Function,mayBeNull:r}]);if(u)throw u;var f=new Microsoft.Office.Common.EventMethodObject(new Microsoft.Office.Common.MethodObject(t,Microsoft.Office.Common.InvokeType.syncRegisterEvent,r),new Microsoft.Office.Common.MethodObject(i,Microsoft.Office.Common.InvokeType.syncUnregisterEvent,r));this._methodObjectList[n]=f},registerEventEx:function(n,t,i,r,u){var f=!1,e=Function._validateParams(arguments,[{name:"eventName",type:String,mayBeNull:f},{name:"registerMethod",type:Function,mayBeNull:f},{name:"registerMethodInvokeType",type:Number,mayBeNull:f},{name:"unregisterMethod",type:Function,mayBeNull:f},{name:"unregisterMethodInvokeType",type:Number,mayBeNull:f}]);if(e)throw e;var o=new Microsoft.Office.Common.EventMethodObject(new Microsoft.Office.Common.MethodObject(t,i,f),new Microsoft.Office.Common.MethodObject(r,u,f));this._methodObjectList[n]=o},unregisterEvent:function(n){var t=Function._validateParams(arguments,[{name:"eventName",type:String,mayBeNull:!1}]);if(t)throw t;this.unregisterMethod(n)},registerConversation:function(n,t,i,r){var e="appDomains",u=!0,f=Function._validateParams(arguments,[{name:"conversationId",type:String,mayBeNull:!1},{name:"conversationUrl",type:String,mayBeNull:!1,optional:u},{name:e,type:Object,mayBeNull:u,optional:u},{name:"serializerVersion",type:Number,mayBeNull:u,optional:u}]);if(f)throw f;if(i){if(!(i instanceof Array))throw OsfMsAjaxFactory.msAjaxError.argument(e);this._appDomains[n]=i}this._conversations[n]={url:t,serializerVersion:r}},unregisterConversation:function(n){var t=Function._validateParams(arguments,[{name:"conversationId",type:String,mayBeNull:!1}]);if(t)throw t;delete this._conversations[n]},setPolicyManager:function(n){var i="policyManager",t=Function._validateParams(arguments,[{name:i,type:Object,mayBeNull:!1}]);if(t)throw t;if(!n.checkPermission)throw OsfMsAjaxFactory.msAjaxError.argument(i);this._policyManager=n},getPolicyManager:function(){return this._policyManager},dispose:function(){var t=null,n=this;n._methodObjectList=t;n._eventHandlerProxyList=t;n._Id=t;n._conversations=t;n._policyManager=t;n._appDomains=t;n._onHandleRequestError=t}};Microsoft.Office.Common.ClientEndPoint=function(n,t,i,r){var f="targetWindow",u=this,e=Function._validateParams(arguments,[{name:"conversationId",type:String,mayBeNull:!1},{name:f,mayBeNull:!1},{name:"targetUrl",type:String,mayBeNull:!1},{name:"serializerVersion",type:Number,mayBeNull:!0,optional:!0}]);if(e)throw e;try{if(!t.postMessage)throw OsfMsAjaxFactory.msAjaxError.argument(f);}catch(o){if(!Object.prototype.hasOwnProperty.call(t,"postMessage"))throw OsfMsAjaxFactory.msAjaxError.argument(f);}u._conversationId=n;u._targetWindow=t;u._targetUrl=i;u._callingIndex=0;u._callbackList={};u._eventHandlerList={};u._serializerVersion=r!=null?r:OSF.SerializerVersion.MsAjax};Microsoft.Office.Common.ClientEndPoint.prototype={invoke:function(n,t,i){var r=this,e=Function._validateParams(arguments,[{name:"targetMethodName",type:String,mayBeNull:!1},{name:"callback",type:Function,mayBeNull:!0},{name:"param",mayBeNull:!0}]);if(e)throw e;var u=r._callingIndex++,h=new Date,f={callback:t,createdOn:h.getTime()};if(i&&typeof i=="object"&&typeof i.__timeout__=="number"){f.timeout=i.__timeout__;delete i.__timeout__}r._callbackList[u]=f;try{var s=new Microsoft.Office.Common.Request(n,Microsoft.Office.Common.ActionType.invoke,r._conversationId,u,i),o=Microsoft.Office.Common.MessagePackager.envelope(s,r._serializerVersion);r._targetWindow.postMessage(o,r._targetUrl);Microsoft.Office.Common.XdmCommunicationManager._startMethodTimeoutTimer()}catch(c){try{t!==null&&t(Microsoft.Office.Common.InvokeResultCode.errorInRequest,c)}finally{delete r._callbackList[u]}}},registerForEvent:function(n,t,i,r){var u=this,e=Function._validateParams(arguments,[{name:"targetEventName",type:String,mayBeNull:!1},{name:"eventHandler",type:Function,mayBeNull:!1},{name:"callback",type:Function,mayBeNull:!0},{name:"data",mayBeNull:!0,optional:!0}]);if(e)throw e;var f=u._callingIndex++,h=new Date;u._callbackList[f]={callback:i,createdOn:h.getTime()};try{var s=new Microsoft.Office.Common.Request(n,Microsoft.Office.Common.ActionType.registerEvent,u._conversationId,f,r),o=Microsoft.Office.Common.MessagePackager.envelope(s,u._serializerVersion);u._targetWindow.postMessage(o,u._targetUrl);Microsoft.Office.Common.XdmCommunicationManager._startMethodTimeoutTimer();u._eventHandlerList[n]=t}catch(c){try{i!==null&&i(Microsoft.Office.Common.InvokeResultCode.errorInRequest,c)}finally{delete u._callbackList[f]}}},unregisterForEvent:function(n,t,i){var r=this,f=Function._validateParams(arguments,[{name:"targetEventName",type:String,mayBeNull:!1},{name:"callback",type:Function,mayBeNull:!0},{name:"data",mayBeNull:!0,optional:!0}]);if(f)throw f;var u=r._callingIndex++,s=new Date;r._callbackList[u]={callback:t,createdOn:s.getTime()};try{var o=new Microsoft.Office.Common.Request(n,Microsoft.Office.Common.ActionType.unregisterEvent,r._conversationId,u,i),e=Microsoft.Office.Common.MessagePackager.envelope(o,r._serializerVersion);r._targetWindow.postMessage(e,r._targetUrl);Microsoft.Office.Common.XdmCommunicationManager._startMethodTimeoutTimer()}catch(h){try{t!==null&&t(Microsoft.Office.Common.InvokeResultCode.errorInRequest,h)}finally{delete r._callbackList[u]}}finally{delete r._eventHandlerList[n]}}};Microsoft.Office.Common.XdmCommunicationManager=function(){var tt="serviceEndPointId",e=!0,d="channel is not ready.",h="conversationId",g="Unknown conversation Id.",t=!1,n=null,c=[],s=n,u=n,b=10,o=t,f=n,it=2e3,k=65e3,nt=k,r={},i={},a=t;function rt(n){for(var t in r)if(r[t]._conversations[n])return r[t];OsfMsAjaxFactory.msAjaxDebug.trace(g);throw OsfMsAjaxFactory.msAjaxError.argument(h);}function ht(n){var t=i[n];t||OsfMsAjaxFactory.msAjaxDebug.trace(g);return t}function ut(t,i){var u=t._methodObjectList[i._actionName];if(!u){OsfMsAjaxFactory.msAjaxDebug.trace("The specified method is not registered on service endpoint:"+i._actionName);throw OsfMsAjaxFactory.msAjaxError.argument("messageObject");}var r=n;r=i._actionType===Microsoft.Office.Common.ActionType.invoke?u:i._actionType===Microsoft.Office.Common.ActionType.registerEvent?u.getRegisterMethodObject():u.getUnregisterMethodObject();return r}function st(n){c.push(n)}function ot(){if(u!==n){if(!o)if(c.length>0){var t=c.shift();l(t)}else{clearInterval(u);u=n}}else OsfMsAjaxFactory.msAjaxDebug.trace(d)}function l(n){o=n.getInvokeBlockingFlag();n.invoke();s=+new Date}function lt(){if(f){var r,o=0,s=new Date,u;for(var h in i){r=i[h];for(var e in r._callbackList){var t=r._callbackList[e];u=t.timeout?t.timeout:nt;if(u>=0&&Math.abs(s.getTime()-t.createdOn)>=u)try{t.callback&&t.callback(Microsoft.Office.Common.InvokeResultCode.errorHandlingMethodCallTimedout,n)}finally{delete r._callbackList[e]}else o++}}if(o===0){clearInterval(f);f=n}}else OsfMsAjaxFactory.msAjaxDebug.trace(d)}function ct(){o=t}function et(n){if(window.addEventListener)window.addEventListener("message",n,t);else if(navigator.userAgent.indexOf("MSIE")>-1&&window.attachEvent)window.attachEvent("onmessage",n);else{OsfMsAjaxFactory.msAjaxDebug.trace("Browser doesn't support the required API.");throw OsfMsAjaxFactory.msAjaxError.argument("Browser");}}function w(n,i){var f=t;if(n===e)return e;if(!n||!i||!n.length||!i.length)return f;var r,u;r=document.createElement("a");u=document.createElement("a");r.href=n;u.href=i;f=v(r,u);delete r,u;return f}function p(n,i){var u=t;if(!i||!i.length||!n||!(n instanceof Array)||!n.length)return u;var f=document.createElement("a"),e=document.createElement("a");f.href=i;for(var r=0;r<n.length&&!u;r++)if(n[r].indexOf("://")!==-1){e.href=n[r];u=v(f,e)}delete f,e;return u}function v(n,t){return n.hostname==t.hostname&&n.protocol==t.protocol&&n.port==t.port}function ft(i){var ft="Access Denied";if(i.data!=""){var r,f=OSF.SerializerVersion.MsAjax,it=i.data;try{r=Microsoft.Office.Common.MessagePackager.unenvelope(it,OSF.SerializerVersion.Browser);f=r._serializerVersion!=n?r._serializerVersion:f}catch(yt){}if(f!=OSF.SerializerVersion.Browser)try{r=Microsoft.Office.Common.MessagePackager.unenvelope(it,f)}catch(yt){return}if(typeof r._messageType=="undefined")return;if(r._messageType===Microsoft.Office.Common.MessageType.request){var g=i.origin==n||i.origin=="null"?r._origin:i.origin;try{var h=rt(r._conversationId),a=h._conversations[r._conversationId];f=a.serializerVersion!=n?a.serializerVersion:f;if(!w(a.url,i.origin)&&!p(h._appDomains[r._conversationId],i.origin))throw"Failed origin check";var tt=h.getPolicyManager();if(tt&&!tt.checkPermission(r._conversationId,r._actionName,r._data))throw ft;var lt=ut(h,r),at=new Microsoft.Office.Common.InvokeCompleteCallback(i.source,g,r._actionName,r._conversationId,r._correlationId,ct,f),nt=new Microsoft.Office.Common.Invoker(lt,r._data,at,h._eventHandlerProxyList,r._conversationId,r._actionName,f),k=e;if(u==n)if((s==n||+new Date-s>b)&&!o){l(nt);k=t}else u=setInterval(ot,b);k&&st(nt)}catch(yt){h&&h._onHandleRequestError&&h._onHandleRequestError(r,yt);var d=Microsoft.Office.Common.InvokeResultCode.errorHandlingRequest;yt==ft&&(d=Microsoft.Office.Common.InvokeResultCode.errorHandlingRequestAccessDenied);var vt=new Microsoft.Office.Common.Response(r._actionName,r._conversationId,r._correlationId,d,Microsoft.Office.Common.ResponseType.forCalling,yt),et=Microsoft.Office.Common.MessagePackager.envelope(vt,f);i.source&&i.source.postMessage&&i.source.postMessage(et,g)}}else if(r._messageType===Microsoft.Office.Common.MessageType.response){var c=ht(r._conversationId);if(!c)return;c._serializerVersion=f;if(!w(c._targetUrl,i.origin))throw"Failed orgin check";if(r._responseType===Microsoft.Office.Common.ResponseType.forCalling){var v=c._callbackList[r._correlationId];if(v)try{v.callback&&v.callback(r._errorCode,r._data)}finally{delete c._callbackList[r._correlationId]}}else{var y=c._eventHandlerList[r._actionName];y!==undefined&&y!==n&&y(r._data)}}else return}}function y(){if(!a){et(ft);a=e}}return{connect:function(n,t,r,u){var f=i[n];if(!f){y();f=new Microsoft.Office.Common.ClientEndPoint(n,t,r,u);i[n]=f}return f},getClientEndPoint:function(n){var r=Function._validateParams(arguments,[{name:h,type:String,mayBeNull:t}]);if(r)throw r;return i[n]},createServiceEndPoint:function(n){y();var t=new Microsoft.Office.Common.ServiceEndPoint(n);r[n]=t;return t},getServiceEndPoint:function(n){var i=Function._validateParams(arguments,[{name:tt,type:String,mayBeNull:t}]);if(i)throw i;return r[n]},deleteClientEndPoint:function(n){var r=Function._validateParams(arguments,[{name:h,type:String,mayBeNull:t}]);if(r)throw r;delete i[n]},deleteServiceEndPoint:function(n){var i=Function._validateParams(arguments,[{name:tt,type:String,mayBeNull:t}]);if(i)throw i;delete r[n]},checkUrlWithAppDomains:function(n,t){return p(n,t)},_setMethodTimeout:function(n){var i=Function._validateParams(arguments,[{name:"methodTimeout",type:Number,mayBeNull:t}]);if(i)throw i;nt=n<=0?k:n},_startMethodTimeoutTimer:function(){f||(f=setInterval(lt,it))}}}();Microsoft.Office.Common.Message=function(n,t,i,r,u){var e=!1,f=this,o=Function._validateParams(arguments,[{name:"messageType",type:Number,mayBeNull:e},{name:"actionName",type:String,mayBeNull:e},{name:"conversationId",type:String,mayBeNull:e},{name:"correlationId",mayBeNull:e},{name:"data",mayBeNull:!0,optional:!0}]);if(o)throw o;f._messageType=n;f._actionName=t;f._conversationId=i;f._correlationId=r;f._origin=window.location.href;f._data=typeof u=="undefined"?null:u};Microsoft.Office.Common.Message.prototype={getActionName:function(){return this._actionName},getConversationId:function(){return this._conversationId},getCorrelationId:function(){return this._correlationId},getOrigin:function(){return this._origin},getData:function(){return this._data},getMessageType:function(){return this._messageType}};Microsoft.Office.Common.Request=function(n,t,i,r,u){Microsoft.Office.Common.Request.uber.constructor.call(this,Microsoft.Office.Common.MessageType.request,n,i,r,u);this._actionType=t};OSF.OUtil.extend(Microsoft.Office.Common.Request,Microsoft.Office.Common.Message);Microsoft.Office.Common.Request.prototype.getActionType=function(){return this._actionType};Microsoft.Office.Common.Response=function(n,t,i,r,u,f){Microsoft.Office.Common.Response.uber.constructor.call(this,Microsoft.Office.Common.MessageType.response,n,t,i,f);this._errorCode=r;this._responseType=u};OSF.OUtil.extend(Microsoft.Office.Common.Response,Microsoft.Office.Common.Message);Microsoft.Office.Common.Response.prototype.getErrorCode=function(){return this._errorCode};Microsoft.Office.Common.Response.prototype.getResponseType=function(){return this._responseType};Microsoft.Office.Common.MessagePackager={envelope:function(n,t){if(t==OSF.SerializerVersion.Browser&&typeof JSON!="undefined"){typeof n=="object"&&(n._serializerVersion=t);return JSON.stringify(n)}else{typeof n=="object"&&(n._serializerVersion=OSF.SerializerVersion.MsAjax);return OsfMsAjaxFactory.msAjaxSerializer.serialize(n)}},unenvelope:function(n,t){return t==OSF.SerializerVersion.Browser&&typeof JSON!="undefined"?JSON.parse(n):OsfMsAjaxFactory.msAjaxSerializer.deserialize(n,!0)}};Microsoft.Office.Common.ResponseSender=function(n,t,i,r,u,f,e){var h=!1,o=this,c=Function._validateParams(arguments,[{name:"requesterWindow",mayBeNull:h},{name:"requesterUrl",type:String,mayBeNull:h},{name:"actionName",type:String,mayBeNull:h},{name:"conversationId",type:String,mayBeNull:h},{name:"correlationId",mayBeNull:h},{name:"responsetype",type:Number,maybeNull:h},{name:"serializerVersion",type:Number,maybeNull:!0,optional:!0}]);if(c)throw c;o._requesterWindow=n;o._requesterUrl=t;o._actionName=i;o._conversationId=r;o._correlationId=u;o._invokeResultCode=Microsoft.Office.Common.InvokeResultCode.noError;o._responseType=f;var s=o;o._send=function(n){try{var i=new Microsoft.Office.Common.Response(s._actionName,s._conversationId,s._correlationId,s._invokeResultCode,s._responseType,n),t=Microsoft.Office.Common.MessagePackager.envelope(i,e);s._requesterWindow.postMessage(t,s._requesterUrl)}catch(r){OsfMsAjaxFactory.msAjaxDebug.trace("ResponseSender._send error:"+r.message)}}};Microsoft.Office.Common.ResponseSender.prototype={getRequesterWindow:function(){return this._requesterWindow},getRequesterUrl:function(){return this._requesterUrl},getActionName:function(){return this._actionName},getConversationId:function(){return this._conversationId},getCorrelationId:function(){return this._correlationId},getSend:function(){return this._send},setResultCode:function(n){this._invokeResultCode=n}};Microsoft.Office.Common.InvokeCompleteCallback=function(n,t,i,r,u,f,e){var s=this;Microsoft.Office.Common.InvokeCompleteCallback.uber.constructor.call(s,n,t,i,r,u,Microsoft.Office.Common.ResponseType.forCalling,e);s._postCallbackHandler=f;var o=s;s._send=function(n,t){t!=undefined&&(o._invokeResultCode=t);try{var r=new Microsoft.Office.Common.Response(o._actionName,o._conversationId,o._correlationId,o._invokeResultCode,o._responseType,n),i=Microsoft.Office.Common.MessagePackager.envelope(r,e);o._requesterWindow.postMessage(i,o._requesterUrl);o._postCallbackHandler()}catch(u){OsfMsAjaxFactory.msAjaxDebug.trace("InvokeCompleteCallback._send error:"+u.message)}}};OSF.OUtil.extend(Microsoft.Office.Common.InvokeCompleteCallback,Microsoft.Office.Common.ResponseSender);Microsoft.Office.Common.Invoker=function(n,t,i,r,u,f,e){var h=!0,s=!1,o=this,c=Function._validateParams(arguments,[{name:"methodObject",mayBeNull:s},{name:"paramValue",mayBeNull:h},{name:"invokeCompleteCallback",mayBeNull:s},{name:"eventHandlerProxyList",mayBeNull:h},{name:"conversationId",type:String,mayBeNull:s},{name:"eventName",type:String,mayBeNull:s},{name:"serializerVersion",type:Number,mayBeNull:h,optional:h}]);if(c)throw c;o._methodObject=n;o._param=t;o._invokeCompleteCallback=i;o._eventHandlerProxyList=r;o._conversationId=u;o._eventName=f;o._serializerVersion=e};Microsoft.Office.Common.Invoker.prototype={invoke:function(){var n=this;try{var t;switch(n._methodObject.getInvokeType()){case Microsoft.Office.Common.InvokeType.async:n._methodObject.getMethod()(n._param,n._invokeCompleteCallback.getSend());break;case Microsoft.Office.Common.InvokeType.sync:t=n._methodObject.getMethod()(n._param);n._invokeCompleteCallback.getSend()(t);break;case Microsoft.Office.Common.InvokeType.syncRegisterEvent:var r=n._createEventHandlerProxyObject(n._invokeCompleteCallback);t=n._methodObject.getMethod()(r.getSend(),n._param);n._eventHandlerProxyList[n._conversationId+n._eventName]=r.getSend();n._invokeCompleteCallback.getSend()(t);break;case Microsoft.Office.Common.InvokeType.syncUnregisterEvent:var f=n._eventHandlerProxyList[n._conversationId+n._eventName];t=n._methodObject.getMethod()(f,n._param);delete n._eventHandlerProxyList[n._conversationId+n._eventName];n._invokeCompleteCallback.getSend()(t);break;case Microsoft.Office.Common.InvokeType.asyncRegisterEvent:var i=n._createEventHandlerProxyObject(n._invokeCompleteCallback);n._methodObject.getMethod()(i.getSend(),n._invokeCompleteCallback.getSend(),n._param);n._eventHandlerProxyList[n._callerId+n._eventName]=i.getSend();break;case Microsoft.Office.Common.InvokeType.asyncUnregisterEvent:var u=n._eventHandlerProxyList[n._callerId+n._eventName];n._methodObject.getMethod()(u,n._invokeCompleteCallback.getSend(),n._param);delete n._eventHandlerProxyList[n._callerId+n._eventName]}}catch(e){n._invokeCompleteCallback.setResultCode(Microsoft.Office.Common.InvokeResultCode.errorInResponse);n._invokeCompleteCallback.getSend()(e)}},getInvokeBlockingFlag:function(){return this._methodObject.getBlockingFlag()},_createEventHandlerProxyObject:function(n){return new Microsoft.Office.Common.ResponseSender(n.getRequesterWindow(),n.getRequesterUrl(),n.getActionName(),n.getConversationId(),n.getCorrelationId(),Microsoft.Office.Common.ResponseType.forEventing,this._serializerVersion)}};OSF.OUtil.setNamespace("WAC",OSF.DDA);OSF.DDA.WAC.UniqueArguments={Data:"Data",Properties:"Properties",BindingRequest:"DdaBindingsMethod",BindingResponse:"Bindings",SingleBindingResponse:"singleBindingResponse",GetData:"DdaGetBindingData",AddRowsColumns:"DdaAddRowsColumns",SetData:"DdaSetBindingData",ClearFormats:"DdaClearBindingFormats",SetFormats:"DdaSetBindingFormats",SettingsRequest:"DdaSettingsMethod",BindingEventSource:"ddaBinding",ArrayData:"ArrayData"};OSF.OUtil.setNamespace("Delegate",OSF.DDA.WAC);OSF.DDA.WAC.Delegate.SpecialProcessor=function(){var t=[OSF.DDA.WAC.UniqueArguments.SingleBindingResponse,OSF.DDA.WAC.UniqueArguments.BindingRequest,OSF.DDA.WAC.UniqueArguments.BindingResponse,OSF.DDA.WAC.UniqueArguments.GetData,OSF.DDA.WAC.UniqueArguments.AddRowsColumns,OSF.DDA.WAC.UniqueArguments.SetData,OSF.DDA.WAC.UniqueArguments.ClearFormats,OSF.DDA.WAC.UniqueArguments.SetFormats,OSF.DDA.WAC.UniqueArguments.SettingsRequest,OSF.DDA.WAC.UniqueArguments.BindingEventSource],n={};OSF.DDA.WAC.Delegate.SpecialProcessor.uber.constructor.call(this,t,n)};OSF.OUtil.extend(OSF.DDA.WAC.Delegate.SpecialProcessor,OSF.DDA.SpecialProcessor);OSF.DDA.WAC.Delegate.ParameterMap=OSF.DDA.getDecoratedParameterMap(new OSF.DDA.WAC.Delegate.SpecialProcessor,[]);OSF.OUtil.setNamespace("WAC",OSF.DDA);OSF.OUtil.setNamespace("Delegate",OSF.DDA.WAC);OSF.DDA.WAC.getDelegateMethods=function(){var n={};n[OSF.DDA.DispIdHost.Delegates.ExecuteAsync]=OSF.DDA.WAC.Delegate.executeAsync;n[OSF.DDA.DispIdHost.Delegates.RegisterEventAsync]=OSF.DDA.WAC.Delegate.registerEventAsync;n[OSF.DDA.DispIdHost.Delegates.UnregisterEventAsync]=OSF.DDA.WAC.Delegate.unregisterEventAsync;n[OSF.DDA.DispIdHost.Delegates.OpenDialog]=OSF.DDA.WAC.Delegate.openDialog;n[OSF.DDA.DispIdHost.Delegates.MessageParent]=OSF.DDA.WAC.Delegate.messageParent;n[OSF.DDA.DispIdHost.Delegates.SendMessage]=OSF.DDA.WAC.Delegate.sendMessage;n[OSF.DDA.DispIdHost.Delegates.CloseDialog]=OSF.DDA.WAC.Delegate.closeDialog;return n};OSF.DDA.WAC.Delegate.version=1;OSF.DDA.WAC.Delegate.executeAsync=function(n){n.hostCallArgs||(n.hostCallArgs={});n.hostCallArgs.DdaMethod={ControlId:OSF._OfficeAppFactory.getId(),Version:OSF.DDA.WAC.Delegate.version,DispatchId:n.dispId};n.hostCallArgs.__timeout__=-1;n.onCalling&&n.onCalling();var t=+new Date;OSF.getClientEndPoint().invoke("executeMethod",function(i,r){n.onReceiving&&n.onReceiving();var u;if(i==Microsoft.Office.Common.InvokeResultCode.noError){OSF.DDA.WAC.Delegate.version=r.Version;u=r.Error}else switch(i){case Microsoft.Office.Common.InvokeResultCode.errorHandlingRequestAccessDenied:u=OSF.DDA.ErrorCodeManager.errorCodes.ooeNoCapability;break;default:u=OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError}n.onComplete&&n.onComplete(u,r);OSF.AppTelemetry&&OSF.AppTelemetry.onMethodDone(n.dispId,n.hostCallArgs,Math.abs(+new Date-t),u)},n.hostCallArgs)};OSF.DDA.WAC.Delegate._getOnAfterRegisterEvent=function(n,t){var i=+new Date;return function(r,u){t.onReceiving&&t.onReceiving();var f;if(r!=Microsoft.Office.Common.InvokeResultCode.noError)switch(r){case Microsoft.Office.Common.InvokeResultCode.errorHandlingRequestAccessDenied:f=OSF.DDA.ErrorCodeManager.errorCodes.ooeNoCapability;break;default:f=OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError}else f=u?u.Error?u.Error:OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess:OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError;t.onComplete&&t.onComplete(f);OSF.AppTelemetry&&OSF.AppTelemetry.onRegisterDone(n,t.dispId,Math.abs(+new Date-i),f)}};OSF.DDA.WAC.Delegate.registerEventAsync=function(n){n.onCalling&&n.onCalling();OSF.getClientEndPoint().registerForEvent(OSF.DDA.getXdmEventName(n.targetId,n.eventType),function(t){n.onEvent&&n.onEvent(t);OSF.AppTelemetry&&OSF.AppTelemetry.onEventDone(n.dispId)},OSF.DDA.WAC.Delegate._getOnAfterRegisterEvent(!0,n),{controlId:OSF._OfficeAppFactory.getId(),eventDispId:n.dispId,targetId:n.targetId})};OSF.DDA.WAC.Delegate.unregisterEventAsync=function(n){n.onCalling&&n.onCalling();OSF.getClientEndPoint().unregisterForEvent(OSF.DDA.getXdmEventName(n.targetId,n.eventType),OSF.DDA.WAC.Delegate._getOnAfterRegisterEvent(!1,n),{controlId:OSF._OfficeAppFactory.getId(),eventDispId:n.dispId,targetId:n.targetId})};OSF.OUtil.setNamespace("WebApp",OSF);OSF.WebApp.AddHostInfoAndXdmInfo=function(n){return OSF._OfficeAppFactory.getWindowLocationSearch&&OSF._OfficeAppFactory.getWindowLocationHash?n+OSF._OfficeAppFactory.getWindowLocationSearch()+OSF._OfficeAppFactory.getWindowLocationHash():n};OSF.WebApp._UpdateLinksForHostAndXdmInfo=function(){for(var t=document.querySelectorAll("a[data-officejs-navigate]"),n=0;n<t.length;n++)OSF.WebApp._isGoodUrl(t[n].href)&&(t[n].href=OSF.WebApp.AddHostInfoAndXdmInfo(t[n].href));for(var r=document.querySelectorAll("form[data-officejs-navigate]"),n=0;n<r.length;n++){var i=r[n];OSF.WebApp._isGoodUrl(i.action)&&(i.action=OSF.WebApp.AddHostInfoAndXdmInfo(i.action))}};OSF.WebApp._isGoodUrl=function(n){if(typeof n=="undefined")return!1;n=n.trim();var r=n.indexOf(":"),t=r>0?n.substr(0,r):null,i=t!==null?t.toLowerCase()==="http"||t.toLowerCase()==="https":!0;i=i&&n!="#"&&n!="/"&&n!=""&&n!=OSF._OfficeAppFactory.getWebAppState().webAppUrl;return i};OSF.InitializationHelper=function(n,t,i,r,u){var f=this;f._hostInfo=n;f._webAppState=t;f._context=i;f._settings=r;f._hostFacade=u;f._appContext={};f._tabbableElements="a[href]:not([tabindex='-1']),area[href]:not([tabindex='-1']),button:not([disabled]):not([tabindex='-1']),input:not([disabled]):not([tabindex='-1']),select:not([disabled]):not([tabindex='-1']),textarea:not([disabled]):not([tabindex='-1']),*[tabindex]:not([tabindex='-1']),*[contenteditable]:not([disabled]):not([tabindex='-1'])";f._initializeSettings=function(n,t){var o="undefined",f,r=n.get_settings(),u=OSF.OUtil.getSessionStorage();if(u){var i=u.getItem(OSF._OfficeAppFactory.getCachedSessionSettingsKey());if(i)r=typeof JSON!==o?JSON.parse(i):OsfMsAjaxFactory.msAjaxSerializer.deserialize(i,!0);else{i=typeof JSON!==o?JSON.stringify(r):OsfMsAjaxFactory.msAjaxSerializer.serialize(r);u.setItem(OSF._OfficeAppFactory.getCachedSessionSettingsKey(),i)}}var e=OSF.DDA.SettingsManager.deserializeSettings(r);f=t?new OSF.DDA.RefreshableSettings(e):new OSF.DDA.Settings(e);return f};var e=function(n){var t=window.open;n.open=function(n,i,r){var u=null;try{u=t(n,i,r)}catch(e){OSF.AppTelemetry&&OSF.AppTelemetry.logAppCommonMessage("Exception happens at windowOpen."+e)}if(!u){var f={strUrl:n,strWindowName:i,strWindowFeatures:r};OSF._OfficeAppFactory.getClientEndPoint().invoke("ContextActivationManager_openWindowInHost",null,f)}return u}};e(window)};OSF.InitializationHelper.prototype.saveAndSetDialogInfo=function(n){var r="IsDialog",u=function(){var n=OSF.OUtil.parseXdmInfo(!0);if(n){var t=n.split("|");return t[1]}return null},t=OSF.OUtil.getSessionStorage();if(t){n||(n=OSF.OUtil.parseHostInfoFromWindowName(!0,OSF._OfficeAppFactory.getWindowName()));if(n&&n.indexOf("isDialog")>-1){var i=u();i!=null&&t.setItem(i+r,"true")}this._hostInfo.isDialog=t.getItem(OSF.OUtil.getXdmFieldValue(OSF.XdmFieldName.AppId,!1)+r)!=null?!0:!1}};OSF.InitializationHelper.prototype.getAppContext=function(n,t){var i=this,f=i,r=function(n,i){var r;if(i._appName===OSF.AppName.ExcelWebApp){var h=i._settings;r={};for(var a in h){var c=h[a];r[c[0]]=c[1]}}else r=i._settings;if(n===0&&i._id!=undefined&&i._appName!=undefined&&i._appVersion!=undefined&&i._appUILocale!=undefined&&i._dataLocale!=undefined&&i._docUrl!=undefined&&i._clientMode!=undefined&&i._settings!=undefined&&i._reason!=undefined){f._appContext=i;var l=i._appInstanceId?i._appInstanceId:i._id,y=!1,v=!0,u=0;i._appMinorVersion!=undefined&&(u=i._appMinorVersion);var e=undefined;i._requirementMatrix!=undefined&&(e=i._requirementMatrix);var o=new OSF.OfficeAppContext(i._id,i._appName,i._appVersion,i._appUILocale,i._dataLocale,i._docUrl,i._clientMode,r,i._reason,i._osfControlType,i._eToken,i._correlationId,l,y,v,u,e,i._hostCustomMessage,i._hostFullVersion,i._clientWindowHeight,i._clientWindowWidth,i._addinName);OSF.AppTelemetry&&OSF.AppTelemetry.initialize(o);t(o)}else{var s="Function ContextActivationManager_getAppContextAsync call failed. ErrorCode is "+n+", exception: "+i;OSF.AppTelemetry&&OSF.AppTelemetry.logAppException(s);throw s;}};try{if(i._hostInfo.isDialog&&window.opener!=null){var u=OfficeExt.WACUtils.parseAppContextFromWindowName(!1,OSF._OfficeAppFactory.getWindowName());r(0,u)}else i._webAppState.clientEndPoint.invoke("ContextActivationManager_getAppContextAsync",r,i._webAppState.id)}catch(e){OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("Exception thrown when trying to invoke getAppContextAsync. Exception:["+e+"]");throw e;}};OSF.InitializationHelper.prototype.setAgaveHostCommunication=function(){var r="ContextActivationManager_notifyHost",i=null,t=!1;try{var n=this,f=OSF.OUtil.parseXdmInfoWithGivenFragment(t,OSF._OfficeAppFactory.getWindowLocationHash());!f&&OSF._OfficeAppFactory.getWindowName&&(f=OSF.OUtil.parseXdmInfoFromWindowName(t,OSF._OfficeAppFactory.getWindowName()));if(f){var u=OSF.OUtil.getInfoItems(f);if(u!=undefined&&u.length>=3){n._webAppState.conversationID=u[0];n._webAppState.id=u[1];n._webAppState.webAppUrl=u[2].indexOf(":")>=0?u[2]:decodeURIComponent(u[2])}}n._webAppState.wnd=window.opener!=i?window.opener:window.parent;var e=OSF.OUtil.parseSerializerVersionWithGivenFragment(t,OSF._OfficeAppFactory.getWindowLocationHash());isNaN(e)&&OSF._OfficeAppFactory.getWindowName&&(e=OSF.OUtil.parseSerializerVersionFromWindowName(t,OSF._OfficeAppFactory.getWindowName()));n._webAppState.serializerVersion=e;n._webAppState.clientEndPoint=Microsoft.Office.Common.XdmCommunicationManager.connect(n._webAppState.conversationID,n._webAppState.wnd,n._webAppState.webAppUrl,n._webAppState.serializerVersion);n._webAppState.serviceEndPoint=Microsoft.Office.Common.XdmCommunicationManager.createServiceEndPoint(n._webAppState.id);var s=n._webAppState.conversationID+OSF.SharedConstants.NotificationConversationIdSuffix;n._webAppState.serviceEndPoint.registerConversation(s,n._webAppState.webAppUrl);if(this._hostInfo.isDialog&&window.opener!=i)return;var o=function(u){switch(u){case OSF.AgaveHostAction.Select:n._webAppState.focused=!0;break;case OSF.AgaveHostAction.UnSelect:n._webAppState.focused=t;break;case OSF.AgaveHostAction.TabIn:case OSF.AgaveHostAction.CtrlF6In:window.focus();var e=document.querySelectorAll(n._tabbableElements),f=OSF.OUtil.focusToFirstTabbable(e,t);if(!f){window.blur();n._webAppState.focused=t;n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,OSF.AgaveHostAction.ExitNoFocusable])}break;case OSF.AgaveHostAction.TabInShift:window.focus();var e=document.querySelectorAll(n._tabbableElements),f=OSF.OUtil.focusToFirstTabbable(e,!0);if(!f){window.blur();n._webAppState.focused=t;n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,OSF.AgaveHostAction.ExitNoFocusableShift])}break;default:OsfMsAjaxFactory.msAjaxDebug.trace("actionId "+u+" notifyAgave is wrong.")}};n._webAppState.serviceEndPoint.registerMethod("Office_notifyAgave",o,Microsoft.Office.Common.InvokeType.async,t);OSF.OUtil.addEventListener(window,"focus",function(){n._webAppState.focused||(n._webAppState.focused=!0);n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,OSF.AgaveHostAction.Select])});OSF.OUtil.addEventListener(window,"blur",function(){n._webAppState.focused&&(n._webAppState.focused=t);n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,OSF.AgaveHostAction.UnSelect])});OSF.OUtil.addEventListener(window,"keydown",function(u){u.preventDefault=u.preventDefault||function(){u.returnValue=t};if(u.keyCode==117&&(u.ctrlKey||u.metaKey)){var e=OSF.AgaveHostAction.CtrlF6Exit;u.shiftKey&&(e=OSF.AgaveHostAction.CtrlF6ExitShift);n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,e])}else if(u.keyCode==9){u.preventDefault();var f=document.querySelectorAll(n._tabbableElements),o=OSF.OUtil.focusToNextTabbable(f,u.target||u.srcElement,u.shiftKey);o||(n._hostInfo.isDialog?OSF.OUtil.focusToFirstTabbable(f,u.shiftKey):u.shiftKey?n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,OSF.AgaveHostAction.TabExitShift]):n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,OSF.AgaveHostAction.TabExit]))}else if(u.keyCode==27){u.preventDefault();n.dismissDialogNotification&&n.dismissDialogNotification();n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,OSF.AgaveHostAction.EscExit])}else if(u.keyCode==113){u.preventDefault();n._webAppState.clientEndPoint.invoke(r,i,[n._webAppState.id,OSF.AgaveHostAction.F2Exit])}});OSF.OUtil.addEventListener(window,"keypress",function(n){n.keyCode==117&&n.ctrlKey&&(n.preventDefault?n.preventDefault():n.returnValue=t)})}catch(h){OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("Exception thrown in setAgaveHostCommunication. Exception:["+h+"]");throw h;}};OSF.InitializationHelper.prototype.initWebDialog=function(n){if(n.get_isDialog()){if(OSF.DDA.UI.ChildUI){n.ui=new OSF.DDA.UI.ChildUI;window.opener!=null&&this.registerMessageReceivedEventForWindowDialog&&this.registerMessageReceivedEventForWindowDialog()}}else if(OSF.DDA.UI.ParentUI){n.ui=new OSF.DDA.UI.ParentUI;OfficeExt.Container&&OSF.DDA.DispIdHost.addAsyncMethods(n.ui,[OSF.DDA.AsyncMethodNames.CloseContainerAsync])}};OSF.getClientEndPoint=function(){var n=OSF._OfficeAppFactory.getInitializationHelper();return n._webAppState.clientEndPoint};OSF.InitializationHelper.prototype.prepareRightAfterWebExtensionInitialize=function(){var n=this;if(n._hostInfo.isDialog){window.focus();var i=document.querySelectorAll(n._tabbableElements),t=OSF.OUtil.focusToFirstTabbable(i,!1);if(!t){window.blur();n._webAppState.focused=!1;n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,OSF.AgaveHostAction.ExitNoFocusable])}}};(function(){var n=function(){var o=function(n){n&&OSF.OUtil.loadScript(n,function(){OsfMsAjaxFactory.msAjaxDebug.trace("loaded customized script:"+n)})},f,e,n,i=null,r=OSF.OUtil.parseXdmInfo();if(r){n=OSF.OUtil.getInfoItems(r);if(n&&n.length>=3){f=n[0];e=n[2];var t=OSF.OUtil.parseSerializerVersionWithGivenFragment(!1,OSF._OfficeAppFactory.getWindowLocationHash());isNaN(t)&&OSF._OfficeAppFactory.getWindowName&&(t=OSF.OUtil.parseSerializerVersionFromWindowName(!1,OSF._OfficeAppFactory.getWindowName()));i=Microsoft.Office.Common.XdmCommunicationManager.connect(f,window.parent,e,t)}}var u=null;if(i)try{i.invoke("getCustomizedScriptPathAsync",function(n,t){o(n===0?t:null)},{__timeout__:1e3})}catch(s){OsfMsAjaxFactory.msAjaxDebug.trace("no script override through cross frame communication.")}else{try{window.external&&typeof window.external.getCustomizedScriptPath!="undefined"&&(u=window.external.getCustomizedScriptPath())}catch(s){OsfMsAjaxFactory.msAjaxDebug.trace("no script override through window.external.")}o(u)}},t=!0;t&&!OsfMsAjaxFactory.isMsAjaxLoaded()?OSF._OfficeAppFactory&&OSF._OfficeAppFactory&&OSF._OfficeAppFactory.getLoadScriptHelper&&OSF._OfficeAppFactory.getLoadScriptHelper().isScriptLoading(OSF.ConstantNames.MicrosoftAjaxId)?OSF._OfficeAppFactory.getLoadScriptHelper().waitForScripts([OSF.ConstantNames.MicrosoftAjaxId],n):OsfMsAjaxFactory.loadMsAjaxFull(function(){if(OsfMsAjaxFactory.isMsAjaxLoaded())n();else throw"Not able to load MicrosoftAjax.js.";}):n()})();var OSFLog;(function(n){var u="ResponseTime",f="Message",r="SessionId",i="CorrelationId",t=!0,e=function(){function n(n){this._table=n;this._fields={}}Object.defineProperty(n.prototype,"Fields",{get:function(){return this._fields},enumerable:t,configurable:t});Object.defineProperty(n.prototype,"Table",{get:function(){return this._table},enumerable:t,configurable:t});n.prototype.SerializeFields=function(){};n.prototype.SetSerializedField=function(n,t){typeof t!="undefined"&&t!==null&&(this._serializedFields[n]=t.toString())};n.prototype.SerializeRow=function(){var n=this;n._serializedFields={};n.SetSerializedField("Table",n._table);n.SerializeFields();return JSON.stringify(n._serializedFields)};return n}();n.BaseUsageData=e;var c=function(n){var k="HostJSVersion",p="OfficeJSVersion",y="DocUrl",v="AppSizeHeight",w="AppSizeWidth",d="ClientId",c="HostVersion",b="Host",s="UserId",o="Browser",e="AssetId",h="AppURL",a="AppInstanceId",l="AppId";__extends(u,n);function u(){n.call(this,"AppActivated")}Object.defineProperty(u.prototype,i,{get:function(){return this.Fields[i]},set:function(n){this.Fields[i]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,r,{get:function(){return this.Fields[r]},set:function(n){this.Fields[r]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,l,{get:function(){return this.Fields[l]},set:function(n){this.Fields[l]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,a,{get:function(){return this.Fields[a]},set:function(n){this.Fields[a]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,h,{get:function(){return this.Fields[h]},set:function(n){this.Fields[h]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,e,{get:function(){return this.Fields[e]},set:function(n){this.Fields[e]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,o,{get:function(){return this.Fields[o]},set:function(n){this.Fields[o]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,s,{get:function(){return this.Fields[s]},set:function(n){this.Fields[s]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,b,{get:function(){return this.Fields[b]},set:function(n){this.Fields[b]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,c,{get:function(){return this.Fields[c]},set:function(n){this.Fields[c]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,d,{get:function(){return this.Fields[d]},set:function(n){this.Fields[d]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,w,{get:function(){return this.Fields[w]},set:function(n){this.Fields[w]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,v,{get:function(){return this.Fields[v]},set:function(n){this.Fields[v]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,f,{get:function(){return this.Fields[f]},set:function(n){this.Fields[f]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,y,{get:function(){return this.Fields[y]},set:function(n){this.Fields[y]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,p,{get:function(){return this.Fields[p]},set:function(n){this.Fields[p]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,k,{get:function(){return this.Fields[k]},set:function(n){this.Fields[k]=n},enumerable:t,configurable:t});u.prototype.SerializeFields=function(){var n=this;n.SetSerializedField(i,n.CorrelationId);n.SetSerializedField(r,n.SessionId);n.SetSerializedField(l,n.AppId);n.SetSerializedField(a,n.AppInstanceId);n.SetSerializedField(h,n.AppURL);n.SetSerializedField(e,n.AssetId);n.SetSerializedField(o,n.Browser);n.SetSerializedField(s,n.UserId);n.SetSerializedField(b,n.Host);n.SetSerializedField(c,n.HostVersion);n.SetSerializedField(d,n.ClientId);n.SetSerializedField(w,n.AppSizeWidth);n.SetSerializedField(v,n.AppSizeHeight);n.SetSerializedField(f,n.Message);n.SetSerializedField(y,n.DocUrl);n.SetSerializedField(p,n.OfficeJSVersion);n.SetSerializedField(k,n.HostJSVersion)};return u}(e);n.AppActivatedUsageData=c;var l=function(n){var e="StartTime",o="ScriptId";__extends(f,n);function f(){n.call(this,"ScriptLoad")}Object.defineProperty(f.prototype,i,{get:function(){return this.Fields[i]},set:function(n){this.Fields[i]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,r,{get:function(){return this.Fields[r]},set:function(n){this.Fields[r]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,o,{get:function(){return this.Fields[o]},set:function(n){this.Fields[o]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,e,{get:function(){return this.Fields[e]},set:function(n){this.Fields[e]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,u,{get:function(){return this.Fields[u]},set:function(n){this.Fields[u]=n},enumerable:t,configurable:t});f.prototype.SerializeFields=function(){var n=this;n.SetSerializedField(i,n.CorrelationId);n.SetSerializedField(r,n.SessionId);n.SetSerializedField(o,n.ScriptId);n.SetSerializedField(e,n.StartTime);n.SetSerializedField(u,n.ResponseTime)};return f}(e);n.ScriptLoadUsageData=l;var h=function(n){var h="CloseMethod",s="OpenTime",e="AppSizeFinalHeight",o="AppSizeFinalWidth",f="FocusTime";__extends(u,n);function u(){n.call(this,"AppClosed")}Object.defineProperty(u.prototype,i,{get:function(){return this.Fields[i]},set:function(n){this.Fields[i]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,r,{get:function(){return this.Fields[r]},set:function(n){this.Fields[r]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,f,{get:function(){return this.Fields[f]},set:function(n){this.Fields[f]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,o,{get:function(){return this.Fields[o]},set:function(n){this.Fields[o]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,e,{get:function(){return this.Fields[e]},set:function(n){this.Fields[e]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,s,{get:function(){return this.Fields[s]},set:function(n){this.Fields[s]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,h,{get:function(){return this.Fields[h]},set:function(n){this.Fields[h]=n},enumerable:t,configurable:t});u.prototype.SerializeFields=function(){var n=this;n.SetSerializedField(i,n.CorrelationId);n.SetSerializedField(r,n.SessionId);n.SetSerializedField(f,n.FocusTime);n.SetSerializedField(o,n.AppSizeFinalWidth);n.SetSerializedField(e,n.AppSizeFinalHeight);n.SetSerializedField(s,n.OpenTime);n.SetSerializedField(h,n.CloseMethod)};return u}(e);n.AppClosedUsageData=h;var o=function(n){var s="ErrorType",o="Parameters",h="APIID",e="APIType";__extends(f,n);function f(){n.call(this,"APIUsage")}Object.defineProperty(f.prototype,i,{get:function(){return this.Fields[i]},set:function(n){this.Fields[i]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,r,{get:function(){return this.Fields[r]},set:function(n){this.Fields[r]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,e,{get:function(){return this.Fields[e]},set:function(n){this.Fields[e]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,h,{get:function(){return this.Fields[h]},set:function(n){this.Fields[h]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,o,{get:function(){return this.Fields[o]},set:function(n){this.Fields[o]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,u,{get:function(){return this.Fields[u]},set:function(n){this.Fields[u]=n},enumerable:t,configurable:t});Object.defineProperty(f.prototype,s,{get:function(){return this.Fields[s]},set:function(n){this.Fields[s]=n},enumerable:t,configurable:t});f.prototype.SerializeFields=function(){var n=this;n.SetSerializedField(i,n.CorrelationId);n.SetSerializedField(r,n.SessionId);n.SetSerializedField(e,n.APIType);n.SetSerializedField(h,n.APIID);n.SetSerializedField(o,n.Parameters);n.SetSerializedField(u,n.ResponseTime);n.SetSerializedField(s,n.ErrorType)};return f}(e);n.APIUsageUsageData=o;var s=function(n){var e="SuccessCode";__extends(u,n);function u(){n.call(this,"AppInitialization")}Object.defineProperty(u.prototype,i,{get:function(){return this.Fields[i]},set:function(n){this.Fields[i]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,r,{get:function(){return this.Fields[r]},set:function(n){this.Fields[r]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,e,{get:function(){return this.Fields[e]},set:function(n){this.Fields[e]=n},enumerable:t,configurable:t});Object.defineProperty(u.prototype,f,{get:function(){return this.Fields[f]},set:function(n){this.Fields[f]=n},enumerable:t,configurable:t});u.prototype.SerializeFields=function(){var n=this;n.SetSerializedField(i,n.CorrelationId);n.SetSerializedField(r,n.SessionId);n.SetSerializedField(e,n.SuccessCode);n.SetSerializedField(f,n.Message)};return u}(e);n.AppInitializationUsageData=s})(OSFLog||(OSFLog={}));var Logger;(function(n){"use strict";(function(n){n[n.info=0]="info";n[n.warning=1]="warning";n[n.error=2]="error"})(n.TraceLevel||(n.TraceLevel={}));var f=n.TraceLevel;(function(n){n[n.none=0]="none";n[n.flush=1]="flush"})(n.SendFlag||(n.SendFlag={}));var e=n.SendFlag;function u(){OSF.Logger&&OSF.Logger.ulsEndpoint&&OSF.Logger.ulsEndpoint.loadProxyFrame()}n.allowUploadingData=u;function t(n,t,i){if(OSF.Logger&&OSF.Logger.ulsEndpoint){var u={traceLevel:n,message:t,flag:i,internalLog:!0},r=JSON.stringify(u);OSF.Logger.ulsEndpoint.writeLog(r)}}n.sendLog=t;function i(){try{return new r}catch(n){return null}}var r=function(){function n(){var n=this,t=n;n.proxyFrame=null;n.telemetryEndPoint="https://telemetryservice.firstpartyapps.oaspapps.com/telemetryservice/telemetryproxy.html";n.buffer=[];n.proxyFrameReady=!1;OSF.OUtil.addEventListener(window,"message",function(n){return t.tellProxyFrameReady(n)});setTimeout(function(){t.loadProxyFrame()},3e3)}n.prototype.writeLog=function(t){var i=this;i.proxyFrameReady===!0?i.proxyFrame.contentWindow.postMessage(t,n.telemetryOrigin):i.buffer.length<128&&i.buffer.push(t)};n.prototype.loadProxyFrame=function(){var n=this;if(n.proxyFrame==null){n.proxyFrame=document.createElement("iframe");n.proxyFrame.setAttribute("style","display:none");n.proxyFrame.setAttribute("src",n.telemetryEndPoint);document.head.appendChild(n.proxyFrame)}};n.prototype.tellProxyFrameReady=function(t){var i=this,e=i;if(t.data==="ProxyFrameReadyToLog"){i.proxyFrameReady=!0;for(var r=0;r<i.buffer.length;r++)i.writeLog(i.buffer[r]);i.buffer.length=0;OSF.OUtil.removeEventListener(window,"message",function(n){return e.tellProxyFrameReady(n)})}else if(t.data==="ProxyFrameReadyToInit"){var f={appName:"Office APPs",sessionId:OSF.OUtil.Guid.generateNewGuid()},u=JSON.stringify(f);i.proxyFrame.contentWindow.postMessage(u,n.telemetryOrigin)}};n.telemetryOrigin="https://telemetryservice.firstpartyapps.oaspapps.com";return n}();OSF.Logger||(OSF.Logger=n);n.ulsEndpoint=i()})(Logger||(Logger={}));var OSFAppTelemetry;(function(n){var i=null;"use strict";var t,u=OSF.OUtil.Guid.generateNewGuid(),e="",k=new RegExp("^https?://store\\.office(ppe|-int)?\\.com/","i"),b=function(){function n(){}return n}(),r=function(){function n(n,t){this.name=n;this.handler=t}return n}(),o=function(){function n(){this.clientIDKey="Office API client";this.logIdSetKey="Office App Log Id Set"}n.prototype.getClientId=function(){var t=this,n=t.getValue(t.clientIDKey);if(!n||n.length<=0||n.length>40){n=OSF.OUtil.Guid.generateNewGuid();t.setValue(t.clientIDKey,n)}return n};n.prototype.saveLog=function(n,t){var r=this,i=r.getValue(r.logIdSetKey);i=(i&&i.length>0?i+";":"")+n;r.setValue(r.logIdSetKey,i);r.setValue(n,t)};n.prototype.enumerateLog=function(n,t){var i=this,f=i.getValue(i.logIdSetKey);if(f){var e=f.split(";");for(var o in e){var r=e[o],u=i.getValue(r);if(u){n&&n(r,u);t&&i.remove(r)}}t&&i.remove(i.logIdSetKey)}};n.prototype.getValue=function(n){var i=OSF.OUtil.getLocalStorage(),t="";i&&(t=i.getItem(n));return t};n.prototype.setValue=function(n,t){var i=OSF.OUtil.getLocalStorage();i&&i.setItem(n,t)};n.prototype.remove=function(n){var t=OSF.OUtil.getLocalStorage();if(t)try{t.removeItem(n)}catch(i){}};return n}(),f=function(){function n(){}n.prototype.LogData=function(n){OSF.Logger&&OSF.Logger.sendLog(OSF.Logger.TraceLevel.info,n.SerializeRow(),OSF.Logger.SendFlag.none)};n.prototype.LogRawData=function(n){OSF.Logger&&OSF.Logger.sendLog(OSF.Logger.TraceLevel.info,n,OSF.Logger.SendFlag.none)};return n}();function w(u){if(OSF.Logger&&!t){t=new b;t.hostVersion=u.get_hostFullVersion()?u.get_hostFullVersion():u.get_appVersion();t.appId=u.get_id();t.host=u.get_appName();t.browser=window.navigator.userAgent;t.correlationId=u.get_correlationId();t.clientId=(new o).getClientId();t.appInstanceId=u.get_appInstanceId();t.appInstanceId&&(t.appInstanceId=t.appInstanceId.replace(/[{}]/g,"").toLowerCase());t.message=u.get_hostCustomMessage();t.officeJSVersion=OSF.ConstantNames.FileVersion;t.hostJSVersion="16.0.7510.1000";var e=u.get_docUrl();t.docUrl=k.test(e)?e:"";var f=location.href;f&&(f=f.split("?")[0].split("#")[0]);t.appURL=f;(function(n,t){var e,o,r;t.assetId="";t.userId="";try{e=decodeURIComponent(n);o=new DOMParser;r=o.parseFromString(e,"text/xml");var f=r.getElementsByTagName("t")[0].attributes.getNamedItem("cid"),u=r.getElementsByTagName("t")[0].attributes.getNamedItem("oid");f&&f.nodeValue?t.userId=f.nodeValue:u&&u.nodeValue&&(t.userId=u.nodeValue);t.assetId=r.getElementsByTagName("t")[0].attributes.getNamedItem("aid").nodeValue}catch(s){}finally{e=i;r=i;o=i}})(u.get_eToken(),t);(function(){var c=new Date,u=i,o=0,h=!1,f=function(){if(document.hasFocus())u==i&&(u=new Date);else if(u){o+=Math.abs(+new Date-u.getTime());u=i}},t=[];t.push(new r("focus",f));t.push(new r("blur",f));t.push(new r("focusout",f));t.push(new r("focusin",f));var s=function(){for(var r=0;r<t.length;r++)OSF.OUtil.removeEventListener(window,t[r].name,t[r].handler);t.length=0;if(!h){if(document.hasFocus()&&u){o+=Math.abs(+new Date-u.getTime());u=i}n.onAppClosed(Math.abs(+new Date-c.getTime()),o);h=!0}};t.push(new r("beforeunload",s));t.push(new r("unload",s));for(var e=0;e<t.length;e++)OSF.OUtil.addEventListener(window,t[e].name,t[e].handler);f()})();n.onAppActivated()}}n.initialize=w;function d(){if(t){(new o).enumerateLog(function(n,t){return(new f).LogRawData(t)},!0);var n=new OSFLog.AppActivatedUsageData;n.SessionId=u;n.AppId=t.appId;n.AssetId=t.assetId;n.AppURL=t.appURL;n.UserId=t.userId;n.ClientId=t.clientId;n.Browser=t.browser;n.Host=t.host;n.HostVersion=t.hostVersion;n.CorrelationId=t.correlationId;n.AppSizeWidth=window.innerWidth;n.AppSizeHeight=window.innerHeight;n.AppInstanceId=t.appInstanceId;n.Message=t.message;n.DocUrl=t.docUrl;n.OfficeJSVersion=t.officeJSVersion;n.HostJSVersion=t.hostJSVersion;(new f).LogData(n);setTimeout(function(){OSF.Logger&&OSF.Logger.allowUploadingData()},100)}}n.onAppActivated=d;function tt(n,t,i,r){var e=new OSFLog.ScriptLoadUsageData;e.CorrelationId=r;e.SessionId=u;e.ScriptId=n;e.StartTime=t;e.ResponseTime=i;(new f).LogData(e)}n.onScriptDone=tt;function nt(n,i,r,o,s){if(t){var h=new OSFLog.APIUsageUsageData;h.CorrelationId=e;h.SessionId=u;h.APIType=n;h.APIID=i;h.Parameters=r;h.ResponseTime=o;h.ErrorType=s;(new f).LogData(h)}}n.onCallDone=nt;function g(n,t,r,u){var f=i;if(t)if(typeof t=="number")f=String(t);else if(typeof t=="object")for(var e in t){f!==i?f+=",":f="";typeof t[e]=="number"&&(f+=String(t[e]))}else f="";OSF.AppTelemetry.onCallDone("method",n,f,r,u)}n.onMethodDone=g;function p(n,t){OSF.AppTelemetry.onCallDone("property",-1,n,t)}n.onPropertyDone=p;function l(n,t){OSF.AppTelemetry.onCallDone("event",n,i,0,t)}n.onEventDone=l;function c(n,t,r,u){OSF.AppTelemetry.onCallDone(n?"registerevent":"unregisterevent",t,i,r,u)}n.onRegisterDone=c;function h(n,i){if(t){var r=new OSFLog.AppClosedUsageData;r.CorrelationId=e;r.SessionId=u;r.FocusTime=i;r.OpenTime=n;r.AppSizeFinalWidth=window.innerWidth;r.AppSizeFinalHeight=window.innerHeight;(new o).saveLog(u,r.SerializeRow())}}n.onAppClosed=h;function y(n){e=n}n.setOsfControlAppCorrelationId=y;function s(n,t){var i=new OSFLog.AppInitializationUsageData;i.CorrelationId=e;i.SessionId=u;i.SuccessCode=n?1:0;i.Message=t;(new f).LogData(i)}n.doAppInitializationLogging=s;function v(n){s(!1,n)}n.logAppCommonMessage=v;function a(n){s(!0,n)}n.logAppException=a;OSF.AppTelemetry=n})(OSFAppTelemetry||(OSFAppTelemetry={}));Microsoft.Office.WebExtension.EventType={};OSF.EventDispatch=function(n){var t=this;t._eventHandlers={};t._queuedEventsArgs={};for(var r in n){var i=n[r];t._eventHandlers[i]=[];t._queuedEventsArgs[i]=[]}};OSF.EventDispatch.prototype={getSupportedEvents:function(){var n=[];for(var t in this._eventHandlers)n.push(t);return n},supportsEvent:function(n){var t=!1;for(var i in this._eventHandlers)if(n==i){t=!0;break}return t},hasEventHandler:function(n,t){var i=this._eventHandlers[n];if(i&&i.length>0)for(var r in i)if(i[r]===t)return!0;return!1},addEventHandler:function(n,t){if(typeof t!="function")return!1;var i=this._eventHandlers[n];if(i&&!this.hasEventHandler(n,t)){i.push(t);return!0}else return!1},addEventHandlerAndFireQueuedEvent:function(n,t){var r=this._eventHandlers[n],u=r.length==0,i=this.addEventHandler(n,t);u&&i&&this.fireQueuedEvent(n);return i},removeEventHandler:function(n,t){var i=this._eventHandlers[n];if(i&&i.length>0)for(var r=0;r<i.length;r++)if(i[r]===t){i.splice(r,1);return!0}return!1},clearEventHandlers:function(n){if(typeof this._eventHandlers[n]!="undefined"&&this._eventHandlers[n].length>0){this._eventHandlers[n]=[];return!0}return!1},getEventHandlerCount:function(n){return this._eventHandlers[n]!=undefined?this._eventHandlers[n].length:-1},fireEvent:function(n){if(n.type==undefined)return!1;var t=n.type;if(t&&this._eventHandlers[t]){var i=this._eventHandlers[t];for(var r in i)i[r](n);return!0}else return!1},fireOrQueueEvent:function(n){var i=this,t=n.type;if(t&&i._eventHandlers[t]){var u=i._eventHandlers[t],r=i._queuedEventsArgs[t];u.length==0?r.push(n):i.fireEvent(n);return!0}else return!1},fireQueuedEvent:function(n){if(n&&this._eventHandlers[n]){var i=this._eventHandlers[n],t=this._queuedEventsArgs[n];if(i.length>0){for(var u=i[0];t.length>0;){var r=t.shift();u(r)}return!0}}return!1}};OSF.DDA.OMFactory=OSF.DDA.OMFactory||{};OSF.DDA.OMFactory.manufactureEventArgs=function(n,t,i){var f="hostType",u=this,r;switch(n){case Microsoft.Office.WebExtension.EventType.DocumentSelectionChanged:r=new OSF.DDA.DocumentSelectionChangedEventArgs(t);break;case Microsoft.Office.WebExtension.EventType.BindingSelectionChanged:r=new OSF.DDA.BindingSelectionChangedEventArgs(u.manufactureBinding(i,t.document),i[OSF.DDA.PropertyDescriptors.Subset]);break;case Microsoft.Office.WebExtension.EventType.BindingDataChanged:r=new OSF.DDA.BindingDataChangedEventArgs(u.manufactureBinding(i,t.document));break;case Microsoft.Office.WebExtension.EventType.SettingsChanged:r=new OSF.DDA.SettingsChangedEventArgs(t);break;case Microsoft.Office.WebExtension.EventType.ActiveViewChanged:r=new OSF.DDA.ActiveViewChangedEventArgs(i);break;case Microsoft.Office.WebExtension.EventType.OfficeThemeChanged:r=new OSF.DDA.Theming.OfficeThemeChangedEventArgs(i);break;case Microsoft.Office.WebExtension.EventType.DocumentThemeChanged:r=new OSF.DDA.Theming.DocumentThemeChangedEventArgs(i);break;case Microsoft.Office.WebExtension.EventType.AppCommandInvoked:r=OSF.DDA.AppCommand.AppCommandInvokedEventArgs.create(i);break;case Microsoft.Office.WebExtension.EventType.DataNodeInserted:r=new OSF.DDA.NodeInsertedEventArgs(u.manufactureDataNode(i[OSF.DDA.DataNodeEventProperties.NewNode]),i[OSF.DDA.DataNodeEventProperties.InUndoRedo]);break;case Microsoft.Office.WebExtension.EventType.DataNodeReplaced:r=new OSF.DDA.NodeReplacedEventArgs(u.manufactureDataNode(i[OSF.DDA.DataNodeEventProperties.OldNode]),u.manufactureDataNode(i[OSF.DDA.DataNodeEventProperties.NewNode]),i[OSF.DDA.DataNodeEventProperties.InUndoRedo]);break;case Microsoft.Office.WebExtension.EventType.DataNodeDeleted:r=new OSF.DDA.NodeDeletedEventArgs(u.manufactureDataNode(i[OSF.DDA.DataNodeEventProperties.OldNode]),u.manufactureDataNode(i[OSF.DDA.DataNodeEventProperties.NextSiblingNode]),i[OSF.DDA.DataNodeEventProperties.InUndoRedo]);break;case Microsoft.Office.WebExtension.EventType.TaskSelectionChanged:r=new OSF.DDA.TaskSelectionChangedEventArgs(t);break;case Microsoft.Office.WebExtension.EventType.ResourceSelectionChanged:r=new OSF.DDA.ResourceSelectionChangedEventArgs(t);break;case Microsoft.Office.WebExtension.EventType.ViewSelectionChanged:r=new OSF.DDA.ViewSelectionChangedEventArgs(t);break;case Microsoft.Office.WebExtension.EventType.DialogMessageReceived:r=new OSF.DDA.DialogEventArgs(i);break;case Microsoft.Office.WebExtension.EventType.DialogParentMessageReceived:r=new OSF.DDA.DialogParentEventArgs(i);break;case Microsoft.Office.WebExtension.EventType.OlkItemSelectedChanged:if(OSF._OfficeAppFactory.getHostInfo()[f]=="outlook"||OSF._OfficeAppFactory.getHostInfo()[f]=="outlookwebapp"){r=new OSF.DDA.OlkItemSelectedChangedEventArgs(i);t.initialize(r.initialData);t.setCurrentItemNumber(r.itemNumber.itemNumber)}else throw OsfMsAjaxFactory.msAjaxError.argument(Microsoft.Office.WebExtension.Parameters.EventType,OSF.OUtil.formatString(Strings.OfficeOM.L_NotSupportedEventType,n));break;default:throw OsfMsAjaxFactory.msAjaxError.argument(Microsoft.Office.WebExtension.Parameters.EventType,OSF.OUtil.formatString(Strings.OfficeOM.L_NotSupportedEventType,n));}return r};OSF.DDA.AsyncMethodNames.addNames({AddHandlerAsync:"addHandlerAsync",RemoveHandlerAsync:"removeHandlerAsync"});OSF.DDA.AsyncMethodCalls.define({method:OSF.DDA.AsyncMethodNames.AddHandlerAsync,requiredArguments:[{name:Microsoft.Office.WebExtension.Parameters.EventType,"enum":Microsoft.Office.WebExtension.EventType,verify:function(n,t,i){return i.supportsEvent(n)}},{name:Microsoft.Office.WebExtension.Parameters.Handler,types:["function"]}],supportedOptions:[],privateStateCallbacks:[]});OSF.DDA.AsyncMethodCalls.define({method:OSF.DDA.AsyncMethodNames.RemoveHandlerAsync,requiredArguments:[{name:Microsoft.Office.WebExtension.Parameters.EventType,"enum":Microsoft.Office.WebExtension.EventType,verify:function(n,t,i){return i.supportsEvent(n)}}],supportedOptions:[{name:Microsoft.Office.WebExtension.Parameters.Handler,value:{types:["function","object"],defaultValue:null}}],privateStateCallbacks:[]});var OfficeExt;(function(n){var t;(function(t){var r=function(){var f="object",e="string",u=null;function r(){var t=this,n=t;t._pseudoDocument=u;t._eventDispatch=u;t._processAppCommandInvocation=function(t){var i=n._verifyManifestCallback(t.callbackName);if(i.errorCode!=OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess){n._invokeAppCommandCompletedMethod(t.appCommandId,i.errorCode,"");return}var r=n._constructEventObjectForCallback(t);r?window.setTimeout(function(){i.callback(r)},0):n._invokeAppCommandCompletedMethod(t.appCommandId,OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError,"")}}r.initializeOsfDda=function(){OSF.DDA.AsyncMethodNames.addNames({AppCommandInvocationCompletedAsync:"appCommandInvocationCompletedAsync"});OSF.DDA.AsyncMethodCalls.define({method:OSF.DDA.AsyncMethodNames.AppCommandInvocationCompletedAsync,requiredArguments:[{name:Microsoft.Office.WebExtension.Parameters.Id,types:[e]},{name:Microsoft.Office.WebExtension.Parameters.Status,types:["number"]},{name:Microsoft.Office.WebExtension.Parameters.Data,types:[e]}]});OSF.OUtil.augmentList(OSF.DDA.EventDescriptors,{AppCommandInvokedEvent:"AppCommandInvokedEvent"});OSF.OUtil.augmentList(Microsoft.Office.WebExtension.EventType,{AppCommandInvoked:"appCommandInvoked"});OSF.OUtil.setNamespace("AppCommand",OSF.DDA);OSF.DDA.AppCommand.AppCommandInvokedEventArgs=n.AppCommand.AppCommandInvokedEventArgs};r.prototype.initializeAndChangeOnce=function(n){var i=this;t.registerDdaFacade();i._pseudoDocument={};OSF.DDA.DispIdHost.addAsyncMethods(i._pseudoDocument,[OSF.DDA.AsyncMethodNames.AppCommandInvocationCompletedAsync]);i._eventDispatch=new OSF.EventDispatch([Microsoft.Office.WebExtension.EventType.AppCommandInvoked]);var r=function(t){n&&(t.status=="succeeded"?n(OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess):n(OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError))};OSF.DDA.DispIdHost.addEventSupport(i._pseudoDocument,i._eventDispatch);i._pseudoDocument.addHandlerAsync(Microsoft.Office.WebExtension.EventType.AppCommandInvoked,i._processAppCommandInvocation,r)};r.prototype._verifyManifestCallback=function(n){var s="function",e={callback:u,errorCode:OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidCallback};n=n.trim();try{for(var t=n.split("."),r=window,i=0;i<t.length-1;i++)if(r[t[i]]&&(typeof r[t[i]]==f||typeof r[t[i]]==s))r=r[t[i]];else return e;var o=r[t[t.length-1]];if(typeof o!=s)return e}catch(h){return e}return{callback:o,errorCode:OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess}};r.prototype._invokeAppCommandCompletedMethod=function(n,t,i){this._pseudoDocument.appCommandInvocationCompletedAsync(n,t,i)};r.prototype._constructEventObjectForCallback=function(n){var f=this,t=new i;try{var r=JSON.parse(n.eventObjStr);this._translateEventObjectInternal(r,t);Object.defineProperty(t,"completed",{value:function(i){t.completedContext=i;var r=JSON.stringify(t);f._invokeAppCommandCompletedMethod(n.appCommandId,OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess,r)},enumerable:!0})}catch(e){t=u}return t};r.prototype._translateEventObjectInternal=function(n,t){for(var i in n)if(n.hasOwnProperty(i)){var r=n[i];if(typeof r==f&&r!=u){OSF.OUtil.defineEnumerableProperty(t,i,{value:{}});this._translateEventObjectInternal(r,t[i])}else Object.defineProperty(t,i,{value:r,enumerable:!0,writable:!0})}};r.prototype._constructObjectByTemplate=function(n,t){var r={};if(!n||!t)return r;for(var i in n)if(n.hasOwnProperty(i)){r[i]=u;if(t[i]!=u){var h=n[i],s=t[i],o=typeof s;typeof h==f&&h!=u?r[i]=this._constructObjectByTemplate(h,s):(o=="number"||o==e||o=="boolean")&&(r[i]=s)}}return r};r.instance=function(){r._instance==u&&(r._instance=new r);return r._instance};r._instance=u;return r}();t.AppCommandManager=r;var u=function(){function n(n,t,i){var r=this;r.type=Microsoft.Office.WebExtension.EventType.AppCommandInvoked;r.appCommandId=n;r.callbackName=t;r.eventObjStr=i}n.create=function(i){return new n(i[t.AppCommandInvokedEventEnums.AppCommandId],i[t.AppCommandInvokedEventEnums.CallbackName],i[t.AppCommandInvokedEventEnums.EventObjStr])};return n}();t.AppCommandInvokedEventArgs=u;var i=function(){function n(){}return n}();t.AppCommandCallbackEventArgs=i;t.AppCommandInvokedEventEnums={AppCommandId:"appCommandId",CallbackName:"callbackName",EventObjStr:"eventObjStr"}})(t=n.AppCommand||(n.AppCommand={}))})(OfficeExt||(OfficeExt={}));OfficeExt.AppCommand.AppCommandManager.initializeOsfDda();OSF.OUtil.setNamespace("Marshaling",OSF.DDA);OSF.OUtil.setNamespace("AppCommand",OSF.DDA.Marshaling);var OSF_DDA_Marshaling_AppCommand_AppCommandInvokedEventKeys;(function(n){var r="EventObjStr",i="CallbackName",t="AppCommandId";n[n[t]=0]=t;n[n[i]=1]=i;n[n[r]=2]=r})(OSF_DDA_Marshaling_AppCommand_AppCommandInvokedEventKeys||(OSF_DDA_Marshaling_AppCommand_AppCommandInvokedEventKeys={}));OSF.DDA.Marshaling.AppCommand.AppCommandInvokedEventKeys=OSF_DDA_Marshaling_AppCommand_AppCommandInvokedEventKeys;var OSF_DDA_Marshaling_AppCommand_AppCommandCompletedMethodParameterKeys;(function(n){n[n.Id=0]="Id";n[n.Status=1]="Status";n[n.Data=2]="Data"})(OSF_DDA_Marshaling_AppCommand_AppCommandCompletedMethodParameterKeys||(OSF_DDA_Marshaling_AppCommand_AppCommandCompletedMethodParameterKeys={}));OSF.DDA.Marshaling.AppCommand.AppCommandCompletedMethodParameterKeys=OSF_DDA_Marshaling_AppCommand_AppCommandCompletedMethodParameterKeys;var OfficeExt;(function(n){var t;(function(t){function i(){if(OSF.DDA.WAC){var t=OSF.DDA.WAC.Delegate.ParameterMap;t.define({type:OSF.DDA.MethodDispId.dispidAppCommandInvocationCompletedMethod,toHost:[{name:Microsoft.Office.WebExtension.Parameters.Id,value:OSF.DDA.Marshaling.AppCommand.AppCommandCompletedMethodParameterKeys.Id},{name:Microsoft.Office.WebExtension.Parameters.Status,value:OSF.DDA.Marshaling.AppCommand.AppCommandCompletedMethodParameterKeys.Status},{name:Microsoft.Office.WebExtension.Parameters.Data,value:OSF.DDA.Marshaling.AppCommand.AppCommandCompletedMethodParameterKeys.Data}]});t.define({type:OSF.DDA.EventDispId.dispidAppCommandInvokedEvent,fromHost:[{name:OSF.DDA.EventDescriptors.AppCommandInvokedEvent,value:t.self}]});t.addComplexType(OSF.DDA.EventDescriptors.AppCommandInvokedEvent);t.define({type:OSF.DDA.EventDescriptors.AppCommandInvokedEvent,fromHost:[{name:n.AppCommand.AppCommandInvokedEventEnums.AppCommandId,value:OSF.DDA.Marshaling.AppCommand.AppCommandInvokedEventKeys.AppCommandId},{name:n.AppCommand.AppCommandInvokedEventEnums.CallbackName,value:OSF.DDA.Marshaling.AppCommand.AppCommandInvokedEventKeys.CallbackName},{name:n.AppCommand.AppCommandInvokedEventEnums.EventObjStr,value:OSF.DDA.Marshaling.AppCommand.AppCommandInvokedEventKeys.EventObjStr}]})}}t.registerDdaFacade=i})(t=n.AppCommand||(n.AppCommand={}))})(OfficeExt||(OfficeExt={}));OSF.DialogShownStatus={hasDialogShown:!1,isWindowDialog:!1};OSF.OUtil.augmentList(OSF.DDA.EventDescriptors,{DialogMessageReceivedEvent:"DialogMessageReceivedEvent"});OSF.OUtil.augmentList(Microsoft.Office.WebExtension.EventType,{DialogMessageReceived:"dialogMessageReceived",DialogEventReceived:"dialogEventReceived"});OSF.OUtil.augmentList(OSF.DDA.PropertyDescriptors,{MessageType:"messageType",MessageContent:"messageContent"});OSF.DDA.DialogEventType={};OSF.OUtil.augmentList(OSF.DDA.DialogEventType,{DialogClosed:"dialogClosed",NavigationFailed:"naviationFailed"});OSF.DDA.AsyncMethodNames.addNames({DisplayDialogAsync:"displayDialogAsync",CloseAsync:"close"});OSF.DDA.SyncMethodNames.addNames({MessageParent:"messageParent",AddMessageHandler:"addEventHandler",SendMessage:"sendMessage"});OSF.DDA.UI.ParentUI=function(){var i=new OSF.EventDispatch([Microsoft.Office.WebExtension.EventType.DialogMessageReceived,Microsoft.Office.WebExtension.EventType.DialogEventReceived,Microsoft.Office.WebExtension.EventType.DialogParentMessageReceived]),t=OSF.DDA.AsyncMethodNames.DisplayDialogAsync.displayName,n=this;n[t]||OSF.OUtil.defineEnumerableProperty(n,t,{value:function(){var t=OSF._OfficeAppFactory.getHostFacade()[OSF.DDA.DispIdHost.Methods.OpenDialog];t(arguments,i,n)}});OSF.OUtil.finalizeProperties(this)};OSF.DDA.UI.ChildUI=function(){var t=OSF.DDA.SyncMethodNames.MessageParent.displayName,n=this;n[t]||OSF.OUtil.defineEnumerableProperty(n,t,{value:function(){var t=OSF._OfficeAppFactory.getHostFacade()[OSF.DDA.DispIdHost.Methods.MessageParent];return t(arguments,n)}});var i=OSF.DDA.SyncMethodNames.AddMessageHandler.displayName;n[i]||typeof OSF.DialogParentMessageEventDispatch=="undefined"||OSF.DDA.DispIdHost.addEventSupport(n,OSF.DialogParentMessageEventDispatch);OSF.OUtil.finalizeProperties(this)};OSF.DialogHandler=function(){};OSF.DDA.DialogEventArgs=function(n){n[OSF.DDA.PropertyDescriptors.MessageType]==OSF.DialogMessageType.DialogMessageReceived?OSF.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.DialogMessageReceived},message:{value:n[OSF.DDA.PropertyDescriptors.MessageContent]}}):OSF.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.DialogParentEventReceived},error:{value:n[OSF.DDA.PropertyDescriptors.MessageType]}})};OSF.DDA.DialogParentEventArgs=function(n){n[OSF.DDA.PropertyDescriptors.MessageType]==OSF.DialogMessageType.DialogParentMessageReceived?OSF.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.DialogParentMessageReceived},message:{value:n[OSF.DDA.PropertyDescriptors.MessageContent]}}):OSF.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.DialogParentEventReceived},error:{value:n[OSF.DDA.PropertyDescriptors.MessageType]}})};OSF.DDA.AsyncMethodCalls.define({method:OSF.DDA.AsyncMethodNames.DisplayDialogAsync,requiredArguments:[{name:Microsoft.Office.WebExtension.Parameters.Url,types:["string"]}],supportedOptions:[{name:Microsoft.Office.WebExtension.Parameters.Width,value:{types:["number"],defaultValue:99}},{name:Microsoft.Office.WebExtension.Parameters.Height,value:{types:["number"],defaultValue:99}},{name:Microsoft.Office.WebExtension.Parameters.RequireHTTPs,value:{types:["boolean"],defaultValue:!0}},{name:Microsoft.Office.WebExtension.Parameters.DisplayInIframe,value:{types:["boolean"],defaultValue:!1}}],privateStateCallbacks:[],onSucceeded:function(n){var f=n[Microsoft.Office.WebExtension.Parameters.Id],i=n[Microsoft.Office.WebExtension.Parameters.Data],t=new OSF.DialogHandler,e=OSF.DDA.AsyncMethodNames.CloseAsync.displayName;OSF.OUtil.defineEnumerableProperty(t,e,{value:function(){var n=OSF._OfficeAppFactory.getHostFacade()[OSF.DDA.DispIdHost.Methods.CloseDialog];n(arguments,f,i,t)}});var r=OSF.DDA.SyncMethodNames.AddMessageHandler.displayName;OSF.OUtil.defineEnumerableProperty(t,r,{value:function(){var f=OSF.DDA.SyncMethodCalls[OSF.DDA.SyncMethodNames.AddMessageHandler.id],n=f.verifyAndExtractCall(arguments,t,i),u=n[Microsoft.Office.WebExtension.Parameters.EventType],r=n[Microsoft.Office.WebExtension.Parameters.Handler];return i.addEventHandlerAndFireQueuedEvent(u,r)}});var u=OSF.DDA.SyncMethodNames.SendMessage.displayName;OSF.OUtil.defineEnumerableProperty(t,u,{value:function(){var n=OSF._OfficeAppFactory.getHostFacade()[OSF.DDA.DispIdHost.Methods.SendMessage];return n(arguments,i,t)}});return t},checkCallArgs:function(n){n[Microsoft.Office.WebExtension.Parameters.Width]<=0&&(n[Microsoft.Office.WebExtension.Parameters.Width]=1);n[Microsoft.Office.WebExtension.Parameters.Width]>100&&(n[Microsoft.Office.WebExtension.Parameters.Width]=99);n[Microsoft.Office.WebExtension.Parameters.Height]<=0&&(n[Microsoft.Office.WebExtension.Parameters.Height]=1);n[Microsoft.Office.WebExtension.Parameters.Height]>100&&(n[Microsoft.Office.WebExtension.Parameters.Height]=99);n[Microsoft.Office.WebExtension.Parameters.RequireHTTPs]||(n[Microsoft.Office.WebExtension.Parameters.RequireHTTPs]=!0);return n}});OSF.DDA.AsyncMethodCalls.define({method:OSF.DDA.AsyncMethodNames.CloseAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[]});OSF.DDA.SyncMethodCalls.define({method:OSF.DDA.SyncMethodNames.MessageParent,requiredArguments:[{name:Microsoft.Office.WebExtension.Parameters.MessageToParent,types:["string","number","boolean"]}],supportedOptions:[]});OSF.DDA.SyncMethodCalls.define({method:OSF.DDA.SyncMethodNames.AddMessageHandler,requiredArguments:[{name:Microsoft.Office.WebExtension.Parameters.EventType,"enum":Microsoft.Office.WebExtension.EventType,verify:function(n,t,i){return i.supportsEvent(n)}},{name:Microsoft.Office.WebExtension.Parameters.Handler,types:["function"]}],supportedOptions:[]});OSF.DDA.SyncMethodCalls.define({method:OSF.DDA.SyncMethodNames.SendMessage,requiredArguments:[{name:Microsoft.Office.WebExtension.Parameters.MessageContent,types:["string"]}],supportedOptions:[],privateStateCallbacks:[]});OSF.OUtil.setNamespace("Marshaling",OSF.DDA);OSF.OUtil.setNamespace("Dialog",OSF.DDA.Marshaling);OSF.DDA.Marshaling.Dialog.DialogMessageReceivedEventKeys={MessageType:"messageType",MessageContent:"messageContent"};OSF.DDA.Marshaling.Dialog.DialogParentMessageReceivedEventKeys={MessageType:"messageType",MessageContent:"messageContent"};OSF.DDA.Marshaling.MessageParentKeys={MessageToParent:"messageToParent"};OSF.DDA.Marshaling.DialogNotificationShownEventType={DialogNotificationShown:"dialogNotificationShown"};OSF.DDA.Marshaling.SendMessageKeys={MessageContent:"messageContent"};var OfficeExt;(function(n){var t;(function(n){var t={Excel:"excel",Word:"word",PowerPoint:"powerpoint",Outlook:"outlook"};function r(n){switch(n){case t.Excel:case t.Word:case t.PowerPoint:case t.Outlook:return new i;default:return new i}return null}n.getDialogCssManager=r;var i=function(){function n(){var i="font-size: 14px",r="font-family: Segoe UI,Arial,Verdana,sans-serif",u="width: 100%",t="position: absolute",n=this;n.overlayElementCSS=[t,"top: 0","left: 0",u,"height: 100%","background-color: rgba(198, 198, 198, 0.5)","z-index: 99998"];n.dialogNotificationPanelCSS=[u,"height: 120px",t,"z-index: 99999","background-color: rgba(255, 255, 255, 1)","left: 0px","top: 50%","margin-top: -60px"];n.dialogNotificationTextPanelCSS=["margin: 20px 30px",r,i,"height: 40px"];n.dialogNotificationButtonPanelCSS="margin:0px 25px";n.buttonStyleCSS=["text-align: center","width: 70px","height: 25px",i,r,"margin: 0px 5px","border-width: 1px","border-style: solid"]}n.prototype.getOverlayElementCSS=function(){return this.overlayElementCSS.join(";")};n.prototype.getDialogNotificationPanelCSS=function(){return this.dialogNotificationPanelCSS.join(";")};n.prototype.getDialogNotificationTextPanelCSS=function(){return this.dialogNotificationTextPanelCSS.join(";")};n.prototype.getDialogNotificationButtonPanelCSS=function(){return this.dialogNotificationButtonPanelCSS};n.prototype.getDialogButtonCSS=function(){return this.buttonStyleCSS.join(";")};return n}();n.DefaultDialogCSSManager=i})(t=n.WacCommonUICssManager||(n.WacCommonUICssManager={}))})(OfficeExt||(OfficeExt={}));var OfficeExt;(function(n){var t;(function(t){var i;(function(t){var h="div",l="message",f=!1,i=null,r=i,w=i,s=i,u=i,tt="action=closeDialog",e=i,y=-1,c=i,it="#ababab",nt="#ffffff",st="#ccc",rt="newWindowNotificaiton",o={dispId:OSF.DDA.EventDispId.dispidDialogNotificationShownInAddinEvent,eventType:OSF.DDA.Marshaling.DialogNotificationShownEventType.DialogNotificationShown,onComplete:i};function pt(n){var t=n.input;t!=i&&(c={HostButtonBorderColor:t[OSF.HostThemeButtonStyleKeys.ButtonBorderColor],HostButtonBackgroundColor:t[OSF.HostThemeButtonStyleKeys.ButtonBackgroundColor]});n.completed()}t.setHostThemeButtonStyle=pt;function lt(t){try{var y=f,l=f,tt=OSF._OfficeAppFactory.getInitializationHelper()._hostInfo,h=n.WacCommonUICssManager.getDialogCssManager(tt.hostType),it=OSF.OUtil.formatString(Strings.OfficeOM.L_ShowWindowDialogNotification,OSF._OfficeAppFactory.getInitializationHelper()._appContext._addinName);s=ot(h);document.body.insertBefore(s,document.body.firstChild);u=ut(h,it);u.id=rt;var c=et(h),i=g(h,Strings.OfficeOM.L_ShowWindowDialogNotificationAllow),r=g(h,Strings.OfficeOM.L_ShowWindowDialogNotificationIgnore);c.appendChild(i);c.appendChild(r);u.appendChild(c);document.body.insertBefore(u,document.body.firstChild);function w(){yt(t);d()}i.onclick=w;function p(){function n(n){k();b(n);e(OSF.DDA.ErrorCodeManager.errorCodes.ooeEndUserIgnore)}o.onComplete=n;OSF.DDA.WAC.Delegate.unregisterEventAsync(o)}r.onclick=p;i.addEventListener("keydown",function(n){if(n.shiftKey&&n.keyCode==9){a(i);v(r);r.focus();n.preventDefault();n.stopPropagation()}else if(n.keyCode==13){y=!0;n.preventDefault();n.stopPropagation()}},f);i.addEventListener("keyup",function(n){if(n.keyCode==13&&y){y=f;w();n.preventDefault();n.stopPropagation()}},f);r.addEventListener("keydown",function(n){if(n.shiftKey||n.keyCode!=9){if(n.keyCode==13){l=!0;n.preventDefault();n.stopPropagation()}}else{a(r);v(i);i.focus();n.preventDefault();n.stopPropagation()}},f);r.addEventListener("keyup",function(n){if(n.keyCode==13&&l){l=f;p();n.preventDefault();n.stopPropagation()}},f);window.focus();function nt(){i.focus()}o.onComplete=nt;OSF.DDA.WAC.Delegate.registerEventAsync(o)}catch(ft){OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("Exception happens at new window dialog."+ft);e(OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError)}}t.handleNewWindowDialog=lt;function vt(n){try{if(r!=i){var u=OSF._OfficeAppFactory.getInitializationHelper()._appContext._appDomains;if(u)for(var t=0;t<u.length&&u[t].indexOf("://")!==-1;t++)r.postMessage(tt,u[t]);r==i||r.closed||r.close();window.removeEventListener(l,p);window.clearInterval(y);r=i;n(OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess)}else n(OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError)}catch(f){OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("Exception happens at close window dialog."+f);n(OSF.DDA.ErrorCodeManager.errorCodes.ooeInternalError)}}t.closeDialog=vt;function ft(n){var r=n.hostCallArgs[Microsoft.Office.WebExtension.Parameters.MessageToParent],t=OSF._OfficeAppFactory.getInitializationHelper()._appContext._appDomains;if(t)for(var i=0;i<t.length&&t[i].indexOf("://")!==-1;i++)window.opener.postMessage(r,t[i])}t.messageParent=ft;function ct(){function n(n){n.source==window.opener&&n.data.indexOf(tt)>-1&&window.close()}window.addEventListener(l,n)}t.registerMessageReceivedEvent=ct;function ht(n,t){w=n;e=t}t.setHandlerAndShowDialogCallback=ht;function at(){u&&u.id==rt&&e&&e(OSF.DDA.ErrorCodeManager.errorCodes.ooeEndUserIgnore);d()}t.escDismissDialogNotification=at;function p(n){if(n.source==r)try{var t={};t[OSF.DDA.Marshaling.Dialog.DialogMessageReceivedEventKeys.MessageType]=OSF.DialogMessageType.DialogMessageReceived;t[OSF.DDA.Marshaling.Dialog.DialogMessageReceivedEventKeys.MessageContent]=n.data;w(t)}catch(i){OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("Error happened during receive message handler."+i)}}function yt(t){var f=OSF._OfficeAppFactory.getInitializationHelper()._hostInfo,d=[f.hostType,f.hostPlatform,f.hostSpecificFileVersion,f.hostLocale,f.osfControlAppCorrelationId,"isDialog"],g=d.join("|"),u=OSF._OfficeAppFactory.getInitializationHelper()._appContext,k=t[OSF.ShowWindowDialogParameterKeys.Url],o=JSON.parse(window.name);o[OSF.WindowNameItemKeys.HostInfo]=g;o[OSF.WindowNameItemKeys.AppContext]=u;var s=t[OSF.ShowWindowDialogParameterKeys.Width]*u._clientWindowWidth/100,h=t[OSF.ShowWindowDialogParameterKeys.Height]*u._clientWindowHeight/100,b=u._clientWindowWidth/2-s/2,c=u._clientWindowHeight/2-h/2,v="width="+s+", height="+h+", left="+b+", top="+c+",channelmode=no,directories=no,fullscreen=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=no,titlebar=yes,toolbar=no";r=window.open(k,n.WACUtils.serializeObjectToString(o),v);window.addEventListener(l,p);function a(){try{if(r==i||r.closed){window.clearInterval(y);window.removeEventListener(l,p);var n={};n[OSF.DDA.Marshaling.Dialog.DialogMessageReceivedEventKeys.MessageType]=OSF.DialogMessageType.DialogClosed;w(n)}}catch(t){OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("Error happened during check or handle window close."+t)}}y=window.setInterval(a,1e3);e!=i?e(OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess):OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("showDialogCallback can not be null.")}function g(n,t){var i=document.createElement("input");i.setAttribute("type","button");i.style.cssText=n.getDialogButtonCSS();i.style.borderColor=it;i.style.backgroundColor=nt;i.setAttribute("value",t);var u=function(){v(i)},r=function(){a(i)};i.addEventListener("mouseover",u);i.addEventListener("focus",u);i.addEventListener("mouseout",r);i.addEventListener("focusout",r);return i}function v(n){if(c!=i){n.style.borderColor=c.HostButtonBorderColor;n.style.backgroundColor=c.HostButtonBackgroundColor}else if(OSF.CommonUI&&OSF.CommonUI.HostButtonBorderColor&&OSF.CommonUI.HostButtonBackgroundColor){n.style.borderColor=OSF.CommonUI.HostButtonBorderColor;n.style.backgroundColor=OSF.CommonUI.HostButtonBackgroundColor}else n.style.backgroundColor=st}function a(n){n.style.borderColor=it;n.style.backgroundColor=nt}function d(){function n(n){k();b(n)}o.onComplete=n;OSF.DDA.WAC.Delegate.unregisterEventAsync(o)}function k(){if(u!=i){document.body.removeChild(u);u=i}if(s!=i){document.body.removeChild(s);s=i}}function ot(n){var t=document.createElement(h);t.style.cssText=n.getOverlayElementCSS();return t}function ut(n,t){var r=document.createElement(h);r.style.cssText=n.getDialogNotificationPanelCSS();var i=document.createElement(h);i.innerText=t;i.style.cssText=n.getDialogNotificationTextPanelCSS();r.appendChild(i);return r}function et(n){var t=document.createElement(h);t.style.cssText=n.getDialogNotificationButtonPanelCSS();t.style.cssFloat=document.documentElement.getAttribute("dir")=="rtl"?"left":"right";return t}function b(n){if(n!=OSF.DDA.ErrorCodeManager.errorCodes.ooeSuccess){var t=document.querySelectorAll(OSF._OfficeAppFactory.getInitializationHelper()._tabbableElements);OSF.OUtil.focusToFirstTabbable(t,f)}}})(i=t.Dialog||(t.Dialog={}))})(t=n.AddinNativeAction||(n.AddinNativeAction={}))})(OfficeExt||(OfficeExt={}));OSF.DDA.WAC.Delegate.ParameterMap.define({type:OSF.DDA.EventDispId.dispidDialogMessageReceivedEvent,fromHost:[{name:OSF.DDA.EventDescriptors.DialogMessageReceivedEvent,value:OSF.DDA.WAC.Delegate.ParameterMap.self}]});OSF.DDA.WAC.Delegate.ParameterMap.addComplexType(OSF.DDA.EventDescriptors.DialogMessageReceivedEvent);OSF.DDA.WAC.Delegate.ParameterMap.define({type:OSF.DDA.EventDescriptors.DialogMessageReceivedEvent,fromHost:[{name:OSF.DDA.PropertyDescriptors.MessageType,value:OSF.DDA.Marshaling.Dialog.DialogMessageReceivedEventKeys.MessageType},{name:OSF.DDA.PropertyDescriptors.MessageContent,value:OSF.DDA.Marshaling.Dialog.DialogMessageReceivedEventKeys.MessageContent}]});OSF.DDA.WAC.Delegate.ParameterMap.define({type:OSF.DDA.EventDispId.dispidDialogParentMessageReceivedEvent,fromHost:[{name:OSF.DDA.EventDescriptors.DialogParentMessageReceivedEvent,value:OSF.DDA.WAC.Delegate.ParameterMap.self}]});OSF.DDA.WAC.Delegate.ParameterMap.addComplexType(OSF.DDA.EventDescriptors.DialogParentMessageReceivedEvent);OSF.DDA.WAC.Delegate.ParameterMap.define({type:OSF.DDA.EventDescriptors.DialogParentMessageReceivedEvent,fromHost:[{name:OSF.DDA.PropertyDescriptors.MessageType,value:OSF.DDA.Marshaling.Dialog.DialogParentMessageReceivedEventKeys.MessageType},{name:OSF.DDA.PropertyDescriptors.MessageContent,value:OSF.DDA.Marshaling.Dialog.DialogParentMessageReceivedEventKeys.MessageContent}]});OSF.DDA.WAC.Delegate.ParameterMap.define({type:OSF.DDA.MethodDispId.dispidMessageParentMethod,toHost:[{name:Microsoft.Office.WebExtension.Parameters.MessageToParent,value:OSF.DDA.Marshaling.MessageParentKeys.MessageToParent}]});OSF.DDA.WAC.Delegate.ParameterMap.define({type:OSF.DDA.MethodDispId.dispidSendMessageMethod,toHost:[{name:Microsoft.Office.WebExtension.Parameters.MessageContent,value:OSF.DDA.Marshaling.SendMessageKeys.MessageContent}]});OSF.DDA.WAC.Delegate.openDialog=function(n){var u="https://",f="http://",r=JSON.parse(n.targetId),e=OSF.DDA.WAC.Delegate._getOnAfterRegisterEvent(!0,n);function t(n){var t={Error:n};e(Microsoft.Office.Common.InvokeResultCode.noError,t)}if(OSF.DialogShownStatus.hasDialogShown){t(OSF.DDA.ErrorCodeManager.errorCodes.ooeDialogAlreadyOpened);return}var i=r[OSF.ShowWindowDialogParameterKeys.Url].toLowerCase();if(i==null||!i.startsWith(u)){i.startsWith(f)?t(OSF.DDA.ErrorCodeManager.errorCodes.ooeRequireHTTPS):t(OSF.DDA.ErrorCodeManager.errorCodes.ooeInvalidScheme);return}if(r[OSF.ShowWindowDialogParameterKeys.DisplayInIframe]){OSF.DialogShownStatus.isWindowDialog=!1;OSF.DDA.WAC.Delegate.registerEventAsync(n)}else{OSF.DialogShownStatus.isWindowDialog=!0;OfficeExt.AddinNativeAction.Dialog.setHandlerAndShowDialogCallback(function(t){n.onEvent&&n.onEvent(t);OSF.AppTelemetry&&OSF.AppTelemetry.onEventDone(n.dispId)},t);OfficeExt.AddinNativeAction.Dialog.handleNewWindowDialog(r)}};OSF.DDA.WAC.Delegate.messageParent=function(n){window.opener!=null?OfficeExt.AddinNativeAction.Dialog.messageParent(n):OSF.DDA.WAC.Delegate.executeAsync(n)};OSF.DDA.WAC.Delegate.sendMessage=function(n){OSF.DDA.WAC.Delegate.executeAsync(n)};OSF.DDA.WAC.Delegate.closeDialog=function(n){var i=OSF.DDA.WAC.Delegate._getOnAfterRegisterEvent(!1,n);function t(n){var t={Error:n};i(Microsoft.Office.Common.InvokeResultCode.noError,t)}if(OSF.DialogShownStatus.hasDialogShown)if(OSF.DialogShownStatus.isWindowDialog){n.onCalling&&n.onCalling();OfficeExt.AddinNativeAction.Dialog.closeDialog(t)}else OSF.DDA.WAC.Delegate.unregisterEventAsync(n);else t(OSF.DDA.ErrorCodeManager.errorCodes.ooeWebDialogClosed)};OSF.InitializationHelper.prototype.dismissDialogNotification=function(){OfficeExt.AddinNativeAction.Dialog.escDismissDialogNotification()};OSF.InitializationHelper.prototype.registerMessageReceivedEventForWindowDialog=function(){OfficeExt.AddinNativeAction.Dialog.registerMessageReceivedEvent()};OSF.DDA.AsyncMethodNames.addNames({CloseContainerAsync:"closeContainer"});var OfficeExt;(function(n){var t=function(){function n(){}return n}();n.Container=t})(OfficeExt||(OfficeExt={}));OSF.DDA.AsyncMethodCalls.define({method:OSF.DDA.AsyncMethodNames.CloseContainerAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[]});OSF.DDA.WAC.Delegate.ParameterMap.define({type:OSF.DDA.MethodDispId.dispidCloseContainerMethod,fromHost:[],toHost:[]});OSF.OUtil.augmentList(Microsoft.Office.WebExtension.EventType,{OlkItemSelectedChanged:"olkItemSelectedChanged"});OSF.OUtil.augmentList(OSF.DDA.EventDescriptors,{OlkItemSelectedData:"OlkItemSelectedData"});OSF.DDA.OlkItemSelectedChangedEventArgs=function(n){OSF.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.OlkItemSelectedChanged},initialData:{value:JSON.parse(n[OSF.DDA.EventDescriptors.OlkItemSelectedData][0])},itemNumber:{value:JSON.parse(n[OSF.DDA.EventDescriptors.OlkItemSelectedData][1])}})};OSF.DDA.WAC.Delegate.ParameterMap.define({type:OSF.DDA.EventDispId.dispidOlkItemSelectedChangedEvent,fromHost:[{name:OSF.DDA.EventDescriptors.OlkItemSelectedData,value:OSF.DDA.WAC.Delegate.ParameterMap.sourceData}],isComplexType:!0});OSF.InitializationHelper.prototype.prepareRightBeforeWebExtensionInitialize=function(){OSF.WebApp._UpdateLinksForHostAndXdmInfo()};OSF.InitializationHelper.prototype.prepareRightAfterWebExtensionInitialize=function(){var n=OfficeExt.AppCommand.AppCommandManager.instance();n.initializeAndChangeOnce()};OSF.InitializationHelper.prototype.getInitializationReason=function(n){return n.get_reason()};var executeAsyncBase=OSF.DDA.WAC.Delegate.executeAsync;OSF.DDA.WAC.Delegate.executeAsync=function(n){var t=n.onCalling;n.onCalling=function(){n.hostCallArgs=OSF.DDA.OutlookAppOm.addAdditionalArgs(n.dispId,n.hostCallArgs);t&&t()};executeAsyncBase(n)};OSF.InitializationHelper.prototype.prepareApiSurface=function(n){var t=new OSF.DDA.License(n.get_eToken());if(n.get_appName()==OSF.AppName.OutlookWebApp){OSF.WebApp._UpdateLinksForHostAndXdmInfo();this.initWebDialog(n);OSF._OfficeAppFactory.setContext(new OSF.DDA.OutlookContext(n,this._settings,t,n.appOM));OSF._OfficeAppFactory.setHostFacade(new OSF.DDA.DispIdHost.Facade(OSF.DDA.WAC.getDelegateMethods,OSF.DDA.WAC.Delegate.ParameterMap))}else{OfficeJsClient_OutlookWin32.prepareApiSurface(n);OSF._OfficeAppFactory.setContext(new OSF.DDA.OutlookContext(n,this._settings,t,n.appOM,OSF.DDA.Theming?OSF.DDA.Theming.getOfficeTheme:null,n.ui));OSF._OfficeAppFactory.setHostFacade(new OSF.DDA.DispIdHost.Facade(OSF.DDA.DispIdHost.getClientDelegateMethods,OSF.DDA.SafeArray.Delegate.ParameterMap))}};OSF.DDA.SettingsManager={SerializedSettings:"serializedSettings",DateJSONPrefix:"Date(",DataJSONSuffix:")",serializeSettings:function(n){var r={};for(var i in n){var t=n[i];try{t=JSON?JSON.stringify(t,function(n,t){return OSF.OUtil.isDate(this[n])?OSF.DDA.SettingsManager.DateJSONPrefix+this[n].getTime()+OSF.DDA.SettingsManager.DataJSONSuffix:t}):Sys.Serialization.JavaScriptSerializer.serialize(t);r[i]=t}catch(u){}}return r},deserializeSettings:function(n){var r={};n=n||{};for(var i in n){var t=n[i];try{t=JSON?JSON.parse(t,function(n,t){var i;if(typeof t=="string"&&t&&t.length>6&&t.slice(0,5)===OSF.DDA.SettingsManager.DateJSONPrefix&&t.slice(-1)===OSF.DDA.SettingsManager.DataJSONSuffix){i=new Date(parseInt(t.slice(5,-1)));if(i)return i}return t}):Sys.Serialization.JavaScriptSerializer.deserialize(t,!0);r[i]=t}catch(u){}}return r}};OSF.InitializationHelper.prototype.loadAppSpecificScriptAndCreateOM=function(n,t,i){Type.registerNamespace("Microsoft.Office.WebExtension.MailboxEnums");Microsoft.Office.WebExtension.MailboxEnums.EntityType={MeetingSuggestion:"meetingSuggestion",TaskSuggestion:"taskSuggestion",Address:"address",EmailAddress:"emailAddress",Url:"url",PhoneNumber:"phoneNumber",Contact:"contact",FlightReservations:"flightReservations",ParcelDeliveries:"parcelDeliveries"};Microsoft.Office.WebExtension.MailboxEnums.ItemType={Message:"message",Appointment:"appointment"};Microsoft.Office.WebExtension.MailboxEnums.ResponseType={None:"none",Organizer:"organizer",Tentative:"tentative",Accepted:"accepted",Declined:"declined"};Microsoft.Office.WebExtension.MailboxEnums.RecipientType={Other:"other",DistributionList:"distributionList",User:"user",ExternalUser:"externalUser"};Microsoft.Office.WebExtension.MailboxEnums.AttachmentType={File:"file",Item:"item",Cloud:"cloud"};Microsoft.Office.WebExtension.MailboxEnums.BodyType={Text:"text",Html:"html"};Microsoft.Office.WebExtension.MailboxEnums.ItemNotificationMessageType={ProgressIndicator:"progressIndicator",InformationalMessage:"informationalMessage",ErrorMessage:"errorMessage"};Microsoft.Office.WebExtension.CoercionType={Text:"text",Html:"html"};Microsoft.Office.WebExtension.MailboxEnums.UserProfileType={Office365:"office365",OutlookCom:"outlookCom",Enterprise:"enterprise"};Microsoft.Office.WebExtension.MailboxEnums.RestVersion={v1_0:"v1.0",v2_0:"v2.0",Beta:"beta"};Microsoft.Office.WebExtension.MailboxEnums.ModuleType={Addins:"addins"};Type.registerNamespace("OSF.DDA");var u=window.OSF||{};u.DDA=u.DDA||{};window.OSF.DDA.OutlookAppOm=u.DDA.OutlookAppOm=function(n,t,i){this.$$d_navigateToModuleAsync=Function.createDelegate(this,this.navigateToModuleAsync);this.$$d_displayPersonaCardAsync=Function.createDelegate(this,this.displayPersonaCardAsync);this.$$d_displayNewMessageFormApi=Function.createDelegate(this,this.displayNewMessageFormApi);this.$$d__displayNewAppointmentFormApi$p$0=Function.createDelegate(this,this._displayNewAppointmentFormApi$p$0);this.$$d_windowOpenOverrideHandler=Function.createDelegate(this,this.windowOpenOverrideHandler);this.$$d__getRestUrl$p$0=Function.createDelegate(this,this._getRestUrl$p$0);this.$$d__getEwsUrl$p$0=Function.createDelegate(this,this._getEwsUrl$p$0);this.$$d__getDiagnostics$p$0=Function.createDelegate(this,this._getDiagnostics$p$0);this.$$d__getUserProfile$p$0=Function.createDelegate(this,this._getUserProfile$p$0);this.$$d__getItem$p$0=Function.createDelegate(this,this._getItem$p$0);this.$$d__callAppReadyCallback$p$0=Function.createDelegate(this,this._callAppReadyCallback$p$0);this.$$d__getInitialDataResponseHandler$p$0=Function.createDelegate(this,this._getInitialDataResponseHandler$p$0);window.OSF.DDA.OutlookAppOm._instance$p=this;this._officeAppContext$p$0=n;this._appReadyCallback$p$0=i;var r=this;var u=function(){i&&(n.get_isDialog()?window.setTimeout(r.$$d__callAppReadyCallback$p$0,0):r.invokeHostMethod(1,null,r.$$d__getInitialDataResponseHandler$p$0))};this._areStringsLoaded$p$0()?u():this._loadLocalizedScript$p$0(u)};window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i=function(n){if(!n)throw Error.create(window._u.ExtensibilityStrings.l_ElevatedPermissionNeeded_Text);};window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i=function(n,t,i,r){if(n<t||n>i)throw Error.argumentOutOfRange(r);};window.OSF.DDA.OutlookAppOm._throwOnInvalidModule$p=function(n){if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("module");else if(n==="")throw Error.argument("module","module cannot be empty.");if(n!==window.Microsoft.Office.WebExtension.MailboxEnums.ModuleType.Addins)throw Error.notImplemented(String.format("API not supported for module '{0}'",n));};window.OSF.DDA.OutlookAppOm._getHtmlBody$p=function(n){var t="";if("htmlBody"in n){window.OSF.DDA.OutlookAppOm._throwOnInvalidHtmlBody$p(n.htmlBody);t=n.htmlBody}return t};window.OSF.DDA.OutlookAppOm._getAttachments$p=function(n){var t=[];if("attachments"in n){t=n.attachments;window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentsArray$p(t)}return t};window.OSF.DDA.OutlookAppOm._getOptionsAndCallback$p=function(n){var t=[];"options"in n&&(t[0]=n.options);"callback"in n&&(t[t.length]=n.callback);return t};window.OSF.DDA.OutlookAppOm._createAttachmentsDataForHost$p=function(n){var r=new Array(0);if(Array.isInstanceOfType(n))for(var t=0;t<n.length;t++)if(Object.isInstanceOfType(n[t])){var i=n[t];window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachment$p(i);r[t]=window.OSF.DDA.OutlookAppOm._createAttachmentData$p(i)}else throw Error.argument("attachments");return r};window.OSF.DDA.OutlookAppOm._throwOnInvalidHtmlBody$p=function(n){if(!String.isInstanceOfType(n))throw Error.argument("htmlBody");if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argument("htmlBody");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,window.OSF.DDA.OutlookAppOm.maxBodyLength,"htmlBody")};window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentsArray$p=function(n){if(!Array.isInstanceOfType(n))throw Error.argument("attachments");};window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachment$p=function(n){if(!Object.isInstanceOfType(n))throw Error.argument("attachments");if(!("type"in n)||!("name"in n))throw Error.argument("attachments");if(!("url"in n||"itemId"in n))throw Error.argument("attachments");};window.OSF.DDA.OutlookAppOm._createAttachmentData$p=function(n){var i=null;if(n.type==="file"){var f=n.url;var t=n.name;var e=r.ScriptHelpers.isValueTrue(n.isInline);window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentUrlOrName$p(f,t);i=window.OSF.DDA.OutlookAppOm._createFileAttachmentData$p(f,t,e)}else if(n.type==="item"){var u=window.OSF.DDA.OutlookAppOm.getItemIdBasedOnHost(n.itemId);var t=n.name;window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentItemIdOrName$p(u,t);i=window.OSF.DDA.OutlookAppOm._createItemAttachmentData$p(u,t)}else throw Error.argument("attachments");return i};window.OSF.DDA.OutlookAppOm._createFileAttachmentData$p=function(n,t,i){return["file",t,n,i]};window.OSF.DDA.OutlookAppOm._createItemAttachmentData$p=function(n,t){return["item",t,n]};window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentUrlOrName$p=function(n,t){if(!String.isInstanceOfType(n)||!String.isInstanceOfType(t))throw Error.argument("attachments");if(n.length>2048)throw Error.argumentOutOfRange("attachments",n.length,window._u.ExtensibilityStrings.l_AttachmentUrlTooLong_Text);window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentName$p(t)};window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentItemIdOrName$p=function(n,t){if(!String.isInstanceOfType(n)||!String.isInstanceOfType(t))throw Error.argument("attachments");if(n.length>200)throw Error.argumentOutOfRange("attachments",n.length,window._u.ExtensibilityStrings.l_AttachmentItemIdTooLong_Text);window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentName$p(t)};window.OSF.DDA.OutlookAppOm._throwOnInvalidAttachmentName$p=function(n){if(n.length>255)throw Error.argumentOutOfRange("attachments",n.length,window._u.ExtensibilityStrings.l_AttachmentNameTooLong_Text);};window.OSF.DDA.OutlookAppOm._throwOnInvalidRestVersion$p=function(n){if(!n)throw Error.argumentNull("restVersion");if(n!==window.Microsoft.Office.WebExtension.MailboxEnums.RestVersion.v1_0&&n!==window.Microsoft.Office.WebExtension.MailboxEnums.RestVersion.v2_0&&n!==window.Microsoft.Office.WebExtension.MailboxEnums.RestVersion.Beta)throw Error.argument("restVersion");};window.OSF.DDA.OutlookAppOm.getItemIdBasedOnHost=function(n){return window.OSF.DDA.OutlookAppOm._instance$p._initialData$p$0&&window.OSF.DDA.OutlookAppOm._instance$p._initialData$p$0.get__isRestIdSupported$i$0()?window.OSF.DDA.OutlookAppOm._instance$p.convertToRestId(n,window.Microsoft.Office.WebExtension.MailboxEnums.RestVersion.v1_0):window.OSF.DDA.OutlookAppOm._instance$p.convertToEwsId(n,window.Microsoft.Office.WebExtension.MailboxEnums.RestVersion.v1_0)};window.OSF.DDA.OutlookAppOm.addAdditionalArgs=function(n,t){return t};window.OSF.DDA.OutlookAppOm._throwOnArgumentType$p=function(n,t,i){if(Object.getType(n)!==t)throw Error.argumentType(i);};window.OSF.DDA.OutlookAppOm._validateOptionalStringParameter$p=function(n,t,i,u){if(!r.ScriptHelpers.isNullOrUndefined(n)){window.OSF.DDA.OutlookAppOm._throwOnArgumentType$p(n,String,u);var f=n;window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(f.length,t,i,u)}};window.OSF.DDA.OutlookAppOm._convertRecipientArrayParameterForOutlookForDisplayApi$p=function(n){return n?n.join(";"):null};window.OSF.DDA.OutlookAppOm._convertComposeEmailDictionaryParameterForSetApi$p=function(n){if(!n)return null;for(var i=new Array(n.length),t=0;t<n.length;t++)i[t]=[n[t].address,n[t].name];return i};window.OSF.DDA.OutlookAppOm._validateAndNormalizeRecipientEmails$p=function(n,t){if(r.ScriptHelpers.isNullOrUndefined(n))return null;window.OSF.DDA.OutlookAppOm._throwOnArgumentType$p(n,Array,t);var u=n;var f=null;var e=!1;window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(u.length,0,window.OSF.DDA.OutlookAppOm._maxRecipients$p,String.format("{0}.length",t));for(var i=0;i<u.length;i++)if(r.EmailAddressDetails.isInstanceOfType(u[i])){e=!0;break}e&&(f=[]);for(var i=0;i<u.length;i++)if(e){f[i]=r.EmailAddressDetails.isInstanceOfType(u[i])?u[i].emailAddress:u[i];window.OSF.DDA.OutlookAppOm._throwOnArgumentType$p(f[i],String,String.format("{0}[{1}]",t,i))}else window.OSF.DDA.OutlookAppOm._throwOnArgumentType$p(u[i],String,String.format("{0}[{1}]",t,i));return f};u.DDA.OutlookAppOm.prototype={_initialData$p$0:null,_item$p$0:null,_userProfile$p$0:null,_diagnostics$p$0:null,_officeAppContext$p$0:null,_appReadyCallback$p$0:null,_clientEndPoint$p$0:null,_hostItemType$p$0:0,_supportsPersistence$p$0:!1,_additionalOutlookParams$p$0:null,get_clientEndPoint:function(){this._clientEndPoint$p$0||(this._clientEndPoint$p$0=u._OfficeAppFactory.getClientEndPoint());return this._clientEndPoint$p$0},set_clientEndPoint:function(n){this._clientEndPoint$p$0=n;return n},get_initialData:function(){return this._initialData$p$0},get__appName$i$0:function(){return this._officeAppContext$p$0.get_appName()},get_additionalOutlookParams:function(){return this._additionalOutlookParams$p$0},windowOpenOverrideHandler:function(n,t,i,r){this.invokeHostMethod(403,{launchUrl:n},null)},createAsyncResult:function(n,t,i,f,e){var s={};var o=null;s[u.DDA.AsyncResultEnum.Properties.Value]=n;s[u.DDA.AsyncResultEnum.Properties.Context]=f;if(0!==t){o={};var h=r.OutlookErrorManager.getErrorArgs(i);o[u.DDA.AsyncResultEnum.ErrorProperties.Name]=h.name;o[u.DDA.AsyncResultEnum.ErrorProperties.Message]=e?e:h.message;o[u.DDA.AsyncResultEnum.ErrorProperties.Code]=i}return new u.DDA.AsyncResult(s,o)},_throwOnMethodCallForInsufficientPermission$i$0:function(n,t){if(this._initialData$p$0._permissionLevel$p$0<n)throw Error.create(String.format(window._u.ExtensibilityStrings.l_ElevatedPermissionNeededForMethod_Text,t));},_displayReplyForm$i$0:function(n){this._displayReplyFormHelper$p$0(n,!1)},_displayReplyAllForm$i$0:function(n){this._displayReplyFormHelper$p$0(n,!0)},_displayReplyFormHelper$p$0:function(n,t){if(String.isInstanceOfType(n))this._doDisplayReplyForm$p$0(n,t);else if(Object.isInstanceOfType(n)&&Object.getTypeName(n)==="Object")this._doDisplayReplyFormWithAttachments$p$0(n,t);else throw Error.argumentType();},_doDisplayReplyForm$p$0:function(n,t){r.ScriptHelpers.isNullOrUndefined(n)||window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,window.OSF.DDA.OutlookAppOm.maxBodyLength,"htmlBody");this.invokeHostMethod(t?11:10,{htmlBody:n},null)},_doDisplayReplyFormWithAttachments$p$0:function(n,t){var f=window.OSF.DDA.OutlookAppOm._getHtmlBody$p(n);var u=window.OSF.DDA.OutlookAppOm._getAttachments$p(n);var i=r.CommonParameters.parse(window.OSF.DDA.OutlookAppOm._getOptionsAndCallback$p(n),!1);var e=this;this._standardInvokeHostMethod$i$0(t?31:30,{htmlBody:f,attachments:window.OSF.DDA.OutlookAppOm._createAttachmentsDataForHost$p(u)},function(n){return n},i._asyncContext$p$0,i._callback$p$0)},_standardInvokeHostMethod$i$0:function(n,t,i,r,u){var f=this;this.invokeHostMethod(n,t,function(n,t){if(u){var o=null;if(Object.isInstanceOfType(t)){var e=t;if("error"in e||"data"in e||"errorCode"in e)if(e.error){var s=e.errorCode;o=f.createAsyncResult(null,1,s,r,null)}else{var h=i?i(e.data):e.data;o=f.createAsyncResult(h,0,0,r,null)}}!o&&n&&(o=f.createAsyncResult(null,1,9002,r,null));u(o)}})},invokeHostMethod:function(n,t,i){if(64===this._officeAppContext$p$0.get_appName()){var r={ApiParams:t};r.MethodData={ControlId:u._OfficeAppFactory.getId(),DispatchId:n};r=window.OSF.DDA.OutlookAppOm.addAdditionalArgs(n,r);n===1?this.get_clientEndPoint().invoke("GetInitialData",i,r):this.get_clientEndPoint().invoke("ExecuteMethod",i,r)}else if(this._isOwaOnlyMethod$p$0(n))i&&i(-2,null);else{var f=this._convertToOutlookParameters$p$0(n,t);var e=this;u.ClientHostController.execute(n,f,function(n,t){if(i){var f=n.toArray();var u=window.JSON.parse(f[0]);if(Object.isInstanceOfType(u)){var r=u;if(f.length>1&&f[1]){r.error=!0;r.errorCode=f[1]}else r.error=!1;i(t,r)}else if(Number.isInstanceOfType(u)){var e={};e.error=!0;e.errorCode=u;i(t,e)}else throw Error.notImplemented("Return data type from host must be Dictionary or int");}})}},_dictionaryToDate$i$0:function(n){var t=new Date(n.year,n.month,n.date,n.hours,n.minutes,n.seconds,n.milliseconds?n.milliseconds:0);if(window.isNaN(t.getTime()))throw Error.format(window._u.ExtensibilityStrings.l_InvalidDate_Text);return t},_dateToDictionary$i$0:function(n){var t={};t.month=n.getMonth();t.date=n.getDate();t.year=n.getFullYear();t.hours=n.getHours();t.minutes=n.getMinutes();t.seconds=n.getSeconds();t.milliseconds=n.getMilliseconds();return t},_isOwaOnlyMethod$p$0:function(n){switch(n){case 402:case 401:case 400:case 403:return!0;default:return!1}},isOutlook16OrGreater:function(){var n=this._initialData$p$0.get__hostVersion$i$0();var i=0;var t=0;if(n){i=n.indexOf(".");t=window.parseInt(n.substring(0,i))}return t>=16},_convertToOutlookParameters$p$0:function(n,t){var i=null;switch(n){case 1:case 2:case 12:case 3:case 14:case 18:case 26:case 32:case 41:case 34:break;case 4:var r=window.JSON.stringify(t.customProperties);i=[r];break;case 5:i=[t.body];break;case 8:case 9:i=[t.itemId];break;case 7:i=[window.OSF.DDA.OutlookAppOm._convertRecipientArrayParameterForOutlookForDisplayApi$p(t.requiredAttendees),window.OSF.DDA.OutlookAppOm._convertRecipientArrayParameterForOutlookForDisplayApi$p(t.optionalAttendees),t.start,t.end,t.location,window.OSF.DDA.OutlookAppOm._convertRecipientArrayParameterForOutlookForDisplayApi$p(t.resources),t.subject,t.body];break;case 44:i=[window.OSF.DDA.OutlookAppOm._convertRecipientArrayParameterForOutlookForDisplayApi$p(t.toRecipients),window.OSF.DDA.OutlookAppOm._convertRecipientArrayParameterForOutlookForDisplayApi$p(t.ccRecipients),window.OSF.DDA.OutlookAppOm._convertRecipientArrayParameterForOutlookForDisplayApi$p(t.bccRecipients),t.subject,t.htmlBody,t.attachments];break;case 43:i=[t.ewsIdOrEmail];break;case 45:i=[t.module,t.queryString];break;case 40:i=[t.extensionId,t.consentState];break;case 11:case 10:i=[t.htmlBody];break;case 31:case 30:i=[t.htmlBody,t.attachments];break;case 23:case 13:case 38:case 29:i=[t.data,t.coercionType];break;case 37:case 28:i=[t.coercionType];break;case 17:i=[t.subject];break;case 15:i=[t.recipientField];break;case 22:case 21:i=[t.recipientField,window.OSF.DDA.OutlookAppOm._convertComposeEmailDictionaryParameterForSetApi$p(t.recipientArray)];break;case 19:i=[t.itemId,t.name];break;case 16:i=[t.uri,t.name,t.isInline];break;case 20:i=[t.attachmentIndex];break;case 25:i=[t.TimeProperty,t.time];break;case 24:i=[t.TimeProperty];break;case 27:i=[t.location];break;case 33:case 35:i=[t.key,t.type,t.persistent,t.message,t.icon];break;case 36:i=[t.key];break;default:break}this._supportsPersistence$p$0&&(i?i.push(window.JSON.stringify(this._additionalOutlookParams$p$0)):i=[window.JSON.stringify(this._additionalOutlookParams$p$0)]);return i},_displayNewAppointmentFormApi$p$0:function(n){var f=window.OSF.DDA.OutlookAppOm._validateAndNormalizeRecipientEmails$p(n.requiredAttendees,"requiredAttendees");var u=window.OSF.DDA.OutlookAppOm._validateAndNormalizeRecipientEmails$p(n.optionalAttendees,"optionalAttendees");window.OSF.DDA.OutlookAppOm._validateOptionalStringParameter$p(n.location,0,window.OSF.DDA.OutlookAppOm._maxLocationLength$p,"location");window.OSF.DDA.OutlookAppOm._validateOptionalStringParameter$p(n.body,0,window.OSF.DDA.OutlookAppOm.maxBodyLength,"body");window.OSF.DDA.OutlookAppOm._validateOptionalStringParameter$p(n.subject,0,window.OSF.DDA.OutlookAppOm._maxSubjectLength$p,"subject");if(!r.ScriptHelpers.isNullOrUndefined(n.start)){window.OSF.DDA.OutlookAppOm._throwOnArgumentType$p(n.start,Date,"start");var s=n.start;n.start=s.getTime();if(!r.ScriptHelpers.isNullOrUndefined(n.end)){window.OSF.DDA.OutlookAppOm._throwOnArgumentType$p(n.end,Date,"end");var i=n.end;if(i<s)throw Error.argumentOutOfRange("end",i,window._u.ExtensibilityStrings.l_InvalidEventDates_Text);n.end=i.getTime()}}var t=null;if(f||u){t={};var h=n;for(var e in h){var o={key:e,value:h[e]};t[o.key]=o.value}f&&(t.requiredAttendees=f);u&&(t.optionalAttendees=u)}this.invokeHostMethod(7,t||n,null)},displayNewMessageFormApi:function(n){var t={};if(n){var e=window.OSF.DDA.OutlookAppOm._validateAndNormalizeRecipientEmails$p(n.toRecipients,"toRecipients");var o=window.OSF.DDA.OutlookAppOm._validateAndNormalizeRecipientEmails$p(n.ccRecipients,"ccRecipients");var s=window.OSF.DDA.OutlookAppOm._validateAndNormalizeRecipientEmails$p(n.bccRecipients,"bccRecipients");window.OSF.DDA.OutlookAppOm._validateOptionalStringParameter$p(n.htmlBody,0,window.OSF.DDA.OutlookAppOm.maxBodyLength,"htmlBody");window.OSF.DDA.OutlookAppOm._validateOptionalStringParameter$p(n.subject,0,window.OSF.DDA.OutlookAppOm._maxSubjectLength$p,"subject");var f=window.OSF.DDA.OutlookAppOm._getAttachments$p(n);var i=n;for(var r in i){var u={key:r,value:i[r]};t[u.key]=u.value}e&&(t.toRecipients=e);o&&(t.ccRecipients=o);s&&(t.bccRecipients=s);f&&(t.attachments=window.OSF.DDA.OutlookAppOm._createAttachmentsDataForHost$p(f))}this.invokeHostMethod(44,t||n,null)},displayPersonaCardAsync:function(n){for(var u=[],t=1;t<arguments.length;++t)u[t-1]=arguments[t];if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("ewsIdOrEmail");else if(n==="")throw Error.argument("ewsIdOrEmail","ewsIdOrEmail cannot be empty.");var i=r.CommonParameters.parse(u,!1);this._standardInvokeHostMethod$i$0(43,{ewsIdOrEmail:n.trim()},null,i._asyncContext$p$0,i._callback$p$0)},navigateToModuleAsync:function(n){for(var e=[],i=1;i<arguments.length;++i)e[i-1]=arguments[i];window.OSF.DDA.OutlookAppOm._throwOnInvalidModule$p(n);var t=r.CommonParameters.parse(e,!1);var u={};if(n===window.Microsoft.Office.WebExtension.MailboxEnums.ModuleType.Addins){var f="";t._options$p$0&&t._options$p$0.queryString&&(f=t._options$p$0.queryString);u.queryString=f}u.module=n;this._standardInvokeHostMethod$i$0(45,u,null,t._asyncContext$p$0,t._callback$p$0)},_initializeMethods$p$0:function(){var n=this;if(r.Item.isInstanceOfType(this._item$p$0)||this._hostItemType$p$0===6){n.displayNewAppointmentForm=this.$$d__displayNewAppointmentFormApi$p$0;n.displayNewMessageForm=this.$$d_displayNewMessageFormApi;n.displayPersonaCardAsync=this.$$d_displayPersonaCardAsync;n.navigateToModuleAsync=this.$$d_navigateToModuleAsync}},_getInitialDataResponseHandler$p$0:function(n,t){if(!n){this.initialize(t);this.displayName="mailbox";window.setTimeout(this.$$d__callAppReadyCallback$p$0,0)}},_callAppReadyCallback$p$0:function(){this._appReadyCallback$p$0()},_invokeGetTokenMethodAsync$p$0:function(n,t,i,u){if(r.ScriptHelpers.isNullOrUndefined(i))throw Error.argumentNull("callback");var f=this;this.invokeHostMethod(n,null,function(n,t){var e;if(n)e=f.createAsyncResult(null,1,9017,u,String.format(window._u.ExtensibilityStrings.l_InternalProtocolError_Text,n));else{var r=t;e=r.wasSuccessful?f.createAsyncResult(r.token,0,0,u,null):f.createAsyncResult(null,1,r.errorCode,u,r.errorMessage)}i(e)})},_getItem$p$0:function(){return this._item$p$0},_getUserProfile$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._initialData$p$0._permissionLevel$p$0);return this._userProfile$p$0},_getDiagnostics$p$0:function(){return this._diagnostics$p$0},_getEwsUrl$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._initialData$p$0._permissionLevel$p$0);return this._initialData$p$0.get__ewsUrl$i$0()},_getRestUrl$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._initialData$p$0._permissionLevel$p$0);return this._initialData$p$0.get__restUrl$i$0()?this._initialData$p$0.get__restUrl$i$0():null},_findOffset$p$0:function(n){for(var r=this._initialData$p$0.get__timeZoneOffsets$i$0(),i=0;i<r.length;i++){var t=r[i];var f=window.parseInt(t.start);var u=window.parseInt(t.end);if(n.getTime()-f>=0&&n.getTime()-u<0)return window.parseInt(t.offset)}throw Error.format(window._u.ExtensibilityStrings.l_InvalidDate_Text);},_areStringsLoaded$p$0:function(){var n=!1;try{n=!r.ScriptHelpers.isNullOrUndefined(window._u.ExtensibilityStrings.l_EwsRequestOversized_Text)}catch(t){}return n},_loadLocalizedScript$p$0:function(n){for(var s=null,l="",a=document.getElementsByTagName("script"),o=a.length-1;o>=0;o--){var i=null;var v=a[o].attributes;if(v){var p=v.getNamedItem("src");p&&(i=p.value);if(i){var y=!1;i=i.toLowerCase();var f=i.indexOf("office_strings.js");if(f<0){f=i.indexOf("office_strings.debug.js");y=!0}if(f>0&&f<i.length){s=i.replace(y?"office_strings.debug.js":"office_strings.js","outlook_strings.js");var r=i.substring(0,f);var u=r.lastIndexOf("/",r.length-2);u===-1&&(u=r.lastIndexOf("\\",r.length-2));u!==-1&&r.length>u+1&&(l=r.substring(0,u+1));break}}}}if(s){var h=document.getElementsByTagName("head")[0];var t=null;var b=this;var e=function(){if(n&&(!t.readyState||t.readyState&&(t.readyState==="loaded"||t.readyState==="complete"))){t.onload=null;t.onreadystatechange=null;n()}};var c=this;var w=function(){if(!c._areStringsLoaded$p$0()){var n=l+"en-us/"+"outlook_strings.js";t.onload=null;t.onreadystatechange=null;t=c._createScriptElement$p$0(n);t.onload=e;t.onreadystatechange=e;h.appendChild(t)}};t=this._createScriptElement$p$0(s);t.onload=e;t.onreadystatechange=e;window.setTimeout(w,2e3);h.appendChild(t)}},_createScriptElement$p$0:function(n){var t=document.createElement("script");t.type="text/javascript";t.src=n;return t}};u.DDA.OutlookAppOm.prototype.initialize=function(n){var t="itemType";this._initialData$p$0=new r.InitialData(n);this._hostItemType$p$0=n[t];1===n[t]?this._item$p$0=new r.Message(this._initialData$p$0):3===n[t]?this._item$p$0=new r.MeetingRequest(this._initialData$p$0):2===n[t]?this._item$p$0=new r.Appointment(this._initialData$p$0):4===n[t]?this._item$p$0=new r.MessageCompose(this._initialData$p$0):5===n[t]?this._item$p$0=new r.AppointmentCompose(this._initialData$p$0):6===n[t];this._userProfile$p$0=new r.UserProfile(this._initialData$p$0);this._diagnostics$p$0=new r.Diagnostics(this._initialData$p$0,this._officeAppContext$p$0.get_appName());this._additionalOutlookParams$p$0={};window.OSF.DDA.OutlookAppOm._instance$p.get__appName$i$0()===8&&(this._supportsPersistence$p$0=this.isOutlook16OrGreater());this._initializeMethods$p$0();r.InitialData._defineReadOnlyProperty$i(this,"item",this.$$d__getItem$p$0);r.InitialData._defineReadOnlyProperty$i(this,"userProfile",this.$$d__getUserProfile$p$0);r.InitialData._defineReadOnlyProperty$i(this,"diagnostics",this.$$d__getDiagnostics$p$0);r.InitialData._defineReadOnlyProperty$i(this,"ewsUrl",this.$$d__getEwsUrl$p$0);r.InitialData._defineReadOnlyProperty$i(this,"restUrl",this.$$d__getRestUrl$p$0);window.OSF.DDA.OutlookAppOm._instance$p.get__appName$i$0()===64&&this._initialData$p$0.get__overrideWindowOpen$i$0()&&(window.open=this.$$d_windowOpenOverrideHandler)};u.DDA.OutlookAppOm.prototype.makeEwsRequestAsync=function(n){for(var u=[],i=1;i<arguments.length;++i)u[i-1]=arguments[i];if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("data");if(n.length>window.OSF.DDA.OutlookAppOm._maxEwsRequestSize$p)throw Error.argument("data",window._u.ExtensibilityStrings.l_EwsRequestOversized_Text);this._throwOnMethodCallForInsufficientPermission$i$0(3,"makeEwsRequestAsync");var f=r.CommonParameters.parse(u,!0,!0);var t=new r.EwsRequest(f._asyncContext$p$0);var e=this;t.onreadystatechange=function(){4===t.get__requestState$i$1()&&f._callback$p$0(t._asyncResult$p$0)};t.send(n)};u.DDA.OutlookAppOm.prototype.recordDataPoint=function(n){if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("data");this.invokeHostMethod(402,n,null)};u.DDA.OutlookAppOm.prototype.recordTrace=function(n){if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("data");this.invokeHostMethod(401,n,null)};u.DDA.OutlookAppOm.prototype.trackCtq=function(n){if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("data");this.invokeHostMethod(400,n,null)};u.DDA.OutlookAppOm.prototype.convertToLocalClientTime=function(n){var t=new Date(n.getTime());var i=t.getTimezoneOffset()*-1;if(this._initialData$p$0&&this._initialData$p$0.get__timeZoneOffsets$i$0()){t.setUTCMinutes(t.getUTCMinutes()-i);i=this._findOffset$p$0(t);t.setUTCMinutes(t.getUTCMinutes()+i)}var r=this._dateToDictionary$i$0(t);r.timezoneOffset=i;return r};u.DDA.OutlookAppOm.prototype.convertToUtcClientTime=function(n){var t=this._dictionaryToDate$i$0(n);if(this._initialData$p$0&&this._initialData$p$0.get__timeZoneOffsets$i$0()){var i=this._findOffset$p$0(t);t.setUTCMinutes(t.getUTCMinutes()-i);i=n.timezoneOffset?n.timezoneOffset:t.getTimezoneOffset()*-1;t.setUTCMinutes(t.getUTCMinutes()+i)}return t};u.DDA.OutlookAppOm.prototype.convertToRestId=function(n,t){if(!n)throw Error.argumentNull("itemId");window.OSF.DDA.OutlookAppOm._throwOnInvalidRestVersion$p(t);return n.replace(new RegExp("[/]","g"),"-").replace(new RegExp("[+]","g"),"_")};u.DDA.OutlookAppOm.prototype.convertToEwsId=function(n,t){if(!n)throw Error.argumentNull("itemId");window.OSF.DDA.OutlookAppOm._throwOnInvalidRestVersion$p(t);return n.replace(new RegExp("[-]","g"),"/").replace(new RegExp("[_]","g"),"+")};u.DDA.OutlookAppOm.prototype.getUserIdentityTokenAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];this._throwOnMethodCallForInsufficientPermission$i$0(1,"getUserIdentityTokenAsync");var t=r.CommonParameters.parse(i,!0,!0);this._invokeGetTokenMethodAsync$p$0(2,"GetUserIdentityToken",t._callback$p$0,t._asyncContext$p$0)};u.DDA.OutlookAppOm.prototype.getCallbackTokenAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];this._throwOnMethodCallForInsufficientPermission$i$0(1,"getCallbackTokenAsync");var t=r.CommonParameters.parse(i,!0,!0);this._invokeGetTokenMethodAsync$p$0(12,"GetCallbackToken",t._callback$p$0,t._asyncContext$p$0)};u.DDA.OutlookAppOm.prototype.displayMessageForm=function(n){if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("itemId");this.invokeHostMethod(8,{itemId:window.OSF.DDA.OutlookAppOm.getItemIdBasedOnHost(n)},null)};u.DDA.OutlookAppOm.prototype.displayAppointmentForm=function(n){if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("itemId");this.invokeHostMethod(9,{itemId:window.OSF.DDA.OutlookAppOm.getItemIdBasedOnHost(n)},null)};u.DDA.OutlookAppOm.prototype.RegisterConsentAsync=function(n){if(n!==2&&n!==1&&n)throw Error.argumentOutOfRange("consentState");var t={};t.consentState=n.toString();t.extensionId=this.GetExtensionId();this.invokeHostMethod(40,t,null)};u.DDA.OutlookAppOm.prototype.CloseApp=function(){this.invokeHostMethod(42,null,null)};u.DDA.OutlookAppOm.prototype.GetIsRead=function(){return this._initialData$p$0.get__isRead$i$0()};u.DDA.OutlookAppOm.prototype.GetEndNodeUrl=function(){return this._initialData$p$0.get__endNodeUrl$i$0()};u.DDA.OutlookAppOm.prototype.GetConsentMetadata=function(){return this._initialData$p$0.get__consentMetadata$i$0()};u.DDA.OutlookAppOm.prototype.GetEntryPointUrl=function(){return this._initialData$p$0.get__entryPointUrl$i$0()};u.DDA.OutlookAppOm.prototype.GetMarketplaceContentMarket=function(){return this._initialData$p$0.get__marketplaceContentMarket$i$0()};u.DDA.OutlookAppOm.prototype.GetMarketplaceAssetId=function(){return this._initialData$p$0.get__marketplaceAssetId$i$0()};u.DDA.OutlookAppOm.prototype.GetExtensionId=function(){return this._initialData$p$0.get__extensionId$i$0()};u.DDA.OutlookAppOm.prototype.setCurrentItemNumber=function(n){n>0&&(this._additionalOutlookParams$p$0.itemNumber=n.toString())};window.OSF.DDA.Settings=u.DDA.Settings=function(n){this._rawData$p$0=n};window.OSF.DDA.Settings._convertFromRawSettings$p=function(n){if(!n)return{};if(window.OSF.DDA.OutlookAppOm._instance$p.get__appName$i$0()===8||window.OSF.DDA.OutlookAppOm._instance$p.get__appName$i$0()===65536||window.OSF.DDA.OutlookAppOm._instance$p.get__appName$i$0()===4194304){var t=n.SettingsKey;if(t)return u.DDA.SettingsManager.deserializeSettings(t)}return n};u.DDA.Settings.prototype={_rawData$p$0:null,_settingsData$p$0:null,get__data$p$0:function(){if(!this._settingsData$p$0){this._settingsData$p$0=window.OSF.DDA.Settings._convertFromRawSettings$p(this._rawData$p$0);this._rawData$p$0=null}return this._settingsData$p$0},_saveSettingsForOutlook$p$0:function(n,t){var r=null;try{var e=u.DDA.SettingsManager.serializeSettings(this.get__data$p$0());var o=window.JSON.stringify(e);var f={SettingsKey:o};u.DDA.ClientSettingsManager.write(f)}catch(s){r=s}if(n){var i;i=r?window.OSF.DDA.OutlookAppOm._instance$p.createAsyncResult(null,1,9019,t,r.message):window.OSF.DDA.OutlookAppOm._instance$p.createAsyncResult(null,0,0,t,null);n(i)}},_saveSettingsForOwa$p$0:function(n,t){var i=u.DDA.SettingsManager.serializeSettings(this.get__data$p$0());var r=this;window.OSF.DDA.OutlookAppOm._instance$p.invokeHostMethod(404,[i],function(i,r){if(n){var u;if(i)u=window.OSF.DDA.OutlookAppOm._instance$p.createAsyncResult(null,1,9017,t,String.format(window._u.ExtensibilityStrings.l_InternalProtocolError_Text,i));else{var f=r;u=f.error?window.OSF.DDA.OutlookAppOm._instance$p.createAsyncResult(null,1,9019,t,f.errorMessage):window.OSF.DDA.OutlookAppOm._instance$p.createAsyncResult(null,0,0,t,null)}n(u)}})}};u.DDA.Settings.prototype.get=function(n){return this.get__data$p$0()[n]};u.DDA.Settings.prototype.set=function(n,t){this.get__data$p$0()[n]=t};u.DDA.Settings.prototype.remove=function(n){delete this.get__data$p$0()[n]};u.DDA.Settings.prototype.saveAsync=function(){for(var i=[],t=0;t<arguments.length;++t)i[t]=arguments[t];var n=r.CommonParameters.parse(i,!1);if(window.JSON.stringify(u.DDA.SettingsManager.serializeSettings(this.get__data$p$0())).length>32768){var f=window.OSF.DDA.OutlookAppOm._instance$p.createAsyncResult(null,1,9019,n._asyncContext$p$0,"");var e=this;window.setTimeout(function(){n._callback$p$0(f)},0);return}window.OSF.DDA.OutlookAppOm._instance$p.get__appName$i$0()===64?this._saveSettingsForOwa$p$0(n._callback$p$0,n._asyncContext$p$0):this._saveSettingsForOutlook$p$0(n._callback$p$0,n._asyncContext$p$0)};Type.registerNamespace("$h");var r=window.$h||{};Type.registerNamespace("Office.cast");var f=window.Office||{};f.cast=f.cast||{};r.Appointment=function(n){this.$$d__getOrganizer$p$2=Function.createDelegate(this,this._getOrganizer$p$2);this.$$d__getNormalizedSubject$p$2=Function.createDelegate(this,this._getNormalizedSubject$p$2);this.$$d__getSubject$p$2=Function.createDelegate(this,this._getSubject$p$2);this.$$d__getResources$p$2=Function.createDelegate(this,this._getResources$p$2);this.$$d__getRequiredAttendees$p$2=Function.createDelegate(this,this._getRequiredAttendees$p$2);this.$$d__getOptionalAttendees$p$2=Function.createDelegate(this,this._getOptionalAttendees$p$2);this.$$d__getLocation$p$2=Function.createDelegate(this,this._getLocation$p$2);this.$$d__getEnd$p$2=Function.createDelegate(this,this._getEnd$p$2);this.$$d__getStart$p$2=Function.createDelegate(this,this._getStart$p$2);r.Appointment.initializeBase(this,[n]);r.InitialData._defineReadOnlyProperty$i(this,"start",this.$$d__getStart$p$2);r.InitialData._defineReadOnlyProperty$i(this,"end",this.$$d__getEnd$p$2);r.InitialData._defineReadOnlyProperty$i(this,"location",this.$$d__getLocation$p$2);r.InitialData._defineReadOnlyProperty$i(this,"optionalAttendees",this.$$d__getOptionalAttendees$p$2);r.InitialData._defineReadOnlyProperty$i(this,"requiredAttendees",this.$$d__getRequiredAttendees$p$2);r.InitialData._defineReadOnlyProperty$i(this,"resources",this.$$d__getResources$p$2);r.InitialData._defineReadOnlyProperty$i(this,"subject",this.$$d__getSubject$p$2);r.InitialData._defineReadOnlyProperty$i(this,"normalizedSubject",this.$$d__getNormalizedSubject$p$2);r.InitialData._defineReadOnlyProperty$i(this,"organizer",this.$$d__getOrganizer$p$2)};r.Appointment.prototype={getItemType:function(){return window.Microsoft.Office.WebExtension.MailboxEnums.ItemType.Appointment},_getStart$p$2:function(){return this._data$p$0.get__start$i$0()},_getEnd$p$2:function(){return this._data$p$0.get__end$i$0()},_getLocation$p$2:function(){return this._data$p$0.get__location$i$0()},_getOptionalAttendees$p$2:function(){return this._data$p$0.get__cc$i$0()},_getRequiredAttendees$p$2:function(){return this._data$p$0.get__to$i$0()},_getResources$p$2:function(){return this._data$p$0.get__resources$i$0()},_getSubject$p$2:function(){return this._data$p$0.get__subject$i$0()},_getNormalizedSubject$p$2:function(){return this._data$p$0.get__normalizedSubject$i$0()},_getOrganizer$p$2:function(){return this._data$p$0.get__organizer$i$0()}};r.Appointment.prototype.getEntities=function(){return this._data$p$0._getEntities$i$0()};r.Appointment.prototype.getEntitiesByType=function(n){return this._data$p$0._getEntitiesByType$i$0(n)};r.Appointment.prototype.getSelectedEntities=function(){return this._data$p$0._getSelectedEntities$i$0()};r.Appointment.prototype.getRegExMatches=function(){window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"getRegExMatches");return this._data$p$0._getRegExMatches$i$0()};r.Appointment.prototype.getFilteredEntitiesByName=function(n){return this._data$p$0._getFilteredEntitiesByName$i$0(n)};r.Appointment.prototype.getRegExMatchesByName=function(n){window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"getRegExMatchesByName");return this._data$p$0._getRegExMatchesByName$i$0(n)};r.Appointment.prototype.getSelectedRegExMatches=function(){window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"getSelectedRegExMatches");return this._data$p$0._getSelectedRegExMatches$i$0()};r.Appointment.prototype.displayReplyForm=function(n){window.OSF.DDA.OutlookAppOm._instance$p._displayReplyForm$i$0(n)};r.Appointment.prototype.displayReplyAllForm=function(n){window.OSF.DDA.OutlookAppOm._instance$p._displayReplyAllForm$i$0(n)};r.AppointmentCompose=function(n){this.$$d__getLocation$p$2=Function.createDelegate(this,this._getLocation$p$2);this.$$d__getEnd$p$2=Function.createDelegate(this,this._getEnd$p$2);this.$$d__getStart$p$2=Function.createDelegate(this,this._getStart$p$2);this.$$d__getOptionalAttendees$p$2=Function.createDelegate(this,this._getOptionalAttendees$p$2);this.$$d__getRequiredAttendees$p$2=Function.createDelegate(this,this._getRequiredAttendees$p$2);r.AppointmentCompose.initializeBase(this,[n]);r.InitialData._defineReadOnlyProperty$i(this,"requiredAttendees",this.$$d__getRequiredAttendees$p$2);r.InitialData._defineReadOnlyProperty$i(this,"optionalAttendees",this.$$d__getOptionalAttendees$p$2);r.InitialData._defineReadOnlyProperty$i(this,"start",this.$$d__getStart$p$2);r.InitialData._defineReadOnlyProperty$i(this,"end",this.$$d__getEnd$p$2);r.InitialData._defineReadOnlyProperty$i(this,"location",this.$$d__getLocation$p$2)};r.AppointmentCompose.prototype={_requiredAttendees$p$2:null,_optionalAttendees$p$2:null,_start$p$2:null,_end$p$2:null,_location$p$2:null,getItemType:function(){return window.Microsoft.Office.WebExtension.MailboxEnums.ItemType.Appointment},_getRequiredAttendees$p$2:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._requiredAttendees$p$2||(this._requiredAttendees$p$2=new r.ComposeRecipient(0,"requiredAttendees"));return this._requiredAttendees$p$2},_getOptionalAttendees$p$2:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._optionalAttendees$p$2||(this._optionalAttendees$p$2=new r.ComposeRecipient(1,"optionalAttendees"));return this._optionalAttendees$p$2},_getStart$p$2:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._start$p$2||(this._start$p$2=new r.ComposeTime(1));return this._start$p$2},_getEnd$p$2:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._end$p$2||(this._end$p$2=new r.ComposeTime(2));return this._end$p$2},_getLocation$p$2:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._location$p$2||(this._location$p$2=new r.ComposeLocation);return this._location$p$2}};r.AttachmentConstants=function(){};r.AttachmentDetails=function(n){this.$$d__getIsInline$p$0=Function.createDelegate(this,this._getIsInline$p$0);this.$$d__getAttachmentType$p$0=Function.createDelegate(this,this._getAttachmentType$p$0);this.$$d__getSize$p$0=Function.createDelegate(this,this._getSize$p$0);this.$$d__getContentType$p$0=Function.createDelegate(this,this._getContentType$p$0);this.$$d__getName$p$0=Function.createDelegate(this,this._getName$p$0);this.$$d__getId$p$0=Function.createDelegate(this,this._getId$p$0);this._data$p$0=n;r.InitialData._defineReadOnlyProperty$i(this,"id",this.$$d__getId$p$0);r.InitialData._defineReadOnlyProperty$i(this,"name",this.$$d__getName$p$0);r.InitialData._defineReadOnlyProperty$i(this,"contentType",this.$$d__getContentType$p$0);r.InitialData._defineReadOnlyProperty$i(this,"size",this.$$d__getSize$p$0);r.InitialData._defineReadOnlyProperty$i(this,"attachmentType",this.$$d__getAttachmentType$p$0);r.InitialData._defineReadOnlyProperty$i(this,"isInline",this.$$d__getIsInline$p$0)};r.AttachmentDetails.prototype={_data$p$0:null,_getId$p$0:function(){return this._data$p$0.id},_getName$p$0:function(){return this._data$p$0.name},_getContentType$p$0:function(){return this._data$p$0.contentType},_getSize$p$0:function(){return this._data$p$0.size},_getAttachmentType$p$0:function(){var n=this._data$p$0.attachmentType;return n<r.AttachmentDetails._attachmentTypeMap$p.length?r.AttachmentDetails._attachmentTypeMap$p[n]:window.Microsoft.Office.WebExtension.MailboxEnums.AttachmentType.File},_getIsInline$p$0:function(){return this._data$p$0.isInline}};r.Body=function(){};r.Body._tryMapToHostCoercionType$i=function(n,t){t.val=undefined;if(n===window.Microsoft.Office.WebExtension.CoercionType.Html)t.val=3;else if(n===window.Microsoft.Office.WebExtension.CoercionType.Text)t.val=0;else return!1;return!0};r.Body.prototype.getAsync=function(n){for(var e=[],t=1;t<arguments.length;++t)e[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"body.getAsync");var o=r.CommonParameters.parse(e,!0);var i;var f,u;if(!(u=r.Body._tryMapToHostCoercionType$i(n,f={val:i}),i=f.val,u))throw Error.argument("coercionType");var s={coercionType:i};window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(37,s,null,o._asyncContext$p$0,o._callback$p$0)};r.ComposeBody=function(){r.ComposeBody.initializeBase(this)};r.ComposeBody._createParameterDictionaryToHost$i=function(n,t){var u={data:n};if(t._options$p$0&&t._options$p$0.hasOwnProperty("coercionType")&&!r.ScriptHelpers.isNull(t._options$p$0.coercionType)){var i;var e,f;if(!(f=r.Body._tryMapToHostCoercionType$i(t._options$p$0.coercionType,e={val:i}),i=e.val,f)){t._callback$p$0&&t._callback$p$0(window.OSF.DDA.OutlookAppOm._instance$p.createAsyncResult(null,1,1e3,t._asyncContext$p$0,null));return null}u.coercionType=i}else u.coercionType=0;return u};r.ComposeBody.prototype.getTypeAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"body.getTypeAsync");var t=r.CommonParameters.parse(i,!0);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(14,null,null,t._asyncContext$p$0,t._callback$p$0)};r.ComposeBody.prototype.setSelectedDataAsync=function(n){for(var f=[],t=1;t<arguments.length;++t)f[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"body.setSelectedDataAsync");var i=r.CommonParameters.parse(f,!1);if(!String.isInstanceOfType(n))throw Error.argumentType("data",Object.getType(n),String);window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,1e6,"data");var u=r.ComposeBody._createParameterDictionaryToHost$i(n,i);u&&window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(13,u,null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeBody.prototype.prependAsync=function(n){for(var f=[],t=1;t<arguments.length;++t)f[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"body.prependAsync");var i=r.CommonParameters.parse(f,!1);if(!String.isInstanceOfType(n))throw Error.argumentType("data",Object.getType(n),String);window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,1e6,"data");var u=r.ComposeBody._createParameterDictionaryToHost$i(n,i);u&&window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(23,u,null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeBody.prototype.setAsync=function(n){for(var f=[],t=1;t<arguments.length;++t)f[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"body.setAsync");var i=r.CommonParameters.parse(f,!1);if(!String.isInstanceOfType(n))throw Error.argumentType("data",Object.getType(n),String);window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,1e6,"data");var u=r.ComposeBody._createParameterDictionaryToHost$i(n,i);u&&window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(38,u,null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeItem=function(n){this.$$d__getBody$p$1=Function.createDelegate(this,this._getBody$p$1);this.$$d__getSubject$p$1=Function.createDelegate(this,this._getSubject$p$1);r.ComposeItem.initializeBase(this,[n]);r.InitialData._defineReadOnlyProperty$i(this,"subject",this.$$d__getSubject$p$1);r.InitialData._defineReadOnlyProperty$i(this,"body",this.$$d__getBody$p$1)};r.ComposeItem.prototype={_subject$p$1:null,_body$p$1:null,_getBody$p$1:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._body$p$1||(this._body$p$1=new r.ComposeBody);return this._body$p$1},_getSubject$p$1:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._subject$p$1||(this._subject$p$1=new r.ComposeSubject);return this._subject$p$1}};r.ComposeItem.prototype.addFileAttachmentAsync=function(n,t){for(var e=[],u=2;u<arguments.length;++u)e[u-2]=arguments[u];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"addFileAttachmentAsync");if(!r.ScriptHelpers.isNonEmptyString(n))throw Error.argument("uri");if(!r.ScriptHelpers.isNonEmptyString(t))throw Error.argument("attachmentName");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,2048,"uri");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(t.length,0,255,"attachmentName");var i=r.CommonParameters.parse(e,!1);var f=!1;r.ScriptHelpers.isNull(i._options$p$0)||(f=r.ScriptHelpers.isValueTrue(i._options$p$0.isInline));var o={uri:n,name:t,isInline:f,__timeout__:6e5};window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(16,o,null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeItem.prototype.addItemAttachmentAsync=function(n,t){for(var f=[],i=2;i<arguments.length;++i)f[i-2]=arguments[i];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"addItemAttachmentAsync");if(!r.ScriptHelpers.isNonEmptyString(n))throw Error.argument("itemId");if(!r.ScriptHelpers.isNonEmptyString(t))throw Error.argument("attachmentName");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,200,"itemId");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(t.length,0,255,"attachmentName");var u=r.CommonParameters.parse(f,!1);var e={itemId:window.OSF.DDA.OutlookAppOm.getItemIdBasedOnHost(n),name:t,__timeout__:6e5};window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(19,e,null,u._asyncContext$p$0,u._callback$p$0)};r.ComposeItem.prototype.removeAttachmentAsync=function(n){for(var u=[],t=1;t<arguments.length;++t)u[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"removeAttachmentAsync");if(!r.ScriptHelpers.isNonEmptyString(n))throw Error.argument("attachmentId");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,200,"attachmentId");var i=r.CommonParameters.parse(u,!1);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(20,{attachmentIndex:n},null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeItem.prototype.getSelectedDataAsync=function(n){for(var e=[],t=1;t<arguments.length;++t)e[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"getSelectedDataAsync");var o=r.CommonParameters.parse(e,!0);var i;var f,u;if(n!==window.Microsoft.Office.WebExtension.CoercionType.Html&&n!==window.Microsoft.Office.WebExtension.CoercionType.Text||!(u=r.Body._tryMapToHostCoercionType$i(n,f={val:i}),i=f.val,u))throw Error.argument("coercionType");var s={coercionType:i};window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(28,s,null,o._asyncContext$p$0,o._callback$p$0)};r.ComposeItem.prototype.setSelectedDataAsync=function(n){for(var f=[],t=1;t<arguments.length;++t)f[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"setSelectedDataAsync");var i=r.CommonParameters.parse(f,!1);if(!String.isInstanceOfType(n))throw Error.argumentType("data",Object.getType(n),String);window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,1e6,"data");var u=r.ComposeBody._createParameterDictionaryToHost$i(n,i);u&&window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(29,u,null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeItem.prototype.close=function(){window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(41,null,null,null,null)};r.ComposeItem.prototype.saveAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"saveAsync");var t=r.CommonParameters.parse(i,!1);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(32,null,null,t._asyncContext$p$0,t._callback$p$0)};r.ComposeRecipient=function(n,t){this._type$p$0=n;this._propertyName$p$0=t};r.ComposeRecipient._throwOnInvalidDisplayNameOrEmail$p=function(n,t){if(!n&&!t)throw Error.argument("recipients");if(n&&n.length>255)throw Error.argumentOutOfRange("recipients",n.length,window._u.ExtensibilityStrings.l_DisplayNameTooLong_Text);if(t&&t.length>571)throw Error.argumentOutOfRange("recipients",t.length,window._u.ExtensibilityStrings.l_EmailAddressTooLong_Text);};r.ComposeRecipient._getAsyncFormatter$p=function(n){for(var u=n,i=[],t=0;t<u.length;t++){var f=new r.EmailAddressDetails(u[t]);i[t]=f}return i};r.ComposeRecipient._createEmailDictionaryForHost$p=function(n,t){return{address:n,name:t}};r.ComposeRecipient.prototype={_propertyName$p$0:null,_type$p$0:0,setAddHelper:function(n,t,i){window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,100,"recipients");var h=r.CommonParameters.parse(t,!1);var e=[];if(Array.isInstanceOfType(n))for(var u=0;u<n.length;u++)if(String.isInstanceOfType(n[u])){r.ComposeRecipient._throwOnInvalidDisplayNameOrEmail$p(n[u],n[u]);e[u]=r.ComposeRecipient._createEmailDictionaryForHost$p(n[u],n[u])}else if(r.EmailAddressDetails.isInstanceOfType(n[u])){var f=n[u];r.ComposeRecipient._throwOnInvalidDisplayNameOrEmail$p(f.displayName,f.emailAddress);e[u]=r.ComposeRecipient._createEmailDictionaryForHost$p(f.emailAddress,f.displayName)}else if(Object.isInstanceOfType(n[u])){var c=n[u];var o=c.emailAddress;var s=c.displayName;r.ComposeRecipient._throwOnInvalidDisplayNameOrEmail$p(s,o);e[u]=r.ComposeRecipient._createEmailDictionaryForHost$p(o,s)}else throw Error.argument("recipients");else throw Error.argument("recipients");var l=this;window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(i?21:22,{recipientField:this._type$p$0,recipientArray:e},function(n){return n},h._asyncContext$p$0,h._callback$p$0)}};r.ComposeRecipient.prototype.getAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];var t=r.CommonParameters.parse(i,!0);window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,this._propertyName$p$0+".getAsync");window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(15,{recipientField:this._type$p$0},r.ComposeRecipient._getAsyncFormatter$p,t._asyncContext$p$0,t._callback$p$0)};r.ComposeRecipient.prototype.setAsync=function(n){for(var i=[],t=1;t<arguments.length;++t)i[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,this._propertyName$p$0+".setAsync");this.setAddHelper(n,i,!0)};r.ComposeRecipient.prototype.addAsync=function(n){for(var i=[],t=1;t<arguments.length;++t)i[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,this._propertyName$p$0+".addAsync");this.setAddHelper(n,i,!1)};r.ComposeRecipient.RecipientField=function(){};r.ComposeRecipient.RecipientField.prototype={to:0,cc:1,bcc:2,requiredAttendees:0,optionalAttendees:1};r.ComposeRecipient.RecipientField.registerEnum("$h.0",!1);r.ComposeLocation=function(){};r.ComposeLocation.prototype.getAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"location.getAsync");var t=r.CommonParameters.parse(i,!0);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(26,null,null,t._asyncContext$p$0,t._callback$p$0)};r.ComposeLocation.prototype.setAsync=function(n){for(var u=[],t=1;t<arguments.length;++t)u[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"location.setAsync");var i=r.CommonParameters.parse(u,!1);window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,255,"location");window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(27,{location:n},null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeSubject=function(){};r.ComposeSubject.prototype.getAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];var t=r.CommonParameters.parse(i,!0);window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"subject.getAsync");window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(18,null,null,t._asyncContext$p$0,t._callback$p$0)};r.ComposeSubject.prototype.setAsync=function(n){for(var u=[],t=1;t<arguments.length;++t)u[t-1]=arguments[t];var i=r.CommonParameters.parse(u,!1);window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,"subject.setAsync");if(!String.isInstanceOfType(n))throw Error.argument("data");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,255,"data");window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(17,{subject:n},null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeTime=function(n){this.$$d__ticksToDateFormatter$p$0=Function.createDelegate(this,this._ticksToDateFormatter$p$0);this._timeType$p$0=n};r.ComposeTime.prototype={_timeType$p$0:0,_ticksToDateFormatter$p$0:function(n){var t=n;return new Date(t)},_getPropertyName$p$0:function(){return this._timeType$p$0===1?"start":"end"}};r.ComposeTime.prototype.getAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,this._getPropertyName$p$0()+".getAsync");var t=r.CommonParameters.parse(i,!0);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(24,{TimeProperty:this._timeType$p$0},this.$$d__ticksToDateFormatter$p$0,t._asyncContext$p$0,t._callback$p$0)};r.ComposeTime.prototype.setAsync=function(n){for(var u=[],t=1;t<arguments.length;++t)u[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(2,this._getPropertyName$p$0()+".setAsync");if(!Date.isInstanceOfType(n))throw Error.argumentType("dateTime",Object.getType(n),Date);if(window.isNaN(n.getTime()))throw Error.argument("dateTime");if(n.getTime()<-864e13||n.getTime()>864e13)throw Error.argumentOutOfRange("dateTime");var i=r.CommonParameters.parse(u,!1);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(25,{TimeProperty:this._timeType$p$0,time:n.getTime()},null,i._asyncContext$p$0,i._callback$p$0)};r.ComposeTime.TimeType=function(){};r.ComposeTime.TimeType.prototype={start:1,end:2};r.ComposeTime.TimeType.registerEnum("$h.1",!1);r.Contact=function(n){this.$$d__getContactString$p$0=Function.createDelegate(this,this._getContactString$p$0);this.$$d__getAddresses$p$0=Function.createDelegate(this,this._getAddresses$p$0);this.$$d__getUrls$p$0=Function.createDelegate(this,this._getUrls$p$0);this.$$d__getEmailAddresses$p$0=Function.createDelegate(this,this._getEmailAddresses$p$0);this.$$d__getPhoneNumbers$p$0=Function.createDelegate(this,this._getPhoneNumbers$p$0);this.$$d__getBusinessName$p$0=Function.createDelegate(this,this._getBusinessName$p$0);this.$$d__getPersonName$p$0=Function.createDelegate(this,this._getPersonName$p$0);this._data$p$0=n;r.InitialData._defineReadOnlyProperty$i(this,"personName",this.$$d__getPersonName$p$0);r.InitialData._defineReadOnlyProperty$i(this,"businessName",this.$$d__getBusinessName$p$0);r.InitialData._defineReadOnlyProperty$i(this,"phoneNumbers",this.$$d__getPhoneNumbers$p$0);r.InitialData._defineReadOnlyProperty$i(this,"emailAddresses",this.$$d__getEmailAddresses$p$0);r.InitialData._defineReadOnlyProperty$i(this,"urls",this.$$d__getUrls$p$0);r.InitialData._defineReadOnlyProperty$i(this,"addresses",this.$$d__getAddresses$p$0);r.InitialData._defineReadOnlyProperty$i(this,"contactString",this.$$d__getContactString$p$0)};r.Contact.prototype={_data$p$0:null,_phoneNumbers$p$0:null,_getPersonName$p$0:function(){return this._data$p$0.PersonName},_getBusinessName$p$0:function(){return this._data$p$0.BusinessName},_getAddresses$p$0:function(){return r.Entities._getExtractedStringProperty$i(this._data$p$0,"Addresses")},_getEmailAddresses$p$0:function(){return r.Entities._getExtractedStringProperty$i(this._data$p$0,"EmailAddresses")},_getUrls$p$0:function(){return r.Entities._getExtractedStringProperty$i(this._data$p$0,"Urls")},_getPhoneNumbers$p$0:function(){if(!this._phoneNumbers$p$0){var n=this;this._phoneNumbers$p$0=r.Entities._getExtractedObjects$i(r.PhoneNumber,this._data$p$0,"PhoneNumbers",function(n){return new r.PhoneNumber(n)})}return this._phoneNumbers$p$0},_getContactString$p$0:function(){return this._data$p$0.ContactString}};r.CustomProperties=function(n){if(r.ScriptHelpers.isNullOrUndefined(n))throw Error.argumentNull("data");if(Array.isInstanceOfType(n)){var t=n;if(t.length>0)this._data$p$0=t[0];else throw Error.argument("data");}else this._data$p$0=n};r.CustomProperties.prototype={_data$p$0:null};r.CustomProperties.prototype.get=function(n){var i=this._data$p$0[n];if(typeof i=="string"){var t=i;if(t.length>6&&t.startsWith("Date(")&&t.endsWith(")")){var f=t.substring(5,t.length-1);var r=window.parseInt(f);if(!window.isNaN(r)){var u=new Date(r);u&&(i=u)}}}return i};r.CustomProperties.prototype.set=function(n,t){window.OSF.OUtil.isDate(t)&&(t="Date("+t.getTime()+")");this._data$p$0[n]=t};r.CustomProperties.prototype.remove=function(n){delete this._data$p$0[n]};r.CustomProperties.prototype.saveAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];var f=2500;if(window.JSON.stringify(this._data$p$0).length>f)throw Error.argument();var t=r.CommonParameters.parse(i,!1,!0);var u=new r.SaveDictionaryRequest(t._callback$p$0,t._asyncContext$p$0);u._sendRequest$i$0(4,"SaveCustomProperties",{customProperties:this._data$p$0})};r.Diagnostics=function(n,t){this.$$d__getOwaView$p$0=Function.createDelegate(this,this._getOwaView$p$0);this.$$d__getHostVersion$p$0=Function.createDelegate(this,this._getHostVersion$p$0);this.$$d__getHostName$p$0=Function.createDelegate(this,this._getHostName$p$0);this._data$p$0=n;this._appName$p$0=t;r.InitialData._defineReadOnlyProperty$i(this,"hostName",this.$$d__getHostName$p$0);r.InitialData._defineReadOnlyProperty$i(this,"hostVersion",this.$$d__getHostVersion$p$0);64===this._appName$p$0&&r.InitialData._defineReadOnlyProperty$i(this,"OWAView",this.$$d__getOwaView$p$0)};r.Diagnostics.prototype={_data$p$0:null,_appName$p$0:0,_getHostName$p$0:function(){switch(this._appName$p$0){case 8:return"Outlook";case 64:return"OutlookWebApp";case 65536:return"OutlookIOS";case 4194304:return"OutlookAndroid";default:return null}},_getHostVersion$p$0:function(){return this._data$p$0.get__hostVersion$i$0()},_getOwaView$p$0:function(){return this._data$p$0.get__owaView$i$0()}};r.EmailAddressDetails=function(n){this.$$d__getRecipientType$p$0=Function.createDelegate(this,this._getRecipientType$p$0);this.$$d__getAppointmentResponse$p$0=Function.createDelegate(this,this._getAppointmentResponse$p$0);this.$$d__getDisplayName$p$0=Function.createDelegate(this,this._getDisplayName$p$0);this.$$d__getEmailAddress$p$0=Function.createDelegate(this,this._getEmailAddress$p$0);this._data$p$0=n;r.InitialData._defineReadOnlyProperty$i(this,"emailAddress",this.$$d__getEmailAddress$p$0);r.InitialData._defineReadOnlyProperty$i(this,"displayName",this.$$d__getDisplayName$p$0);r.ScriptHelpers.dictionaryContainsKey(n,"appointmentResponse")&&r.InitialData._defineReadOnlyProperty$i(this,"appointmentResponse",this.$$d__getAppointmentResponse$p$0);r.ScriptHelpers.dictionaryContainsKey(n,"recipientType")&&r.InitialData._defineReadOnlyProperty$i(this,"recipientType",this.$$d__getRecipientType$p$0)};r.EmailAddressDetails._createFromEmailUserDictionary$i=function(n){var t={};var u=n.Name;var i=n.UserId;t.name=u||r.EmailAddressDetails._emptyString$p;t.address=i||r.EmailAddressDetails._emptyString$p;return new r.EmailAddressDetails(t)};r.EmailAddressDetails.prototype={_data$p$0:null,_getEmailAddress$p$0:function(){return this._data$p$0.address},_getDisplayName$p$0:function(){return this._data$p$0.name},_getAppointmentResponse$p$0:function(){var n=this._data$p$0.appointmentResponse;return n<r.EmailAddressDetails._responseTypeMap$p.length?r.EmailAddressDetails._responseTypeMap$p[n]:window.Microsoft.Office.WebExtension.MailboxEnums.ResponseType.None},_getRecipientType$p$0:function(){var n=this._data$p$0.recipientType;return n<r.EmailAddressDetails._recipientTypeMap$p.length?r.EmailAddressDetails._recipientTypeMap$p[n]:window.Microsoft.Office.WebExtension.MailboxEnums.RecipientType.Other}};r.EmailAddressDetails.prototype.toJSON=function(){var n={};n.emailAddress=this._getEmailAddress$p$0();n.displayName=this._getDisplayName$p$0();r.ScriptHelpers.dictionaryContainsKey(this._data$p$0,"appointmentResponse")&&(n.appointmentResponse=this._getAppointmentResponse$p$0());r.ScriptHelpers.dictionaryContainsKey(this._data$p$0,"recipientType")&&(n.recipientType=this._getRecipientType$p$0());return n};r.Entities=function(n,t,i,u){this.$$d__createMeetingSuggestion$p$0=Function.createDelegate(this,this._createMeetingSuggestion$p$0);this.$$d__getParcelDeliveries$p$0=Function.createDelegate(this,this._getParcelDeliveries$p$0);this.$$d__getFlightReservations$p$0=Function.createDelegate(this,this._getFlightReservations$p$0);this.$$d__getContacts$p$0=Function.createDelegate(this,this._getContacts$p$0);this.$$d__getPhoneNumbers$p$0=Function.createDelegate(this,this._getPhoneNumbers$p$0);this.$$d__getUrls$p$0=Function.createDelegate(this,this._getUrls$p$0);this.$$d__getEmailAddresses$p$0=Function.createDelegate(this,this._getEmailAddresses$p$0);this.$$d__getMeetingSuggestions$p$0=Function.createDelegate(this,this._getMeetingSuggestions$p$0);this.$$d__getTaskSuggestions$p$0=Function.createDelegate(this,this._getTaskSuggestions$p$0);this.$$d__getAddresses$p$0=Function.createDelegate(this,this._getAddresses$p$0);this._data$p$0=n||{};this._filteredData$p$0=t||{};this._dateTimeSent$p$0=i;r.InitialData._defineReadOnlyProperty$i(this,"addresses",this.$$d__getAddresses$p$0);r.InitialData._defineReadOnlyProperty$i(this,"taskSuggestions",this.$$d__getTaskSuggestions$p$0);r.InitialData._defineReadOnlyProperty$i(this,"meetingSuggestions",this.$$d__getMeetingSuggestions$p$0);r.InitialData._defineReadOnlyProperty$i(this,"emailAddresses",this.$$d__getEmailAddresses$p$0);r.InitialData._defineReadOnlyProperty$i(this,"urls",this.$$d__getUrls$p$0);r.InitialData._defineReadOnlyProperty$i(this,"phoneNumbers",this.$$d__getPhoneNumbers$p$0);r.InitialData._defineReadOnlyProperty$i(this,"contacts",this.$$d__getContacts$p$0);r.InitialData._defineReadOnlyProperty$i(this,"flightReservations",this.$$d__getFlightReservations$p$0);r.InitialData._defineReadOnlyProperty$i(this,"parcelDeliveries",this.$$d__getParcelDeliveries$p$0);this._permissionLevel$p$0=u};r.Entities._getExtractedObjects$i=function(n,t,i,u,f,e){var s=null;var o=t[i];if(!o)return new Array(0);f&&(o=r.Entities._removeDuplicate$p(Object,o,r.Entities._entityDictionaryEquals$p,e));s=new Array(o.length);for(var l=0,a=o,v=a.length,h=0;h<v;++h){var c=a[h];s[l++]=u?u(c):c}return s};r.Entities._getExtractedStringProperty$i=function(n,t,i){var u=n[t];if(!u)return new Array(0);i&&(u=r.Entities._removeDuplicate$p(String,u,r.Entities._stringEquals$p,null));return u};r.Entities._createContact$p=function(n){return new r.Contact(n)};r.Entities._createTaskSuggestion$p=function(n){return new r.TaskSuggestion(n)};r.Entities._createPhoneNumber$p=function(n){return new r.PhoneNumber(n)};r.Entities._entityDictionaryEquals$p=function(n,t,i){return n===t?!0:!n||!t?!1:n[i]===t[i]?!0:!1};r.Entities._stringEquals$p=function(n,t,i){return n===t};r.Entities._removeDuplicate$p=function(n,t,i,r){for(var u=t.length-1;u>=0;u--){for(var e=!1,f=u-1;f>=0;f--)if(i(t[u],t[f],r)){e=!0;break}e&&Array.removeAt(t,u)}return t};r.Entities.prototype={_dateTimeSent$p$0:null,_data$p$0:null,_filteredData$p$0:null,_filteredEntitiesCache$p$0:null,_permissionLevel$p$0:0,_taskSuggestions$p$0:null,_meetingSuggestions$p$0:null,_phoneNumbers$p$0:null,_contacts$p$0:null,_addresses$p$0:null,_emailAddresses$p$0:null,_urls$p$0:null,_flightReservations$p$0:null,_parcelDeliveries$p$0:null,_getByType$i$0:function(n){if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.MeetingSuggestion)return this._getMeetingSuggestions$p$0();else if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.TaskSuggestion)return this._getTaskSuggestions$p$0();else if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.Address)return this._getAddresses$p$0();else if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.PhoneNumber)return this._getPhoneNumbers$p$0();else if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.EmailAddress)return this._getEmailAddresses$p$0();else if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.Url)return this._getUrls$p$0();else if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.Contact)return this._getContacts$p$0();else if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.FlightReservations)return this._getFlightReservations$p$0();else if(n===window.Microsoft.Office.WebExtension.MailboxEnums.EntityType.ParcelDeliveries)return this._getParcelDeliveries$p$0();return null},_getFilteredEntitiesByName$i$0:function(n){this._filteredEntitiesCache$p$0||(this._filteredEntitiesCache$p$0={});if(!r.ScriptHelpers.dictionaryContainsKey(this._filteredEntitiesCache$p$0,n)){for(var u=!1,i=0;i<r.Entities._allEntityKeys$p.length;i++){var f=r.Entities._allEntityKeys$p[i];var t=this._filteredData$p$0[f];if(t&&r.ScriptHelpers.dictionaryContainsKey(t,n)){switch(f){case"EmailAddresses":case"Urls":this._filteredEntitiesCache$p$0[n]=r.Entities._getExtractedStringProperty$i(t,n);break;case"Addresses":this._filteredEntitiesCache$p$0[n]=r.Entities._getExtractedStringProperty$i(t,n,!0);break;case"PhoneNumbers":this._filteredEntitiesCache$p$0[n]=r.Entities._getExtractedObjects$i(r.PhoneNumber,t,n,r.Entities._createPhoneNumber$p,!1,null);break;case"TaskSuggestions":this._filteredEntitiesCache$p$0[n]=r.Entities._getExtractedObjects$i(r.TaskSuggestion,t,n,r.Entities._createTaskSuggestion$p,!0,"TaskString");break;case"MeetingSuggestions":this._filteredEntitiesCache$p$0[n]=r.Entities._getExtractedObjects$i(r.MeetingSuggestion,t,n,this.$$d__createMeetingSuggestion$p$0,!0,"MeetingString");break;case"Contacts":this._filteredEntitiesCache$p$0[n]=r.Entities._getExtractedObjects$i(r.Contact,t,n,r.Entities._createContact$p,!0,"ContactString");break}u=!0;break}}u||(this._filteredEntitiesCache$p$0[n]=null)}return this._filteredEntitiesCache$p$0[n]},_createMeetingSuggestion$p$0:function(n){return new r.MeetingSuggestion(n,this._dateTimeSent$p$0)},_getAddresses$p$0:function(){this._addresses$p$0||(this._addresses$p$0=r.Entities._getExtractedStringProperty$i(this._data$p$0,"Addresses",!0));return this._addresses$p$0},_getEmailAddresses$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._permissionLevel$p$0);this._emailAddresses$p$0||(this._emailAddresses$p$0=r.Entities._getExtractedStringProperty$i(this._data$p$0,"EmailAddresses",!1));return this._emailAddresses$p$0},_getUrls$p$0:function(){this._urls$p$0||(this._urls$p$0=r.Entities._getExtractedStringProperty$i(this._data$p$0,"Urls",!1));return this._urls$p$0},_getPhoneNumbers$p$0:function(){this._phoneNumbers$p$0||(this._phoneNumbers$p$0=r.Entities._getExtractedObjects$i(r.PhoneNumber,this._data$p$0,"PhoneNumbers",r.Entities._createPhoneNumber$p));return this._phoneNumbers$p$0},_getTaskSuggestions$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._permissionLevel$p$0);this._taskSuggestions$p$0||(this._taskSuggestions$p$0=r.Entities._getExtractedObjects$i(r.TaskSuggestion,this._data$p$0,"TaskSuggestions",r.Entities._createTaskSuggestion$p,!0,"TaskString"));return this._taskSuggestions$p$0},_getMeetingSuggestions$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._permissionLevel$p$0);this._meetingSuggestions$p$0||(this._meetingSuggestions$p$0=r.Entities._getExtractedObjects$i(r.MeetingSuggestion,this._data$p$0,"MeetingSuggestions",this.$$d__createMeetingSuggestion$p$0,!0,"MeetingString"));return this._meetingSuggestions$p$0},_getContacts$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._permissionLevel$p$0);this._contacts$p$0||(this._contacts$p$0=r.Entities._getExtractedObjects$i(r.Contact,this._data$p$0,"Contacts",r.Entities._createContact$p,!0,"ContactString"));return this._contacts$p$0},_getParcelDeliveries$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._permissionLevel$p$0);this._parcelDeliveries$p$0||(this._parcelDeliveries$p$0=r.Entities._getExtractedObjects$i(Object,this._data$p$0,"ParcelDeliveries",null));return this._parcelDeliveries$p$0},_getFlightReservations$p$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._permissionLevel$p$0);this._flightReservations$p$0||(this._flightReservations$p$0=r.Entities._getExtractedObjects$i(Object,this._data$p$0,"FlightReservations",null));return this._flightReservations$p$0}};r.ReplyConstants=function(){};r.AsyncConstants=function(){};window.Office.cast.item=f.cast.item=function(){};window.Office.cast.item.toItemRead=function(n){if(r.Item.isInstanceOfType(n))return n;throw Error.argumentType();};window.Office.cast.item.toItemCompose=function(n){if(r.ComposeItem.isInstanceOfType(n))return n;throw Error.argumentType();};window.Office.cast.item.toMessage=function(n){return window.Office.cast.item.toMessageRead(n)};window.Office.cast.item.toMessageRead=function(n){if(r.Message.isInstanceOfType(n))return n;throw Error.argumentType();};window.Office.cast.item.toMessageCompose=function(n){if(r.MessageCompose.isInstanceOfType(n))return n;throw Error.argumentType();};window.Office.cast.item.toMeetingRequest=function(n){if(r.MeetingRequest.isInstanceOfType(n))return n;throw Error.argumentType();};window.Office.cast.item.toAppointment=function(n){return window.Office.cast.item.toAppointmentRead(n)};window.Office.cast.item.toAppointmentRead=function(n){if(r.Appointment.isInstanceOfType(n))return n;throw Error.argumentType();};window.Office.cast.item.toAppointmentCompose=function(n){if(r.AppointmentCompose.isInstanceOfType(n))return n;throw Error.argumentType();};r.Item=function(n){this.$$d__getBody$p$1=Function.createDelegate(this,this._getBody$p$1);this.$$d__getAttachments$p$1=Function.createDelegate(this,this._getAttachments$p$1);this.$$d__getItemClass$p$1=Function.createDelegate(this,this._getItemClass$p$1);this.$$d__getItemId$p$1=Function.createDelegate(this,this._getItemId$p$1);this.$$d__getDateTimeModified$p$1=Function.createDelegate(this,this._getDateTimeModified$p$1);this.$$d__getDateTimeCreated$p$1=Function.createDelegate(this,this._getDateTimeCreated$p$1);r.Item.initializeBase(this,[n]);r.InitialData._defineReadOnlyProperty$i(this,"dateTimeCreated",this.$$d__getDateTimeCreated$p$1);r.InitialData._defineReadOnlyProperty$i(this,"dateTimeModified",this.$$d__getDateTimeModified$p$1);r.InitialData._defineReadOnlyProperty$i(this,"itemId",this.$$d__getItemId$p$1);r.InitialData._defineReadOnlyProperty$i(this,"itemClass",this.$$d__getItemClass$p$1);r.InitialData._defineReadOnlyProperty$i(this,"attachments",this.$$d__getAttachments$p$1);r.InitialData._defineReadOnlyProperty$i(this,"body",this.$$d__getBody$p$1)};r.Item.prototype={_body$p$1:null,_getItemId$p$1:function(){return this._data$p$0.get__itemId$i$0()},_getItemClass$p$1:function(){return this._data$p$0.get__itemClass$i$0()},_getDateTimeCreated$p$1:function(){return this._data$p$0.get__dateTimeCreated$i$0()},_getDateTimeModified$p$1:function(){return this._data$p$0.get__dateTimeModified$i$0()},_getAttachments$p$1:function(){return this._data$p$0.get__attachments$i$0()},_getBody$p$1:function(){this._body$p$1||(this._body$p$1=new r.Body);return this._body$p$1}};r.ItemBase=function(n){this.$$d__createCustomProperties$i$0=Function.createDelegate(this,this._createCustomProperties$i$0);this.$$d__getNotificationMessages$p$0=Function.createDelegate(this,this._getNotificationMessages$p$0);this.$$d_getItemType=Function.createDelegate(this,this.getItemType);this._data$p$0=n;r.InitialData._defineReadOnlyProperty$i(this,"itemType",this.$$d_getItemType);r.InitialData._defineReadOnlyProperty$i(this,"notificationMessages",this.$$d__getNotificationMessages$p$0)};r.ItemBase.prototype={_data$p$0:null,_notificationMessages$p$0:null,get_data:function(){return this._data$p$0},_createCustomProperties$i$0:function(n){return new r.CustomProperties(n)},_getNotificationMessages$p$0:function(){this._notificationMessages$p$0||(this._notificationMessages$p$0=new r.NotificationMessages);return this._notificationMessages$p$0}};r.ItemBase.prototype.loadCustomPropertiesAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];var t=r.CommonParameters.parse(i,!0,!0);var u=new r._loadDictionaryRequest(this.$$d__createCustomProperties$i$0,"customProperties",t._callback$p$0,t._asyncContext$p$0);u._sendRequest$i$0(3,"LoadCustomProperties",{})};r.MeetingRequest=function(n){this.$$d__getRequiredAttendees$p$3=Function.createDelegate(this,this._getRequiredAttendees$p$3);this.$$d__getOptionalAttendees$p$3=Function.createDelegate(this,this._getOptionalAttendees$p$3);this.$$d__getLocation$p$3=Function.createDelegate(this,this._getLocation$p$3);this.$$d__getEnd$p$3=Function.createDelegate(this,this._getEnd$p$3);this.$$d__getStart$p$3=Function.createDelegate(this,this._getStart$p$3);r.MeetingRequest.initializeBase(this,[n]);r.InitialData._defineReadOnlyProperty$i(this,"start",this.$$d__getStart$p$3);r.InitialData._defineReadOnlyProperty$i(this,"end",this.$$d__getEnd$p$3);r.InitialData._defineReadOnlyProperty$i(this,"location",this.$$d__getLocation$p$3);r.InitialData._defineReadOnlyProperty$i(this,"optionalAttendees",this.$$d__getOptionalAttendees$p$3);r.InitialData._defineReadOnlyProperty$i(this,"requiredAttendees",this.$$d__getRequiredAttendees$p$3)};r.MeetingRequest.prototype={_getStart$p$3:function(){return this._data$p$0.get__start$i$0()},_getEnd$p$3:function(){return this._data$p$0.get__end$i$0()},_getLocation$p$3:function(){return this._data$p$0.get__location$i$0()},_getOptionalAttendees$p$3:function(){return this._data$p$0.get__cc$i$0()},_getRequiredAttendees$p$3:function(){return this._data$p$0.get__to$i$0()}};r.MeetingSuggestion=function(n,t){this.$$d__getEndTime$p$0=Function.createDelegate(this,this._getEndTime$p$0);this.$$d__getStartTime$p$0=Function.createDelegate(this,this._getStartTime$p$0);this.$$d__getSubject$p$0=Function.createDelegate(this,this._getSubject$p$0);this.$$d__getLocation$p$0=Function.createDelegate(this,this._getLocation$p$0);this.$$d__getAttendees$p$0=Function.createDelegate(this,this._getAttendees$p$0);this.$$d__getMeetingString$p$0=Function.createDelegate(this,this._getMeetingString$p$0);this._data$p$0=n;this._dateTimeSent$p$0=t;r.InitialData._defineReadOnlyProperty$i(this,"meetingString",this.$$d__getMeetingString$p$0);r.InitialData._defineReadOnlyProperty$i(this,"attendees",this.$$d__getAttendees$p$0);r.InitialData._defineReadOnlyProperty$i(this,"location",this.$$d__getLocation$p$0);r.InitialData._defineReadOnlyProperty$i(this,"subject",this.$$d__getSubject$p$0);r.InitialData._defineReadOnlyProperty$i(this,"start",this.$$d__getStartTime$p$0);r.InitialData._defineReadOnlyProperty$i(this,"end",this.$$d__getEndTime$p$0)};r.MeetingSuggestion.prototype={_dateTimeSent$p$0:null,_data$p$0:null,_attendees$p$0:null,_getMeetingString$p$0:function(){return this._data$p$0.MeetingString},_getLocation$p$0:function(){return this._data$p$0.Location},_getSubject$p$0:function(){return this._data$p$0.Subject},_getStartTime$p$0:function(){var n=this._createDateTimeFromParameter$p$0("StartTime");var t=r.MeetingSuggestionTimeDecoder.resolve(n,this._dateTimeSent$p$0);return t.getTime()!==n.getTime()?window.OSF.DDA.OutlookAppOm._instance$p.convertToUtcClientTime(window.OSF.DDA.OutlookAppOm._instance$p._dateToDictionary$i$0(t)):n},_getEndTime$p$0:function(){var n=this._createDateTimeFromParameter$p$0("EndTime");var t=r.MeetingSuggestionTimeDecoder.resolve(n,this._dateTimeSent$p$0);return t.getTime()!==n.getTime()?window.OSF.DDA.OutlookAppOm._instance$p.convertToUtcClientTime(window.OSF.DDA.OutlookAppOm._instance$p._dateToDictionary$i$0(t)):n},_createDateTimeFromParameter$p$0:function(n){var t=this._data$p$0[n];return t?new Date(t):null},_getAttendees$p$0:function(){if(!this._attendees$p$0){var n=this;this._attendees$p$0=r.Entities._getExtractedObjects$i(r.EmailAddressDetails,this._data$p$0,"Attendees",function(n){return r.EmailAddressDetails._createFromEmailUserDictionary$i(n)})}return this._attendees$p$0}};r.MeetingSuggestionTimeDecoder=function(){};r.MeetingSuggestionTimeDecoder.resolve=function(n,t){if(!t)return n;try{var e;var i;var u;var f=new Date(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0,0);var h,s,o;if(o=r.MeetingSuggestionTimeDecoder._decode$p(n,h={val:u},s={val:e}),u=h.val,e=s.val,o){i=r._preciseDate.isInstanceOfType(u)?r.MeetingSuggestionTimeDecoder._resolvePreciseDate$p(f,u):r._relativeDate.isInstanceOfType(u)?r.MeetingSuggestionTimeDecoder._resolveRelativeDate$p(f,u):f;if(window.isNaN(i.getTime()))return t;i.setMilliseconds(i.getMilliseconds()+e);return i}else return n}catch(c){return t}};r.MeetingSuggestionTimeDecoder._isNullOrUndefined$i=function(n){return null===n||n===undefined};r.MeetingSuggestionTimeDecoder._resolvePreciseDate$p=function(n,t){var u=t._year$i$1;var e=t._month$i$1?t._month$i$1-1:n.getMonth();var f=t._day$i$1;if(!f)return n;var i;if(r.MeetingSuggestionTimeDecoder._isNullOrUndefined$i(u)){i=new Date(n.getFullYear(),e,f);i.getTime()<n.getTime()&&(i=new Date(n.getFullYear()+1,e,f))}else i=new Date(u<50?2e3+u:1900+u,e,f);return i.getMonth()!==e?n:i};r.MeetingSuggestionTimeDecoder._resolveRelativeDate$p=function(n,t){var i;switch(t._unit$i$1){case 0:i=new Date(n.getFullYear(),n.getMonth(),n.getDate());i.setDate(i.getDate()+t._offset$i$1);return i;case 5:return r.MeetingSuggestionTimeDecoder._findBestDateForWeekDate$p(n,t._offset$i$1,t._tag$i$1);case 2:var u=1;switch(t._modifier$i$1){case 1:break;case 2:u=16;break;default:t._offset$i$1||(u=n.getDate());break}i=new Date(n.getFullYear(),n.getMonth(),u);i.setMonth(i.getMonth()+t._offset$i$1);i.getTime()<n.getTime()&&i.setDate(i.getDate()+n.getDate()-1);return i;case 1:i=new Date(n.getFullYear(),n.getMonth(),n.getDate());i.setDate(n.getDate()+7*t._offset$i$1);if(t._modifier$i$1!==1&&t._modifier$i$1){if(t._modifier$i$1===2){i.setDate(i.getDate()+5-i.getDay());return i}}else{i.setDate(i.getDate()+1-i.getDay());return i.getTime()<n.getTime()?n:i}break;case 4:return r.MeetingSuggestionTimeDecoder._findBestDateForWeekOfMonthDate$p(n,t);case 3:if(t._offset$i$1>0)return new Date(n.getFullYear()+t._offset$i$1,0,1);break;default:break}return n};r.MeetingSuggestionTimeDecoder._findBestDateForWeekDate$p=function(n,t,i){if(t>-5&&t<5){var u=(i+6)%7+1;var r=7*t+(u-n.getDay());n.setDate(n.getDate()+r);return n}else{var r=(i-n.getDay())%7;r<0&&(r+=7);n.setDate(n.getDate()+r);return n}};r.MeetingSuggestionTimeDecoder._findBestDateForWeekOfMonthDate$p=function(n,t){var e;var i;var u;e=n;if(t._tag$i$1<=0||t._tag$i$1>12||t._offset$i$1<=0||t._offset$i$1>5)return n;var o=(12+t._tag$i$1-e.getMonth()-1)%12;i=new Date(e.getFullYear(),e.getMonth()+o,1);if(t._modifier$i$1===1)if(t._offset$i$1===1&&i.getDay()!==6&&i.getDay())return i;else{u=new Date(i.getFullYear(),i.getMonth(),i.getDate());u.setDate(u.getDate()+(8-i.getDay())%7);i.getDay()!==6&&i.getDay()&&i.getDay()!==1&&u.setDate(u.getDate()-7);u.setDate(u.getDate()+7*(t._offset$i$1-1));return u.getMonth()+1!==t._tag$i$1?n:u}else{u=new Date(i.getFullYear(),i.getMonth(),r.MeetingSuggestionTimeDecoder._daysInMonth$p(i.getMonth(),i.getFullYear()));var f=1-u.getDay();f>0&&(f=f-7);u.setDate(u.getDate()+f);u.setDate(u.getDate()+7*(1-t._offset$i$1));return u.getMonth()+1!==t._tag$i$1?i.getDay()!==6&&i.getDay()?i:n:u}};r.MeetingSuggestionTimeDecoder._decode$p=function(n,t,i){var e=32767;t.val=null;i.val=0;if(!n)return!1;i.val=r.MeetingSuggestionTimeDecoder._getTimeOfDayInMillisecondsUTC$p(n);var o=n.getTime()-i.val;var u=(o-r.MeetingSuggestionTimeDecoder._baseDate$p.getTime())/864e5;if(u<0)return!1;else if(u>=262144)return!1;else{var f=u>>15;u=u&e;switch(f){case 0:return r.MeetingSuggestionTimeDecoder._decodePreciseDate$p(u,t);case 1:return r.MeetingSuggestionTimeDecoder._decodeRelativeDate$p(u,t);default:return!1}}};r.MeetingSuggestionTimeDecoder._decodePreciseDate$p=function(n,t){var c=7;var o=15;var s=31;var h=127;var f=null;var u=0;var e=0;t.val=null;var i=n>>12&c;if((i&4)==4){f=n>>5&h;if((i&2)==2){if((i&1)==1)return!1;u=n>>1&o}}else{(i&2)==2&&(u=n>>8&o);(i&1)==1&&(e=n>>3&s)}t.val=new r._preciseDate(e,u,f);return!0};r.MeetingSuggestionTimeDecoder._decodeRelativeDate$p=function(n,t){var s=15;var o=63;var c=7;var h=3;var u=n&s;n>>=4;var i=r.MeetingSuggestionTimeDecoder._fromComplement$p(n&o,6);n>>=6;var e=n&c;n>>=3;var f=n&h;try{t.val=new r._relativeDate(f,i,e,u);return!0}catch(l){t.val=null;return!1}};r.MeetingSuggestionTimeDecoder._fromComplement$p=function(n,t){var i=1<<t-1;var r=(1<<t)-1;return(n&i)===i?-((n^r)+1):n};r.MeetingSuggestionTimeDecoder._daysInMonth$p=function(n,t){return 32-new Date(t,n,32).getDate()};r.MeetingSuggestionTimeDecoder._getTimeOfDayInMillisecondsUTC$p=function(n){var t=0;t+=n.getUTCHours()*3600;t+=n.getUTCMinutes()*60;t+=n.getUTCSeconds();t*=1e3;t+=n.getUTCMilliseconds();return t};r._extractedDate=function(){};r._preciseDate=function(n,t,i){r._preciseDate.initializeBase(this);this._day$i$1=n;this._month$i$1=t;r.MeetingSuggestionTimeDecoder._isNullOrUndefined$i(i)||(this._year$i$1=i%100)};r._preciseDate.prototype={_day$i$1:0,_month$i$1:0,_year$i$1:null};r._relativeDate=function(n,t,i,u){r._relativeDate.initializeBase(this);this._modifier$i$1=n;this._offset$i$1=t;this._unit$i$1=i;this._tag$i$1=u};r._relativeDate.prototype={_modifier$i$1:0,_offset$i$1:0,_unit$i$1:0,_tag$i$1:0};r.Message=function(n){this.$$d__getConversationId$p$2=Function.createDelegate(this,this._getConversationId$p$2);this.$$d__getInternetMessageId$p$2=Function.createDelegate(this,this._getInternetMessageId$p$2);this.$$d__getCc$p$2=Function.createDelegate(this,this._getCc$p$2);this.$$d__getTo$p$2=Function.createDelegate(this,this._getTo$p$2);this.$$d__getFrom$p$2=Function.createDelegate(this,this._getFrom$p$2);this.$$d__getSender$p$2=Function.createDelegate(this,this._getSender$p$2);this.$$d__getNormalizedSubject$p$2=Function.createDelegate(this,this._getNormalizedSubject$p$2);this.$$d__getSubject$p$2=Function.createDelegate(this,this._getSubject$p$2);r.Message.initializeBase(this,[n]);r.InitialData._defineReadOnlyProperty$i(this,"subject",this.$$d__getSubject$p$2);r.InitialData._defineReadOnlyProperty$i(this,"normalizedSubject",this.$$d__getNormalizedSubject$p$2);r.InitialData._defineReadOnlyProperty$i(this,"sender",this.$$d__getSender$p$2);r.InitialData._defineReadOnlyProperty$i(this,"from",this.$$d__getFrom$p$2);r.InitialData._defineReadOnlyProperty$i(this,"to",this.$$d__getTo$p$2);r.InitialData._defineReadOnlyProperty$i(this,"cc",this.$$d__getCc$p$2);r.InitialData._defineReadOnlyProperty$i(this,"internetMessageId",this.$$d__getInternetMessageId$p$2);r.InitialData._defineReadOnlyProperty$i(this,"conversationId",this.$$d__getConversationId$p$2)};r.Message.prototype={getItemType:function(){return window.Microsoft.Office.WebExtension.MailboxEnums.ItemType.Message},_getSubject$p$2:function(){return this._data$p$0.get__subject$i$0()},_getNormalizedSubject$p$2:function(){return this._data$p$0.get__normalizedSubject$i$0()},_getSender$p$2:function(){return this._data$p$0.get__sender$i$0()},_getFrom$p$2:function(){return this._data$p$0.get__from$i$0()},_getTo$p$2:function(){return this._data$p$0.get__to$i$0()},_getCc$p$2:function(){return this._data$p$0.get__cc$i$0()},_getInternetMessageId$p$2:function(){return this._data$p$0.get__internetMessageId$i$0()},_getConversationId$p$2:function(){return this._data$p$0.get__conversationId$i$0()}};r.Message.prototype.getEntities=function(){return this._data$p$0._getEntities$i$0()};r.Message.prototype.getEntitiesByType=function(n){return this._data$p$0._getEntitiesByType$i$0(n)};r.Message.prototype.getFilteredEntitiesByName=function(n){return this._data$p$0._getFilteredEntitiesByName$i$0(n)};r.Message.prototype.getSelectedEntities=function(){return this._data$p$0._getSelectedEntities$i$0()};r.Message.prototype.getRegExMatches=function(){window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"getRegExMatches");return this._data$p$0._getRegExMatches$i$0()};r.Message.prototype.getRegExMatchesByName=function(n){window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"getRegExMatchesByName");return this._data$p$0._getRegExMatchesByName$i$0(n)};r.Message.prototype.getSelectedRegExMatches=function(){window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(1,"getSelectedRegExMatches");return this._data$p$0._getSelectedRegExMatches$i$0()};r.Message.prototype.displayReplyForm=function(n){window.OSF.DDA.OutlookAppOm._instance$p._displayReplyForm$i$0(n)};r.Message.prototype.displayReplyAllForm=function(n){window.OSF.DDA.OutlookAppOm._instance$p._displayReplyAllForm$i$0(n)};r.MessageCompose=function(n){this.$$d__getConversationId$p$2=Function.createDelegate(this,this._getConversationId$p$2);this.$$d__getBcc$p$2=Function.createDelegate(this,this._getBcc$p$2);this.$$d__getCc$p$2=Function.createDelegate(this,this._getCc$p$2);this.$$d__getTo$p$2=Function.createDelegate(this,this._getTo$p$2);r.MessageCompose.initializeBase(this,[n]);r.InitialData._defineReadOnlyProperty$i(this,"to",this.$$d__getTo$p$2);r.InitialData._defineReadOnlyProperty$i(this,"cc",this.$$d__getCc$p$2);r.InitialData._defineReadOnlyProperty$i(this,"bcc",this.$$d__getBcc$p$2);r.InitialData._defineReadOnlyProperty$i(this,"conversationId",this.$$d__getConversationId$p$2)};r.MessageCompose.prototype={_to$p$2:null,_cc$p$2:null,_bcc$p$2:null,getItemType:function(){return window.Microsoft.Office.WebExtension.MailboxEnums.ItemType.Message},_getTo$p$2:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._to$p$2||(this._to$p$2=new r.ComposeRecipient(0,"to"));return this._to$p$2},_getCc$p$2:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._cc$p$2||(this._cc$p$2=new r.ComposeRecipient(1,"cc"));return this._cc$p$2},_getBcc$p$2:function(){this._data$p$0._throwOnRestrictedPermissionLevel$i$0();this._bcc$p$2||(this._bcc$p$2=new r.ComposeRecipient(2,"bcc"));return this._bcc$p$2},_getConversationId$p$2:function(){return this._data$p$0.get__conversationId$i$0()}};r.NotificationMessages=function(){};r.NotificationMessages._mapToHostItemNotificationMessageType$p=function(n){var i;var t;i=n.type;if(i===window.Microsoft.Office.WebExtension.MailboxEnums.ItemNotificationMessageType.ProgressIndicator)t=1;else if(i===window.Microsoft.Office.WebExtension.MailboxEnums.ItemNotificationMessageType.InformationalMessage)t=0;else if(i===window.Microsoft.Office.WebExtension.MailboxEnums.ItemNotificationMessageType.ErrorMessage)t=2;else throw Error.argument("type");n.type=t};r.NotificationMessages._validateKey$p=function(n){if(!r.ScriptHelpers.isNonEmptyString(n))throw Error.argument("key");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.length,0,32,"key")};r.NotificationMessages._validateDictionary$p=function(n){if(!r.ScriptHelpers.isNonEmptyString(n.type))throw Error.argument("type");if(n.type===window.Microsoft.Office.WebExtension.MailboxEnums.ItemNotificationMessageType.InformationalMessage){if(!r.ScriptHelpers.isNonEmptyString(n.icon))throw Error.argument("icon");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.icon.length,0,32,"icon");if(r.ScriptHelpers.isUndefined(n.persistent))throw Error.argument("persistent");if(!Boolean.isInstanceOfType(n.persistent))throw Error.argumentType("persistent",Object.getType(n.persistent),Boolean);}else{if(!r.ScriptHelpers.isUndefined(n.icon))throw Error.argument("icon");if(!r.ScriptHelpers.isUndefined(n.persistent))throw Error.argument("persistent");}if(!r.ScriptHelpers.isNonEmptyString(n.message))throw Error.argument("message");window.OSF.DDA.OutlookAppOm._throwOnOutOfRange$i(n.message.length,0,150,"message")};r.NotificationMessages.prototype.addAsync=function(n,t){for(var f=[],i=2;i<arguments.length;++i)f[i-2]=arguments[i];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(0,"NotificationMessages.addAsync");var e=r.CommonParameters.parse(f,!1);r.NotificationMessages._validateKey$p(n);r.NotificationMessages._validateDictionary$p(t);var u={};u=r.ScriptHelpers.deepClone(t);u.key=n;r.NotificationMessages._mapToHostItemNotificationMessageType$p(u);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(33,u,null,e._asyncContext$p$0,e._callback$p$0)};r.NotificationMessages.prototype.getAllAsync=function(){for(var i=[],n=0;n<arguments.length;++n)i[n]=arguments[n];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(0,"NotificationMessages.getAllAsync");var t=r.CommonParameters.parse(i,!0);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(34,null,null,t._asyncContext$p$0,t._callback$p$0)};r.NotificationMessages.prototype.replaceAsync=function(n,t){for(var f=[],i=2;i<arguments.length;++i)f[i-2]=arguments[i];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(0,"NotificationMessages.replaceAsync");var e=r.CommonParameters.parse(f,!1);r.NotificationMessages._validateKey$p(n);r.NotificationMessages._validateDictionary$p(t);var u={};u=r.ScriptHelpers.deepClone(t);u.key=n;r.NotificationMessages._mapToHostItemNotificationMessageType$p(u);window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(35,u,null,e._asyncContext$p$0,e._callback$p$0)};r.NotificationMessages.prototype.removeAsync=function(n){for(var u=[],t=1;t<arguments.length;++t)u[t-1]=arguments[t];window.OSF.DDA.OutlookAppOm._instance$p._throwOnMethodCallForInsufficientPermission$i$0(0,"NotificationMessages.removeAsync");var i=r.CommonParameters.parse(u,!1);r.NotificationMessages._validateKey$p(n);var f={key:n};window.OSF.DDA.OutlookAppOm._instance$p._standardInvokeHostMethod$i$0(36,f,null,i._asyncContext$p$0,i._callback$p$0)};r.OutlookErrorManager=function(){};r.OutlookErrorManager.getErrorArgs=function(n){r.OutlookErrorManager._isInitialized$p||r.OutlookErrorManager._initialize$p();return u.DDA.ErrorCodeManager.getErrorArgs(n)};r.OutlookErrorManager._initialize$p=function(){r.OutlookErrorManager._addErrorMessage$p(9e3,"AttachmentSizeExceeded",window._u.ExtensibilityStrings.l_AttachmentExceededSize_Text);r.OutlookErrorManager._addErrorMessage$p(9001,"NumberOfAttachmentsExceeded",window._u.ExtensibilityStrings.l_ExceededMaxNumberOfAttachments_Text);r.OutlookErrorManager._addErrorMessage$p(9002,"InternalFormatError",window._u.ExtensibilityStrings.l_InternalFormatError_Text);r.OutlookErrorManager._addErrorMessage$p(9003,"InvalidAttachmentId",window._u.ExtensibilityStrings.l_InvalidAttachmentId_Text);r.OutlookErrorManager._addErrorMessage$p(9004,"InvalidAttachmentPath",window._u.ExtensibilityStrings.l_InvalidAttachmentPath_Text);r.OutlookErrorManager._addErrorMessage$p(9005,"CannotAddAttachmentBeforeUpgrade",window._u.ExtensibilityStrings.l_CannotAddAttachmentBeforeUpgrade_Text);r.OutlookErrorManager._addErrorMessage$p(9006,"AttachmentDeletedBeforeUploadCompletes",window._u.ExtensibilityStrings.l_AttachmentDeletedBeforeUploadCompletes_Text);r.OutlookErrorManager._addErrorMessage$p(9007,"AttachmentUploadGeneralFailure",window._u.ExtensibilityStrings.l_AttachmentUploadGeneralFailure_Text);r.OutlookErrorManager._addErrorMessage$p(9008,"AttachmentToDeleteDoesNotExist",window._u.ExtensibilityStrings.l_DeleteAttachmentDoesNotExist_Text);r.OutlookErrorManager._addErrorMessage$p(9009,"AttachmentDeleteGeneralFailure",window._u.ExtensibilityStrings.l_AttachmentDeleteGeneralFailure_Text);r.OutlookErrorManager._addErrorMessage$p(9010,"InvalidEndTime",window._u.ExtensibilityStrings.l_InvalidEndTime_Text);r.OutlookErrorManager._addErrorMessage$p(9011,"HtmlSanitizationFailure",window._u.ExtensibilityStrings.l_HtmlSanitizationFailure_Text);r.OutlookErrorManager._addErrorMessage$p(9012,"NumberOfRecipientsExceeded",String.format(window._u.ExtensibilityStrings.l_NumberOfRecipientsExceeded_Text,500));r.OutlookErrorManager._addErrorMessage$p(9013,"NoValidRecipientsProvided",window._u.ExtensibilityStrings.l_NoValidRecipientsProvided_Text);r.OutlookErrorManager._addErrorMessage$p(9014,"CursorPositionChanged",window._u.ExtensibilityStrings.l_CursorPositionChanged_Text);r.OutlookErrorManager._addErrorMessage$p(9016,"InvalidSelection",window._u.ExtensibilityStrings.l_InvalidSelection_Text);r.OutlookErrorManager._addErrorMessage$p(9017,"AccessRestricted","");r.OutlookErrorManager._addErrorMessage$p(9018,"GenericTokenError","");r.OutlookErrorManager._addErrorMessage$p(9019,"GenericSettingsError","");r.OutlookErrorManager._addErrorMessage$p(9020,"GenericResponseError","");r.OutlookErrorManager._addErrorMessage$p(9021,"SaveError",window._u.ExtensibilityStrings.l_SaveError_Text);r.OutlookErrorManager._addErrorMessage$p(9022,"MessageInDifferentStoreError",window._u.ExtensibilityStrings.l_MessageInDifferentStoreError_Text);r.OutlookErrorManager._addErrorMessage$p(9023,"DuplicateNotificationKey",window._u.ExtensibilityStrings.l_DuplicateNotificationKey_Text);r.OutlookErrorManager._addErrorMessage$p(9024,"NotificationKeyNotFound",window._u.ExtensibilityStrings.l_NotificationKeyNotFound_Text);r.OutlookErrorManager._addErrorMessage$p(9025,"NumberOfNotificationsExceeded",window._u.ExtensibilityStrings.l_NumberOfNotificationsExceeded_Text);r.OutlookErrorManager._addErrorMessage$p(9026,"PersistedNotificationArrayReadError",window._u.ExtensibilityStrings.l_PersistedNotificationArrayReadError_Text);r.OutlookErrorManager._addErrorMessage$p(9027,"PersistedNotificationArraySaveError",window._u.ExtensibilityStrings.l_PersistedNotificationArraySaveError_Text);r.OutlookErrorManager._addErrorMessage$p(9028,"CannotPersistPropertyInUnsavedDraftError",window._u.ExtensibilityStrings.l_CannotPersistPropertyInUnsavedDraftError_Text);r.OutlookErrorManager._addErrorMessage$p(9029,"CanOnlyGetTokenForSavedItem",window._u.ExtensibilityStrings.l_CallSaveAsyncBeforeToken_Text);r.OutlookErrorManager._isInitialized$p=!0};r.OutlookErrorManager._addErrorMessage$p=function(n,t,i){u.DDA.ErrorCodeManager.addErrorMessage(n,{name:t,message:i})};r.OutlookErrorManager.OutlookErrorCodes=function(){};r.OutlookErrorManager.OsfDdaErrorCodes=function(){};r.PhoneNumber=function(n){this.$$d__getPhoneType$p$0=Function.createDelegate(this,this._getPhoneType$p$0);this.$$d__getOriginalPhoneString$p$0=Function.createDelegate(this,this._getOriginalPhoneString$p$0);this.$$d__getPhoneString$p$0=Function.createDelegate(this,this._getPhoneString$p$0);this._data$p$0=n;r.InitialData._defineReadOnlyProperty$i(this,"phoneString",this.$$d__getPhoneString$p$0);r.InitialData._defineReadOnlyProperty$i(this,"originalPhoneString",this.$$d__getOriginalPhoneString$p$0);r.InitialData._defineReadOnlyProperty$i(this,"type",this.$$d__getPhoneType$p$0)};r.PhoneNumber.prototype={_data$p$0:null,_getPhoneString$p$0:function(){return this._data$p$0.PhoneString},_getOriginalPhoneString$p$0:function(){return this._data$p$0.OriginalPhoneString},_getPhoneType$p$0:function(){return this._data$p$0.Type}};r.TaskSuggestion=function(n){this.$$d__getAssignees$p$0=Function.createDelegate(this,this._getAssignees$p$0);this.$$d__getTaskString$p$0=Function.createDelegate(this,this._getTaskString$p$0);this._data$p$0=n;r.InitialData._defineReadOnlyProperty$i(this,"taskString",this.$$d__getTaskString$p$0);r.InitialData._defineReadOnlyProperty$i(this,"assignees",this.$$d__getAssignees$p$0)};r.TaskSuggestion.prototype={_data$p$0:null,_assignees$p$0:null,_getTaskString$p$0:function(){return this._data$p$0.TaskString},_getAssignees$p$0:function(){if(!this._assignees$p$0){var n=this;this._assignees$p$0=r.Entities._getExtractedObjects$i(r.EmailAddressDetails,this._data$p$0,"Assignees",function(n){return r.EmailAddressDetails._createFromEmailUserDictionary$i(n)})}return this._assignees$p$0}};r.UserProfile=function(n){this.$$d__getUserProfileType$p$0=Function.createDelegate(this,this._getUserProfileType$p$0);this.$$d__getTimeZone$p$0=Function.createDelegate(this,this._getTimeZone$p$0);this.$$d__getEmailAddress$p$0=Function.createDelegate(this,this._getEmailAddress$p$0);this.$$d__getDisplayName$p$0=Function.createDelegate(this,this._getDisplayName$p$0);this._data$p$0=n;r.InitialData._defineReadOnlyProperty$i(this,"displayName",this.$$d__getDisplayName$p$0);r.InitialData._defineReadOnlyProperty$i(this,"emailAddress",this.$$d__getEmailAddress$p$0);r.InitialData._defineReadOnlyProperty$i(this,"timeZone",this.$$d__getTimeZone$p$0);r.InitialData._defineReadOnlyProperty$i(this,"type",this.$$d__getUserProfileType$p$0)};r.UserProfile.prototype={_data$p$0:null,_getUserProfileType$p$0:function(){return this._data$p$0.get__userProfileType$i$0()},_getDisplayName$p$0:function(){return this._data$p$0.get__userDisplayName$i$0()},_getEmailAddress$p$0:function(){return this._data$p$0.get__userEmailAddress$i$0()},_getTimeZone$p$0:function(){return this._data$p$0.get__userTimeZone$i$0()}};r.OutlookDispid=function(){};r.OutlookDispid.prototype={owaOnlyMethod:0,getInitialData:1,getUserIdentityToken:2,loadCustomProperties:3,saveCustomProperties:4,ewsRequest:5,displayNewAppointmentForm:7,displayMessageForm:8,displayAppointmentForm:9,displayReplyForm:10,displayReplyAllForm:11,getCallbackToken:12,bodySetSelectedDataAsync:13,getBodyTypeAsync:14,getRecipientsAsync:15,addFileAttachmentAsync:16,setSubjectAsync:17,getSubjectAsync:18,addItemAttachmentAsync:19,removeAttachmentAsync:20,setRecipientsAsync:21,addRecipientsAsync:22,bodyPrependAsync:23,getTimeAsync:24,setTimeAsync:25,getLocationAsync:26,setLocationAsync:27,getSelectedDataAsync:28,setSelectedDataAsync:29,displayReplyFormWithAttachments:30,displayReplyAllFormWithAttachments:31,saveAsync:32,addNotficationMessageAsync:33,getAllNotficationMessagesAsync:34,replaceNotficationMessageAsync:35,removeNotficationMessageAsync:36,getBodyAsync:37,setBodyAsync:38,appCommands1:39,registerConsentAsync:40,close:41,closeApp:42,displayPersonaCardAsync:43,displayNewMessageForm:44,navigateToModuleAsync:45,eventCompleted:94,closeContainer:97,messageParent:144,trackCtq:400,recordTrace:401,recordDataPoint:402,windowOpenOverrideHandler:403,saveSettingsRequest:404};r.OutlookDispid.registerEnum("$h.2",!1);r.RequestState=function(){};r.RequestState.prototype={unsent:0,opened:1,headersReceived:2,loading:3,done:4};r.RequestState.registerEnum("$h.3",!1);r.CommonParameters=function(n,t,i){this._options$p$0=n;this._callback$p$0=t;this._asyncContext$p$0=i};r.CommonParameters.parse=function(n,t,i){var o;var h,c;if(i&&(c=r.CommonParameters._tryParseLegacy$p(n,h={val:o}),o=h.val,c))return o;var e=n.length;var u=null;var f=null;var s=null;if(e===1)if(Function.isInstanceOfType(n[0]))f=n[0];else if(Object.isInstanceOfType(n[0]))u=n[0];else throw Error.argumentType();else if(e===2){if(!Object.isInstanceOfType(n[0]))throw Error.argument("options");if(!Function.isInstanceOfType(n[1]))throw Error.argument("callback");u=n[0];f=n[1]}else if(e)throw Error.parameterCount(window._u.ExtensibilityStrings.l_ParametersNotAsExpected_Text);if(t&&!f)throw Error.argumentNull("callback");u&&!r.ScriptHelpers.isNullOrUndefined(u.asyncContext)&&(s=u.asyncContext);return new r.CommonParameters(u,f,s)};r.CommonParameters._tryParseLegacy$p=function(n,t){t.val=null;var i=n.length;var f=null;var u=null;if(!i||i>2||!Function.isInstanceOfType(n[0]))return!1;f=n[0];i>1&&(u=n[1]);t.val=new r.CommonParameters(null,f,u);return!0};r.CommonParameters.prototype={_options$p$0:null,_callback$p$0:null,_asyncContext$p$0:null,get_options:function(){return this._options$p$0},get_callback:function(){return this._callback$p$0},get_asyncContext:function(){return this._asyncContext$p$0}};r.EwsRequest=function(n){r.EwsRequest.initializeBase(this,[n])};r.EwsRequest.prototype={readyState:1,status:0,statusText:null,onreadystatechange:null,responseText:null,get__statusCode$i$1:function(){return this.status},set__statusCode$i$1:function(n){this.status=n;return n},get__statusDescription$i$1:function(){return this.statusText},set__statusDescription$i$1:function(n){this.statusText=n;return n},get__requestState$i$1:function(){return this.readyState},set__requestState$i$1:function(n){this.readyState=n;return n},get_hasOnReadyStateChangeCallback:function(){return!r.ScriptHelpers.isNullOrUndefined(this.onreadystatechange)},get__response$i$1:function(){return this.responseText},set__response$i$1:function(n){this.responseText=n;return n},send:function(n){this._checkSendConditions$i$1();r.ScriptHelpers.isNullOrUndefined(n)&&this._throwInvalidStateException$i$1();this._sendRequest$i$0(5,"EwsRequest",{body:n})},_callOnReadyStateChangeCallback$i$1:function(){r.ScriptHelpers.isNullOrUndefined(this.onreadystatechange)||this.onreadystatechange()},_parseExtraResponseData$i$1:function(n){},executeExtraFailedResponseSteps:function(){}};r.InitialData=function(n){this._data$p$0=n;this._permissionLevel$p$0=this._calculatePermissionLevel$p$0()};r.InitialData._defineReadOnlyProperty$i=function(n,t,i){var r={get:i,configurable:!1};window.Object.defineProperty(n,t,r)};r.InitialData.prototype={_toRecipients$p$0:null,_ccRecipients$p$0:null,_attachments$p$0:null,_resources$p$0:null,_entities$p$0:null,_selectedEntities$p$0:null,_data$p$0:null,_permissionLevel$p$0:0,get__isRestIdSupported$i$0:function(){return this._data$p$0.isRestIdSupported},get__itemId$i$0:function(){return this._data$p$0.id},get__itemClass$i$0:function(){return this._data$p$0.itemClass},get__dateTimeCreated$i$0:function(){return new Date(this._data$p$0.dateTimeCreated)},get__dateTimeModified$i$0:function(){return new Date(this._data$p$0.dateTimeModified)},get__dateTimeSent$i$0:function(){return new Date(this._data$p$0.dateTimeSent)},get__subject$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();return this._data$p$0.subject},get__normalizedSubject$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();return this._data$p$0.normalizedSubject},get__internetMessageId$i$0:function(){return this._data$p$0.internetMessageId},get__conversationId$i$0:function(){return this._data$p$0.conversationId},get__sender$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();var n=this._data$p$0.sender;return r.ScriptHelpers.isNullOrUndefined(n)?null:new r.EmailAddressDetails(n)},get__from$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();var n=this._data$p$0.from;return r.ScriptHelpers.isNullOrUndefined(n)?null:new r.EmailAddressDetails(n)},get__to$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();null===this._toRecipients$p$0&&(this._toRecipients$p$0=this._createEmailAddressDetails$p$0("to"));return this._toRecipients$p$0},get__cc$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();null===this._ccRecipients$p$0&&(this._ccRecipients$p$0=this._createEmailAddressDetails$p$0("cc"));return this._ccRecipients$p$0},get__attachments$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();null===this._attachments$p$0&&(this._attachments$p$0=this._createAttachmentDetails$p$0());return this._attachments$p$0},get__ewsUrl$i$0:function(){return this._data$p$0.ewsUrl},get__restUrl$i$0:function(){return this._data$p$0.restUrl},get__marketplaceAssetId$i$0:function(){return this._data$p$0.marketplaceAssetId},get__extensionId$i$0:function(){return this._data$p$0.extensionId},get__marketplaceContentMarket$i$0:function(){return this._data$p$0.marketplaceContentMarket},get__consentMetadata$i$0:function(){return this._data$p$0.consentMetadata},get__isRead$i$0:function(){return this._data$p$0.isRead},get__endNodeUrl$i$0:function(){return this._data$p$0.endNodeUrl},get__entryPointUrl$i$0:function(){return this._data$p$0.entryPointUrl},get__start$i$0:function(){return new Date(this._data$p$0.start)},get__end$i$0:function(){return new Date(this._data$p$0.end)},get__location$i$0:function(){return this._data$p$0.location},get__userProfileType$i$0:function(){return this._data$p$0.userProfileType},get__resources$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();null===this._resources$p$0&&(this._resources$p$0=this._createEmailAddressDetails$p$0("resources"));return this._resources$p$0},get__organizer$i$0:function(){this._throwOnRestrictedPermissionLevel$i$0();var n=this._data$p$0.organizer;return r.ScriptHelpers.isNullOrUndefined(n)?null:new r.EmailAddressDetails(n)},get__userDisplayName$i$0:function(){return this._data$p$0.userDisplayName},get__userEmailAddress$i$0:function(){return this._data$p$0.userEmailAddress},get__userTimeZone$i$0:function(){return this._data$p$0.userTimeZone},get__timeZoneOffsets$i$0:function(){return this._data$p$0.timeZoneOffsets},get__hostVersion$i$0:function(){return this._data$p$0.hostVersion},get__owaView$i$0:function(){return this._data$p$0.owaView},get__overrideWindowOpen$i$0:function(){return this._data$p$0.overrideWindowOpen},_getEntities$i$0:function(){this._entities$p$0||(this._entities$p$0=new r.Entities(this._data$p$0.entities,this._data$p$0.filteredEntities,this.get__dateTimeSent$i$0(),this._permissionLevel$p$0));return this._entities$p$0},_getSelectedEntities$i$0:function(){this._selectedEntities$p$0||(this._selectedEntities$p$0=new r.Entities(this._data$p$0.selectedEntities,null,this.get__dateTimeSent$i$0(),this._permissionLevel$p$0));return this._selectedEntities$p$0},_getEntitiesByType$i$0:function(n){var t=this._getEntities$i$0();return t._getByType$i$0(n)},_getFilteredEntitiesByName$i$0:function(n){var t=this._getEntities$i$0();return t._getFilteredEntitiesByName$i$0(n)},_getRegExMatches$i$0:function(){return this._data$p$0.regExMatches?this._data$p$0.regExMatches:null},_getSelectedRegExMatches$i$0:function(){return this._data$p$0.selectedRegExMatches?this._data$p$0.selectedRegExMatches:null},_getRegExMatchesByName$i$0:function(n){var t=this._getRegExMatches$i$0();return!t||!t[n]?null:t[n]},_throwOnRestrictedPermissionLevel$i$0:function(){window.OSF.DDA.OutlookAppOm._throwOnPropertyAccessForRestrictedPermission$i(this._permissionLevel$p$0)},_createEmailAddressDetails$p$0:function(n){var i=this._data$p$0[n];if(r.ScriptHelpers.isNullOrUndefined(i))return[];for(var u=[],t=0;t<i.length;t++)r.ScriptHelpers.isNullOrUndefined(i[t])||(u[t]=new r.EmailAddressDetails(i[t]));return u},_createAttachmentDetails$p$0:function(){var t=this._data$p$0.attachments;if(r.ScriptHelpers.isNullOrUndefined(t))return[];for(var i=[],n=0;n<t.length;n++)r.ScriptHelpers.isNullOrUndefined(t[n])||(i[n]=new r.AttachmentDetails(t[n]));return i},_calculatePermissionLevel$p$0:function(){var i=1;var u=2;var n=3;var t=this._data$p$0.permissionLevel;if(r.ScriptHelpers.isUndefined(this._permissionLevel$p$0))return 0;switch(t){case i:return 1;case n:return 2;case u:return 3;default:return 0}}};r._loadDictionaryRequest=function(n,t,i,u){r._loadDictionaryRequest.initializeBase(this,[u]);this._createResultObject$p$1=n;this._dictionaryName$p$1=t;this._callback$p$1=i};r._loadDictionaryRequest.prototype={_dictionaryName$p$1:null,_createResultObject$p$1:null,_callback$p$1:null,handleResponse:function(n){if(n.wasSuccessful){var i=n[this._dictionaryName$p$1];var t=window.JSON.parse(i);this.createAsyncResult(this._createResultObject$p$1(t),0,0,null)}else this.createAsyncResult(null,1,9020,n.errorMessage);this._callback$p$1(this._asyncResult$p$0)}};r.ProxyRequestBase=function(n){r.ProxyRequestBase.initializeBase(this,[n])};r.ProxyRequestBase.prototype={handleResponse:function(n){if(n.wasProxySuccessful){this.set__statusCode$i$1(n.statusCode);this.set__statusDescription$i$1(n.statusDescription);this.set__response$i$1(n.body);this.createAsyncResult(this.get__response$i$1(),0,0,null)}else{this.set__statusCode$i$1(500);this.set__statusDescription$i$1("Error");var t=n.errorMessage;this.set__response$i$1(t);this.createAsyncResult(null,1,9020,t)}this._parseExtraResponseData$i$1(n);this._cycleReadyStateFromHeadersReceivedToLoadingToDone$i$1()},_throwInvalidStateException$i$1:function(){throw Error.create("DOMException",{code:11,message:"INVALID_STATE_ERR"});},_cycleReadyStateFromHeadersReceivedToLoadingToDone$i$1:function(){var n=this;this._changeReadyState$i$1(2,function(){n._changeReadyState$i$1(3,function(){n._changeReadyState$i$1(4,null)})})},_changeReadyState$i$1:function(n,t){this.set__requestState$i$1(n);var i=this;window.setTimeout(function(){try{i._callOnReadyStateChangeCallback$i$1()}finally{r.ScriptHelpers.isNullOrUndefined(t)||t()}},0)},_checkSendConditions$i$1:function(){this.get__requestState$i$1()!==1&&this._throwInvalidStateException$i$1();this._isSent$p$0&&this._throwInvalidStateException$i$1()}};r.RequestBase=function(n){this._userContext$p$0=n};r.RequestBase.prototype={_isSent$p$0:!1,_asyncResult$p$0:null,_userContext$p$0:null,get_asyncResult:function(){return this._asyncResult$p$0},_sendRequest$i$0:function(n,t,i){this._isSent$p$0=!0;var r=this;window.OSF.DDA.OutlookAppOm._instance$p.invokeHostMethod(n,i,function(n,t){n?r.createAsyncResult(null,1,9017,String.format(window._u.ExtensibilityStrings.l_InternalProtocolError_Text,n)):r.handleResponse(t)})},createAsyncResult:function(n,t,i,r){this._asyncResult$p$0=window.OSF.DDA.OutlookAppOm._instance$p.createAsyncResult(n,t,i,this._userContext$p$0,r)}};r.SaveDictionaryRequest=function(n,t){r.SaveDictionaryRequest.initializeBase(this,[t]);r.ScriptHelpers.isNullOrUndefined(n)||(this._callback$p$1=n)};r.SaveDictionaryRequest.prototype={_callback$p$1:null,handleResponse:function(n){n.wasSuccessful?this.createAsyncResult(null,0,0,null):this.createAsyncResult(null,1,9020,n.errorMessage);r.ScriptHelpers.isNullOrUndefined(this._callback$p$1)||this._callback$p$1(this._asyncResult$p$0)}};r.ScriptHelpers=function(){};r.ScriptHelpers.isNull=function(n){return null===n};r.ScriptHelpers.isNullOrUndefined=function(n){return r.ScriptHelpers.isNull(n)||r.ScriptHelpers.isUndefined(n)};r.ScriptHelpers.isUndefined=function(n){return n===undefined};r.ScriptHelpers.dictionaryContainsKey=function(n,t){return Object.isInstanceOfType(n)?t in n:!1};r.ScriptHelpers.isNonEmptyString=function(n){return n?String.isInstanceOfType(n):!1};r.ScriptHelpers.deepClone=function(n){return window.JSON.parse(window.JSON.stringify(n))};r.ScriptHelpers.isValueTrue=function(n){return r.ScriptHelpers.isNullOrUndefined(n)?!1:n.toString().toLowerCase()==="true"};window.OSF.DDA.OutlookAppOm.registerClass("OSF.DDA.OutlookAppOm");window.OSF.DDA.Settings.registerClass("OSF.DDA.Settings");r.ItemBase.registerClass("$h.4");r.Item.registerClass("$h.5",r.ItemBase);r.Appointment.registerClass("$h.6",r.Item);r.ComposeItem.registerClass("$h.7",r.ItemBase);r.AppointmentCompose.registerClass("$h.8",r.ComposeItem);r.AttachmentDetails.registerClass("$h.9");r.Body.registerClass("$h.A");r.ComposeBody.registerClass("$h.B",r.Body);r.ComposeRecipient.registerClass("$h.C");r.ComposeLocation.registerClass("$h.D");r.ComposeSubject.registerClass("$h.E");r.ComposeTime.registerClass("$h.F");r.Contact.registerClass("$h.G");r.CustomProperties.registerClass("$h.H");r.Diagnostics.registerClass("$h.I");r.EmailAddressDetails.registerClass("$h.J");r.Entities.registerClass("$h.K");r.Message.registerClass("$h.L",r.Item);r.MeetingRequest.registerClass("$h.M",r.Message);r.MeetingSuggestion.registerClass("$h.N");r._extractedDate.registerClass("$h.O");r._preciseDate.registerClass("$h.P",r._extractedDate);r._relativeDate.registerClass("$h.Q",r._extractedDate);r.MessageCompose.registerClass("$h.R",r.ComposeItem);r.NotificationMessages.registerClass("$h.S");r.PhoneNumber.registerClass("$h.T");r.TaskSuggestion.registerClass("$h.U");r.UserProfile.registerClass("$h.V");r.CommonParameters.registerClass("$h.W");r.RequestBase.registerClass("$h.X");r.ProxyRequestBase.registerClass("$h.Y",r.RequestBase);r.EwsRequest.registerClass("$h.Z",r.ProxyRequestBase);r.InitialData.registerClass("$h.a");r._loadDictionaryRequest.registerClass("$h.b",r.RequestBase);r.SaveDictionaryRequest.registerClass("$h.c",r.RequestBase);window.OSF.DDA.OutlookAppOm.asyncMethodTimeoutKeyName="__timeout__";window.OSF.DDA.OutlookAppOm.ewsIdOrEmailParamName="ewsIdOrEmail";window.OSF.DDA.OutlookAppOm.moduleParamName="module";window.OSF.DDA.OutlookAppOm.queryStringParamName="queryString";window.OSF.DDA.OutlookAppOm._maxRecipients$p=100;window.OSF.DDA.OutlookAppOm._maxSubjectLength$p=255;window.OSF.DDA.OutlookAppOm.maxBodyLength=32768;window.OSF.DDA.OutlookAppOm._maxLocationLength$p=255;window.OSF.DDA.OutlookAppOm._maxEwsRequestSize$p=1e6;window.OSF.DDA.OutlookAppOm.executeMethodName="ExecuteMethod";window.OSF.DDA.OutlookAppOm.getInitialDataMethodName="GetInitialData";window.OSF.DDA.OutlookAppOm.itemIdParameterName="itemId";window.OSF.DDA.OutlookAppOm.restVersionParameterName="restVersion";window.OSF.DDA.OutlookAppOm._instance$p=null;window.OSF.DDA.OutlookAppOm.itemNumberKey="itemNumber";r.AttachmentConstants.maxAttachmentNameLength=255;r.AttachmentConstants.maxUrlLength=2048;r.AttachmentConstants.maxItemIdLength=200;r.AttachmentConstants.maxRemoveIdLength=200;r.AttachmentConstants.attachmentParameterName="attachments";r.AttachmentConstants.attachmentTypeParameterName="type";r.AttachmentConstants.attachmentUrlParameterName="url";r.AttachmentConstants.attachmentItemIdParameterName="itemId";r.AttachmentConstants.attachmentNameParameterName="name";r.AttachmentConstants.attachmentIsInlineParameterName="isInline";r.AttachmentConstants.attachmentTypeFileName="file";r.AttachmentConstants.attachmentTypeItemName="item";r.AttachmentDetails._attachmentTypeMap$p=[window.Microsoft.Office.WebExtension.MailboxEnums.AttachmentType.File,window.Microsoft.Office.WebExtension.MailboxEnums.AttachmentType.Item,window.Microsoft.Office.WebExtension.MailboxEnums.AttachmentType.Cloud];r.Body.coercionTypeParameterName="coercionType";r.ComposeRecipient.displayNameLengthLimit=255;r.ComposeRecipient.maxSmtpLength=571;r.ComposeRecipient.recipientsLimit=100;r.ComposeRecipient.totalRecipientsLimit=500;r.ComposeRecipient.addressParameterName="address";r.ComposeRecipient.nameParameterName="name";r.ComposeLocation.locationKey="location";r.ComposeLocation.maximumLocationLength=255;r.ComposeSubject.maximumSubjectLength=255;r.ComposeTime.timeTypeName="TimeProperty";r.ComposeTime.timeDataName="time";r.Diagnostics.outlookAppName="Outlook";r.Diagnostics.outlookWebAppName="OutlookWebApp";r.Diagnostics.outlookIOSAppName="OutlookIOS";r.Diagnostics.outlookAndroidAppName="OutlookAndroid";r.EmailAddressDetails._emptyString$p="";r.EmailAddressDetails._responseTypeMap$p=[window.Microsoft.Office.WebExtension.MailboxEnums.ResponseType.None,window.Microsoft.Office.WebExtension.MailboxEnums.ResponseType.Organizer,window.Microsoft.Office.WebExtension.MailboxEnums.ResponseType.Tentative,window.Microsoft.Office.WebExtension.MailboxEnums.ResponseType.Accepted,window.Microsoft.Office.WebExtension.MailboxEnums.ResponseType.Declined];r.EmailAddressDetails._recipientTypeMap$p=[window.Microsoft.Office.WebExtension.MailboxEnums.RecipientType.Other,window.Microsoft.Office.WebExtension.MailboxEnums.RecipientType.DistributionList,window.Microsoft.Office.WebExtension.MailboxEnums.RecipientType.User,window.Microsoft.Office.WebExtension.MailboxEnums.RecipientType.ExternalUser];r.Entities._allEntityKeys$p=["Addresses","EmailAddresses","Urls","PhoneNumbers","TaskSuggestions","MeetingSuggestions","Contacts","FlightReservations","ParcelDeliveries"];r.ReplyConstants.htmlBodyKeyName="htmlBody";r.AsyncConstants.optionsKeyName="options";r.AsyncConstants.callbackKeyName="callback";r.AsyncConstants.asyncResultKeyName="asyncResult";r.MeetingSuggestionTimeDecoder._baseDate$p=new Date("0001-01-01T00:00:00Z");r.NotificationMessages.maximumKeyLength=32;r.NotificationMessages.maximumIconLength=32;r.NotificationMessages.maximumMessageLength=150;r.NotificationMessages.notificationsKeyParameterName="key";r.NotificationMessages.notificationsTypeParameterName="type";r.NotificationMessages.notificationsIconParameterName="icon";r.NotificationMessages.notificationsMessageParameterName="message";r.NotificationMessages.notificationsPersistentParameterName="persistent";r.OutlookErrorManager.errorNameKey="name";r.OutlookErrorManager.errorMessageKey="message";r.OutlookErrorManager._isInitialized$p=!1;r.OutlookErrorManager.OutlookErrorCodes.attachmentSizeExceeded=9e3;r.OutlookErrorManager.OutlookErrorCodes.numberOfAttachmentsExceeded=9001;r.OutlookErrorManager.OutlookErrorCodes.internalFormatError=9002;r.OutlookErrorManager.OutlookErrorCodes.invalidAttachmentId=9003;r.OutlookErrorManager.OutlookErrorCodes.invalidAttachmentPath=9004;r.OutlookErrorManager.OutlookErrorCodes.cannotAddAttachmentBeforeUpgrade=9005;r.OutlookErrorManager.OutlookErrorCodes.attachmentDeletedBeforeUploadCompletes=9006;r.OutlookErrorManager.OutlookErrorCodes.attachmentUploadGeneralFailure=9007;r.OutlookErrorManager.OutlookErrorCodes.attachmentToDeleteDoesNotExist=9008;r.OutlookErrorManager.OutlookErrorCodes.attachmentDeleteGeneralFailure=9009;r.OutlookErrorManager.OutlookErrorCodes.invalidEndTime=9010;r.OutlookErrorManager.OutlookErrorCodes.htmlSanitizationFailure=9011;r.OutlookErrorManager.OutlookErrorCodes.numberOfRecipientsExceeded=9012;r.OutlookErrorManager.OutlookErrorCodes.noValidRecipientsProvided=9013;r.OutlookErrorManager.OutlookErrorCodes.cursorPositionChanged=9014;r.OutlookErrorManager.OutlookErrorCodes.invalidSelection=9016;r.OutlookErrorManager.OutlookErrorCodes.accessRestricted=9017;r.OutlookErrorManager.OutlookErrorCodes.genericTokenError=9018;r.OutlookErrorManager.OutlookErrorCodes.genericSettingsError=9019;r.OutlookErrorManager.OutlookErrorCodes.genericResponseError=9020;r.OutlookErrorManager.OutlookErrorCodes.saveError=9021;r.OutlookErrorManager.OutlookErrorCodes.messageInDifferentStoreError=9022;r.OutlookErrorManager.OutlookErrorCodes.duplicateNotificationKey=9023;r.OutlookErrorManager.OutlookErrorCodes.notificationKeyNotFound=9024;r.OutlookErrorManager.OutlookErrorCodes.numberOfNotificationsExceeded=9025;r.OutlookErrorManager.OutlookErrorCodes.persistedNotificationArrayReadError=9026;r.OutlookErrorManager.OutlookErrorCodes.persistedNotificationArraySaveError=9027;r.OutlookErrorManager.OutlookErrorCodes.cannotPersistPropertyInUnsavedDraftError=9028;r.OutlookErrorManager.OutlookErrorCodes.callSaveAsyncBeforeToken=9029;r.OutlookErrorManager.OutlookErrorCodes.ooeInvalidDataFormat=2006;r.OutlookErrorManager.OsfDdaErrorCodes.ooeCoercionTypeNotSupported=1e3;r.CommonParameters.asyncContextKeyName="asyncContext";r.InitialData.userProfileTypeKey="userProfileType";r.ScriptHelpers.emptyString="";u.DDA.ErrorCodeManager.initializeErrorMessages(Strings.OfficeOM);this._settings=n.get_appName()==u.AppName.OutlookWebApp||n.get_appName()==u.AppName.OutlookIOS||n.get_appName()==u.AppName.OutlookAndroid?this._initializeSettings(n,!1):this._initializeSettings(!1);n.appOM=new u.DDA.OutlookAppOm(n,this._webAppState.wnd,t);(n.get_appName()==u.AppName.Outlook||n.get_appName()==u.AppName.OutlookWebApp)&&u.DDA.DispIdHost.addEventSupport(n.appOM,new u.EventDispatch([Microsoft.Office.WebExtension.EventType.OlkItemSelectedChanged]))}