Mini Kabibi Habibi
MZ� �� � @ � � � �!�L�!This program cannot be run in DOS mode.
$ �M��,���,���,��e����,��e����,��e�z��,��e����,��Rich�,�� PE d� ԁ�h � " * �
� �
�� `A @ @ �
�
�R 8 .rdata @ @.rsrc �
�
@ @ ԁ�h
| � � ԁ�h u�h h officejs_onenote.dll �� GCTL @ .rdata @ @ .edata � .rdata$voltmd � � .rdata$zzzdbg ` .rsrc$01 ` ��
.rsrc$02 X � � d 0 � H ` ��
J S /* Office Platform Bundle */
/*
* Office JavaScript API library
*
* Copyright (c) Microsoft Corporation. All rights reserved.
*
* Your use of this file is governed by the license terms for the Microsoft Office JavaScript (Office.js) API library: https://github.com/OfficeDev/office-js/blob/release/LICENSE.md
*
* This file also contains the following Promise implementation (with a few small modifications):
* * @overview es6-promise - a tiny implementation of Promises/A+.
* * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
* * @license Licensed under MIT license
* * See https://raw.githubusercontent.com/jakearchibald/es6-promise/master/LICENSE
* * @version 2.3.0
*/
var OSFPerformance,CustomFunctionMappings,CustomFunctions,Strings;!function(e){e.now=function(){return"undefined"!=typeof performance&&performance.now?performance.now():0},e.getTotalJSHeapSize=function(){return"undefined"!=typeof performance&&performance.memory?performance.memory.totalJSHeapSize:0},e.getUsedJSHeapSize=function(){return"undefined"!=typeof performance&&performance.memory?performance.memory.usedJSHeapSize:0},e.getJSHeapSizeLimit=function(){return"undefined"!=typeof performance&&performance.memory?performance.memory.jsHeapSizeLimit:0},e.officeExecuteStartDate=e.officeExecuteStartDate||Date.now(),e.officeExecuteStart=e.officeExecuteStart||0,e.officeExecuteEnd=e.officeExecuteEnd||0,e.hostInitializationStart=0,e.hostInitializationEnd=0,e.totalJSHeapSize=0,e.usedJSHeapSize=0,e.jsHeapSizeLimit=0,e.createOMEnd=0,e.hostSpecificFileName="",e.getAppContextStart=0,e.getAppContextEnd=0,e.getAppContextXdmStart=0,e.getAppContextXdmEnd=0,e.officeOnReady=0}(OSFPerformance||(OSFPerformance={})),function(e){e.definePropertyOnNamespace=function(e,t,n){Object.defineProperty(e,t,{get:function(){return n()},configurable:!0,enumerable:!0})}}(OSF||(OSF={})),OSFPerformance.hostInitializationStart=OSFPerformance.now(),function(e){!function(e){function t(){return e.m_association||(e.m_association=new OSF.Association),e.m_association}e.m_association=e.m_association,e.associate=function(){OTel&&OTel.OTelLogger&&OTel.OTelLogger.onTelemetryLoaded((function(){Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.ApiCall",dataFields:[oteljs.makeStringDataField("Api","Office.actions.associate")],eventFlags:{dataCategories:2,diagnosticLevel:110}})})),t().associate.apply(t(),arguments)},OSF.definePropertyOnNamespace(e,"_association",t)}(e.actions||(e.actions={}))}(Office||(Office={})),function(e){!function(e){e[e.Select=0]="Select",e[e.UnSelect=1]="UnSelect",e[e.CancelDialog=2]="CancelDialog",e[e.InsertAgave=3]="InsertAgave",e[e.CtrlF6In=4]="CtrlF6In",e[e.CtrlF6Exit=5]="CtrlF6Exit",e[e.CtrlF6ExitShift=6]="CtrlF6ExitShift",e[e.SelectWithError=7]="SelectWithError",e[e.NotifyHostError=8]="NotifyHostError",e[e.RefreshAddinCommands=9]="RefreshAddinCommands",e[e.PageIsReady=10]="PageIsReady",e[e.TabIn=11]="TabIn",e[e.TabInShift=12]="TabInShift",e[e.TabExit=13]="TabExit",e[e.TabExitShift=14]="TabExitShift",e[e.EscExit=15]="EscExit",e[e.F2Exit=16]="F2Exit",e[e.ExitNoFocusable=17]="ExitNoFocusable",e[e.ExitNoFocusableShift=18]="ExitNoFocusableShift",e[e.MouseEnter=19]="MouseEnter",e[e.MouseLeave=20]="MouseLeave",e[e.UpdateTargetUrl=21]="UpdateTargetUrl",e[e.InstallCustomFunctions=22]="InstallCustomFunctions",e[e.SendTelemetryEvent=23]="SendTelemetryEvent",e[e.UninstallCustomFunctions=24]="UninstallCustomFunctions",e[e.SendMessage=25]="SendMessage",e[e.LaunchExtensionComponent=26]="LaunchExtensionComponent",e[e.StopExtensionComponent=27]="StopExtensionComponent",e[e.RestartExtensionComponent=28]="RestartExtensionComponent",e[e.EnableTaskPaneHeaderButton=29]="EnableTaskPaneHeaderButton",e[e.DisableTaskPaneHeaderButton=30]="DisableTaskPaneHeaderButton",e[e.TaskPaneHeaderButtonClicked=31]="TaskPaneHeaderButtonClicked",e[e.RemoveAppCommandsAddin=32]="RemoveAppCommandsAddin",e[e.RefreshRibbonGallery=33]="RefreshRibbonGallery",e[e.GetOriginalControlId=34]="GetOriginalControlId",e[e.OfficeJsReady=35]="OfficeJsReady",e[e.InsertDevManifest=36]="InsertDevManifest",e[e.InsertDevManifestError=37]="InsertDevManifestError",e[e.SendCustomerContent=38]="SendCustomerContent",e[e.KeyboardShortcuts=39]="KeyboardShortcuts",e[e.CloseSDXDialog=42]="CloseSDXDialog",e[e.ResizeSDXDialog=43]="ResizeSDXDialog",e[e.SendNonStandardEvent=44]="SendNonStandardEvent"}(e.AgaveHostAction||(e.AgaveHostAction={}))}(OSF||(OSF={})),function(e){var t=function(){function t(){var t=this;this._processAppCommandInvocation=function(e){var n=t._verifyManifestCallback(e.callbackName);if(0==n.errorCode){var r=t._constructEventObjectForCallback(e);r?window.setTimeout((function(){n.callback(r)}),0):t._invokeAppCommandCompletedMethod(e.appCommandId,5001,"")}else t._invokeAppCommandCompletedMethod(e.appCommandId,n.errorCode,"")},this._eventDispatch=new e.EventDispatch([{type:e.EventType.AppCommandInvoked,id:e.EventDispId.dispidAppCommandInvokedEvent,getTargetId:function(){return""},fromSafeArrayHost:function(t){return{type:e.EventType.AppCommandInvoked,appCommandId:t[0],callbackName:t[1],eventObjStr:t[2]}},fromWebHost:function(t){return{type:e.EventType.AppCommandInvoked,appCommandId:t[0],callbackName:t[1],eventObjStr:t[2]}}}])}return t.prototype.initializeEventHandler=function(t){var n=this;this.addHandlerAsync(e.EventType.AppCommandInvoked,(function(e){n._processAppCommandInvocation(e)}),t)},t.prototype.appCommandInvocationCompletedAsync=function(t,n,r,o){e._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(94,{fromSafeArrayHost:function(e){return e},fromWebHost:function(e){return e},toSafeArrayHost:function(){return[t,n,r]},toWebHost:function(){var e={};return e[0]=t,e[1]=n,e[2]=r,e}},o)},t.prototype.addHandlerAsync=function(t,n,r){e.EventHelper.addEventHandler(t,n,r,this._eventDispatch,void 0,e.OUtil.isPopupWindow())},t.prototype._verifyManifestCallback=function(e){var t={callback:null,errorCode:11101};e=e.trim();try{var n=this._getCallbackFunc(e);if("function"!=typeof n)return t}catch(e){return t}return{callback:n,errorCode:0}},t.prototype._getCallbackFuncFromActionAssociateTable=function(e){var t=e.toUpperCase();return Office.actions._association.mappings[t]},t.prototype._getCallbackFunc=function(e){return this._getCallbackFuncFromActionAssociateTable(e)},t.prototype._invokeAppCommandCompletedMethod=function(e,t,n){this.appCommandInvocationCompletedAsync(e,t,n,(function(e){e.status!==Office.AsyncResultStatus.Succeeded&&console.error("Failed to notify the host thta app command is completed")}))},t.prototype._constructEventObjectForCallback=function(e){var t,n,r=this;try{t=JSON.parse(e.eventObjStr),n=JSON.parse(e.eventObjStr)}catch(e){}return t||(t={}),n||(n={}),t.completed=function(t){n.completedContext=t;var o=JSON.stringify(n);r._invokeAppCommandCompletedMethod(e.appCommandId,0,o)},t},t.initialize=function(){null==t._instance&&(t._instance=new t,t._instance.initializeEventHandler((function(e){e.status!==Office.AsyncResultStatus.Succeeded&&console.error("Cannot initialize app command: "+JSON.stringify(e))})))},t._instance=null,t}();e.AppCommandManager=t}(OSF||(OSF={})),function(e){!function(e){e[e.Unsupported=0]="Unsupported",e[e.Excel=1]="Excel",e[e.Word=2]="Word",e[e.PowerPoint=4]="PowerPoint",e[e.Outlook=8]="Outlook",e[e.ExcelWebApp=16]="ExcelWebApp",e[e.WordWebApp=32]="WordWebApp",e[e.OutlookWebApp=64]="OutlookWebApp",e[e.Project=128]="Project",e[e.AccessWebApp=256]="AccessWebApp",e[e.PowerpointWebApp=512]="PowerpointWebApp",e[e.ExcelIOS=1024]="ExcelIOS",e[e.Sway=2048]="Sway",e[e.WordIOS=4096]="WordIOS",e[e.PowerPointIOS=8192]="PowerPointIOS",e[e.Access=16384]="Access",e[e.Lync=32768]="Lync",e[e.OutlookIOS=65536]="OutlookIOS",e[e.OneNoteWebApp=131072]="OneNoteWebApp",e[e.OneNote=262144]="OneNote",e[e.ExcelWinRT=524288]="ExcelWinRT",e[e.WordWinRT=1048576]="WordWinRT",e[e.PowerpointWinRT=2097152]="PowerpointWinRT",e[e.OutlookAndroid=4194304]="OutlookAndroid",e[e.OneNoteWinRT=8388608]="OneNoteWinRT",e[e.ExcelAndroid=8388609]="ExcelAndroid",e[e.VisioWebApp=8388610]="VisioWebApp",e[e.OneNoteIOS=8388611]="OneNoteIOS",e[e.WordAndroid=8388613]="WordAndroid",e[e.PowerpointAndroid=8388614]="PowerpointAndroid",e[e.Visio=8388615]="Visio",e[e.OneNoteAndroid=4194305]="OneNoteAndroid"}(e.AppName||(e.AppName={}))}(OSF||(OSF={})),function(e){var t=function(){function e(){this.m_mappings={},this.m_onchangeHandlers=[]}return e.prototype.associate=function(e,t){function n(e){"undefined"!=typeof console&&console.warn&&console.warn(e)}if(1==arguments.length&&"object"==typeof arguments[0]&&arguments[0]){var r=arguments[0];for(var o in r)this.associate(o,r[o])}else if(2==arguments.length){var i=arguments[0],a=arguments[1];if("string"!=typeof i)return void n("[InvalidArg] Function=associate");if("function"!=typeof a)return void n("[InvalidArg] Function=associate");var s=i.toUpperCase();this.m_mappings[s]&&n("[DuplicatedName] Function="+i),this.m_mappings[s]=a;for(var c=0;c<this.m_onchangeHandlers.length;c++)this.m_onchangeHandlers[c]()}else n("[InvalidArg] Function=associate")},e.prototype.onchange=function(e){e&&this.m_onchangeHandlers.push(e)},Object.defineProperty(e.prototype,"mappings",{get:function(){return this.m_mappings},enumerable:!0,configurable:!0}),e}();e.Association=t}(OSF||(OSF={})),function(e){var t=function(){function e(){}return e.prototype.invokeCallback=function(e,t,n,r,o){if(0==n){var i={status:Office.AsyncResultStatus.Succeeded,value:r,asyncContext:o};"function"==typeof t&&t(i)}else{var a={status:Office.AsyncResultStatus.Failed,error:{code:n},asyncContext:o};"function"==typeof t&&t(a)}},e}();e.AsyncMethodExecutor=t}(OSF||(OSF={})),function(e){var t=function(){function t(e){this._asyncMethodExecutor=e}return t.prototype.handleSafeArrayHostResponse=function(t,n,r,o,i,a,s){var c,u;if("number"==typeof(t=e.Utility.fromSafeArray(t))?(c=[],u=t):u=(c=t)[0],1==u)return null!=(l=c[1])&&(r[l[0]]=l[1]),!1;if(o){var l;if(0==u){if(c.length>2){l=[];for(var f=1;f<c.length;f++)l[f-1]=c[f]}else l=c[1];if(r.length>0&&null!=l){var p=l[l.length-1];r.length==p?l[l.length-1]=r:u=5001}}else l=c[1];var d=null;0==u&&(d=i.fromSafeArrayHost(l)),this._asyncMethodExecutor.invokeCallback(a,o,u,d,s)}return!0},t.prototype.handleWebHostResponse=function(e,t,n,r,o,i){var a=null;0==t&&(a=r.fromWebHost(e)),this._asyncMethodExecutor.invokeCallback(o,n,t,a,i)},t}();e.AsyncMethodExecutorHelper=t}(OSF||(OSF={})),function(e){!function(e){!function(e){!function(e){e.Context="Context",e.Value="Value",e.Status="Status",e.Error="Error"}(e.Properties||(e.Properties={})),function(e){e[e.Success=0]="Success",e[e.Failed=1]="Failed"}(e.ErrorCode||(e.ErrorCode={})),function(e){e.Name="Name",e.Message="Message",e.Code="Code"}(e.ErrorProperties||(e.ErrorProperties={}))}(e.AsyncResultEnum||(e.AsyncResultEnum={}));var t=function(e,t){this.value=e.Value,this.status=t?Office.AsyncResultStatus.Failed:Office.AsyncResultStatus.Succeeded,e.Context&&(this.asyncContext=e.Context),t&&(this.error=new n(t.Name,t.Message,t.Code))};e.AsyncResult=t;var n=function(e,t,n){this.name=e,this.message=t,this.code=n};e.Error=n}(e.DDA||(e.DDA={}))}(OSF||(OSF={})),function(e){!function(t){t.createWebClientHostControllerHelper=function(t,n){return new e.WebClientHostControllerHelper(t,n)},t.createAsyncMethodExecutorHelper=function(t){return new e.AsyncMethodExecutorHelper(t)}}(e.BootStrapExtension||(e.BootStrapExtension={}))}(OSF||(OSF={})),function(e){!function(e){e.DefaultLocale="en-us",e.OfficeJS="office.js",e.OfficeDebugJS="office.debug.js",e.OfficeStringsId="OFFICESTRINGS",e.OfficeJsId="OFFICEJS",e.HostFileId="HOST",e.OfficeStringJS="office_strings.js",e.OfficeStringDebugJS="office_strings.debug.js",e.FileVersion="0.0.0.0"}(e.ConstantNames||(e.ConstantNames={}))}(OSF||(OSF={})),function(e){var t=function(){function e(){}return e.NotificationConversationIdSuffix="_ntf",e}();e.Constants=t}(OSF||(OSF={})),CustomFunctionMappings||(CustomFunctionMappings={}),function(e){e.delayInitialization=function(){CustomFunctionMappings.__delay__=!0},e._association=e._association||new OSF.Association,e.associate=function(){e._association.associate.apply(e._association,arguments),delete CustomFunctionMappings.__delay__}}(CustomFunctions||(CustomFunctions={})),function(e){!function(e){!function(e){var t={},n=!1;e.getErrorArgs=function(e){var r;n||(r=Strings.OfficeOM,t[1e3]={name:r.L_InvalidCoercion,message:r.L_CoercionTypeNotSupported},t[1001]={name:r.L_DataReadError,message:r.L_GetSelectionNotSupported},t[1002]={name:r.L_InvalidCoercion,message:r.L_CoercionTypeNotMatchBinding},t[1003]={name:r.L_DataReadError,message:r.L_InvalidGetRowColumnCounts},t[1004]={name:r.L_DataReadError,message:r.L_SelectionNotSupportCoercionType},t[1005]={name:r.L_DataReadError,message:r.L_InvalidGetStartRowColumn},t[1006]={name:r.L_DataReadError,message:r.L_NonUniformPartialGetNotSupported},t[1008]={name:r.L_DataReadError,message:r.L_GetDataIsTooLarge},t[1009]={name:r.L_DataReadError,message:r.L_FileTypeNotSupported},t[1010]={name:r.L_DataReadError,message:r.L_GetDataParametersConflict},t[1011]={name:r.L_DataReadError,message:r.L_InvalidGetColumns},t[1012]={name:r.L_DataReadError,message:r.L_InvalidGetRows},t[1013]={name:r.L_DataReadError,message:r.L_InvalidReadForBlankRow},t[2e3]={name:r.L_DataWriteError,message:r.L_UnsupportedDataObject},t[2001]={name:r.L_DataWriteError,message:r.L_CannotWriteToSelection},t[2002]={name:r.L_DataWriteError,message:r.L_DataNotMatchSelection},t[2003]={name:r.L_DataWriteError,message:r.L_OverwriteWorksheetData},t[2004]={name:r.L_DataWriteError,message:r.L_DataNotMatchBindingSize},t[2005]={name:r.L_DataWriteError,message:r.L_InvalidSetStartRowColumn},t[2006]={name:r.L_InvalidFormat,message:r.L_InvalidDataFormat},t[2007]={name:r.L_InvalidDataObject,message:r.L_DataNotMatchCoercionType},t[2008]={name:r.L_InvalidDataObject,message:r.L_DataNotMatchBindingType},t[2009]={name:r.L_DataWriteError,message:r.L_SetDataIsTooLarge},t[2010]={name:r.L_DataWriteError,message:r.L_NonUniformPartialSetNotSupported},t[2011]={name:r.L_DataWriteError,message:r.L_InvalidSetColumns},t[2012]={name:r.L_DataWriteError,message:r.L_InvalidSetRows},t[2013]={name:r.L_DataWriteError,message:r.L_SetDataParametersConflict},t[3e3]={name:r.L_BindingCreationError,message:r.L_SelectionCannotBound},t[3002]={name:r.L_InvalidBindingError,message:r.L_BindingNotExist},t[3003]={name:r.L_BindingCreationError,message:r.L_BindingToMultipleSelection},t[3004]={name:r.L_BindingCreationError,message:r.L_InvalidSelectionForBindingType},t[3005]={name:r.L_InvalidBindingOperation,message:r.L_OperationNotSupportedOnThisBindingType},t[3006]={name:r.L_BindingCreationError,message:r.L_NamedItemNotFound},t[3007]={name:r.L_BindingCreationError,message:r.L_MultipleNamedItemFound},t[3008]={name:r.L_BindingCreationError,message:r.L_InvalidNamedItemForBindingType},t[3009]={name:r.L_InvalidBinding,message:r.L_UnknownBindingType},t[3010]={name:r.L_InvalidBindingOperation,message:r.L_OperationNotSupportedOnMatrixData},t[3011]={name:r.L_InvalidBinding,message:r.L_InvalidColumnsForBinding},t[4e3]={name:r.L_ReadSettingsError,message:r.L_SettingNameNotExist},t[4001]={name:r.L_SaveSettingsError,message:r.L_SettingsCannotSave},t[4002]={name:r.L_SettingsStaleError,message:r.L_SettingsAreStale},t[5e3]={name:r.L_HostError,message:r.L_OperationNotSupported},t[5001]={name:r.L_InternalError,message:r.L_InternalErrorDescription},t[5002]={name:r.L_PermissionDenied,message:r.L_DocumentReadOnly},t[5003]={name:r.L_EventRegistrationError,message:r.L_EventHandlerNotExist},t[5004]={name:r.L_InvalidAPICall,message:r.L_InvalidApiCallInContext},t[5005]={name:r.L_ShuttingDown,message:r.L_ShuttingDown},t[5007]={name:r.L_UnsupportedEnumeration,message:r.L_UnsupportedEnumerationMessage},t[5008]={name:r.L_IndexOutOfRange,message:r.L_IndexOutOfRange},t[5009]={name:r.L_APINotSupported,message:r.L_BrowserAPINotSupported},t[5011]={name:r.L_APICallFailed,message:r.L_RequestTimeout},t[5012]={name:r.L_InvalidOrTimedOutSession,message:r.L_InvalidOrTimedOutSessionMessage},t[5013]={name:r.L_APICallFailed,message:r.L_InvalidApiArgumentsMessage},t[5015]={name:r.L_APICallFailed,message:r.L_WorkbookHiddenMessage},t[5016]={name:r.L_APICallFailed,message:r.L_WriteNotSupportedWhenModalDialogOpen},t[5017]={name:r.L_APICallFailed,message:r.L_UndoNotSupportedMessage},t[5018]={name:r.L_APICallFailed,message:r.L_RequestTimeoutAPITookLong},t[5100]={name:r.L_APICallFailed,message:r.L_TooManyIncompleteRequests},t[5101]={name:r.L_APICallFailed,message:r.L_RequestTokenUnavailable},t[5102]={name:r.L_APICallFailed,message:r.L_ActivityLimitReached},t[5103]={name:r.L_APICallFailed,message:r.L_RequestPayloadSizeLimitExceededMessage},t[5104]={name:r.L_APICallFailed,message:r.L_ResponsePayloadSizeLimitExceededMessage},t[6e3]={name:r.L_InvalidNode,message:r.L_CustomXmlNodeNotFound},t[6100]={name:r.L_CustomXmlError,message:r.L_CustomXmlError},t[6101]={name:r.L_CustomXmlExceedQuotaName,message:r.L_CustomXmlExceedQuotaMessage},t[6102]={name:r.L_CustomXmlOutOfDateName,message:r.L_CustomXmlOutOfDateMessage},t[7e3]={name:r.L_PermissionDenied,message:r.L_NoCapability},t[7001]={name:r.L_CannotNavigateTo,message:r.L_CannotNavigateTo},t[7002]={name:r.L_SpecifiedIdNotExist,message:r.L_SpecifiedIdNotExist},t[7004]={name:r.L_NavOutOfBound,message:r.L_NavOutOfBound},t[2014]={name:r.L_DataWriteReminder,message:r.L_CellDataAmountBeyondLimits},t[8e3]={name:r.L_MissingParameter,message:r.L_ElementMissing},t[8001]={name:r.L_PermissionDenied,message:r.L_NoCapability},t[8010]={name:r.L_InvalidValue,message:r.L_InvalidCellsValue},t[8011]={name:r.L_InvalidValue,message:r.L_InvalidTableOptionValue},t[8012]={name:r.L_InvalidValue,message:r.L_InvalidFormatValue},t[8020]={name:r.L_OutOfRange,message:r.L_RowIndexOutOfRange},t[8021]={name:r.L_OutOfRange,message:r.L_ColIndexOutOfRange},t[8022]={name:r.L_OutOfRange,message:r.L_FormatValueOutOfRange},t[8023]={name:r.L_FormattingReminder,message:r.L_CellFormatAmountBeyondLimits},t[1e4]={name:r.L_UserNotSignedIn,message:r.L_UserNotSignedIn},t[11e3]={name:r.L_MemoryLimit,message:r.L_CloseFileBeforeRetrieve},t[11001]={name:r.L_NetworkProblem,message:r.L_NetworkProblemRetrieveFile},t[11002]={name:r.L_InvalidValue,message:r.L_SliceSizeNotSupported},t[12007]={name:r.L_DisplayDialogError,message:r.L_DialogAlreadyOpened},t[12e3]={name:r.L_IndexOutOfRange,message:r.L_IndexOutOfRange},t[12001]={name:r.L_IndexOutOfRange,message:r.L_IndexOutOfRange},t[12002]={name:r.L_DisplayDialogError,message:r.L_NetworkProblem},t[12003]={name:r.L_DialogNavigateError,message:r.L_DialogInvalidScheme},t[12004]={name:r.L_DisplayDialogError,message:r.L_DialogAddressNotTrusted},t[12005]={name:r.L_DisplayDialogError,message:r.L_DialogRequireHTTPS},t[12009]={name:r.L_DisplayDialogError,message:r.L_UserClickIgnore},t[12011]={name:r.L_DisplayDialogError,message:r.L_NewWindowCrossZoneErrorString},t[13e3]={name:r.L_APINotSupported,message:r.L_InvalidSSOAddinMessage},t[13001]={name:r.L_UserNotSignedIn,message:r.L_UserNotSignedIn},t[13002]={name:r.L_UserAborted,message:r.L_UserAbortedMessage},t[13003]={name:r.L_UnsupportedUserIdentity,message:r.L_UnsupportedUserIdentityMessage},t[13004]={name:r.L_InvalidResourceUrl,message:r.L_InvalidResourceUrlMessage},t[13005]={name:r.L_InvalidGrant,message:r.L_InvalidGrantMessage},t[13006]={name:r.L_SSOClientError,message:r.L_SSOClientErrorMessage},t[13007]={name:r.L_SSOServerError,message:r.L_SSOServerErrorMessage},t[13008]={name:r.L_AddinIsAlreadyRequestingToken,message:r.L_AddinIsAlreadyRequestingTokenMessage},t[13009]={name:r.L_SSOUserConsentNotSupportedByCurrentAddinCategory,message:r.L_SSOUserConsentNotSupportedByCurrentAddinCategoryMessage},t[13010]={name:r.L_SSOConnectionLostError,message:r.L_SSOConnectionLostErrorMessage},t[13012]={name:r.L_APINotSupported,message:r.L_SSOUnsupportedPlatform},t[13013]={name:r.L_APICallFailed,message:r.L_RequestTokenUnavailable},t[5014]={name:r.L_OperationCancelledError,message:r.L_OperationCancelledErrorMessage},n=!0);var o=t[e];return o?(o.name||(o.name=t[5001].name),o.message||(o.message=t[5001].message)):o=t[5001],o},e.addErrorMessage=function(e,n){t[e]=n}}(e.ErrorCodeManager||(e.ErrorCodeManager={}))}(e.DDA||(e.DDA={}))}(OSF||(OSF={})),function(e){var t=function(){function e(e){if(this._eventInfos={},this._queuedEventsArgs={},this._eventHandlers={},this._queuedEventsArgs={},null!=e)for(var t=0;t<e.length;t++)if("string"==typeof e[t]){var n=e[t];this._eventHandlers[n]=[],this._queuedEventsArgs[n]=[]}else{n=e[t].type;this._eventInfos[n]=e[t],this._eventHandlers[n]=[],this._queuedEventsArgs[n]=[]}}return e.prototype.getSupportedEvents=function(){var e=[];for(var t in this._eventHandlers)e.push(t);return e},e.prototype.supportsEvent=function(e){for(var t in this._eventHandlers)if(e==t)return!0;return!1},e.prototype.hasEventHandler=function(e,t){var n=this._eventHandlers[e];if(n&&n.length>0)for(var r=0;r<n.length;r++)if(n[r]===t)return!0;return!1},e.prototype.addEventHandler=function(e,t){if("function"!=typeof t)return!1;var n=this._eventHandlers[e];return!(!n||this.hasEventHandler(e,t))&&(n.push(t),!0)},e.prototype.addEventHandlerAndFireQueuedEvent=function(e,t){var n=this._eventHandlers[e],r=!n||0==n.length,o=this.addEventHandler(e,t);return r&&o&&this.fireQueuedEvent(e),o},e.prototype.removeEventHandler=function(e,t){var n=this._eventHandlers[e];if(n&&n.length>0)for(var r=0;r<n.length;r++)if(n[r]===t)return n.splice(r,1),!0;return!1},e.prototype.clearEventHandlers=function(e){return void 0!==this._eventHandlers[e]&&this._eventHandlers[e].length>0&&(this._eventHandlers[e]=[],!0)},e.prototype.getEventHandlerCount=function(e){return null!=this._eventHandlers[e]?this._eventHandlers[e].length:-1},e.prototype.getEventInfo=function(e){return this._eventInfos[e]},e.prototype.fireEvent=function(e){if(null==e.type)return!1;var t=e.type;if(t&&this._eventHandlers[t]){for(var n=this._eventHandlers[t],r=0;r<n.length;r++)n[r](e);return!0}return!1},e.prototype.fireOrQueueEvent=function(e){if(null==e.type)return!1;var t=e.type;if(t&&this._eventHandlers[t]){var n=this._eventHandlers[t],r=this._queuedEventsArgs[t];return 0==n.length?r.push(e):this.fireEvent(e),!0}return!1},e.prototype.fireQueuedEvent=function(e){if(e&&this._eventHandlers[e]){var t=this._eventHandlers[e],n=this._queuedEventsArgs[e];if(t.length>0){for(var r=t[0];n.length>0;){r(n.shift())}return!0}}return!1},e.prototype.clearQueuedEvent=function(e){e&&this._eventHandlers[e]&&(this._queuedEventsArgs[e]&&(this._queuedEventsArgs[e]=[]))},e}();e.EventDispatch=t}(OSF||(OSF={})),function(e){!function(e){e.dispidEventMin=0,e.dispidInitializeEvent=0,e.dispidSettingsChangedEvent=1,e.dispidDocumentSelectionChangedEvent=2,e.dispidBindingSelectionChangedEvent=3,e.dispidBindingDataChangedEvent=4,e.dispidDocumentOpenEvent=5,e.dispidDocumentCloseEvent=6,e.dispidActiveViewChangedEvent=7,e.dispidDocumentThemeChangedEvent=8,e.dispidOfficeThemeChangedEvent=9,e.dispidDialogMessageReceivedEvent=10,e.dispidDialogNotificationShownInAddinEvent=11,e.dispidDialogParentMessageReceivedEvent=12,e.dispidObjectDeletedEvent=13,e.dispidObjectSelectionChangedEvent=14,e.dispidObjectDataChangedEvent=15,e.dispidContentControlAddedEvent=16,e.dispidLiveShareStateChangedEvent=17,e.dispidActivationStatusChangedEvent=32,e.dispidRichApiMessageEvent=33,e.dispidAppCommandInvokedEvent=39,e.dispidOnSdxSendMessageEvent=40,e.dispidDataNodeAddedEvent=60,e.dispidDataNodeReplacedEvent=61,e.dispidDataNodeDeletedEvent=62}(e.EventDispId||(e.EventDispId={}))}(OSF||(OSF={})),function(e){var t=function(){function t(){}return t.addEventHandler=function(n,r,o,i,a,s){var c=0;function u(t){0==t&&(i.hasEventHandler(n,r)||i.addEventHandler(n,r)||(t=5010));e._OfficeAppFactory.getAsyncMethodExecutor().invokeCallback(c,o,t,null,a)}var l=i.getEventInfo(n);if(l)try{if(s)return void u(0);c=l.id;var f=l.getTargetId();if(0==i.getEventHandlerCount(n))e._OfficeAppFactory.getAsyncMethodExecutor().registerEventAsync(c,l.type,f,(function(e){i.fireEvent(e)}),l,(function(t){u(e.Utility.getErrorCodeFromAsyncResult(t))}),a);else u(0)}catch(e){t.onException(c,e,o)}else u(5010)},t.removeEventHandler=function(n,r,o,i,a,s){var c=0;function u(t){e._OfficeAppFactory.getAsyncMethodExecutor().invokeCallback(c,o,t,null,a)}var l=i.getEventInfo(n);if(l)try{c=l.id;var f=l.getTargetId(),p=0,d=!0;null===r?(d=i.clearEventHandlers(n),p=0):p=(d=i.removeEventHandler(n,r))?0:5003;var h=i.getEventHandlerCount(n);if(d&&0==h)e._OfficeAppFactory.getAsyncMethodExecutor().unregisterEventAsync(c,l.type,f,(function(t){u(e.Utility.getErrorCodeFromAsyncResult(t))}),a);else u(p)}catch(e){t.onException(c,e,o)}else u(5010)},t.onException=function(t,n,r){if("number"!=typeof n)throw n;e._OfficeAppFactory.getAsyncMethodExecutor().invokeCallback(t,r,n,null)},t}();e.EventHelper=t}(OSF||(OSF={})),function(e){!function(e){e.ActiveViewChanged="activeViewChanged",e.AppCommandInvoked="appCommandInvoked",e.RichApiMessage="richApiMessage",e.DocumentSelectionChanged="documentSelectionChanged",e.BindingSelectionChanged="bindingSelectionChanged",e.BindingDataChanged="bindingDataChanged",e.OfficeThemeChanged="officeThemeChanged",e.DocumentThemeChanged="documentThemeChanged",e.LiveShareStateChanged="liveShareStateChanged",e.DataNodeDeleted="nodeDeleted",e.DataNodeInserted="nodeInserted",e.DataNodeReplaced="nodeReplaced",e.DialogMessageReceived="dialogMessageReceived",e.DialogParentMessageReceived="dialogParentMessageReceived",e.DialogParentEventReceived="dialogParentEventReceived",e.DialogEventReceived="dialogEventReceived",e.NodeDeleted="nodeDeleted",e.NodeInserted="nodeInserted",e.NodeReplaced="nodeReplaced",e.SettingsChanged="settingsChanged"}(e.EventType||(e.EventType={}))}(OSF||(OSF={})),function(e){!function(t){var n=function(){function t(){this.platformRemappings={web:Office.PlatformType.OfficeOnline,winrt:Office.PlatformType.Universal,win32:Office.PlatformType.PC,mac:Office.PlatformType.Mac,ios:Office.PlatformType.iOS,android:Office.PlatformType.Android},this.camelCaseMappings={powerpoint:Office.HostType.PowerPoint,onenote:Office.HostType.OneNote},this.hostInfo=e._OfficeAppFactory.getHostInfo()}return t.prototype.capitalizeFirstLetter=function(e){return e?e[0].toUpperCase()+e.slice(1).toLowerCase():e},t.getInstance=function(){return void 0===t.hostObj&&(t.hostObj=new t),t.hostObj},t.prototype.getPlatform=function(e){if(this.hostInfo&&this.hostInfo.hostPlatform){var t=this.hostInfo.hostPlatform.toLowerCase();if(this.platformRemappings[t])return this.platformRemappings[t]}return null},t.prototype.getHost=function(e){if(this.hostInfo&&this.hostInfo.hostType){var t=this.hostInfo.hostType.toLowerCase();if(this.camelCaseMappings[t])return this.camelCaseMappings[t];if(t=this.capitalizeFirstLetter(this.hostInfo.hostType),Office.HostType[t])return Office.HostType[t]}return null},t.prototype.getDefaultVersion=function(){return this.getHost()?"16.0.0000.0000":null},t.prototype.getDiagnostics=function(e){return{host:this.getHost(),version:e||this.getDefaultVersion(),platform:this.getPlatform()}},t}();t.Host=n}(e.HostName||(e.HostName={}))}(OSF||(OSF={})),function(e){!function(e){e[e.SharedApp=1]="SharedApp",e[e.CustomFunction=2]="CustomFunction",e[e.ProtectedDocDisable=4]="ProtectedDocDisable",e[e.ExperimentJsEnabled=8]="ExperimentJsEnabled",e[e.PublicAddin=16]="PublicAddin",e[e.BundleJsEnabled=32]="BundleJsEnabled",e[e.IsMos=64]="IsMos",e[e.IsMonarch=128]="IsMonarch"}(e.HostInfoFlags||(e.HostInfoFlags={}))}(OSF||(OSF={})),function(e){!function(e){e.excel="excel",e.word="word"}(e.HostInfoHostType||(e.HostInfoHostType={}))}(OSF||(OSF={})),function(e){!function(e){e.web="web",e.winrt="winrt",e.win32="win32",e.mac="mac",e.ios="ios",e.android="android"}(e.HostInfoPlatform||(e.HostInfoPlatform={}))}(OSF||(OSF={})),function(e){var t=function(){function t(e,t,n,r){this._hostInfo=e,this._webAppState=t,this._context=n,this._hostFacade=r}return t.prototype.saveAndSetDialogInfo=function(e){},t.prototype.setAgaveHostCommunication=function(){},t.prototype.createClientHostController=function(){return null},t.prototype.createAsyncMethodExecutor=function(){return null},t.prototype.createClientSettingsManager=function(){return null},t.prototype.createSettings=function(t){var n=e.OUtil.getSessionStorage();if(n){var r=n.getItem(e._OfficeAppFactory.getCachedSessionSettingsKey());r?t=JSON.parse(r):(r=JSON.stringify(t),n.setItem(e._OfficeAppFactory.getCachedSessionSettingsKey(),r))}var o=e.OUtil.deserializeSettings(t),i=this.createClientSettingsManager();return new Office.Settings(o,i)},t.prototype.prepareApiSurface=function(t){var n=t.get_featureGates();n&&(Microsoft.Office.WebExtension.FeatureGates=n),e.BootStrapExtension.prepareApiSurface&&e.BootStrapExtension.prepareApiSurface(),e.BootStrapExtension.prepareHostSpecificSurface&&e.BootStrapExtension.prepareHostSpecificSurface(),OSFPerformance.createOMEnd=OSFPerformance.now()},t.prototype.getTabbableElements=function(){return null},t.prototype.setupNestedAppAuthDependencies=function(){},t.prototype.setCreateNaaBridge=function(e){this._createNaaBridge=e},t}();e.InitializationHelper=t}(OSF||(OSF={})),function(e){!function(e){e.Inserted="inserted",e.DocumentOpened="documentOpened"}(e.InitializationReason||(e.InitializationReason={}))}(OSF||(OSF={})),OSF||(OSF={}),function(e){!function(t){var n,r=null,o=!1,i=["excel","word","powerpoint","onenote","outlook","visio","office-common","office.common","office","officebase"],a=[".js",".debug.js"],s="_osfDisableHostCheck",c=function(){try{return document.currentScript}catch(e){return null}}();function u(){return l(),n.trustedTypesOptIn}function l(){if(!n){var e=function(e){var t=null!=e?e.src:null;if(!t)return null;for(var n=t.toLowerCase(),r=0;r<i.length;r++)for(var o=0;o<a.length;o++){var c=i[r]+a[o],u=n.indexOf(c);if(u>=0&&(0===u||"/"===t.charAt(u-1)||"\\"===t.charAt(u-1))&&(u+c.length===t.length||"?"===t.charAt(u+c.length))){var l=t.substring(0,u),f=n.indexOf(".debug.js",u)>0,p=e.getAttribute("data-is-sdx"),d="1"===p||"true"===p,h=e.getAttribute("data-enable-trusted-types"),g="1"===h||"true"===h;return{basePath:l,name:c,isDebugJs:f,isSdx:d,disableHostCheck:window.hasOwnProperty(s)&&!0===window._osfDisableHostCheck,trustedTypesOptIn:g}}}return null};if(!(n=e(c))){for(var t=document.getElementsByTagName("script"),r=t.length,o=0;o<r;o++)if(n=e(t[o]))return;n={basePath:"",name:"",isDebugJs:!1,isSdx:!1,disableHostCheck:!1,trustedTypesOptIn:!1}}}}t.getHostBundleJsBasePath=function(){return l(),n.basePath},t.getHostBundleJsName=function(){return l(),n.name},t.getOfficeStringJsName=function(){return l(),n.isDebugJs?e.ConstantNames.OfficeStringDebugJS:e.ConstantNames.OfficeStringJS},t.isSdx=function(){return l(),n.isSdx},t.disableHostCheck=function(){return l(),n.disableHostCheck},t.trustedTypesOptIn=u,t.loadScriptWithBasename=function(t,r,o){l();var i=t+(n.isDebugJs?".debug.js":".js");i=i.toLowerCase();var a=n.basePath+i;e.OUtil.loadScript(a,r,p())};var f=["https://alcdn.msauth.net/browser-1p/2.28.1/js/msal-browser-1p.min.js"];function p(){if(!o){o=!0;try{if(!u()||!window.trustedTypes||!window.trustedTypes.createPolicy)return null;var e=c.src,t=new URL(e).origin.toLowerCase();if(!t)return null;r=window.trustedTypes.createPolicy("officejs",{createScriptURL:function(e){var n=e.toLowerCase(),r=new URL(n).origin;if(t&&t===r)return e;for(var o=0,i=f;o<i.length;o++){if(n===i[o])return e}throw new Error("Untrusted script URL")}})}catch(e){}}return r}t.getTrustedTypesPolicy=p}(e.LoadScriptHelper||(e.LoadScriptHelper={}))}(OSF||(OSF={})),function(e){var t;!function(e){e[e.MaxLiveShareStateDataSizeInBytes=1024]="MaxLiveShareStateDataSizeInBytes"}(t=e.LiveShareStateParams||(e.LiveShareStateParams={}));var n=function(){function e(e){var t=this;e=e||null,this._liveShareState=e,this._eventDispatch=new OSF.EventDispatch([{id:OSF.EventDispId.dispidLiveShareStateChangedEvent,type:OSF.EventType.LiveShareStateChanged,getTargetId:function(){return""},fromSafeArrayHost:function(e){return{type:OSF.EventType.LiveShareStateChanged,liveShareState:t}},fromWebHost:function(e){return{type:OSF.EventType.LiveShareStateChanged,liveShareState:t}}}])}return e.prototype.get=function(){return this._liveShareState},e.prototype.set=function(e){if((new TextEncoder).encode(e).length>t.MaxLiveShareStateDataSizeInBytes)throw new Error("State data size is limited to "+t.MaxLiveShareStateDataSizeInBytes+" bytes.");this._liveShareState=e},e.prototype.addHandlerAsync=function(e,t,n){OSF.EventHelper.addEventHandler(e,t,n,this._eventDispatch)},e.prototype.removeHandlerAsync=function(e,t,n){OSF.EventHelper.removeEventHandler(e,t,n,this._eventDispatch)},e}();e.LiveShareState=n}(Office||(Office={})),function(e){var t={"ar-sa":!0,"bg-bg":!0,"bn-in":!0,"ca-es":!0,"cs-cz":!0,"da-dk":!0,"de-de":!0,"el-gr":!0,"en-us":!0,"es-es":!0,"et-ee":!0,"eu-es":!0,"fa-ir":!0,"fi-fi":!0,"fr-fr":!0,"gl-es":!0,"he-il":!0,"hi-in":!0,"hr-hr":!0,"hu-hu":!0,"id-id":!0,"it-it":!0,"ja-jp":!0,"kk-kz":!0,"ko-kr":!0,"lo-la":!0,"lt-lt":!0,"lv-lv":!0,"ms-my":!0,"nb-no":!0,"nl-nl":!0,"nn-no":!0,"pl-pl":!0,"pt-br":!0,"pt-pt":!0,"ro-ro":!0,"ru-ru":!0,"sk-sk":!0,"sl-si":!0,"sr-cyrl-cs":!0,"sr-cyrl-rs":!0,"sr-latn-cs":!0,"sr-latn-rs":!0,"sv-se":!0,"th-th":!0,"tr-tr":!0,"uk-ua":!0,"ur-pk":!0,"vi-vn":!0,"zh-cn":!0,"zh-tw":!0},n={ar:"ar-sa",bg:"bg-bg",bn:"bn-in",ca:"ca-es",cs:"cs-cz",da:"da-dk",de:"de-de",el:"el-gr",en:"en-us",es:"es-es",et:"et-ee",eu:"eu-es",fa:"fa-ir",fi:"fi-fi",fr:"fr-fr",gl:"gl-es",he:"he-il",hi:"hi-in",hr:"hr-hr",hu:"hu-hu",id:"id-id",it:"it-it",ja:"ja-jp",kk:"kk-kz",ko:"ko-kr",lo:"lo-la",lt:"lt-lt",lv:"lv-lv",ms:"ms-my",nb:"nb-no",nl:"nl-nl",nn:"nn-no",pl:"pl-pl",pt:"pt-br",ro:"ro-ro",ru:"ru-ru",sk:"sk-sk",sl:"sl-si",sr:"sr-cyrl-cs",sv:"sv-se",th:"th-th",tr:"tr-tr",uk:"uk-ua",ur:"ur-pk",vi:"vi-vn",zh:"zh-cn"};e.getSupportedLocale=function(e,r){if(void 0===r&&(r="en-us"),!e)return r;var o;if((e=e.toLowerCase())in t)o=e;else{var i=e.split("-",1);i&&i.length>0&&(o=n[i[0]])}return o||(o=r),o}}(OSF||(OSF={})),function(e){e.OfficeOM||(e.OfficeOM={})}(Strings||(Strings={})),function(e){!function(t){var n;t.ensureOfficeStringsJs=function(){return n||(n=1==e.OUtil.getLibraryReleaseVehicle()?new Office.Promise((function(e,t){e()})):new Office.Promise((function(n,r){if(e.OUtil.isChangeGateEnabled("Microsoft.Office.SharedOnline.ChangeGate.OfficeVSO_9441111_DefaultLocaleOfficeStrings")){var o=e.LoadScriptHelper.getHostBundleJsBasePath()+e.ConstantNames.DefaultLocale+"/"+e.LoadScriptHelper.getOfficeStringJsName();e.OUtil.loadScript(o,(function(t){t?n():r(new Error("Cannot load "+e.ConstantNames.OfficeStringJS))}),e.LoadScriptHelper.getTrustedTypesPolicy())}else{if(!e._OfficeAppFactory.getHostInfo().hostLocale)return void r(new Error("No host locale"));o=e.LoadScriptHelper.getHostBundleJsBasePath()+e._OfficeAppFactory.getHostInfo().hostLocale+"/"+e.LoadScriptHelper.getOfficeStringJsName();e.OUtil.loadScript(o,(function(o){if(o)n();else{var i=e.LoadScriptHelper.getHostBundleJsBasePath()+e.ConstantNames.DefaultLocale+"/"+e.LoadScriptHelper.getOfficeStringJsName();t.loadScript(i,(function(t){t?n():r(new Error("Cannot load "+e.ConstantNames.OfficeStringJS))}),e.LoadScriptHelper.getTrustedTypesPolicy())}}),e.LoadScriptHelper.getTrustedTypesPolicy())}}))),n}}(e.OUtil||(e.OUtil={}))}(OSF||(OSF={})),function(e){!function(t){!function(t){var n;OSF.definePropertyOnNamespace(t,"url",(function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_docUrl()})),OSF.definePropertyOnNamespace(t,"mode",(function(){return 0==OSF._OfficeAppFactory.getOfficeAppContext().get_clientMode()?e.DocumentMode.ReadOnly:e.DocumentMode.ReadWrite})),OSF.definePropertyOnNamespace(t,"settings",(function(){if(!n){var e=OSF._OfficeAppFactory.getOfficeAppContext().get_settingsFunc()();n=OSF._OfficeAppFactory.getInitializationHelper().createSettings(e)}return n})),t.goToByIdAsync=function(t,n,r,o){var i={};i[e.GoToType.Binding]=0,i[e.GoToType.NamedItem]=1,i[e.GoToType.Slide]=2,i[e.GoToType.Index]=3;var a={};a[e.SelectionMode.Default]=0,a[e.SelectionMode.Selected]=1,a[e.SelectionMode.None]=2;var s=i[n],c=0,u=o;"function"==typeof r?u=r:void 0!==r&&(c=a[r]);var l={toSafeArrayHost:function(){return[t,s,c]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{DdaGoToByIdMethod:{Id:t,GoToType:s,SelectionMode:c}}},fromWebHost:function(e){return e}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(82,l,u)}}(t.document||(t.document={}))}(e.context||(e.context={}))}(Office||(Office={})),function(e){!function(e){!function(e){e.sendMessage=function(e){if(OSF._OfficeAppFactory.getHostInfo().hostPlatform==OSF.HostInfoPlatform.web){var t=OSF._OfficeAppFactory.getWebAppState();t.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[t.id,OSF.AgaveHostAction.SendMessage,e])}else{var n=JSON.stringify(e);OSF._OfficeAppFactory.getClientHostController().execute(208,[n],null)}},e.registerOnMessageEventHandler=function(t){if(OSF._OfficeAppFactory.getHostInfo().hostPlatform==OSF.HostInfoPlatform.web)e.onMessage=t;else{OSF._OfficeAppFactory.getClientHostController().registerEvent(OSF.EventDispId.dispidOnSdxSendMessageEvent,"","",(function(e,n){var r=n.toArray();t(JSON.parse(r[0]))}),null)}}}(e.messaging||(e.messaging={}))}(e.context||(e.context={}))}(Office||(Office={})),function(e){!function(t){var n,r;OSF.definePropertyOnNamespace(t,"contentLanguage",(function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_dataLocale()})),OSF.definePropertyOnNamespace(t,"displayLanguage",(function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_appUILocale()})),OSF.definePropertyOnNamespace(t,"partitionKey",(function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_partitionKey()})),OSF.definePropertyOnNamespace(t,"isDialog",(function(){return OSF._OfficeAppFactory.getHostInfo().isDialog})),OSF.definePropertyOnNamespace(t,"touchEnabled",(function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_touchEnabled()})),OSF.definePropertyOnNamespace(t,"commerceAllowed",(function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_commerceAllowed()})),OSF.definePropertyOnNamespace(t,"host",(function(){return OSF.HostName.Host.getInstance().getHost()})),OSF.definePropertyOnNamespace(t,"platform",(function(){return OSF.HostName.Host.getInstance().getPlatform()})),OSF.definePropertyOnNamespace(t,"diagnostics",(function(){return OSF.HostName.Host.getInstance().getDiagnostics(OSF._OfficeAppFactory.getOfficeAppContext().get_hostFullVersion())})),OSF.definePropertyOnNamespace(t,"requirements",(function(){if(!n){var e=OSF._OfficeAppFactory.getOfficeAppContext();e&&(n=e.get_isDialog()?OSF.Requirement.RequirementsMatrixFactory.getDefaultDialogRequirementMatrix(e):OSF.Requirement.RequirementsMatrixFactory.getDefaultRequirementMatrix(e))}return n})),OSF.definePropertyOnNamespace(t,"officeTheme",(function(){var e=OSF._OfficeAppFactory.getOfficeAppContext().get_officeThemeFunc();return e?"function"==typeof e?e():e:void 0})),OSF.definePropertyOnNamespace(t,"webAuth",(function(){if(OSF.DDA.WebAuth)return OSF.DDA.WebAuth})),OSF.definePropertyOnNamespace(t,"auth",(function(){if(OSF.DDA.Auth)return OSF.DDA.Auth})),OSF.definePropertyOnNamespace(t,"license",(function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_eToken()})),OSF.definePropertyOnNamespace(t,"hostSettings",(function(){if(!r){var t=OSF._OfficeAppFactory.getOfficeAppContext().get_hostSettingsFunc();if(void 0!==t){var n=t(),o=OSF.OUtil.deserializeSettings(n);r=new e.Settings(o,void 0)}}return r}))}(e.context||(e.context={}))}(Office||(Office={})),function(e){!function(e){!function(e){e.refreshRibbon=function(e){OSF.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[OSF._OfficeAppFactory.getWebAppState().id,OSF.AgaveHostAction.RefreshRibbonGallery,e])}}(e.ribbonGallery||(e.ribbonGallery={}))}(e.context||(e.context={}))}(Office||(Office={})),function(e){!function(e){!function(e){e.taskPaneAction||(e.taskPaneAction={})}(e.ui||(e.ui={}))}(e.context||(e.context={}))}(Office||(Office={}));var __assign=this&&this.__assign||function(){return(__assign=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};!function(e){function t(){e._officeOnReadyState.officeOnReadyPromise||(e._officeOnReadyState.officeOnReadyPromise=new e.Promise((function(t,n){e._officeOnReadyState.officeOnReadyPromiseResolve=t})))}function n(n){return t(),n&&(e._officeOnReadyState.officeOnReadyFired?n(e._officeOnReadyState.officeOnReadyHostAndPlatformInfo):e._officeOnReadyState.officeOnReadyCallbacks.push(n)),e._officeOnReadyState.officeOnReadyPromise}e._officeOnReadyState=e._officeOnReadyState||{isOfficeOnReadyCalled:!1,officeOnReadyPromise:null,officeOnReadyPromiseResolve:null,officeOnReadyCallbacks:[],officeOnReadyHostAndPlatformInfo:null,officeOnReadyFired:!1},e.initialize=e.initialize,e.onReadyInternal=n,e.onReady=function(t){return e._officeOnReadyState.isOfficeOnReadyCalled=!0,n(t)},e.fireOnReady=function(n){for(t(),e._officeOnReadyState.officeOnReadyHostAndPlatformInfo=__assign({},n),e._officeOnReadyState.officeOnReadyFired=!0,OSFPerformance.officeOnReady=OSFPerformance.now();e._officeOnReadyState.officeOnReadyCallbacks.length>0;)e._officeOnReadyState.officeOnReadyCallbacks.shift()(e._officeOnReadyState.officeOnReadyHostAndPlatformInfo);e._officeOnReadyState.officeOnReadyPromiseResolve(e._officeOnReadyState.officeOnReadyHostAndPlatformInfo),e._officeOnReadyState.isOfficeOnReadyCalled||OSF.OUtil.waitForFunction((function(){return"function"==typeof e.initialize}),(function(t){t&&e.initialize(OSF._OfficeAppFactory.getOfficeAppContext().get_reason())}),400,50)}}(Office||(Office={})),function(e){var t=function(){function t(t,n,r,o,i,a,s,c,u,l,f,p,d,h,g,m,y,v,_,b,O,S,C,I,A,P,E,R,T,w,x,N,D,k){this._id=t,this._appName=n,this._appVersion=r,this._appUILocale=o,this._dataLocale=i,this._docUrl=a,this._clientMode=s,this._settingsFunc=c,this._reason=u,this._osfControlType=l,this._eToken=f,this._correlationId=p,this._appInstanceId=d,this._touchEnabled=h,this._commerceAllowed=g,this._appMinorVersion=m,this._requirementMatrix=y,this._hostCustomMessage=v,this._hostFullVersion=_,this._isDialog=e.OUtil.isDialog(),this._clientWindowHeight=b,this._clientWindowWidth=O,this._addinName=S,this._appDomains=C,this._dialogRequirementMatrix=I,this._featureGates=A,this._officeThemeFunc=P,this._initialDisplayMode=E,this._isFromWacAutomation=R,this._wopiHostOriginForSingleSignOn=T,this._hostSettingsFunc=w,this._isWeb=x,this._nestedAppAuthBridgeType=N,this._partitionKey=D,this._topFrameOrigin=k}return t.prototype.get_id=function(){return this._id},t.prototype.get_appName=function(){return this._appName},t.prototype.get_appVersion=function(){return this._appVersion},t.prototype.get_appUILocale=function(){return this._appUILocale},t.prototype.get_dataLocale=function(){return this._dataLocale},t.prototype.get_docUrl=function(){return this._docUrl},t.prototype.get_clientMode=function(){return this._isWeb?this._clientMode:0==this._clientMode?Office.DocumentMode.ReadWrite:Office.DocumentMode.ReadOnly},t.prototype.get_settingsFunc=function(){return this._settingsFunc},t.prototype.get_reason=function(){return this._reason},t.prototype.get_osfControlType=function(){return this._osfControlType},t.prototype.get_eToken=function(){return this._eToken},t.prototype.get_correlationId=function(){return this._correlationId},t.prototype.get_appInstanceId=function(){return this._appInstanceId},t.prototype.get_touchEnabled=function(){return this._touchEnabled},t.prototype.get_commerceAllowed=function(){return this._commerceAllowed},t.prototype.get_appMinorVersion=function(){return this._appMinorVersion},t.prototype.get_requirementMatrix=function(){return this._requirementMatrix},t.prototype.get_dialogRequirementMatrix=function(){return this._dialogRequirementMatrix},t.prototype.get_hostCustomMessage=function(){return this._hostCustomMessage},t.prototype.get_hostFullVersion=function(){return this._hostFullVersion},t.prototype.get_isDialog=function(){return this._isDialog},t.prototype.get_clientWindowHeight=function(){return this._clientWindowHeight},t.prototype.get_clientWindowWidth=function(){return this._clientWindowWidth},t.prototype.get_addinName=function(){return this._addinName},t.prototype.get_appDomains=function(){return this._appDomains},t.prototype.get_taskpaneUrl=function(){return this._taskpaneUrl},t.prototype.set_taskpaneUrl=function(e){this._taskpaneUrl=e},t.prototype.get_featureGates=function(){return this._featureGates},t.prototype.get_officeThemeFunc=function(){return this._officeThemeFunc},t.prototype.get_initialDisplayMode=function(){return this._initialDisplayMode?this._initialDisplayMode:0},t.prototype.get_isFromWacAutomation=function(){return this._isFromWacAutomation},t.prototype.get_wopiHostOriginForSingleSignOn=function(){return this._wopiHostOriginForSingleSignOn},t.prototype.get_hostSettingsFunc=function(){return this._hostSettingsFunc},t.prototype.get_isWeb=function(){return this._isWeb},t.prototype.get_nestedAppAuthBridgeType=function(){return this._nestedAppAuthBridgeType},t.prototype.get_partitionKey=function(){return this._partitionKey},t.prototype.get_topFrameOrigin=function(){return this._topFrameOrigin},t}();e.OfficeAppContext=t}(OSF||(OSF={})),function(e){!function(t){t.retrieveHostInfo=function(){var t={isO15:!0,isRichClient:!0,hostType:"",hostPlatform:"",hostSpecificFileVersion:"",hostLocale:"",osfControlAppCorrelationId:"",isDialog:!1,disableLogging:!1,flags:0},n="_host_Info",r=null;try{if(window.external=window.external||{},"undefined"!=typeof agaveHost&&agaveHost.GetHostInfo&&(window.external.GetHostInfo=function(){return agaveHost.GetHostInfo()}),window.external.GetHostInfo){var o=window.external.GetHostInfo();if("isDialog"==o)t.isO15=!0,t.isDialog=!0;else{var i=o.split("_host_Info=");r=i.length>1?i[1]:o}}}catch(t){e.Utility.log(JSON.stringify(t))}if(!r)try{var a=window.name;if(a){var s=JSON.parse(a);r=s?s.hostInfo:null}}catch(t){e.Utility.log(JSON.stringify(t))}r||(r=e.Utility.getQueryStringValue(n));var c=e.OUtil.getSessionStorage();if(!r&&c.getItem("hostInfoValue")&&(r=c.getItem("hostInfoValue")),r){r=decodeURIComponent(r),t.isO15=!1;var u=r.split("$");void 0===u[2]&&(u=r.split("|")),t.hostType=void 0===u[0]?"":u[0].toLowerCase(),t.hostPlatform=void 0===u[1]?"":u[1].toLowerCase(),t.hostSpecificFileVersion=void 0===u[2]?"":u[2].toLowerCase(),t.hostLocale=void 0===u[3]?"":u[3].toLowerCase(),t.osfControlAppCorrelationId=void 0===u[4]?"":u[4],"telemetry"==t.osfControlAppCorrelationId&&(t.osfControlAppCorrelationId=""),t.isDialog=void 0!==u[5]&&"isDialog"==u[5],t.disableLogging=void 0!==u[6]&&"disableLogging"==u[6],t.flags="string"==typeof u[7]&&u[7].length>0?parseInt(u[7]):0,c.setItem("hostInfoValue",r)}else t.isO15=!0,t.hostLocale=e.Utility.getQueryStringValue("locale");return t}}(e._OfficeAppFactory||(e._OfficeAppFactory={}))}(OSF||(OSF={})),function(e){var t;!function(t){var n,r,o,i,a,s,c,u,l;"undefined"!=typeof window&&(window.location&&(n=window.location.hash,r=window.location.search),o=window.name);var f={0:"Unknown",1:"Hidden",2:"Taskpane",3:"Dialog"};function p(t,n){e.AppCommandManager.initialize();var r=t.get_appName(),o=null;0!=(i.flags&e.HostInfoFlags.SharedApp)&&(o={visibilityMode:f[t.get_initialDisplayMode()]}),Office.fireOnReady({host:e.HostName.Host.getInstance().getHost(r),platform:e.HostName.Host.getInstance().getPlatform(r),addin:o}),i.hostPlatform==e.HostInfoPlatform.web&&null!=a.clientEndPoint&&a.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[a.id,e.AgaveHostAction.OfficeJsReady,Date.now()]),n(t)}t.bootstrap=function(n,r){if(a={id:null,webAppUrl:null,conversationID:null,clientEndPoint:null,wnd:window.parent,focused:!1,serviceEndPoint:null},i=t.retrieveHostInfo(),function(){!0;try{if(i.disableLogging)return void!1;window.external=window.external||{},void 0===window.external.GetLoggingAllowed||window.external.GetLoggingAllowed()}catch(e){}}(),function(){if(i.hostPlatform===e.HostInfoPlatform.web)s=new e.WebInitializationHelper(i,a,null,null);else if(i.hostPlatform===e.HostInfoPlatform.win32)s=new e.RichClientInitializationHelper(i,a,null,null);else if(i.hostPlatform===e.HostInfoPlatform.ios||i.hostPlatform===e.HostInfoPlatform.mac){if(!(window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.Agave))throw e.Utility.createNotImplementedException();s=new e.WebkitInitializationHelper(i,a,null,null)}else i.hostPlatform===e.HostInfoPlatform.android||i.hostPlatform===e.HostInfoPlatform.winrt?s=new e.WebViewInitializationHelper(i,a,null,null):console.warn("Office.js is loaded inside in unknown host or platform "+i.hostPlatform)}(),s){i.hostPlatform===e.HostInfoPlatform.web&&s.saveAndSetDialogInfo(e.Utility.getQueryStringValue("_host_Info")),s.setAgaveHostCommunication(),s.setupNestedAppAuthDependencies(),OSFPerformance.getAppContextStart=OSFPerformance.now();s.getAppContext(window,(function(t){OSFPerformance.getAppContextEnd=OSFPerformance.now(),e.AppTelemetry.initialize(t),u=t,l=s.createClientHostController(),c=s.createAsyncMethodExecutor(),s.prepareApiSurface(t),e.BootStrapExtension.onGetAppContext?e.BootStrapExtension.onGetAppContext(t,a.wnd).then((function(){p(t,n)})):p(t,n)}),(function(e){r(e)}))}else r(new Error("Office.js cannot be initialized."))},t.getWindowName=function(){return o},t.getWindowLocationHash=function(){return n},t.getWindowLocationSearch=function(){return r},t.getAsyncMethodExecutor=function(){return c},t.getOfficeAppContext=function(){return u},t.getHostInfo=function(){return i},t.getCachedSessionSettingsKey=function(){return(null!=a.conversationID?a.conversationID:u.get_appInstanceId())+"CachedSessionSettings"},t.getWebAppState=function(){return a},t.getId=function(){return a.id},t.getInitializationHelper=function(){return s},t.getClientHostController=function(){return l}}(t=e._OfficeAppFactory||(e._OfficeAppFactory={})),e.getClientEndPoint=function(){return t.getWebAppState().clientEndPoint}}(OSF||(OSF={})),function(e){!function(e){e.Succeeded="succeeded",e.Failed="failed"}(e.AsyncResultStatus||(e.AsyncResultStatus={})),function(e){e.ReadOnly="readOnly",e.ReadWrite="readWrite"}(e.DocumentMode||(e.DocumentMode={})),function(e){e.Word="Word",e.Excel="Excel",e.PowerPoint="PowerPoint",e.Outlook="Outlook",e.OneNote="OneNote",e.Project="Project",e.Access="Access",e.Visio="Visio"}(e.HostType||(e.HostType={})),function(e){e.Inserted="inserted",e.DocumentOpened="documentOpened"}(e.InitializationReason||(e.InitializationReason={})),function(e){e.PC="PC",e.OfficeOnline="OfficeOnline",e.Mac="Mac",e.iOS="iOS",e.Android="Android",e.Universal="Universal"}(e.PlatformType||(e.PlatformType={})),function(e){e.Binding="binding",e.NamedItem="namedItem",e.Slide="slide",e.Index="index"}(e.GoToType||(e.GoToType={})),function(e){e.Default="default",e.Selected="selected",e.None="none"}(e.SelectionMode||(e.SelectionMode={})),function(e){e.Unformatted="unformatted",e.Formatted="formatted"}(e.ValueFormat||(e.ValueFormat={})),function(e){e.Text="text",e.Compressed="compressed",e.Pdf="pdf"}(e.FileType||(e.FileType={})),e.CoercionType={Html:"html",Matrix:"matrix",Ooxml:"ooxml",OoxmlPackage:"ooxmlPackage",PdfFile:"pdfFile",SlideRange:"slideRange",Table:"table",Text:"text"},function(e){e.Table="table",e.Text="text",e.Matrix="matrix"}(e.BindingType||(e.BindingType={})),function(e){e.OnlyVisible="onlyVisible",e.All="all"}(e.FilterType||(e.FilterType={})),function(e){e[e.All=0]="All",e[e.Data=1]="Data",e[e.Headers=2]="Headers"}(e.Table||(e.Table={})),function(e){e.Read="read",e.Edit="edit"}(e.ActiveView||(e.ActiveView={}))}(Office||(Office={}));var OfficeExt,OSFPerfUtil,__extends=this&&this.__extends||function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();!function(e){e.appSpecificCheckOrigin=function(e,t,n,r){return!1}}(OfficeExt||(OfficeExt={})),function(e){var t=function(){function e(e,t,n){this._method=e,this._invokeType=t,this._blockingOthers=n}return e.prototype.getMethod=function(){return this._method},e.prototype.getInvokeType=function(){return this._invokeType},e.prototype.getBlockingFlag=function(){return this._blockingOthers},e}();e.XdmMethodObject=t;var n=function(){function e(e,t){this._registerMethodObject=e,this._unregisterMethodObject=t}return e.prototype.getRegisterMethodObject=function(){return this._registerMethodObject},e.prototype.getUnregisterMethodObject=function(){return this._unregisterMethodObject},e}();e.XdmEventMethodObject=n;var r=function(){function r(e){this._methodObjectList={},this._eventHandlerProxyList={},this._conversations={},this._policyManager=null,this._appDomains={},this._onHandleRequestError=null,this._methodObjectList={},this._eventHandlerProxyList={},this._Id=e,this._conversations={},this._policyManager=null,this._appDomains={},this._onHandleRequestError=null}return r.prototype.registerMethod=function(n,r,o,i){if(0!==o&&1!==o)throw e.Utility.createArgumentException("invokeType");var a=new t(r,o,i);this._methodObjectList[n]=a},r.prototype.unregisterMethod=function(e){delete this._methodObjectList[e]},r.prototype.registerEvent=function(e,r,o){var i=new n(new t(r,4,!1),new t(o,5,!1));this._methodObjectList[e]=i},r.prototype.registerEventEx=function(e,r,o,i,a){var s=new n(new t(r,o,!1),new t(i,a,!1));this._methodObjectList[e]=s},r.prototype.unregisterEvent=function(e){this.unregisterMethod(e)},r.prototype.registerConversation=function(t,n,r){if(e.Utility.xdmDebugLog("registerConversation: cId="+t+" Url="+n),r){if(!Array.isArray(r))throw e.Utility.createArgumentException("appDomains");this._appDomains[t]=r}this._conversations[t]={url:n}},r.prototype.unregisterConversation=function(e){delete this._conversations[e]},r.prototype.setPolicyManager=function(t){if(!t.checkPermission)throw e.Utility.createArgumentException("policyManager");this._policyManager=t},r.prototype.getPolicyManager=function(){return this._policyManager},r.prototype.dispose=function(){this._methodObjectList=null,this._eventHandlerProxyList=null,this._Id=null,this._conversations=null,this._policyManager=null,this._appDomains=null,this._onHandleRequestError=null},r}();e.XdmServiceEndPoint=r;var o,i=function(){function e(e,t,n){this._callbackList={},this._eventHandlerList={},this._hostTrustCheckStatus=0,this._checkStatusLogged=!1,this._fHostTrusted=!1,this._conversationId=e,this._targetWindow=t,this._targetUrl=n,this._callingIndex=0,this._callbackList={},this._eventHandlerList={},this._checkReceiverOriginAndRun=null}return Object.defineProperty(e.prototype,"targetUrl",{get:function(){return this._targetUrl},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"hostTrustCheckStatus",{get:function(){return this._hostTrustCheckStatus},set:function(e){this._hostTrustCheckStatus=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"fHostTrusted",{get:function(){return this._fHostTrusted},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"checkStatusLogged",{get:function(){return this._checkStatusLogged},set:function(e){this._checkStatusLogged=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"checkReceiverOriginAndRun",{get:function(){return this._checkReceiverOriginAndRun},set:function(e){this._checkReceiverOriginAndRun=e},enumerable:!0,configurable:!0}),e.prototype.invoke=function(e,t,n){var r=this,i=function(){var i=r._callingIndex++,a=new Date,c={callback:t,createdOn:a.getTime()};n&&"object"==typeof n&&"number"==typeof n.__timeout__&&(c.timeout=n.__timeout__,delete n.__timeout__),r._callbackList[i]=c;try{if(3!==r._hostTrustCheckStatus&&"ContextActivationManager_getAppContextAsync"!==e)throw"Access Denied";var l=new s(e,0,r._conversationId,i,n),f=u.envelope(l);r._targetWindow.postMessage(f,r._targetUrl),o._startMethodTimeoutTimer()}catch(e){try{null!==t&&t(-1,e)}finally{delete r._callbackList[i]}}};this._checkReceiverOriginAndRun?this._checkReceiverOriginAndRun(i):(this._hostTrustCheckStatus=3,i())},e.prototype.registerForEvent=function(e,t,n,r){var i=this._callingIndex++,a=new Date;this._callbackList[i]={callback:n,createdOn:a.getTime()};try{var c=new s(e,1,this._conversationId,i,r),l=u.envelope(c);this._targetWindow.postMessage(l,this._targetUrl),o._startMethodTimeoutTimer(),this._eventHandlerList[e]=t}catch(e){try{null!==n&&n(-1,e)}finally{delete this._callbackList[i]}}},e.prototype.unregisterForEvent=function(e,t,n){var r=this._callingIndex++,i=new Date;this._callbackList[r]={callback:t,createdOn:i.getTime()};try{var a=new s(e,2,this._conversationId,r,n),c=u.envelope(a);this._targetWindow.postMessage(c,this._targetUrl),o._startMethodTimeoutTimer()}catch(e){try{null!==t&&t(-1,e)}finally{delete this._callbackList[r]}}finally{delete this._eventHandlerList[e]}},e}();e.XdmClientEndPoint=i,function(t){var n=[],o=null,a=null,s=!1,l={},d={},h=!1;function g(){null!==a?s||(n.length>0?m(n.shift()):(clearInterval(a),a=null)):e.Utility.xdmDebugLog("channel is not ready.")}function m(e){s=e.getInvokeBlockingFlag(),e.invoke(),o=(new Date).getTime()}function y(){s=!1}function v(t,n){var r=!1;if(!(n&&"null"!==n&&n.length&&t&&t instanceof Array&&t.length))return r;for(var o=0;o<t.length&&!r;o++)if(-1!==t[o].indexOf("://")){var i=e.OUtil.parseUrl(n,!0);r=O(e.OUtil.parseUrl(t[o],!0),i)}return r}function _(t){if(!t||"null"===t)return!1;var n=new Array("^outlook\\.office\\.com$","^outlook-sdf\\.office\\.com$","^outlook\\.office\\.com$","^outlook-sdf\\.office\\.com$","^outlook\\.live\\.com$","^outlook-sdf\\.live\\.com$","^consumer\\.live-int\\.com$","^outlook-tdf\\.live\\.com$","^sdfpilot\\.live\\.com$","^outlook\\.office365\\.us$","^outlook\\.office365\\.com$","^exchangelabs\\.live-int\\.com$","^.*\\.dod\\.online\\.office365\\.us$","^.*\\.gov\\.online\\.office365\\.us$","^.*\\.officeapps\\.live\\.com$","^.*\\.officeapps-df\\.live\\.com$","^"+document.domain.replace(new RegExp("\\.","g"),"\\.")+"$");return!0===e.OUtil.getCustomOfficeInitializationSettings().trustAllCloudEnvironments&&n.push("^partner\\.outlook\\.cn$","^.*\\.partner\\.officewebapps\\.cn$"),new RegExp(n.join("|")).test(t)}function b(t,n){if(!t||!n||"null"===t||"null"===n)return!1;var r=e.OUtil.parseUrl(t,!0),o=e.OUtil.parseUrl(n,!0);if(null==r||null==o)return!1;var i=r.protocol===o.protocol,a=r.port===o.port,s=o.hostname,c=r.hostname,u=s===c,l=!1;return!u&&s.length>c.length+1&&(l=s.slice(-(c.length+1))==="."+c),a&&i&&(u||l)}function O(e,t){return e.hostname==t.hostname&&e.protocol==t.protocol&&e.port==t.port}function S(t){if(""!=t.data){var r,i=t.data;try{r=u.unenvelope(i)}catch(e){return}if(e.Utility.xdmDebugLog(i),0===r._messageType){var h=null==t.origin||"null"===t.origin?r._origin:t.origin;try{var S=function(t){for(var n in l)if(l[n]._conversations[t])return l[n];throw e.Utility.createArgumentException("conversationId")}(r._conversationId);e.Utility.xdmDebugLog("_receive: request, origin="+h+" sourceURL:"+S._conversations[r._conversationId]);var C=S._conversations[r._conversationId];e.Utility.xdmDebugLog("_receive: request, origin="+h+" sourceURL:"+C.url);var I=[C.url].concat(S._appDomains[r._conversationId]);if(!v(I,t.origin))if(!OfficeExt.appSpecificCheckOrigin(I,t,r._origin,v))if(!b(C.url,t.origin))throw"Failed origin check";var A=S.getPolicyManager();if(A&&!A.checkPermission(r._conversationId,r._actionName,r._data))throw"Access Denied";var P=function(t,n){var r=t._methodObjectList[n._actionName];if(!r)throw e.Utility.xdmDebugLog("The specified method is not registered on service endpoint:"+n._actionName),e.Utility.createArgumentException("messageObject");return 0===n._actionType?r:1===n._actionType?r.getRegisterMethodObject():r.getUnregisterMethodObject()}(S,r),E=new f(t.source,h,r._actionName,r._conversationId,r._correlationId,y),R=new p(P,r._data,E,S._eventHandlerProxyList,r._conversationId,r._actionName),T=!0;null==a&&((null==o||(new Date).getTime()-o>10)&&!s?(m(R),T=!1):a=setInterval(g,10)),T&&function(e){n.push(e)}(R)}catch(n){S&&S._onHandleRequestError&&S._onHandleRequestError(r,n);var w=-2;"Access Denied"==n&&(w=-5);var x=new c(r._actionName,r._conversationId,r._correlationId,w,0,n),N=u.envelope(x),D=!1;try{D=!(!t.source||!t.source.postMessage)}catch(e){}var k=!1;if(window.location.href&&t.origin&&"null"!==t.origin&&b(window.location.href,t.origin))k=!0;else if(t.origin&&"null"!==t.origin)k=_(e.OUtil.parseUrl(t.origin,!0).hostname);D&&k&&t.source.postMessage(N,h)}}else{if(1!==r._messageType)return;var F=function(t){var n=d[t];return n||e.Utility.xdmDebugLog("Unknown conversation Id."),n}(r._conversationId);if(!F)return;if(e.Utility.xdmDebugLog("_receive: response, origin="+t.origin+" targetURL:"+F._targetUrl),H=F._targetUrl,U=t.origin,!(H&&U&&"null"!==H&&"null"!==U&&H.length&&U.length&&O(e.OUtil.parseUrl(H,!0),e.OUtil.parseUrl(U,!0))))throw"Failed orgin check";if(3==F._hostTrustCheckStatus&&(F._fHostTrusted=!0),0===r._responseType){var j=F._callbackList[r._correlationId];if(j)try{j.callback&&j.callback(r._errorCode,r._data)}finally{delete F._callbackList[r._correlationId]}}else{var M=F._eventHandlerList[r._actionName];null!=M&&M(r._data)}}}var H,U}function C(){h||(!function(t){if(window.addEventListener)window.addEventListener("message",t,!1);else{if(!(navigator.userAgent.indexOf("MSIE")>-1&&window.attachEvent))throw e.Utility.xdmDebugLog("Browser doesn't support the required API."),e.Utility.createArgumentException("Browser");window.attachEvent("onmessage",t)}}(S),h=!0)}t.connect=function(e,t,n){var r=d[e];return r||(C(),r=new i(e,t,n),d[e]=r),r},t.getClientEndPoint=function(e){return d[e]},t.createServiceEndPoint=function(e){C();var t=new r(e);return l[e]=t,t},t.getServiceEndPoint=function(e){return l[e]},t.deleteClientEndPoint=function(e){delete d[e]},t.deleteServiceEndPoint=function(e){delete l[e]},t.checkUrlWithAppDomains=function(e,t){return v(e,t)},t.isTargetSubdomainOfSourceLocation=function(e,t){return b(e,t)},t._setMethodTimeout=function(e){e<=0?65e3:e},t._startMethodTimeoutTimer=function(){},t.isHostNameValidWacDomain=function(e){return _(e)}}(o=e.XdmCommunicationManager||(e.XdmCommunicationManager={}));var a=function(){function e(e,t,n,r,o){this._messageType=e,this._actionName=t,this._conversationId=n,this._correlationId=r,this._origin=window.location.origin,this._data=void 0===o?null:o}return e.prototype.getActionName=function(){return this._actionName},e.prototype.getConversationId=function(){return this._conversationId},e.prototype.getCorrelationId=function(){return this._correlationId},e.prototype.getOrigin=function(){return this._origin},e.prototype.getData=function(){return this._data},e.prototype.getMessageType=function(){return this._messageType},e}(),s=function(e){function t(t,n,r,o,i){var a=e.call(this,0,t,r,o,i)||this;return a._actionType=n,a}return __extends(t,e),t.prototype.getActionType=function(){return this._actionType},t}(a),c=function(e){function t(t,n,r,o,i,a){var s=e.call(this,1,t,n,r,a)||this;return s._errorCode=o,s._responseType=i,s}return __extends(t,e),t.prototype.getErrorCode=function(){return this._errorCode},t.prototype.getResponseType=function(){return this._responseType},t}(a),u=function(){function e(){}return e.envelope=function(e){return JSON.stringify(e)},e.unenvelope=function(e){return JSON.parse(e)},e}(),l=function(){function t(t,n,r,o,i,a){var s=this;this._invokeResultCode=0,this._requesterWindow=t,this._requesterUrl=n,this._actionName=r,this._conversationId=o,this._correlationId=i,this._invokeResultCode=0,this._responseType=a,this._send=function(t){try{var n=new c(s._actionName,s._conversationId,s._correlationId,s._invokeResultCode,s._responseType,t),r=u.envelope(n);s._requesterWindow.postMessage(r,s._requesterUrl),e.Utility.xdmDebugLog("_send: requestUrl="+s._requesterUrl+" _actionName:"+s._actionName)}catch(t){e.Utility.xdmDebugLog("ResponseSender._send error:"+t.message)}}}return t.prototype.getRequesterWindow=function(){return this._requesterWindow},t.prototype.getRequesterUrl=function(){return this._requesterUrl},t.prototype.getActionName=function(){return this._actionName},t.prototype.getConversationId=function(){return this._conversationId},t.prototype.getCorrelationId=function(){return this._correlationId},t.prototype.getSend=function(){return this._send},t.prototype.setResultCode=function(e){this._invokeResultCode=e},t}(),f=function(t){function n(n,r,o,i,a,s){var l=t.call(this,n,r,o,i,a,0)||this;return l._postCallbackHandler=s,l._send=function(t,n){null!=n&&(l._invokeResultCode=n);try{var r=new c(l._actionName,l._conversationId,l._correlationId,l._invokeResultCode,l._responseType,t),o=u.envelope(r);l._requesterWindow.postMessage(o,l._requesterUrl),l._postCallbackHandler()}catch(t){e.Utility.xdmDebugLog("InvokeCompleteCallback._send error:"+t.message)}},l}return __extends(n,t),n}(l),p=function(){function e(e,t,n,r,o,i){this._callerId="",this._methodObject=e,this._param=t,this._invokeCompleteCallback=n,this._eventHandlerProxyList=r,this._conversationId=o,this._eventName=i}return e.prototype.invoke=function(){try{var e;switch(this._methodObject.getInvokeType()){case 0:this._methodObject.getMethod()(this._param,this._invokeCompleteCallback.getSend());break;case 1:e=this._methodObject.getMethod()(this._param),this._invokeCompleteCallback.getSend()(e);break;case 4:var t=this._createEventHandlerProxyObject(this._invokeCompleteCallback);e=this._methodObject.getMethod()(t.getSend(),this._param),this._eventHandlerProxyList[this._conversationId+this._eventName]=t.getSend(),this._invokeCompleteCallback.getSend()(e);break;case 5:var n=this._eventHandlerProxyList[this._conversationId+this._eventName];e=this._methodObject.getMethod()(n,this._param),delete this._eventHandlerProxyList[this._conversationId+this._eventName],this._invokeCompleteCallback.getSend()(e);break;case 2:var r=this._createEventHandlerProxyObject(this._invokeCompleteCallback);this._methodObject.getMethod()(r.getSend(),this._invokeCompleteCallback.getSend(),this._param),this._eventHandlerProxyList[this._callerId+this._eventName]=r.getSend();break;case 3:var o=this._eventHandlerProxyList[this._callerId+this._eventName];this._methodObject.getMethod()(o,this._invokeCompleteCallback.getSend(),this._param),delete this._eventHandlerProxyList[this._callerId+this._eventName]}}catch(e){this._invokeCompleteCallback.setResultCode(-3),this._invokeCompleteCallback.getSend()(e)}},e.prototype.getInvokeBlockingFlag=function(){return this._methodObject.getBlockingFlag()},e.prototype._createEventHandlerProxyObject=function(e){return new l(e.getRequesterWindow(),e.getRequesterUrl(),e.getActionName(),e.getConversationId(),e.getCorrelationId(),1)},e}()}(OSF||(OSF={})),function(e){function t(e,t){return t+="_Resource",void 0!==oteljs?[oteljs.makeDoubleDataField(t+"_responseEnd",e.responseEnd),oteljs.makeDoubleDataField(t+"_responseStart",e.responseStart),oteljs.makeDoubleDataField(t+"_startTime",e.startTime),oteljs.makeDoubleDataField(t+"_transferSize",e.transferSize)]:[]}e.sendPerformanceTelemetry=function(){if(OSF.AppTelemetry.enableTelemetry&&"undefined"!=typeof performance&&performance.getEntriesByType){var e,n,r=OSF.LoadScriptHelper.getHostBundleJsName().toLowerCase();performance.getEntriesByType("resource").forEach((function(t){var o=t.name.toLowerCase();OSF.Utility.stringEndsWith(o,r)?e=t:(OSF.Utility.stringEndsWith(o,OSF.ConstantNames.OfficeDebugJS)||OSF.Utility.stringEndsWith(o,OSF.ConstantNames.OfficeJS))&&(n=t)})),OTel.OTelLogger.onTelemetryLoaded((function(){var r=[];e&&(r=r.concat(t(e,"HostJs"))),n&&(r=r.concat(t(n,"OfficeJs"))),r=r.concat([oteljs.makeDoubleDataField("officeExecuteStartDate",OSFPerformance.officeExecuteStartDate),oteljs.makeDoubleDataField("officeExecuteStart",OSFPerformance.officeExecuteStart),oteljs.makeDoubleDataField("officeExecuteEnd",OSFPerformance.officeExecuteEnd),oteljs.makeDoubleDataField("hostInitializationStart",OSFPerformance.hostInitializationStart),oteljs.makeDoubleDataField("hostInitializationEnd",OSFPerformance.hostInitializationEnd),oteljs.makeDoubleDataField("totalJSHeapSize",OSFPerformance.totalJSHeapSize),oteljs.makeDoubleDataField("usedJSHeapSize",OSFPerformance.usedJSHeapSize),oteljs.makeDoubleDataField("jsHeapSizeLimit",OSFPerformance.jsHeapSizeLimit),oteljs.makeDoubleDataField("getAppContextStart",OSFPerformance.getAppContextStart),oteljs.makeDoubleDataField("getAppContextEnd",OSFPerformance.getAppContextEnd),oteljs.makeDoubleDataField("getAppContextXdmStart",OSFPerformance.getAppContextXdmStart),oteljs.makeDoubleDataField("getAppContextXdmEnd",OSFPerformance.getAppContextXdmEnd),oteljs.makeDoubleDataField("createOMEnd",OSFPerformance.createOMEnd),oteljs.makeDoubleDataField("officeOnReady",OSFPerformance.officeOnReady),oteljs.makeBooleanDataField("isSharedRuntime",0!=(OSF._OfficeAppFactory.getHostInfo().flags&OSF.HostInfoFlags.SharedApp)),oteljs.makeBooleanDataField("isExperimentJsEnabled",0!=(OSF._OfficeAppFactory.getHostInfo().flags&OSF.HostInfoFlags.ExperimentJsEnabled))]),Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.JSPerformanceTelemetryV06",dataFields:r,eventFlags:{dataCategories:2,diagnosticLevel:110}})}))}}}(OSFPerfUtil||(OSFPerfUtil={})),function(e){!function(t){var n,r,o={};function i(e,t,n,r){if(e&&t){var i=window.document,a=o[e];if(a)a.loaded?t(!0):a.pendingCallbacks.push(t);else{var s=i.createElement("script");s.type="text/javascript",a={loaded:!1,pendingCallbacks:[t],timer:null},o[e]=a;var c=function(){null!=a.timer&&(clearTimeout(a.timer),delete a.timer),a.loaded=!0;for(var e=a.pendingCallbacks.length,t=0;t<e;t++){a.pendingCallbacks.shift()(!0)}},u=function(){delete o[e],null!=a.timer&&(clearTimeout(a.timer),delete a.timer);for(var t=a.pendingCallbacks.length,n=0;n<t;n++){a.pendingCallbacks.shift()(!1)}};s.readyState?s.onreadystatechange=function(){"loaded"!=s.readyState&&"complete"!=s.readyState||(s.onreadystatechange=null,c())}:s.onload=c,s.onerror=u,r=r||3e4,a.timer=setTimeout(u,r),s.setAttribute("crossOrigin","anonymous"),s.src=n?n.createScriptURL(e):e,i.getElementsByTagName("head")[0].appendChild(s)}}}!function(e){var t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];e.generateNewGuid=function(){for(var e="",n=(new Date).getTime(),r=0;r<32&&n>0;r++)8!=r&&12!=r&&16!=r&&20!=r||(e+="-"),e+=t[n%16],n=Math.floor(n/16);for(;r<32;r++)8!=r&&12!=r&&16!=r&&20!=r||(e+="-"),e+=t[Math.floor(16*Math.random())];return e}}(t.Guid||(t.Guid={})),t.loadScriptPromise=function(e,t,n){return new Promise((function(r,o){i(e,(function(e){r(e)}),t,n)}))},t.loadScript=i,t.getSessionStorage=function(){if(!n){try{var t=window.sessionStorage}catch(e){t=null}n=new e.SafeStorage(t)}return n},t.getLocalStorage=function(){if(!r){try{var t=window.localStorage}catch(e){t=null}r=new e.SafeStorage(t)}return r},t.waitForFunction=function(e,t,n,r){var o,i=n,a=function(){i--,e()?t(!0):i>0?(o=window.setTimeout(a,r),i--):(window.clearTimeout(o),t(!1))};a()}}(e.OUtil||(e.OUtil={}))}(OSF||(OSF={})),function(e){e.Flights=[],e.DisabledChangeGates=[];e.FlightTreatmentNames={EnableMsal3SsoApi:"Microsoft.Office.SharedOnline.EnableMsal3SsoApi"},function(t){var n="&_flights=",r="&_disabledChangeGates=",o="_flights=",i="_disabledChangeGates=";function a(e,t){return e.substr(0,t.length)===t}function s(e,t,n,r){return a(e,t+"//"+n+":"+r)||a(e,n+":"+r)}t.isArray=function(e){return"[object Array]"===Object.prototype.toString.apply(e)},t.isFunction=function(e){return"[object Function]"===Object.prototype.toString.apply(e)},t.isDate=function(e){return"[object Date]"===Object.prototype.toString.apply(e)},t.addEventListener=function(e,t,n){if(e.addEventListener)e.addEventListener(t,n,!1);else{if(!e.attachEvent)throw new Error("Cannot attach event");e.attachEvent("on"+t,n)}},t.removeEventListener=function(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n,!1);else{if(!e.detachEvent)throw new Error("Cannot remove event");e.detachEvent("on"+t,n)}};var c="Date(";function u(e){var t=[];try{t=JSON.parse(e)}catch(e){}return Array.isArray(t)||(t=[]),t}function l(e,n,r){try{var o=JSON.parse(n),i=null!=o?o[r]:null,a=t.getSessionStorage();if(!e&&a&&null!=o){var s=o.baseFrameName+r;i?a.setItem(s,i):i=a.getItem(s)}return i}catch(e){return null}}function f(e,n,r,o,i){var a=i.split(e),s=a.length>1?a[a.length-1]:null;r&&null!=s&&(s.indexOf("&")>=0&&(s=s.split("&")[0]),s=decodeURIComponent(s));var c=t.getSessionStorage();if(!o&&c){var u=window.name.indexOf(n);if(u>-1){var l=window.name.indexOf(";",u);-1==l&&(l=window.name.length);var f=window.name.substring(u,l);s?c.setItem(f,s):s=c.getItem(f)}}return s}function p(e,t){for(var n=0;n<e.length;n++)if(e.charAt(n)===t){if(n+1>=e.length)return this.removeChar(e,n);if("/"===t){if("?"===e.charAt(n+1)||"#"===e.charAt(n+1))return this.removeChar(e,n)}else if("?"===t&&"#"===e.charAt(n+1))return this.removeChar(e,n)}return e}function d(e){if(e=p(e,"/"),e=p(e,"?"),"https://"==(e=p(e,"#")).substr(0,8))-1!=(t=e.indexOf(":443"))&&(t!=e.length-4&&"/"!=e.charAt(t+4)&&"?"!=e.charAt(t+4)&&"#"!=e.charAt(t+4)||(e=e.substring(0,t)+e.substring(t+4)));else if("http://"==e.substr(0,7)){var t;-1!=(t=e.indexOf(":80"))&&(t!=e.length-3&&"/"!=e.charAt(t+3)&&"?"!=e.charAt(t+3)&&"#"!=e.charAt(t+3)||(e=e.substring(0,t)+e.substring(t+3)))}return e}function h(e){var t,n,r=[],o=[],i=e.length;for(t=0;t<i;t++)(n=e[t]).tabIndex?n.tabIndex>0?o.push(n):0===n.tabIndex&&r.push(n):r.push(n);return o=o.sort((function(e,t){var n=e.tabIndex-t.tabIndex;return 0===n&&(n=o.indexOf(e)-o.indexOf(t)),n})),[].concat(o,r)}t.serializeSettings=function(t){var n={};for(var r in t){var o=t[r];try{o=JSON.stringify(o,(function(t,n){return e.OUtil.isDate(this[t])?c+this[t].getTime()+")":n})),n[r]=o}catch(e){}}return n},t.deserializeSettings=function(e){var t={};for(var n in e=e||{}){var r=e[n];try{r=JSON.parse(r,(function(e,t){var n;return"string"==typeof t&&t&&t.length>6&&t.slice(0,5)===c&&")"===t.slice(-1)&&(n=new Date(parseInt(t.slice(5,-1))))?n:t})),t[n]=r}catch(e){}}return t},t.convertIntToCssHexColor=function(e){return"#"+(Number(e)+16777216).toString(16).slice(-6)},t.parseAppContextFromWindowName=function(e,n){return t.parseInfoFromWindowName(e,n,"appContext")},t.parseHostInfoFromWindowName=function(t,n){return e.OUtil.parseInfoFromWindowName(t,n,"hostInfo")},t.parseXdmInfo=function(e){var n=t.parseXdmInfoWithGivenFragment(e,window.location.hash);return n||(n=t.parseXdmInfoFromWindowName(e,window.name)),n},t.parseXdmInfoFromWindowName=function(t,n){return e.OUtil.parseInfoFromWindowName(t,n,"xdmInfo")},t.parseXdmInfoWithGivenFragment=function(t,n){return e.OUtil.parseInfoWithGivenFragment("&_xdm_Info=","_xdm_",!1,t,n)},t.parseFlights=function(e){var t=function(e,t){return u(f(n,o,!0,e,t))}(e,window.location.hash);return 0==t.length&&(t=function(e,t){return u(l(e,t,"flights"))}(e,window.name)),t},t.parseDisabledChangeGates=function(e){var t=function(e,t){return u(f(r,i,!0,e,t))}(e,window.location.hash);return 0==t.length&&(t=function(e,t){return u(l(e,t,"disabledChangeGates"))}(e,window.name)),t},t.checkFlight=function(t){return e.Flights&&e.Flights.indexOf(t)>=0},t.isChangeGateEnabled=function(t){return!e.DisabledChangeGates||-1===e.DisabledChangeGates.indexOf(t)},t.parseInfoFromWindowName=l,t.parseInfoWithGivenFragment=f,t.getConversationId=function(){var e=window.location.search,t=null;if(e){var n=e.indexOf("&");(t=n>0?e.substring(1,n):e.substr(1))&&"="===t.charAt(t.length-1)&&(t=t.substring(0,t.length-1))&&(t=decodeURIComponent(t))}return t},t.getInfoItems=function(e){var t=e.split("$");return void 0===t[1]&&(t=e.split("|")),void 0===t[1]&&(t=e.split("%7C")),t},t.getXdmFieldValue=function(t,n){var r="",o=e.OUtil.parseXdmInfo(n);if(o){var i=e.OUtil.getInfoItems(o);if(null!=i&&i.length>=3)switch(t){case"ConversationUrl":r=i[2];break;case"AppId":r=i[1]}}return r},t.parseUrl=function(t,n){if(void 0===n&&(n=!1),void 0!==t&&t){var r="NotHttps",o="undefined"!=typeof window&&void 0!==window.navigator&&window.navigator.userAgent.indexOf("Trident")>0,i=("undefined"!=typeof window&&void 0!==window.navigator&&window.navigator.userAgent.indexOf("Edge"),{protocol:void 0,hostname:void 0,host:void 0,port:void 0,pathname:void 0,search:void 0,hash:void 0,isPortPartOfUrl:void 0});try{if(o){var a=document.createElement("a");if(a.href=t,!(a&&a.protocol&&a.host&&a.hostname&&a.href&&d(a.href).toLowerCase()===d(t).toLowerCase()))throw"InvalidUrl";if(e.OUtil.checkFlight(2)&&n&&"https:"!=a.protocol)throw new Error(r);var c=function(e,t){return e&&t?"https:"==t.protocol&&s(e,"https:",t.hostname,"443")?":443":"http:"==t.protocol&&s(e,"http:",t.hostname,"80")?":80":"":""}(t,a);i.protocol=a.protocol,i.hostname=a.hostname,i.port=""==c?a.port:"",i.host=""!=c?a.hostname:a.host,i.pathname=(o?"/":"")+a.pathname,i.search=a.search,i.hash=a.hash,i.isPortPartOfUrl=s(t,a.protocol,a.hostname,a.port)}else{var u=new URL(t);if(u&&u.protocol&&u.host&&u.hostname){if(e.OUtil.checkFlight(2)&&n&&"https:"!=u.protocol)throw new Error(r);i.protocol=u.protocol,i.hostname=u.hostname,i.port=u.port,i.host=u.host,i.pathname=u.pathname,i.search=u.search,i.hash=u.hash,i.isPortPartOfUrl=u.host.lastIndexOf(":"+u.port)==u.host.length-u.port.length-1}}}catch(e){if(e.message===r)throw e}return i}},t.focusToFirstTabbable=function(e,t){var n,r,o=!1,i=function(e){o=!0},a=function(e,t,n){return t<0||t>e||0===t&&n?-1:t!==e-1||n?n?t-1:t+1:-1};if(e=h(e),n=t?e.length-1:0,0===e.length)return null;for(;!o&&n>=0&&n<e.length;)r=e[n],window.focus(),r.addEventListener("focus",i),r.focus(),r.removeEventListener("focus",i),n=a(e.length,n,t),o||r!==document.activeElement||(o=!0);return o?r:null},t.focusToNextTabbable=function(e,t,n){var r,o,i,a=!1,s=function(e){a=!0},c=function(e,t,n){return t<0||t>e||0===t&&n?-1:t!==e-1||n?n?t-1:t+1:-1};if(r=function(e,t){for(var n=0;n<e.length;n++)if(e[n]===t)return n;return-1}(e=h(e),t),(o=c(e.length,r,n))<0)return null;for(;!a&&o>=0&&o<e.length;)(i=e[o]).addEventListener("focus",s),i.focus(),i.removeEventListener("focus",s),o=c(e.length,o,n),a||i!==document.activeElement||(a=!0);return a?i:null},t.defineMethodOnNamespace=function(e,t,n){e[t]=n},t.isDialog=function(){return e._OfficeAppFactory.getHostInfo().isDialog},t.isPopupWindow=function(){return e.OUtil.isDialog()&&e._OfficeAppFactory.getHostInfo().hostPlatform==e.HostInfoPlatform.web&&null!=window.opener},t.getHostPlatform=function(){return e._OfficeAppFactory.getHostInfo().hostPlatform},t.getCustomOfficeInitializationSettings=function(){return"object"==typeof officeInitializationSettings?officeInitializationSettings:{}};var g=0;t.getLibraryReleaseVehicle=function(){return g},t.setLibraryReleaseVehicle=function(e){g=e}}(e.OUtil||(e.OUtil={}))}(OSF||(OSF={})),function(e){!function(e){e.Callback="callback",e.AsyncContext="asyncContext",e.Data="data",e.MessageToParent="messageToParent",e.MessageContent="messageContent",e.MessageOrigin="messageOrigin",e.TargetOrigin="targetOrigin",e.AppCommandInvocationCompletedData="appCommandInvocationCompletedData"}(e.ParameterNames||(e.ParameterNames={}))}(OSF||(OSF={})),function(e){!function(t){var n=function(){};t.RequirementVersion=n;var r=function(){function e(e){this._setMap=e}return e.prototype.isSetSupported=function(e,t){if(null==e)return!1;null==t&&(t=0);var n=this._setMap._sets;if(n.hasOwnProperty(e.toLowerCase())){var r=n[e.toLowerCase()];try{var o=this._getVersion(r+"");t+="";var i=this._getVersion(t);if(o.major>0&&o.major>i.major)return!0;if(o.major>0&&o.minor>=0&&o.major==i.major&&o.minor>=i.minor)return!0}catch(e){return!1}}return!1},e.prototype._getVersion=function(e){var t=(e+="").split("."),n=0,r=0;if(t.length<2&&isNaN(Number(e)))throw"version format incorrect";if(n=Number(t[0]),t.length>=2&&(r=Number(t[1])),isNaN(n)||isNaN(r))throw"version format incorrect";return{minor:r,major:n}},e}();t.RequirementMatrix=r;var o=function(){function e(e){this._sets=e}return e.prototype._addSetMap=function(e){for(var t in e)this._sets[t]=e[t]},e}();t.DefaultSetRequirement=o;var i=function(e){function t(){return e.call(this,{dialogapi:1.1})||this}return __extends(t,e),t}(o);t.DefaultRequiredDialogSetRequirement=i;var a=function(e){function t(){return e.call(this,{dialogorigin:1.1})||this}return __extends(t,e),t}(o);t.DefaultOptionalDialogSetRequirement=a;var s=function(){function t(){}return t.getDefaultRequirementMatrix=function(t){var n=void 0,i=t.get_requirementMatrix();if(null!=i&&i.length>0){var a=JSON.parse(t.get_requirementMatrix().toLowerCase());if(e._OfficeAppFactory.getHostInfo().hostPlatform==e.HostInfoPlatform.web)try{var s="dialogorigin";a.hasOwnProperty(s)||(a[s]=1.1)}catch(e){}n=new r(new o(a))}else n=new r(new o({}));return n},t.getDefaultDialogRequirementMatrix=function(t){var n=void 0,s=t.get_dialogRequirementMatrix();if(null!=s&&s.length>0){var c=JSON.parse(t.get_requirementMatrix().toLowerCase());n=new o(c)}else{n=new i;var u=t.get_requirementMatrix();if(null!=u&&u.length>0&&"undefined"!=typeof JSON){c=JSON.parse(u.toLowerCase());for(var l in n._sets)c.hasOwnProperty(l)&&(n._sets[l]=c[l]);var f=new a;for(var l in f._sets)c.hasOwnProperty(l)&&(n._sets[l]=c[l])}}if(e._OfficeAppFactory.getHostInfo().hostPlatform==e.HostInfoPlatform.web)try{var p="dialogorigin";!n._sets.hasOwnProperty(p)&&window.opener&&(n._sets[p]=1.1)}catch(e){}return new r(n)},t}();t.RequirementsMatrixFactory=s}(e.Requirement||(e.Requirement={}))}(OSF||(OSF={})),function(e){!function(t){!function(t){var n;t.executeRichApiRequestAsync=function(t,n){var r={toSafeArrayHost:function(){return[t]},fromSafeArrayHost:function(e){return{data:e}},toWebHost:function(){return{ArrayData:t}},fromWebHost:function(e){return{data:e.Data}}};e._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(93,r,n)},Object.defineProperty(t,"richApiMessageManager",{get:function(){return n||(n=new e.RichApiMessageManager),n}})}(t.RichApi||(t.RichApi={}))}(e.DDA||(e.DDA={}))}(OSF||(OSF={})),function(e){var t=function(){function t(){this._registerHandlers=[],this._eventDispatch=new e.EventDispatch([{type:e.EventType.RichApiMessage,id:e.EventDispId.dispidRichApiMessageEvent,getTargetId:function(){return""},fromSafeArrayHost:function(e){var n=e;return t.transferEventArgument(n)},fromWebHost:function(e){var n=e.ArrayData;return t.transferEventArgument(n)}}])}return t.transferEventArgument=function(t){var n=[];if(t)for(var r=0;r<t.length;r++){var o=t[r];o.toArray&&(o=o.toArray()),n.push({messageCategory:o[0],messageType:o[1],targetId:o[2],message:o[3],id:o[4],isRemoteOverride:o[5]})}return{type:e.EventType.RichApiMessage,entries:n}},t.prototype.addHandlerAsync=function(t,n,r){e.EventHelper.addEventHandler(t,n,r,this._eventDispatch)},t.prototype.removeHandlerAsync=function(t,n,r){e.EventHelper.removeEventHandler(t,n,r,this._eventDispatch)},t.prototype.register=function(t){var n=this;return this._registerPromise||(this._registerPromise=new Office.Promise((function(t,r){n.addHandlerAsync(e.EventType.RichApiMessage,(function(e){n._registerHandlers.forEach((function(t){t&&t(e)}))}),(function(e){"failed"==e.status?r(e.error):t()}))}))),this._registerPromise.then((function(){n._registerHandlers.push(t)}))},t}();e.RichApiMessageManager=t}(OSF||(OSF={})),function(e){var t=function(){function t(){}return t.prototype.execute=function(e,t,n){"undefined"!=typeof OsfOMToken&&OsfOMToken?window.external.Execute(e,t,n,OsfOMToken):window.external.Execute(e,t,n)},t.prototype.registerEvent=function(e,t,n,r,o){"undefined"!=typeof OsfOMToken&&OsfOMToken?window.external.RegisterEvent(e,n,r,o,OsfOMToken):window.external.RegisterEvent(e,n,r,o)},t.prototype.unregisterEvent=function(e,t,n,r){"undefined"!=typeof OsfOMToken&&OsfOMToken?window.external.UnregisterEvent(e,n,r,OsfOMToken):window.external.UnregisterEvent(e,n,r)},t.prototype.closeSdxDialog=function(t){throw e.Utility.createNotImplementedException()},t.prototype.resizeSdxDialog=function(t,n){throw e.Utility.createNotImplementedException()},t}();e.RichClientHostController=t}(OSF||(OSF={})),function(e){var t=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.officeThemeTimeStamp=null,e.officeTheme=null,e}return __extends(n,t),n.prototype.getOsfControlContext=function(){if(!this._osfControlContext){var t="Warning: Office.js is loaded outside of Office client";try{if(!window.external)return console.error("There is no window.external."),e.Utility.trace(t),null;this._osfControlContext=window.external.GetContext()}catch(n){return console.error("Error when call window.external.GetContext() :"+JSON.stringify(n)),e.Utility.trace(t),null}}return this._osfControlContext},n.prototype.getAppContext=function(t,n,r){var o=this,i=this.getOsfControlContext();if(i){var a,s,c,u,l,f,p,d,h,g,m,y,v,_,b,O,S,C,I,A,P,E,R,T,w,x,N=0,D=!1;if((k=e.Utility.externalNativeFunctionExists)(typeof i.GetContextDataInJson))if("undefined"!=typeof OsfOMToken&&OsfOMToken)if((w=i.GetContextDataInJson(OsfOMToken))&&(x=JSON.parse(w)),x)a=x.appType,s=x.solutionRef,c=x.versionMajor,u=x.versionMinor,l=x.uiLocale,f=x.dataLocale,p=x.docUrl,d=x.clientMode,h=x.activationMode,m=x.controlType,y=x.eToken,v=x.correlationId,_=x.appInstanceId,b=x.touchEnabled,O=i.commerceAllowed,S=x.requirementMatrix,I=x.hostFullVersion,A=x.requirementMatrix,(F=x.featureGates)&&(P=JSON.parse(F)),N=x.initialDisplayMode,E=function(){var t={};if(x.settings)try{var n=JSON.parse(x.settings);if(n)for(var r=[n.names,n.values],o=r[0],i=r[1],a=0;a<o.length;a++)t[o[a]]=i[a]}catch(t){e.Utility.trace("Exception while parsing settings. Details: "+t)}return t},R=function(){var e=x.themeInfo;return o.getOfficeThemeFromInfoString(e)};else D=!0;else D=!0;else D=!0;if(D){a=i.GetAppType(),s=i.GetSolutionRef(),c=i.GetAppVersionMajor(),u=i.GetAppVersionMinor(),l=i.GetAppUILocale(),f=i.GetAppDataLocale(),p=i.GetDocUrl(),d=i.GetAppCapabilities(),h=i.GetActivationMode(),m=i.GetControlIntegrationLevel();try{y=i.GetSolutionToken()}catch(e){}var k;if((k=e.Utility.externalNativeFunctionExists)(typeof i.GetCorrelationId)&&(v=i.GetCorrelationId()),k(typeof i.GetInstanceId)&&(_=i.GetInstanceId()),k(typeof i.GetTouchEnabled)&&(b=i.GetTouchEnabled()),k(typeof i.GetCommerceAllowed)&&(O=i.GetCommerceAllowed()),k(typeof i.GetSupportedMatrix)&&(S=i.GetSupportedMatrix()),k(typeof i.GetHostCustomMessage)&&(C=i.GetHostCustomMessage()),k(typeof i.GetHostFullVersion)&&(I=i.GetHostFullVersion()),k(typeof i.GetDialogRequirementMatrix)&&(A=i.GetDialogRequirementMatrix()),k(typeof i.GetFeaturesForSolution))try{var F;(F=i.GetFeaturesForSolution())&&(P=JSON.parse(F))}catch(t){e.Utility.trace("Exception while creating the SDX FeatureGates object. Details: "+t)}k(typeof i.GetInitialDisplayMode)&&(N=i.GetInitialDisplayMode()),E=function(){return o.getSerializedSettings()},R=function(){return o.getOfficeTheme()},T=function(){return o.getSerializedHostSettings()}}g=2===h?Office.InitializationReason.DocumentOpened:Office.InitializationReason.Inserted,y=y?y.toString():"",n(new e.OfficeAppContext(s,a,c,l,f,p,d,E,g,m,y,v,_,b,O,u,S,C,I,void 0,void 0,void 0,void 0,A,P,R,N,void 0,void 0,T,!1,void 0,void 0,void 0))}else r(new Error("The Office.js is loaded outside of Office client"))},n.prototype.createClientHostController=function(){if(!this._clientHostController){if(this._hostInfo.hostPlatform!==e.HostInfoPlatform.win32)throw e.Utility.createNotImplementedException();this._clientHostController=new e.Win32RichClientHostController}return this._clientHostController},n.prototype.createAsyncMethodExecutor=function(){return new e.SafeArrayAsyncMethodExecutor(this._clientHostController)},n.prototype.createClientSettingsManager=function(){return new e.RichClientSettingsManager(this.getOsfControlContext())},n.prototype.getSerializedSettings=function(){var e=this.getOsfControlContext(),t=[],n=[];"undefined"!=typeof OsfOMToken&&OsfOMToken?e.GetSettings(OsfOMToken).Read(t,n):e.GetSettings().Read(t,n);for(var r={},o=0;o<t.length;o++)r[t[o]]=n[o];return r},n.prototype.getOfficeTheme=function(){var e=this.getOsfControlContext();if(e){if(!(this.officeTheme&&this.officeThemeTimeStamp&&(new Date).getTime()-this.officeThemeTimeStamp<n.officeThemeCacheValidPeriod)){var t=e.GetOfficeThemeInfo();this.officeTheme=this.getOfficeThemeFromInfoString(t),this.officeThemeTimeStamp=(new Date).getTime()}return this.officeTheme}},n.prototype.getOfficeThemeFromInfoString=function(t){var n=null;if(t)try{n=JSON.parse(t)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception while parsing officeThemeInfo. Details: "+t)}var r={};if(n){var o={bodyBackgroundColor:{name:"bodyBackgroundColor",convertToHex:!0},bodyForegroundColor:{name:"bodyForegroundColor",convertToHex:!0},controlBackgroundColor:{name:"controlBackgroundColor",convertToHex:!0},controlForegroundColor:{name:"controlForegroundColor",convertToHex:!0},primaryFontColor:{name:"bodyForegroundColor",convertToHex:!0},primaryBackgroundColor:{name:"bodyBackgroundColor",convertToHex:!0},secondaryFontColor:{name:"controlForegroundColor",convertToHex:!0},secondaryBackgroundColor:{name:"controlBackgroundColor",convertToHex:!0},fluentThemeData:{name:"fluentThemeData",convertToHex:!1}};for(var i in n){var a=!1,s=i;o[i]&&(s=o[i].name,a=o[i].convertToHex),r[s]=a?e.OUtil.convertIntToCssHexColor(n[i]):n[i]}}return r},n.prototype.getSerializedHostSettings=function(){var e=this.getOsfControlContext(),t=[],n=[];"function"==typeof e.GetSettings().ReadHost&&("undefined"!=typeof OsfOMToken&&OsfOMToken?e.GetSettings(OsfOMToken).ReadHost(t,n):e.GetSettings().ReadHost(t,n));for(var r={},o=0;o<t.length;o++)r[t[o]]=n[o];return r},n.officeThemeCacheValidPeriod=5e3,n}(e.InitializationHelper);e.RichClientInitializationHelper=t}(OSF||(OSF={})),function(e){var t=function(){function e(e){this._osfClientContext=e}return e.prototype.read=function(e){var t,n=this._osfClientContext;t="undefined"!=typeof OsfOMToken&&OsfOMToken?n.GetSettings(OsfOMToken):n.GetSettings();var r=function(){var n=[],r=[];t.Read(n,r);for(var o={},i=0;i<n.length;i++)o[n[i]]=r[i];e&&e(0,o)};t.RefreshAsync?t.RefreshAsync((function(){r()})):r()},e.prototype.write=function(e,t){var n=[],r=[];for(var o in e)n.push(o),r.push(e[o]);var i,a=this._osfClientContext;void 0!==(i="undefined"!=typeof OsfOMToken&&OsfOMToken?a.GetSettings(OsfOMToken):a.GetSettings()).WriteAsync?i.WriteAsync(n,r,t):(i.Write(n,r),t(0))},e}();e.RichClientSettingsManager=t}(OSF||(OSF={})),function(e){var t=function(t){function n(n){var r=t.call(this)||this;return r._clientHostController=n,r._asyncMethodExecutorHelper=e.BootStrapExtension.createAsyncMethodExecutorHelper(r),r}return __extends(n,t),n.prototype.executeAsync=function(t,n,r,o){var i=this;try{var a=new Array;this._clientHostController.execute(t,n.toSafeArrayHost(),(function(s,c){var u=e.Utility.fromSafeArray(s);return i._asyncMethodExecutorHelper.handleSafeArrayHostResponse(u,c,a,r,n,t,o)}))}catch(e){this.onException(e,t,r)}},n.prototype.registerEventAsync=function(t,n,r,o,i,a,s){var c=this;try{this._clientHostController.registerEvent(t,n,r,(function(t,n){var r=e.Utility.fromSafeArray(n),a=i.fromSafeArrayHost(r);o(a)}),(function(n){var r,o=e.Utility.fromSafeArray(n);return"number"==typeof o?([],r=o):r=o[0],c.invokeCallback(t,a,r,null,s),!0}))}catch(e){this.onException(e,t,a)}},n.prototype.unregisterEventAsync=function(t,n,r,o,i){var a=this;try{this._clientHostController.unregisterEvent(t,n,r,(function(n,r){var s,c=e.Utility.fromSafeArray(n);return"number"==typeof c?([],s=c):s=c[0],a.invokeCallback(t,o,s,null,i),!0}))}catch(e){this.onException(e,t,o)}},n.prototype.onException=function(t,n,r){var o,i=t.number;if(i)switch(i){case-2146828218:o=7e3;break;case-2147467259:o=n==e.EventDispId.dispidDialogMessageReceivedEvent?12007:5001;break;case-2146828283:case-2147209089:o=5010;break;case-2147208704:o=5100;break;case-2146827850:default:o=5001}r&&this.invokeCallback(n,r,o||5001,null)},n}(e.AsyncMethodExecutor);e.SafeArrayAsyncMethodExecutor=t}(OSF||(OSF={})),function(e){var t=function(){function e(e){this._internalStorage=e}return e.prototype.getItem=function(e){try{return this._internalStorage&&this._internalStorage.getItem(e)}catch(e){return null}},e.prototype.setItem=function(e,t){try{this._internalStorage&&this._internalStorage.setItem(e,t)}catch(e){}},e.prototype.clear=function(){try{this._internalStorage&&this._internalStorage.clear()}catch(e){}},e.prototype.removeItem=function(e){try{this._internalStorage&&this._internalStorage.removeItem(e)}catch(e){}},e.prototype.getKeysWithPrefix=function(e){var t=[];try{for(var n=this._internalStorage&&this._internalStorage.length||0,r=0;r<n;r++){var o=this._internalStorage.key(r);0===o.indexOf(e)&&t.push(o)}}catch(e){}return t},e}();e.SafeStorage=t}(OSF||(OSF={})),function(e){var t=function(){function t(e,t){var n=this;this._clientSettingsManager=t,e=e||{},this._settings=e,this._eventDispatch=new OSF.EventDispatch([{id:OSF.EventDispId.dispidSettingsChangedEvent,type:OSF.EventType.SettingsChanged,getTargetId:function(){return""},fromSafeArrayHost:function(e){return{type:OSF.EventType.SettingsChanged,settings:n}},fromWebHost:function(e){return{type:OSF.EventType.SettingsChanged,settings:n}}}])}return t.prototype.cacheSessionSettings=function(e){var t=OSF.OUtil.getSessionStorage();if(t){var n=OSF.OUtil.serializeSettings(e),r=JSON.stringify(n);t.setItem(OSF._OfficeAppFactory.getCachedSessionSettingsKey(),r)}},t.prototype.get=function(e){var t=this._settings[e];return void 0===t?null:t},t.prototype.set=function(e,t){this._settings[e]=t,this.cacheSessionSettings(this._settings)},t.prototype.remove=function(e){delete this._settings[e],this.cacheSessionSettings(this._settings)},t.prototype.saveAsync=function(e){var t=this._clientSettingsManager,n=OSF.OUtil.serializeSettings(this._settings);t.write(n,(function(t){var n=OSF.Utility.asyncResultFromErrorCode(t);e&&e(n)}))},t.prototype.refreshAsync=function(t){var n=this;this._clientSettingsManager.read((function(r,o){var i=OSF.Utility.asyncResultFromErrorCode(r);i.status===e.AsyncResultStatus.Succeeded&&(n._settings=OSF.OUtil.deserializeSettings(o),i.value=n),t&&t(i)}))},t.prototype.addHandlerAsync=function(e,t,n){OSF.EventHelper.addEventHandler(e,t,n,this._eventDispatch)},t.prototype.removeHandlerAsync=function(e,t,n){OSF.EventHelper.removeEventHandler(e,t,n,this._eventDispatch)},t.prototype.toJSON=function(){return this._settings},t}();e.Settings=t}(Office||(Office={}));var OSFWebkit,OTel,Microsoft,__awaiter=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){e.done?o(e.value):new n((function(t){t(e.value)})).then(a,s)}c((r=r.apply(e,t||[])).next())}))},__generator=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}};!function(e){var t=function(){function t(){}return t.isSovereignVersion=function(){return"undefined"!=typeof isOsfSovereignVersion&&!0===isOsfSovereignVersion},t.prototype.getEnvironmentName=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:return[4,this.getConfig()];case 1:return[2,null!=(e=t.sent())&&e.envName?e.envName:null]}}))}))},t.prototype.getEnvironmentType=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:return[4,this.getConfig()];case 1:return[2,null!=(e=t.sent())&&e.envType?e.envType:null]}}))}))},t.prototype.getTrustedHostOrigins=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:return[4,this.getConfig()];case 1:return[2,null!=(e=t.sent())?e.trustedHostOrigins:null]}}))}))},t.prototype.isConfigAvailable=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,this.getConfig()];case 1:return[2,!!e.sent()]}}))}))},t.prototype.isSovereignHostTrusted=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){switch(n.label){case 0:return e?e===window.location.hostname?[2,!0]:[4,this.getTrustedHostOrigins()]:[2,!1];case 1:return(t=n.sent())&&0!=t.length?[2,new RegExp(t.join("|")).test(e)]:[2,!1]}}))}))},t.prototype.getConfigPath=function(){var t=e.LoadScriptHelper.getHostBundleJsBasePath();if(t){var n="/lib/",r=(t=t.toLowerCase()).indexOf(n);if(r>-1)return t.toLowerCase().substring(0,r+n.length)+"officeconfig.json"}return""},t.prototype.getConfig=function(){return this._configPromise||(this._configPromise=this.tryLoadConfig()),this._configPromise},t.prototype.tryLoadConfig=function(){return __awaiter(this,void 0,void 0,(function(){var t,n,r,o,i,a,s;return __generator(this,(function(c){switch(c.label){case 0:if(!(t=this.getConfigPath()))return[3,2];if(n=e.OUtil.getLocalStorage(),r=t+"_cache",o=n.getItem(r),i=null,o){try{i=JSON.parse(o)}catch(e){}if(864e5,a=(new Date).getTime(),i&&i.config&&i.createTime<=a&&i.createTime+864e5>=a)return[2,i.config]}return[4,this.downloadConfig(t)];case 1:return(s=c.sent())?(i={createTime:(new Date).getTime(),config:s},n.setItem(r,JSON.stringify(i))):i&&(s=i.config),[2,s];case 2:return[2,null]}}))}))},t.prototype.downloadConfig=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){switch(t.label){case 0:return t.trys.push([0,3,,4]),[4,fetch(e)];case 1:return[4,t.sent().json()];case 2:return[2,t.sent()];case 3:return t.sent(),[3,4];case 4:return[2,null]}}))}))},t}();e.SovereignHelper=t}(OSF||(OSF={})),function(e){!function(e){function t(e){return void 0===e||null===e}e.createParameterException=function(e){return new Error("Parameter count mismatch: "+e)},e.createArgumentException=function(e){return new Error("Invalid argument "+e)},e.createNotImplementedException=function(){return new Error("Not implemented yet")},e.log=function(e){console.log(e)},e.trace=function(e){console.log(e)},e.debugLog=function(e){console.log(e)},e.getQueryStringValue=function(e){if("undefined"!=typeof window&&window.location&&window.location.search){var t=new RegExp("[?&]"+e+"=([^&]*)").exec(window.location.search);if(t)return t[1]}return null},e.isNullOrUndefined=t,e.isNullOrEmpty=function(e){return!!t(e)||0===e.length},e.isInUnittest=function(){return"boolean"==typeof g_osfUnittest&&g_osfUnittest}}(e.Utility||(e.Utility={}))}(OSF||(OSF={})),function(e){e.isOfficeReactNative=function(){try{return"undefined"!=typeof OfficePlatformGlobal&&void 0!==OfficePlatformGlobal.ReactNativeReka}catch(e){return!1}},function(e){function t(e){return new Promise(e)}function n(e){var t=e,o=1;if(("object"==typeof e||"unknown"==typeof e)&&null!=e&&e.toArray)if(e.dimensions&&(o=e.dimensions()),2===o)t=r(e);else{var i=e.toArray();t=new Array(i.length);for(var a=0;a<i.length;a++)t[a]=n(i[a])}return t}function r(e){var t;try{var n=e.ubound(1),r=e.ubound(2);if(e=e.toArray(),1==n&&1==r)t=[e];else{t=[];for(var o=0;o<n;o++){for(var i=[],a=0;a<r;a++){var s=e[o*r+a];"{66e7831f-81b2-42e2-823c-89e872d541b3}"!=s&&i.push(s)}i.length>0&&t.push(i)}}}catch(e){}return t}e.xdmDebugLog=function(t){e._DebugXdm&&console.log(t)},e.enableDebugXdm=function(){e._DebugXdm=!0},e.createPromiseFromResult=function(e){return Promise.resolve(e)},e.createPromise=t,e.promisify=function(e,n){return t((function(t,r){e((function(e){0===e?t():r()})),setTimeout((function(){r()}),n)}))},e.compareVersions=function(e,t){var n,r=e.split("."),o=t.split(".");for(n in r){if(parseInt(r[n])<parseInt(o[n]))return!1;if(parseInt(r[n])>parseInt(o[n]))return!0}return!1},e.getErrorCodeFromAsyncResult=function(e){return e.status===Office.AsyncResultStatus.Succeeded?0:e.error&&e.error.code?e.error.code:5001},e.externalNativeFunctionExists=function(e){return"unknown"===e||"undefined"!==e},e.stringEndsWith=function(t,n){if(e.isNullOrUndefined(t))throw e.createArgumentException("value");if(e.isNullOrUndefined(n))throw e.createArgumentException("subString");return!(n.length>t.length)&&t.substr(t.length-n.length)===n},e.fromSafeArray=function(e){var t=e;if(("object"==typeof e||"unknown"==typeof e)&&null!=e&&e.toArray){var r=e.toArray();t=new Array(r.length);for(var o=0;o<r.length;o++)t[o]=n(r[o])}return t},e.twoDVBArrayToJaggedArray=r,e.asyncResultFromErrorCode=function(e){return Array.isArray(e)&&1===e.length&&(e=e[0]),0===e?{status:Office.AsyncResultStatus.Succeeded}:{status:Office.AsyncResultStatus.Failed,error:{code:e}}},e._DebugXdm=!1}(e.Utility||(e.Utility={}))}(OSF||(OSF={})),function(e){var t=function(t){function n(n){var r=t.call(this)||this;return r._clientHostController=n,r._asyncMethodExecutorHelper=e.BootStrapExtension.createAsyncMethodExecutorHelper(r),r}return __extends(n,t),n.prototype.executeAsync=function(e,t,n,r){var o=this;this._clientHostController.execute(e,t.toWebHost(),(function(i,a){return n&&o._asyncMethodExecutorHelper.handleWebHostResponse(a,i,n,t,e,r),!0}))},n.prototype.registerEventAsync=function(e,t,n,r,o,i,a){var s=this;this._clientHostController.registerEvent(e,t,n,(function(e){var t=e,n=o.fromWebHost(t);r(n)}),(function(t,n){return i&&s.invokeCallback(e,i,t,null,a),!0}))},n.prototype.unregisterEventAsync=function(e,t,n,r,o){var i=this;this._clientHostController.unregisterEvent(e,t,n,(function(t,n){return r&&i.invokeCallback(e,r,t,null,o),!0}))},n}(e.AsyncMethodExecutor);e.WebAsyncMethodExecutor=t}(OSF||(OSF={})),function(e){!function(t){!function(t){t.getAuthContextAsync=function(t){e._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(99,{toSafeArrayHost:function(){return[]},fromSafeArrayHost:function(e){return null},toWebHost:function(){return{}},fromWebHost:function(e){return e.authContext}},t)}}(t.WebAuth||(t.WebAuth={}))}(e.DDA||(e.DDA={})),function(t){var n;!function(e){e.AuthCode="authcode",e.Broker="broker",e.Implicit="implicit"}(n=t.AuthFlow||(t.AuthFlow={})),t.loadAttempts=0;var r="webauth/",o="webauth.browserauth.debug.js",i="webauth.browserauth.js",a=!1;t.load=function(){return t.config&&t.config.authFlow===n.AuthCode?(t.loadAttempts++,(a=t.config&&(!0===t.config.useMsal3||!1!==t.config.useMsal3&&e.OUtil.checkFlight(e.FlightTreatmentNames.EnableMsal3SsoApi)))&&(o="webauth.browserauth.msal3.debug.js",i="webauth.browserauth.msal3.js"),new Promise((function(n,s){var c=function(t,n,r){return new Promise((function(o,i){t?e.OUtil.loadScript(t,(function(e){if("boolean"!=typeof e||e)if(e instanceof Event&&e)i(new Event("loadScript: "+e.type+" '"+t+"'"));else if(r&&!n())var a=0,s=setInterval((function(){a+=500,!(n()||a>r)||(clearInterval(s),n())||i(new Event("Missing expected object after loaded."))}),500);else o(null);else i(new Event("loadScript: failed to load '"+t+"'"))}),e.LoadScriptHelper.getTrustedTypesPolicy(),r):o(null)}))},u=[c(t.config&&t.config.authVersion?e.LoadScriptHelper.getHostBundleJsBasePath()+r+t.config.authVersion+"/"+(t.config&&t.config.debugging?o:i):e.LoadScriptHelper.getHostBundleJsBasePath()+r+(t.config&&t.config.debugging?o:i),(function(){return!!BrowserAuth}),t.config.delayWebAuth)];a||u.push(c(t.config.msal,(function(){return!!msal}),t.config.delayMsal)),Promise.all(u).then((function(){t.config?BrowserAuth.Load(t.config,e._OfficeAppFactory.getHostInfo().osfControlAppCorrelationId).then((function(e){n(e)}),(function(e){s(e)})):s(new Event("config is empty."))}),(function(e){s(e)}))}))):new Promise((function(e,t){return t(new Event("'authcode' as authFlow is only supported"))}))},t.getToken=function(e,r,o,i,s,c){return t.config&&t.config.authFlow===n.AuthCode?a?BrowserAuth.GetToken({resource:e,scopes:r,applicationId:o,correlationId:i,popup:!!s,claims:c}):BrowserAuth.GetToken(e,o,i,!!s,!!s,!1,c):Promise.reject(new Event("'authcode' as authFlow is only supported"))}}(e.WebAuth||(e.WebAuth={}))}(OSF||(OSF={})),function(e){var t=function(){function t(t){this._delegateVersion=1,this._webAppState=t,this._webClientHostControllerHelper=e.BootStrapExtension.createWebClientHostControllerHelper(this._webAppState,this._delegateVersion)}return t.prototype.execute=function(e,t,n){var r=this,o=this._webClientHostControllerHelper.getHostCallArgs(e,t),i=this._webClientHostControllerHelper.getTargetMethodName(e);this._webAppState.clientEndPoint.invoke(i,(function(t,o){var i=0;if(0==t)r._delegateVersion=o.Version,i=r._webClientHostControllerHelper.parseErrorFromPayload(e,o);else switch(t){case-5:i=7e3;break;default:i=5001}n&&n(i,o)}),o)},t.prototype.registerEvent=function(e,t,n,r,o){this._webAppState.clientEndPoint.registerForEvent(this.getXdmEventName(n,t),(function(e){r&&r(e)}),this._getOnAfterRegisterEvent(!0,e,o),{controlId:this._webAppState.id,eventDispId:e,targetId:n,__timeout__:-1})},t.prototype.unregisterEvent=function(e,t,n,r){this._webAppState.clientEndPoint.unregisterForEvent(this.getXdmEventName(n,t),this._getOnAfterRegisterEvent(!1,e,r),{controlId:this._webAppState.id,eventDispId:e,targetId:n,__timeout__:-1})},t.prototype.messageParent=function(t){throw e.Utility.createNotImplementedException()},t.prototype.openDialog=function(t,n,r,o,i){throw e.Utility.createNotImplementedException()},t.prototype.closeDialog=function(t,n,r,o){throw e.Utility.createNotImplementedException()},t.prototype.sendMessage=function(t){throw e.Utility.createNotImplementedException()},t.prototype.closeSdxDialog=function(t){this._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[this._webAppState.id,e.AgaveHostAction.CloseSDXDialog,{InstanceId:this._webAppState.id,DialogCloseCallbackParam:t}])},t.prototype.resizeSdxDialog=function(t,n){this._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[this._webAppState.id,e.AgaveHostAction.ResizeSDXDialog,{InstanceId:this._webAppState.id,DialogWidth:t+"px",DialogHeight:n+"px"}])},t.prototype.getXdmEventName=function(t,n){return n==e.EventType.BindingSelectionChanged||n==e.EventType.BindingDataChanged||n==e.EventType.DataNodeDeleted||n==e.EventType.DataNodeInserted||n==e.EventType.DataNodeReplaced?t+"_"+n:n},t.prototype._getOnAfterRegisterEvent=function(t,n,r){var o=(new Date).getTime();return function(i,a){var s;if(0!=i)switch(i){case-5:s=7e3;break;default:s=5001}else s=a?a.Error?a.Error:0:5001;r&&r(s),e.AppTelemetry&&e.AppTelemetry.onRegisterDone(t,n,Math.abs((new Date).getTime()-o),s)}},t}();e.WebClientHostController=t}(OSF||(OSF={})),function(e){var t=function(){function e(e,t){this._webAppState=e,this._delegateVersion=t}return e.prototype.getHostCallArgs=function(e,t){var n=t;return n||(n={}),n.DdaMethod={ControlId:this.getControlId(),DispatchId:e,Version:this._delegateVersion},n.__timeout__=-1,n},e.prototype.getTargetMethodName=function(e){return"executeMethod"},e.prototype.parseErrorFromPayload=function(e,t){return t.Error},e.prototype.getControlId=function(){return this._webAppState.id},e}();e.WebClientHostControllerHelper=t}(OSF||(OSF={})),function(e){var t=function(){function t(){}return t.prototype.read=function(t){e._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(75,{toSafeArrayHost:function(){return[]},fromSafeArrayHost:function(e){return null},toWebHost:function(){return{}},fromWebHost:function(e){return e.Properties.Settings}},(function(e){if(e.status===Office.AsyncResultStatus.Succeeded){for(var n={},r=0;r<e.value.length;r++){var o=e.value[r];Array.isArray(o)?n[o[0]]=o[1]:n[o.Name]=o.Value}t(0,n)}else{var i=e.error.code;t(i,{})}}))},t.prototype.write=function(t,n){var r=e._OfficeAppFactory.getAsyncMethodExecutor(),o=[];for(var i in t){var a=[];a.push(i),a.push(t[i]),o.push(a)}var s={toSafeArrayHost:function(){return null},fromSafeArrayHost:function(e){return null},toWebHost:function(){return{DdaSettingsMethod:{OverwriteIfStale:!0,Properties:o}}},fromWebHost:function(e){return null}};r.executeAsync(76,s,(function(e){if(e.status===Office.AsyncResultStatus.Succeeded)n(0);else{var t=e.error.code;n(t)}}))},t}();e.WebClientSettingsManager=t}(OSF||(OSF={})),function(e){var t=function(t){function n(e,n,r,o){var i=t.call(this,e,n,r,o)||this;return i._serializedSettings={},i._serializedHostSettings={},i._initializeNestedAppAuthPromise=null,i._appContext={},i._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'])",i}return __extends(n,t),Object.defineProperty(n.prototype,"isHostOriginTrusted",{get:function(){return this._isHostOriginTrustedFunc},set:function(e){this._isHostOriginTrustedFunc=e},enumerable:!0,configurable:!0}),n.prototype.saveAndSetDialogInfo=function(t){var n,r=e.OUtil.getSessionStorage();if(r){if(t||(t=e.OUtil.parseHostInfoFromWindowName(!0,e._OfficeAppFactory.getWindowName())),t&&t.indexOf("isDialog")>-1){var o=(n=e.OUtil.parseXdmInfo(!0))?n.split("|")[1]:null;return null!=o&&r.setItem(o+"IsDialog","true"),void(this._hostInfo.isDialog=!0)}this._hostInfo.isDialog=null!=r.getItem(e.OUtil.getXdmFieldValue("AppId",!1)+"IsDialog")}},n.prototype.checkReceiverOriginAndRun=function(t){return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a,s,c,u,l,f;return __generator(this,(function(p){switch(p.label){case 0:return 3===(n=this)._webAppState.clientEndPoint.hostTrustCheckStatus?(t(),[2]):(r=e.OUtil.parseUrl(n._webAppState.clientEndPoint.targetUrl,!1),o="https:"==r.protocol,i=r.hostname,a="NotHttps",0!==n._webAppState.clientEndPoint.hostTrustCheckStatus?[3,4]:(o||(n._webAppState.clientEndPoint.hostTrustCheckStatus=2),2==n._webAppState.clientEndPoint.hostTrustCheckStatus?[3,4]:(s=!1,(c=e.SovereignHelper.isSovereignVersion())&&!0!==e.OUtil.getCustomOfficeInitializationSettings().trustAllCloudEnvironments||(s=e.XdmCommunicationManager.isHostNameValidWacDomain(i),n.isHostOriginTrusted&&(s=s||n.isHostOriginTrusted(i))),s||!c?[3,3]:(n._sovereignHelper||(n._sovereignHelper=new e.SovereignHelper),[4,(u=n._sovereignHelper).isConfigAvailable()]))));case 1:return p.sent()?[4,u.isSovereignHostTrusted(i)]:[2];case 2:s=p.sent(),p.label=3;case 3:s&&(n._webAppState.clientEndPoint.hostTrustCheckStatus=3),p.label=4;case 4:if(n._webAppState.clientEndPoint.checkStatusLogged||null==n._hostInfo||void 0===n._hostInfo||(e.AppTelemetry.onCheckWACHost(n._webAppState.clientEndPoint.hostTrustCheckStatus,n._webAppState.id,n._hostInfo.hostType,n._hostInfo.hostPlatform,n._webAppState.clientEndPoint.targetUrl),n._webAppState.clientEndPoint.checkStatusLogged=!0),3===n._webAppState.clientEndPoint.hostTrustCheckStatus||e.LoadScriptHelper.disableHostCheck())t();else{if(e.LoadScriptHelper.isSdx())throw new Error("Not supported host");l=function(){var r=e.LoadScriptHelper.getHostBundleJsBasePath().match(/^https?:\/\/[^:/?#]*(?::([0-9]+))?/);if(r&&r[0]){var s=e.LoadScriptHelper.getHostBundleJsBasePath()+"AgaveErrorUX/index.html#",c={error:"NotTrustedWAC",locale:e.getSupportedLocale(n._hostInfo.hostLocale,e.ConstantNames.DefaultLocale),hostname:i,noHttps:!o,validate:!1},u=document.createElement("iframe");u.style.visibility="hidden",u.style.height="0",u.style.width="0";var l=function(o){if(o.source==u.contentWindow&&o.origin==r[0])try{!0===JSON.parse(o.data).hostUserTrusted?(n._webAppState.clientEndPoint.hostTrustCheckStatus=3,e.OUtil.removeEventListener(window,"message",l),document.body.removeChild(u)):(c.validate=!1,window.location.replace(s+encodeURIComponent(JSON.stringify(c)))),t()}catch(t){e.OUtil.ensureOfficeStringsJs().then((function(){document.body.textContent=Strings.OfficeOM.L_NotTrustedWAC}))}};e.OUtil.addEventListener(window,"message",l),c.validate=!0,u.setAttribute("src",s+encodeURIComponent(JSON.stringify(c))),u.onload=function(){var e={hostname:i,noHttps:!o};u.contentWindow.postMessage(JSON.stringify(e),r[0])},document.body.appendChild(u)}else e.OUtil.ensureOfficeStringsJs().then((function(){document.body.textContent=Strings.OfficeOM.L_NotTrustedWAC}));if(e.OUtil.checkFlight(2)&&!o)throw new Error(a)},document.body?l():(f=!1,document.addEventListener("DOMContentLoaded",(function(){f||(f=!0,l())})))}return[2]}}))}))},n.prototype.setAgaveHostCommunication=function(){try{var t=this,n=e.OUtil.parseXdmInfoWithGivenFragment(!1,e._OfficeAppFactory.getWindowLocationHash());if(n||(n=e.OUtil.parseXdmInfoFromWindowName(!1,e._OfficeAppFactory.getWindowName())),n){var r=e.OUtil.getInfoItems(n);null!=r&&r.length>=3&&(t._webAppState.conversationID=r[0],t._webAppState.id=r[1],t._webAppState.webAppUrl=r[2].indexOf(":")>=0?r[2]:decodeURIComponent(r[2]))}if(t._webAppState.wnd=null!=window.opener?window.opener:window.parent,this._hostInfo.isDialog&&null!=window.opener)return;t._webAppState.clientEndPoint=e.XdmCommunicationManager.connect(t._webAppState.conversationID,t._webAppState.wnd,t._webAppState.webAppUrl),t._webAppState.serviceEndPoint=e.XdmCommunicationManager.createServiceEndPoint(t._webAppState.id),t._webAppState.clientEndPoint.checkReceiverOriginAndRun=function(e){t.checkReceiverOriginAndRun(e)};var o=t._webAppState.conversationID+e.Constants.NotificationConversationIdSuffix;t._webAppState.serviceEndPoint.registerConversation(o,t._webAppState.webAppUrl);t._webAppState.serviceEndPoint.registerMethod("Office_notifyAgave",(function(n){var r;switch(r="string"==typeof n?n:n[0]){case e.AgaveHostAction.Select:t._webAppState.focused=!0;break;case e.AgaveHostAction.UnSelect:t._webAppState.focused=!1;break;case e.AgaveHostAction.TabIn:case e.AgaveHostAction.CtrlF6In:window.focus();var o=document.querySelectorAll(t._tabbableElements);e.OUtil.focusToFirstTabbable(o,!1)||(window.blur(),t._webAppState.focused=!1,t._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[t._webAppState.id,e.AgaveHostAction.ExitNoFocusable]));break;case e.AgaveHostAction.TabInShift:window.focus();o=document.querySelectorAll(t._tabbableElements);e.OUtil.focusToFirstTabbable(o,!0)||(window.blur(),t._webAppState.focused=!1,t._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[t._webAppState.id,e.AgaveHostAction.ExitNoFocusableShift]));break;case e.AgaveHostAction.SendMessage:if(Office.context.messaging.onMessage){var i=n[1];Office.context.messaging.onMessage(i)}break;case e.AgaveHostAction.TaskPaneHeaderButtonClicked:Office.context.ui.taskPaneAction.onHeaderButtonClick&&Office.context.ui.taskPaneAction.onHeaderButtonClick();break;default:e.Utility.trace("actionId "+r+" notifyAgave is wrong.")}}),0,!1),t.addOrRemoveEventListenersForWindow(!0)}catch(t){throw e.AppTelemetry&&e.AppTelemetry.logAppException("Exception thrown in setAgaveHostCommunication. Exception:["+t+"]"),t}},n.prototype.getAppContext=function(t,n,r){var o=this,i=this,a=function(t,a){if(OSFPerformance.getAppContextXdmEnd=OSFPerformance.now(),a._appName===e.AppName.ExcelWebApp){for(var s=0,c=a._settings;s<c.length;s++){var u=c[s],l=u[0],f=u[1];o._serializedSettings[l]=f}for(var p=0,d=a._hostSettings;p<d.length;p++){var h=d[p];l=h[0],f=h[1];o._serializedHostSettings[l]=f}}else o._serializedSettings=a._settings||{},o._serializedHostSettings=a._hostSettings||{};if(!i._hostInfo.isDialog||null==window.opener){var g=window.location.href;i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,e.AgaveHostAction.UpdateTargetUrl,g])}if(0===t&&null!=a._id&&null!=a._appName&&null!=a._appVersion&&null!=a._appUILocale&&null!=a._dataLocale&&null!=a._docUrl&&null!=a._clientMode&&null!=a._reason){i._appContext=a;var m=a._appInstanceId?a._appInstanceId:a._id,y=0;null!=a._appMinorVersion&&(y=a._appMinorVersion);var v=void 0;null!=a._requirementMatrix&&(v=a._requirementMatrix),a.eToken=a.eToken?a.eToken:"";var _=new e.OfficeAppContext(a._id,a._appName,a._appVersion,a._appUILocale,a._dataLocale,a._docUrl,a._clientMode,(function(){return o._serializedSettings}),a._reason,a._osfControlType,a._eToken,a._correlationId,m,!1,!0,y,v,a._hostCustomMessage,a._hostFullVersion,a._clientWindowHeight,a._clientWindowWidth,a._addinName,a._appDomains,a._dialogRequirementMatrix,a._featureGates,a._officeTheme,a._initialDisplayMode,a._isFromWacAutomation,a._wopiHostOriginForSingleSignOn,(function(){return o._serializedHostSettings}),!0,a._nestedAppAuthBridgeType,a._partitionKey,a._topFrameOrigin);_.set_taskpaneUrl(a._taskpaneUrl),n(_)}else{var b="Function ContextActivationManager_getAppContextAsync call failed. ErrorCode is "+t+", exception: "+a;e.AppTelemetry&&e.AppTelemetry.logAppException(b),r(b)}};try{var s=!0;this._hostInfo.isDialog&&null!=window.opener&&(s=!1);var c=e.OUtil.parseAppContextFromWindowName(s,e._OfficeAppFactory.getWindowName());c?a(0,c):(OSFPerformance.getAppContextXdmStart=OSFPerformance.now(),this._webAppState.clientEndPoint.invoke("ContextActivationManager_getAppContextAsync",a,this._webAppState.id))}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception thrown when trying to invoke getAppContextAsync. Exception:["+t+"]"),r(t)}},n.prototype.createClientHostController=function(){return this._clientHostController||(this._clientHostController=new e.WebClientHostController(this._webAppState)),this._clientHostController},n.prototype.createAsyncMethodExecutor=function(){return new e.WebAsyncMethodExecutor(this._clientHostController)},n.prototype.createClientSettingsManager=function(){return new e.WebClientSettingsManager},n.prototype.addOrRemoveEventListenersForWindow=function(t){var n=this,r=function(){n._webAppState.focused||(n._webAppState.focused=!0),n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.Select])},o=function(){e&&(n._webAppState.focused&&(n._webAppState.focused=!1),n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.UnSelect]))},i=function(t){if(t.preventDefault=t.preventDefault||function(){t.returnValue=!1},117==t.keyCode&&(t.ctrlKey||t.metaKey)){t.preventDefault();var r=e.AgaveHostAction.CtrlF6Exit;t.shiftKey&&(r=e.AgaveHostAction.CtrlF6ExitShift),n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,r])}else if(9==t.keyCode){t.preventDefault();var o=document.querySelectorAll(n._tabbableElements);e.OUtil.focusToNextTabbable(o,t.target||t.srcElement,t.shiftKey)||(n._hostInfo.isDialog?e.OUtil.focusToFirstTabbable(o,t.shiftKey):t.shiftKey?n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.TabExitShift]):n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.TabExit]))}else if(27==t.keyCode)t.preventDefault(),n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.EscExit]);else if(113==t.keyCode)t.preventDefault(),n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.F2Exit]);else if((t.ctrlKey||t.metaKey||t.shiftKey||t.altKey)&&t.keyCode>=1&&t.keyCode<=255){var i={keyCode:t.keyCode,shiftKey:t.shiftKey,altKey:t.altKey,ctrlKey:t.ctrlKey,metaKey:t.metaKey};n._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.KeyboardShortcuts,i])}},a=function(e){117==e.keyCode&&e.ctrlKey&&(e.preventDefault?e.preventDefault():e.returnValue=!1)};e.Utility._DebugXdm||(t?(e.OUtil.addEventListener(window,"focus",r),e.OUtil.addEventListener(window,"blur",o),e.OUtil.addEventListener(window,"keydown",i),e.OUtil.addEventListener(window,"keypress",a)):(e.OUtil.removeEventListener(window,"focus",r),e.OUtil.removeEventListener(window,"blur",o),e.OUtil.removeEventListener(window,"keydown",i),e.OUtil.removeEventListener(window,"keypress",a)))},n.prototype.getTabbableElements=function(){return this._tabbableElements},n.prototype.setupNestedAppAuthDependencies=function(){var e=this;window.__initializeNestedAppAuth=function(){return e._initializeNestedAppAuthPromise||(e._initializeNestedAppAuthPromise=__awaiter(e,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,Office.onReadyInternal()];case 1:return e.sent(),this._createNaaBridge?[4,this._createNaaBridge()]:[3,3];case 2:e.sent(),e.label=3;case 3:return[2]}}))}))),e._initializeNestedAppAuthPromise}},n}(e.InitializationHelper);e.WebInitializationHelper=t}(OSF||(OSF={})),function(e){var t=function(){function t(e,t){this._initializationHelper=e,this._scriptMessager=t}return t.prototype.read=function(e){this._initializationHelper.getAppContext(null,(function(t){if(e){var n=t.get_settingsFunc()();e(0,n)}}),(function(t){e&&e(5001,{})}))},t.prototype.write=function(t,n){var r={},o=[],i=[];for(var a in t)o.push(a),i.push(t[a]);r.keys=o,r.values=i;this._scriptMessager.invokeMethod(e.Webkit.MessageHandlerName,e.Webkit.MethodId.WriteSettings,r,(function(e){n&&n(e[0])}))},t}();e.WebkitClientSettingsManager=t}(OSF||(OSF={})),function(e){!function(t){t.MessageHandlerName="Agave",t.PopupMessageHandlerName="WefPopupHandler",function(e){e[e.Settings=0]="Settings",e[e.SolutionReferenceId=1]="SolutionReferenceId",e[e.AppType=2]="AppType",e[e.MajorVersion=3]="MajorVersion",e[e.MinorVersion=4]="MinorVersion",e[e.RevisionVersion=5]="RevisionVersion",e[e.APIVersionSequence=6]="APIVersionSequence",e[e.AppCapabilities=7]="AppCapabilities",e[e.APPUILocale=8]="APPUILocale",e[e.AppDataLocale=9]="AppDataLocale",e[e.BindingCount=10]="BindingCount",e[e.DocumentUrl=11]="DocumentUrl",e[e.ActivationMode=12]="ActivationMode",e[e.ControlIntegrationLevel=13]="ControlIntegrationLevel",e[e.SolutionToken=14]="SolutionToken",e[e.APISetVersion=15]="APISetVersion",e[e.CorrelationId=16]="CorrelationId",e[e.InstanceId=17]="InstanceId",e[e.TouchEnabled=18]="TouchEnabled",e[e.CommerceAllowed=19]="CommerceAllowed",e[e.RequirementMatrix=20]="RequirementMatrix",e[e.HostCustomMessage=21]="HostCustomMessage",e[e.HostFullVersion=22]="HostFullVersion",e[e.InitialDisplayMode=23]="InitialDisplayMode",e[e.FeatureGates=24]="FeatureGates",e[e.HostSettings=25]="HostSettings",e[e.OfficeThemeInfo=26]="OfficeThemeInfo"}(t.AppContextProperties||(t.AppContextProperties={})),function(e){e[e.Execute=1]="Execute",e[e.RegisterEvent=2]="RegisterEvent",e[e.UnregisterEvent=3]="UnregisterEvent",e[e.WriteSettings=4]="WriteSettings",e[e.GetContext=5]="GetContext",e[e.SendMessage=6]="SendMessage",e[e.MessageParent=7]="MessageParent",e[e.SendMessage2=8]="SendMessage2",e[e.MessageParent2=9]="MessageParent2",e[e.CloseSdxDialog=10]="CloseSdxDialog",e[e.ResizeSdxDialog=11]="ResizeSdxDialog"}(t.MethodId||(t.MethodId={}));var n=function(){function t(e){this.hostScriptProxy=e,this.useFullDialogAPI=!!window._enableFullDialogAPI,this.osfSupportsDialogOrigin=!!window._osfEnableDialogOrigin}return t.prototype.execute=function(t,n,r){var o={id:t,apiArgs:n};this.hostScriptProxy.invokeMethod(e.Webkit.MessageHandlerName,e.Webkit.MethodId.Execute,o,(function(t){if(r){var n=[];if(e.OUtil.isArray(t))for(var o=0;o<t.length;o++){var i=t[o];e.OUtil.isArray(i)&&(i=new e.WebkitSafeArray(i)),n.unshift(i)}return r.apply(null,n)}}))},t.prototype.registerEvent=function(t,n,r,o,i){this.hostScriptProxy.registerEvent(e.Webkit.MessageHandlerName,e.Webkit.MethodId.RegisterEvent,t,r,(function(t){var n=t,r=0;e.OUtil.isArray(t)&&t.length>=2&&(n=t[0],r=t[1]),o&&o(r,new e.WebkitSafeArray(n))}),(function(t){if(i)return i(new e.WebkitSafeArray(t))}))},t.prototype.unregisterEvent=function(t,n,r,o){this.hostScriptProxy.unregisterEvent(e.Webkit.MessageHandlerName,e.Webkit.MethodId.UnregisterEvent,t,r,(function(t){return o(new e.WebkitSafeArray(t))}))},t.prototype.messageParent=function(t){var n,r;if(this.osfSupportsDialogOrigin&&t[e.ParameterNames.TargetOrigin]?(n=this.useFullDialogAPI?JSON.stringify(t):t[e.ParameterNames.MessageToParent],r=e.Webkit.MethodId.MessageParent2):(n=t[e.ParameterNames.MessageToParent],r=e.Webkit.MethodId.MessageParent),this.useFullDialogAPI)this.hostScriptProxy.invokeMethod(e.Webkit.MessageHandlerName,r,n,null);else{var o={dialogMessage:{messageType:0,messageContent:n}},i=r==e.Webkit.MethodId.MessageParent2?t[e.ParameterNames.TargetOrigin]:window.location.origin;window.opener.postMessage(JSON.stringify(o),i)}},t.prototype.openDialog=function(n,r,o,i,a){if(this.useFullDialogAPI)this.registerEvent(n,r,o,i,a);else if(!t.popup||t.popup.closed){t.OpenDialogCallback=void 0;var s=JSON.parse(o),c=s.url;if(c){var u=c.split("#"),l="?";u[0].indexOf("?")>-1&&(l="&");var f="width="+screen.width*s.width/100+", height="+screen.height*s.height/100;u[0]=u[0].concat(l).concat("action=displayDialog");var p=u.join("#");t.popup=window.open(p,"",f),t.DialogEventListener=function(t){if(t.origin==window.location.origin)try{var r=JSON.parse(t.data);r.dialogMessage&&i(n,[0,r.dialogMessage.messageContent,t.origin])}catch(n){e.Utility.trace("messages received cannot be handlered. Message:"+t.data)}},t.OpenDialogCallback=function(e){0==e&&(window.addEventListener("message",t.DialogEventListener),t.interval=window.setInterval(d,1e3),t.NotifyError=function(e){i(n,[e])}),a(e)}}else a(12003)}else a(12007);function d(){try{(null==t.popup||t.popup.closed)&&(window.clearInterval(t.interval),window.removeEventListener("message",t.DialogEventListener),t.NotifyError=null,t.popup=null,i(n,[12006]))}catch(t){e.Utility.trace("Error happened when popup window closed.")}}},t.prototype.closeDialog=function(e,n,r,o){this.useFullDialogAPI?this.unregisterEvent(e,n,r,o):t.popup?(t.interval&&window.clearInterval(t.interval),t.popup.close(),t.popup=null,window.removeEventListener("message",t.DialogEventListener),t.NotifyError=null,o(0)):o(5001)},t.prototype.sendMessage=function(t){var n,r;this.osfSupportsDialogOrigin&&t[e.ParameterNames.TargetOrigin]?(n=JSON.stringify(t),r=e.Webkit.MethodId.SendMessage2):(n=t[e.ParameterNames.MessageContent],r=e.Webkit.MethodId.SendMessage,!isNaN(parseFloat(n))&&isFinite(n)&&(n=n.toString())),this.hostScriptProxy.invokeMethod(e.Webkit.MessageHandlerName,r,n,null)},t.prototype.closeSdxDialog=function(t){var n=[t],r=e.Webkit.MethodId.CloseSdxDialog;this.hostScriptProxy.invokeMethod(e.Webkit.MessageHandlerName,r,n,null)},t.prototype.resizeSdxDialog=function(t,n){var r=[t,n],o=e.Webkit.MethodId.ResizeSdxDialog;this.hostScriptProxy.invokeMethod(e.Webkit.MessageHandlerName,o,r,null)},t}();t.WebkitHostController=n}(e.Webkit||(e.Webkit={}))}(OSF||(OSF={})),function(e){var t=function(t){function n(e,n,r,o){var i=t.call(this,e,n,r,o)||this;return i._serializedSettings={},i._serializedHostSettings={},i.initializeWebkitMessaging(),i}return __extends(n,t),n.prototype.initializeWebkitMessaging=function(){e.ScriptMessaging=OSFWebkit.ScriptMessaging},n.prototype.getAppContext=function(t,n,r){var o,i=this;o=this._hostInfo.isDialog&&window.webkit.messageHandlers[e.Webkit.PopupMessageHandlerName]?e.Webkit.PopupMessageHandlerName:e.Webkit.MessageHandlerName,e.ScriptMessaging.GetScriptMessenger().invokeMethod(o,e.Webkit.MethodId.GetContext,[],(function(t){var r,o=e.Webkit.AppContextProperties,a=t[o.AppType],s=t[o.Settings];if(s&&2===s.length)for(var c=s[0],u=s[1],l=0;l<c.length;l++)i._serializedSettings[c[l]]=u[l];var f=t[o.HostSettings];if(f&&2===f.length)for(c=f[0],u=f[1],l=0;l<c.length;l++)i._serializedHostSettings[c[l]]=u[l];var p=t[o.SolutionReferenceId],d=t[o.MajorVersion],h=t[o.MinorVersion],g=t[o.AppCapabilities],m=t[o.APPUILocale],y=t[o.AppDataLocale],v=t[o.DocumentUrl],_=t[o.ActivationMode],b=t[o.ControlIntegrationLevel],O=t[o.SolutionToken];O=O?O.toString():"";var S,C=t[o.CorrelationId],I=t[o.InstanceId],A=t[o.TouchEnabled],P=t[o.CommerceAllowed],E=t[o.RequirementMatrix],R=t[o.HostCustomMessage],T=t[o.HostFullVersion],w=t[o.InitialDisplayMode],x=t[o.FeatureGates];if(x)try{S=JSON.parse(x)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception trying to parse FeatureGates."+t)}var N=null;if(t[o.OfficeThemeInfo])try{N=JSON.parse(t[o.OfficeThemeInfo])}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception while parsing officeThemeInfo. Details: "+t)}var D={};if(N){var k={bodyBackgroundColor:{name:"bodyBackgroundColor",convertToHex:!0},bodyForegroundColor:{name:"bodyForegroundColor",convertToHex:!0},controlBackgroundColor:{name:"controlBackgroundColor",convertToHex:!0},controlForegroundColor:{name:"controlForegroundColor",convertToHex:!0},primaryFontColor:{name:"bodyForegroundColor",convertToHex:!0},primaryBackgroundColor:{name:"bodyBackgroundColor",convertToHex:!0},secondaryFontColor:{name:"controlForegroundColor",convertToHex:!0},secondaryBackgroundColor:{name:"controlBackgroundColor",convertToHex:!0},fluentThemeData:{name:"fluentThemeData",convertToHex:!1}};for(var F in N){var j=!1,M=F;k[F]&&(M=k[F].name,j=k[F].convertToHex),D[M]=j?e.OUtil.convertIntToCssHexColor(N[F]):N[F]}}r=new e.OfficeAppContext(p,a,d,m,y,v,g,(function(){return i._serializedSettings}),_,b,O,C,I,A,P,h,E,R,T,void 0,void 0,void 0,void 0,void 0,S,D,w,void 0,void 0,(function(){return i._serializedHostSettings}),!1,void 0,void 0,void 0),n(r)}))},n.prototype.createClientHostController=function(){return this._clientHostController||(this._clientHostController=new e.Webkit.WebkitHostController(e.ScriptMessaging.GetScriptMessenger())),this._clientHostController},n.prototype.createAsyncMethodExecutor=function(){return new e.SafeArrayAsyncMethodExecutor(this.createClientHostController())},n.prototype.createClientSettingsManager=function(){return new e.WebkitClientSettingsManager(this,e.ScriptMessaging.GetScriptMessenger())},n}(e.InitializationHelper);e.WebkitInitializationHelper=t}(OSF||(OSF={})),function(e){var t=function(){function t(e){this.data=e,this.safeArrayFlag=this.isSafeArray(e)}return t.prototype.dimensions=function(){var e=0;return this.safeArrayFlag?e=this.data[0][0]:this.isArray()&&(e=2),e},t.prototype.getItem=function(){var e=null;e=this.safeArrayFlag?this.toArray():this.data;for(var t=0;t<arguments.length;t++)e=e[arguments[t]];return e},t.prototype.lbound=function(e){return 0},t.prototype.ubound=function(t){var n=0;if(this.safeArrayFlag)n=this.data[0][t];else if(this.isArray()){if(1==t)return this.data.length;if(2==t){if(e.OUtil.isArray(this.data[0]))return this.data[0].length;if(null!=this.data[0])return 1}}return n},t.prototype.toArray=function(){if(0==this.isArray())return this.data;for(var e=[],n=this.safeArrayFlag?1:0;n<this.data.length;n++){var r=this.data[n];this.isSafeArray(r)?e.push(new t(r)):e.push(r)}return e},t.prototype.isArray=function(){return e.OUtil.isArray(this.data)},t.prototype.isSafeArray=function(t){var n=!1;if(e.OUtil.isArray(t)&&e.OUtil.isArray(t[0])){var r=t[0],o=r[0];if(r.length!=o+1)return!1;for(var i=1,a=1;a<r.length;a++){var s=r[a];if(0==isFinite(s))return!1;i*=s}n=++i==t.length}return n},t}();e.WebkitSafeArray=t}(OSF||(OSF={})),function(e){!function(e){var t=null;e.agaveHostCallback=function(e,n){t.agaveHostCallback(e,n)},e.agaveHostEventCallback=function(e,n){t.agaveHostEventCallback(e,n)},e.GetScriptMessenger=function(){return null==t&&(t=r.IsSupportedByHost()?new r:new o("OSF.ScriptMessaging.agaveHostCallback","OSF.ScriptMessaging.agaveHostEventCallback")),t};var n=function(e,t,n){this.id=e,this.targetId=t,this.handler=n},r=function(){function e(){this.eventHandlers=[]}return e.IsSupportedByHost=function(){return!!window._osfHostAPI},e.prototype.invokeMethod=function(e,t,n,r){window._osfHostAPI(e,this.constructMessagingArgs(t,n),(function(e){var t=r(e);return void 0===t||!0===t}))},e.prototype.registerEvent=function(e,t,n,r,o,i){var a={id:n,targetId:r},s=window._osfHostRegisterEvent(e,this.constructMessagingArgs(t,a),(function(e){return o(e),!1}),(function(e){return i(e),!0}));this.eventHandlers.push({targetId:r,dispId:n,callbackId:s.eventCallbackId})},e.prototype.unregisterEvent=function(e,t,n,r,o){var i={id:n,targetId:r};window._osfHostAPI(e,this.constructMessagingArgs(t,i),(function(e){return o(e),!0}));for(var a=this.eventHandlers.length-1;a>=0;a--){var s=this.eventHandlers[a];s.dispId===n&&s.targetId===r&&(this.eventHandlers.splice(a,1),window._osfHostUnregisterCallback(s.callbackId))}},e.prototype.agaveHostCallback=function(e,t){},e.prototype.agaveHostEventCallback=function(e,t){},e.prototype.constructMessagingArgs=function(e,t){return{params:t,methodId:e}},e}(),o=function(){function e(t,n){this.callingIndex=0,this.callbackList={},this.eventHandlerList={},this.asyncMethodCallbackFunctionName=t,this.eventCallbackFunctionName=n,this.conversationId=e.getCurrentTimeMS().toString()}return e.prototype.invokeMethod=function(e,t,n,r){this.postWebkitMessage({},e,t,n,r)},e.prototype.registerEvent=function(e,t,r,o,i,a){var s={eventCallbackFunction:this.eventCallbackFunctionName},c={id:r,targetId:o},u=this.postWebkitMessage(s,e,t,c,a);this.eventHandlerList[u]=new n(r,o,i)},e.prototype.unregisterEvent=function(e,t,n,r,o){var i={id:n,targetId:r};for(var a in this.eventHandlerList)if(this.eventHandlerList.hasOwnProperty(a)){var s=this.eventHandlerList[a];s.id==n&&s.targetId==r&&delete this.eventHandlerList[a]}this.invokeMethod(e,t,i,o)},e.prototype.agaveHostCallback=function(e,t){var n=this.callbackList[e];if(n){var r=n(t);void 0!==r&&!0!==r||delete this.callbackList[e]}},e.prototype.agaveHostEventCallback=function(e,t){var n=this.eventHandlerList[e];n&&n.handler(t)},e.prototype.postWebkitMessage=function(t,n,r,o,i){t.methodId=r,t.params=o;var a="";i&&(a=this.generateCorrelationId(),this.callbackList[a]=i,t.callbackId=a,t.callbackFunction=this.asyncMethodCallbackFunctionName);var s=function(){window.webkit.messageHandlers[n].postMessage(JSON.stringify(t))},c=e.getCurrentTimeMS();return null==this.lastMessageTimestamp||c-this.lastMessageTimestamp>=e.MESSAGE_TIME_DELTA?(s(),this.lastMessageTimestamp=c):(this.lastMessageTimestamp+=e.MESSAGE_TIME_DELTA,setTimeout((function(){s()}),this.lastMessageTimestamp-c)),a},e.prototype.generateCorrelationId=function(){return++this.callingIndex,this.conversationId+this.callingIndex},e.getCurrentTimeMS=function(){return(new Date).getTime()},e.MESSAGE_TIME_DELTA=10,e}()}(e.ScriptMessaging||(e.ScriptMessaging={}))}(OSFWebkit||(OSFWebkit={})),function(e){var t=function(){function t(e,t){this._initializationHelper=e,this._scriptMessager=t}return t.prototype.read=function(e){this._initializationHelper.getAppContext(null,(function(t){if(e){var n=t.get_settingsFunc()();e(0,n)}}),(function(t){e&&e(5001,{})}))},t.prototype.write=function(t,n){var r={},o=[],i=[];for(var a in t)o.push(a),i.push(t[a]);r.keys=o,r.values=i;this._scriptMessager.invokeMethod(e.WebView.MessageHandlerName,e.WebView.MethodId.WriteSettings,r,(function(e){n&&n(e[0])}))},t}();e.WebViewClientSettingsManager=t}(OSF||(OSF={})),function(e){!function(t){t.MessageHandlerName="Agave",t.PopupMessageHandlerName="WefPopupHandler",function(e){e[e.Settings=0]="Settings",e[e.SolutionReferenceId=1]="SolutionReferenceId",e[e.AppType=2]="AppType",e[e.MajorVersion=3]="MajorVersion",e[e.MinorVersion=4]="MinorVersion",e[e.RevisionVersion=5]="RevisionVersion",e[e.APIVersionSequence=6]="APIVersionSequence",e[e.AppCapabilities=7]="AppCapabilities",e[e.APPUILocale=8]="APPUILocale",e[e.AppDataLocale=9]="AppDataLocale",e[e.BindingCount=10]="BindingCount",e[e.DocumentUrl=11]="DocumentUrl",e[e.ActivationMode=12]="ActivationMode",e[e.ControlIntegrationLevel=13]="ControlIntegrationLevel",e[e.SolutionToken=14]="SolutionToken",e[e.APISetVersion=15]="APISetVersion",e[e.CorrelationId=16]="CorrelationId",e[e.InstanceId=17]="InstanceId",e[e.TouchEnabled=18]="TouchEnabled",e[e.CommerceAllowed=19]="CommerceAllowed",e[e.RequirementMatrix=20]="RequirementMatrix",e[e.OfficeThemeInfo=21]="OfficeThemeInfo"}(t.AppContextProperties||(t.AppContextProperties={})),function(e){e[e.Execute=1]="Execute",e[e.RegisterEvent=2]="RegisterEvent",e[e.UnregisterEvent=3]="UnregisterEvent",e[e.WriteSettings=4]="WriteSettings",e[e.GetContext=5]="GetContext",e[e.OnKeydown=6]="OnKeydown",e[e.AddinInitialized=7]="AddinInitialized",e[e.OpenWindow=8]="OpenWindow",e[e.MessageParent=9]="MessageParent",e[e.SendMessage=10]="SendMessage"}(t.MethodId||(t.MethodId={}));var n=function(){function t(e){this.hostScriptProxy=e}return t.prototype.execute=function(t,n,r){var o=n;null==o&&(o=[]);var i={id:t,apiArgs:o};this.hostScriptProxy.invokeMethod(e.WebView.MessageHandlerName,e.WebView.MethodId.Execute,i,(function(t){var n=t;if(e.OUtil.isArray(t)&&t.length>=2){t[0];n=t[1]}if(r)return r(new e.WebkitSafeArray(n))}))},t.prototype.registerEvent=function(t,n,r,o,i){this.hostScriptProxy.registerEvent(e.WebView.MessageHandlerName,e.WebView.MethodId.RegisterEvent,t,r,(function(t){var n=t,r=0;e.OUtil.isArray(t)&&t.length>=2&&(r=t[0],n=t[1]),o&&o(r,new e.WebkitSafeArray(n))}),(function(t){if(i)return i(new e.WebkitSafeArray(t))}))},t.prototype.unregisterEvent=function(t,n,r,o){this.hostScriptProxy.unregisterEvent(e.WebView.MessageHandlerName,e.WebView.MethodId.UnregisterEvent,t,r,(function(t){return o(new e.WebkitSafeArray(t))}))},t.prototype.messageParent=function(t){var n={dialogMessage:{messageType:0,messageContent:t[e.ParameterNames.MessageToParent]}};window.opener.postMessage(JSON.stringify(n),window.location.origin)},t.prototype.openDialog=function(n,r,o,i,a){var s=JSON.parse(o),c=s.url;if(c){var u=c.split("#"),l="?";c.indexOf("?")>-1&&(l="&");var f="width="+screen.width*s.width/100+", height="+screen.height*s.height/100;u[0]=u[0].concat(l).concat("action=displayDialog");var p,d=u.join("#");t.popup=window.open(d,"",f),window.addEventListener("message",(function(r){if(r.source==t.popup)try{var o=JSON.parse(r.data);o.dialogMessage&&i(n,[0,o.dialogMessage.messageContent])}catch(t){e.Utility.trace("messages received cannot be handled. Message:"+r.data)}})),p=window.setInterval((function(){try{(null==t.popup||t.popup.closed)&&(window.clearInterval(p),i(n,[12006]))}catch(t){e.Utility.trace("Error happened when popup window closed.")}}),1e3),a(0)}},t.prototype.closeDialog=function(e,n,r,o){t.popup?(t.popup.close(),t.popup=null,o(0)):o(5001)},t.prototype.sendMessage=function(t){var n=t[e.ParameterNames.MessageContent];!isNaN(parseFloat(n))&&isFinite(n)&&(n=n.toString()),this.hostScriptProxy.invokeMethod(e.WebView.MessageHandlerName,e.WebView.MethodId.SendMessage,n,null)},t.prototype.closeSdxDialog=function(t){throw e.Utility.createNotImplementedException()},t.prototype.resizeSdxDialog=function(t,n){throw e.Utility.createNotImplementedException()},t}();t.WebViewHostController=n}(e.WebView||(e.WebView={}))}(OSF||(OSF={})),function(e){var t=function(t){function n(e,n,r,o){var i=t.call(this,e,n,r,o)||this;return i._serializedSettings={},i.initializeWebViewMessaging(),i}return __extends(n,t),n.prototype.initializeWebViewMessaging=function(){e.ScriptMessaging=e.WebView.ScriptMessaging},n.prototype.getAppContext=function(t,n,r){var o,i=this;o=this._hostInfo.isDialog?e.WebView.PopupMessageHandlerName:e.WebView.MessageHandlerName,e.ScriptMessaging.GetScriptMessenger().invokeMethod(o,e.WebView.MethodId.GetContext,[],(function(t){var r,o=e.Webkit.AppContextProperties,a=t[o.AppType],s=t[o.Settings];if(s&&2===s.length)for(var c=s[0],u=s[1],l=0;l<c.length;l++)i._serializedSettings[c[l]]=u[l];var f=t[o.SolutionReferenceId],p=t[o.MajorVersion],d=t[o.MinorVersion],h=t[o.AppCapabilities],g=t[o.APPUILocale],m=t[o.AppDataLocale],y=t[o.DocumentUrl],v=t[o.ActivationMode],_=t[o.ControlIntegrationLevel],b=t[o.SolutionToken];b=b?b.toString():"";var O=t[o.CorrelationId],S=t[o.InstanceId],C=t[o.TouchEnabled],I=t[o.CommerceAllowed],A=t[o.RequirementMatrix],P=t[o.HostCustomMessage],E=t[o.HostFullVersion],R=t[o.InitialDisplayMode];r=new e.OfficeAppContext(f,a,p,g,m,y,h,(function(){return i._serializedSettings}),v,_,b,O,S,C,I,d,A,P,E,void 0,void 0,void 0,void 0,void 0,void 0,void 0,R,void 0,void 0,void 0,!1,void 0,void 0,void 0),n(r)}))},n.prototype.createClientHostController=function(){return this._clientHostController||(this._clientHostController=new e.WebView.WebViewHostController(e.ScriptMessaging.GetScriptMessenger())),this._clientHostController},n.prototype.createAsyncMethodExecutor=function(){return new e.SafeArrayAsyncMethodExecutor(this.createClientHostController())},n.prototype.createClientSettingsManager=function(){return new e.WebViewClientSettingsManager(this,e.ScriptMessaging.GetScriptMessenger())},n}(e.InitializationHelper);e.WebViewInitializationHelper=t}(OSF||(OSF={})),function(e){var t;!function(e){!function(e){e[e.MethodCallback=0]="MethodCallback",e[e.EventCallback=1]="EventCallback"}(e.CallbackType||(e.CallbackType={}));var t=function(e,t,n){this.callbackType=e,this.callbackId=t,this.params=n};e.CallbackData=t}(t||(t={})),function(n){var r=function(){function n(){}return n.getInstance=function(){return null==n.uniqueInstance&&(n.uniqueInstance=new n),n.uniqueInstance},n.prototype.postMessage=function(e,t){agaveHost.postMessage(t)},n.prototype.ReceiveMessage=function(n){switch(n.callbackType){case t.CallbackType.MethodCallback:e.WebView.ScriptMessaging.agaveHostCallback(n.callbackId,n.params);break;case t.CallbackType.EventCallback:e.WebView.ScriptMessaging.agaveHostEventCallback(n.callbackId,n.params)}},n}();n.Poster=r}(e.Android||(e.Android={})),function(n){var r=function(){function n(){window.addEventListener("message",this.OnReceiveMessage.bind(this))}return n.prototype.postMessage=function(e,t){window.parent.postMessage(t,"*")},n.prototype.OnReceiveMessage=function(n){if(n.source==window.parent&&window.parent==window.top&&n.origin.startsWith("ms-appx-web://")){var r;try{r=JSON.parse(n.data)}catch(e){return}switch(r.callbackType){case t.CallbackType.MethodCallback:e.WebView.ScriptMessaging.agaveHostCallback(r.callbackId,JSON.parse(r.params));break;case t.CallbackType.EventCallback:e.WebView.ScriptMessaging.agaveHostEventCallback(r.callbackId,JSON.parse(r.params))}}},n}();n.Poster=r}(e.WinRT||(e.WinRT={}))}(OSF||(OSF={})),function(e){!function(t){!function(t){var n=null;t.agaveHostCallback=function(e,t){n.agaveHostCallback(e,t)},t.agaveHostEventCallback=function(e,t){n.agaveHostEventCallback(e,t)},t.GetScriptMessenger=function(){if(null==n){var t=e._OfficeAppFactory.getHostInfo().hostPlatform;if(t===e.HostInfoPlatform.android)n=new o("OSF.ScriptMessaging.agaveHostCallback","OSF.ScriptMessaging.agaveHostEventCallback",e.Android.Poster.getInstance());else{if(t!==e.HostInfoPlatform.winrt)throw e.Utility.createNotImplementedException();n=new o("agaveHostCallback","agaveHostEventCallback",new e.WinRT.Poster)}}return n};var r=function(e,t,n){this.id=e,this.targetId=t,this.handler=n},o=function(){function e(t,n,r){this.callingIndex=0,this.callbackList={},this.eventHandlerList={},this.asyncMethodCallbackFunctionName=t,this.eventCallbackFunctionName=n,this.poster=r,this.conversationId=e.getCurrentTimeMS().toString()}return e.prototype.invokeMethod=function(e,t,n,r){this.postMessage({},e,t,n,r)},e.prototype.registerEvent=function(e,t,n,o,i,a){var s={eventCallbackFunction:this.eventCallbackFunctionName},c={id:n,targetId:o},u=this.postMessage(s,e,t,c,a);this.eventHandlerList[u]=new r(n,o,i)},e.prototype.unregisterEvent=function(e,t,n,r,o){var i={id:n,targetId:r};for(var a in this.eventHandlerList)if(this.eventHandlerList.hasOwnProperty(a)){var s=this.eventHandlerList[a];s.id==n&&s.targetId==r&&delete this.eventHandlerList[a]}this.invokeMethod(e,t,i,o)},e.prototype.agaveHostCallback=function(e,t){var n=this.callbackList[e];if(n){var r=n(t);void 0!==r&&!0!==r||delete this.callbackList[e]}},e.prototype.agaveHostEventCallback=function(e,t){var n=this.eventHandlerList[e];n&&n.handler(t)},e.prototype.postMessage=function(e,t,n,r,o){var i=this.generateCorrelationId();return this.callbackList[i]=o,e.methodId=n,e.params=r,e.callbackId=i,e.callbackFunction=this.asyncMethodCallbackFunctionName,this.poster.postMessage(t,JSON.stringify(e)),i},e.prototype.generateCorrelationId=function(){return++this.callingIndex,this.conversationId+this.callingIndex},e.getCurrentTimeMS=function(){return(new Date).getTime()},e.MESSAGE_TIME_DELTA=10,e}()}(t.ScriptMessaging||(t.ScriptMessaging={}))}(e.WebView||(e.WebView={}))}(OSF||(OSF={})),function(e){var t=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),n.prototype.messageParent=function(t){if(e.Utility.externalNativeFunctionExists(typeof window.external.MessageParent2))"undefined"!=typeof OsfOMToken&&OsfOMToken?window.external.MessageParent2(JSON.stringify(t),OsfOMToken):window.external.MessageParent2(JSON.stringify(t));else{var n=t[e.ParameterNames.MessageToParent];window.external.MessageParent(n)}},n.prototype.openDialog=function(e,t,n,r,o){this.registerEvent(e,t,n,r,o)},n.prototype.closeDialog=function(e,t,n,r){this.unregisterEvent(e,t,n,r)},n.prototype.sendMessage=function(t){if(e.Utility.externalNativeFunctionExists(typeof window.external.MessageChild2))"undefined"!=typeof OsfOMToken&&OsfOMToken?window.external.MessageChild2(JSON.stringify(t),OsfOMToken):window.external.MessageChild2(JSON.stringify(t));else{var n=t[e.ParameterNames.MessageContent];window.external.MessageChild(n)}},n.prototype.closeSdxDialog=function(t){e.Utility.externalNativeFunctionExists(typeof window.external.closeSdxDialog)&&window.external.closeSdxDialog(t)},n.prototype.resizeSdxDialog=function(t,n){e.Utility.externalNativeFunctionExists(typeof window.external.resizeSdxDialog)&&window.external.resizeSdxDialog(t,n)},n}(e.RichClientHostController);e.Win32RichClientHostController=t}(OSF||(OSF={})),function(e){var t=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),n.prototype.openDialog=function(t,r,o,i,a){if(!n.popup||n.popup.closed){window.dialogAPIErrorCode=void 0;var s=JSON.parse(o),c=s.url;if(c){var u=c.split("#"),l="?";u[0].indexOf("?")>-1&&(l="&");var f="width="+screen.width*s.width/100+", height="+screen.height*s.height/100;u[0]=u[0].concat(l).concat("action=displayDialog");var p=u.join("#");if(n.popup=window.open(p,"",f),n.DialogEventListener=function(r){if(r.source==n.popup)try{var o=JSON.parse(r.data);o.dialogMessage&&i(t,[0,o.dialogMessage.messageContent])}catch(t){e.Utility.trace("messages received cannot be handlered. Message:"+r.data)}},null!=n.popup&&null==window.dialogAPIErrorCode)window.addEventListener("message",n.DialogEventListener),n.interval=window.setInterval((function(){try{(null==n.popup||n.popup.closed)&&(window.clearInterval(n.interval),window.removeEventListener("message",n.DialogEventListener),n.NotifyError=null,i(t,[12006]))}catch(t){e.Utility.trace("Error happened when popup window closed.")}}),500),n.NotifyError=function(e){i(t,[e])},a(0);else{var d=5001;window.dialogAPIErrorCode&&(d=window.dialogAPIErrorCode),a(d)}}else a(12003)}else a(12007)},n.prototype.messageParent=function(t){var n={dialogMessage:{messageType:0,messageContent:t[e.ParameterNames.MessageToParent]}};window.opener.postMessage(JSON.stringify(n),window.location.origin)},n.prototype.closeDialog=function(e,t,r,o){n.popup?(n.interval&&window.clearInterval(n.interval),n.popup.close(),n.popup=null,window.removeEventListener("message",n.DialogEventListener),n.NotifyError=null,o(0)):o(5001)},n}(e.Webkit.WebkitHostController);e.MacRichClientHostController=t}(OSF||(OSF={})),function(e){var t;!function(e){!function(e){e.Init=function(){return function(){"use strict";function e(e){return"function"==typeof e}var t,n=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},r=0,o=function(e,n){p[r]=e,p[r+1]=n,2===(r+=2)&&(t?t(d):c())};var i=("undefined"!=typeof window?window:void 0)||{},a=(i.MutationObserver||i.WebKitMutationObserver,"undefined"!=typeof process&&"[object process]"==={}.toString.call(process)),s="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;var c,u,l,f,p=new Array(1e3);function d(){for(var e=0;e<r;e+=2){(0,p[e])(p[e+1]),p[e]=void 0,p[e+1]=void 0}r=0}function h(){}a?(l=process.nextTick,f=process.versions.node.match(/^(?:(\d+)\.)?(?:(\d+)\.)?(\*|\d+)$/),Array.isArray(f)&&"0"===f[1]&&"10"===f[2]&&(l=setImmediate),c=function(){l(d)}):s?((u=new MessageChannel).port1.onmessage=d,c=function(){u.port2.postMessage(0)}):c=function(){setTimeout(d,1)};var g=void 0,m=new I;function y(t,n){if(n.constructor===t.constructor)!function(e,t){1===t._state?b(e,t._result):2===t._state?O(e,t._result):S(t,void 0,(function(t){v(e,t)}),(function(t){O(e,t)}))}(t,n);else{var r=function(e){try{return e.then}catch(e){return m.error=e,m}}(n);r===m?O(t,m.error):void 0===r?b(t,n):e(r)?function(e,t,n){o((function(e){var r=!1,o=function(e,t,n,r){try{e.call(t,n,r)}catch(e){return e}}(n,t,(function(n){r||(r=!0,t!==n?v(e,n):b(e,n))}),(function(t){r||(r=!0,O(e,t))}),e._label);!r&&o&&(r=!0,O(e,o))}),e)}(t,n,r):b(t,n)}}function v(e,t){var n;e===t?O(e,new TypeError("You cannot resolve a promise with itself")):"function"==typeof(n=t)||"object"==typeof n&&null!==n?y(e,t):b(e,t)}function _(e){e._onerror&&e._onerror(e._result),C(e)}function b(e,t){e._state===g&&(e._result=t,e._state=1,0!==e._subscribers.length&&o(C,e))}function O(e,t){e._state===g&&(e._state=2,e._result=t,o(_,e))}function S(e,t,n,r){var i=e._subscribers,a=i.length;e._onerror=null,i[a]=t,i[a+1]=n,i[a+2]=r,0===a&&e._state&&o(C,e)}function C(e){var t=e._subscribers,n=e._state;if(0!==t.length){for(var r,o,i=e._result,a=0;a<t.length;a+=3)r=t[a],o=t[a+n],r?P(n,r,o,i):o(i);e._subscribers.length=0}}function I(){this.error=null}var A=new I;function P(t,n,r,o){var i,a,s,c,u=e(r);if(u){if((i=function(e,t){try{return e(t)}catch(e){return A.error=e,A}}(r,o))===A?(c=!0,a=i.error,i=null):s=!0,n===i)return void O(n,new TypeError("A promises callback cannot return that same promise."))}else i=o,s=!0;n._state!==g||(u&&s?v(n,i):c?O(n,a):1===t?b(n,i):2===t&&O(n,i))}function E(e,t){var n=this;n._instanceConstructor=e,n.promise=new e(h),n._validateInput(t)?(n._input=t,n.length=t.length,n._remaining=t.length,n._init(),0===n.length?b(n.promise,n._result):(n.length=n.length||0,n._enumerate(),0===n._remaining&&b(n.promise,n._result))):O(n.promise,n._validationError())}E.prototype._validateInput=function(e){return n(e)},E.prototype._validationError=function(){return new Error("Array Methods must be provided an Array")},E.prototype._init=function(){this._result=new Array(this.length)};var R=E;E.prototype._enumerate=function(){for(var e=this,t=e.length,n=e.promise,r=e._input,o=0;n._state===g&&o<t;o++)e._eachEntry(r[o],o)},E.prototype._eachEntry=function(e,t){var n,r=this,o=r._instanceConstructor;"object"==typeof(n=e)&&null!==n?e.constructor===o&&e._state!==g?(e._onerror=null,r._settledAt(e._state,t,e._result)):r._willSettleAt(o.resolve(e),t):(r._remaining--,r._result[t]=e)},E.prototype._settledAt=function(e,t,n){var r=this,o=r.promise;o._state===g&&(r._remaining--,2===e?O(o,n):r._result[t]=n),0===r._remaining&&b(o,r._result)},E.prototype._willSettleAt=function(e,t){var n=this;S(e,void 0,(function(e){n._settledAt(1,t,e)}),(function(e){n._settledAt(2,t,e)}))};var T=function(e){return new R(this,e).promise};var w=function(e){var t=new this(h);if(!n(e))return O(t,new TypeError("You must pass an array to race.")),t;var r=e.length;function o(e){v(t,e)}function i(e){O(t,e)}for(var a=0;t._state===g&&a<r;a++)S(this.resolve(e[a]),void 0,o,i);return t};var x=function(e){if(e&&"object"==typeof e&&e.constructor===this)return e;var t=new this(h);return v(t,e),t};var N=function(e){var t=new this(h);return O(t,e),t},D=0;var k=F;function F(t){this._id=D++,this._state=void 0,this._result=void 0,this._subscribers=[],h!==t&&(e(t)||function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof F||function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}(),function(e,t){try{t((function(t){v(e,t)}),(function(t){O(e,t)}))}catch(t){O(e,t)}}(this,t))}return F.all=T,F.race=w,F.resolve=x,F.reject=N,F._setScheduler=function(e){t=e},F._setAsap=function(e){o=e},F._asap=o,F.prototype={constructor:F,then:function(e,t){var n=this,r=n._state;if(1===r&&!e||2===r&&!t)return this;var i=new this.constructor(h),a=n._result;if(r){var s=arguments[r-1];o((function(){P(r,i,s,a)}))}else S(n,i,e,t);return i},catch:function(e){return this.then(null,e)}},k}.call(this)}}(e.PromiseImpl||(e.PromiseImpl={}))}(e._Internal||(e._Internal={})),function(e){e.OfficePromise=function(){if("undefined"==typeof window&&"function"==typeof Promise)return Promise;if("undefined"!=typeof window){if(window.Promise)return window.Promise;var t=e.PromiseImpl.Init();return window.Promise=t,t}}()}(t=e._Internal||(e._Internal={})),e.OfficePromise=t.OfficePromise,e.Promise=e.OfficePromise}(Office||(Office={})),function(e){!function(t){var n,r=e.OUtil.Guid.generateNewGuid(),o=new RegExp("^https?://store\\.office(ppe|-int)?\\.com/","i"),i=!1,a="PRIVATE";t.enableTelemetry=!0;var s=function(){};t.AppInfo=s;var c=function(){function t(){this.clientIDKey="Office API client",this.logIdSetKey="Office App Log Id Set"}return t.prototype.getClientId=function(){var t=this.getValue(this.clientIDKey);return(!t||t.length<=0||t.length>40)&&(t=e.OUtil.Guid.generateNewGuid(),this.setValue(this.clientIDKey,t)),t},t.prototype.getValue=function(t){var n=e.OUtil.getLocalStorage(),r="";return n&&(r=n.getItem(t)),r},t.prototype.setValue=function(t,n){var r=e.OUtil.getLocalStorage();r&&r.setItem(t,n)},t}();function u(e){return e&&(e=e.replace(/[{}]/g,"").toLowerCase()),e||""}function l(e){try{return JSON.parse(e)}catch(t){return e}}function f(){n&&(i||OTel.OTelLogger.onTelemetryLoaded((function(){var t=[],r=n.isMos?1:0;t=t.concat([oteljs.makeStringDataField("Browser",n.browser),oteljs.makeInt64DataField("AppSizeWidth",window.innerWidth),oteljs.makeInt64DataField("AppSizeHeight",window.innerHeight),oteljs.makeInt64DataField("IsMOS",r)]),e.OUtil.isChangeGateEnabled("Microsoft.Office.SharedOnline.ChangeGate.OfficeVSO_10045620_CopilotAgentTelSettings")&&n.launchSource&&n.launchReason&&(t.push(oteljs.makeStringDataField("LaunchSource",n.launchSource)),t.push(oteljs.makeStringDataField("LaunchReason",n.launchReason))),Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.AppActivatedX",dataFields:t,eventFlags:{dataCategories:2,diagnosticLevel:110,samplingPolicy:191}})})))}function p(e,t){}function d(){var t=0!=(e._OfficeAppFactory.getHostInfo().flags&e.HostInfoFlags.PublicAddin);return t||!!n&&g(e._OfficeAppFactory.getHostInfo().hostPlatform,n.hostVersion)}function h(e,t){return d()||t!==e?t:a}function g(t,n){var r=!1,o=/^(\d+)\.(\d+)\.(\d+)\.(\d+)$/.exec(n);if(o){var i=parseInt(o[1]),a=parseInt(o[2]),s=parseInt(o[3]);t==e.HostInfoPlatform.win32?(i<16||16==i&&s<14225)&&(r=!0):t==e.HostInfoPlatform.mac&&(i<16||16==i&&(a<52||52==a&&s<808))&&(r=!0)}return r}function m(){return 0!=(e._OfficeAppFactory.getHostInfo().flags&e.HostInfoFlags.IsMos)}t.initialize=function(f){if(t.enableTelemetry&&!n){n=new s,f.get_hostFullVersion()?n.hostVersion=f.get_hostFullVersion():n.hostVersion=f.get_appVersion(),n.appId=d()?f.get_id():a,n.marketplaceType=f._marketplaceType,n.host=""+f.get_appName(),n.browser=window.navigator.userAgent,n.correlationId=u(f.get_correlationId()),n.clientId=(new c).getClientId(),n.appInstanceId=f.get_appInstanceId(),n.appInstanceId&&(n.appInstanceId=u(n.appInstanceId),n.appInstanceId=h(f.get_id(),n.appInstanceId)),n.message=f.get_hostCustomMessage(),n.officeJSVersion=e.ConstantNames.FileVersion,n.hostJSVersion="NA",f._wacHostEnvironment&&(n.wacHostEnvironment=f._wacHostEnvironment);var p=f.get_isFromWacAutomation();null!=p&&(n.isFromWacAutomation=p.toString().toLowerCase());var g=f.get_docUrl();n.docUrl=o.test(g)?g:"";var y=location.href;if(y&&(n.isPreload=-1!==y.indexOf("preload=1"),y=y.split("?")[0].split("#")[0]),n.isMos=m(),e.OUtil.isChangeGateEnabled("Microsoft.Office.SharedOnline.ChangeGate.OfficeVSO_10045620_CopilotAgentTelSettings")){var v=f.get_settingsFunc()();v&&v.LaunchSource&&v.LaunchReason&&(n.launchSource=l(v.LaunchSource),n.launchReason=l(v.LaunchReason))}!function(t,n){n.assetId="",n.userId="";try{if(!e.Utility.isNullOrEmpty(t)){var r=decodeURIComponent(t),o=new DOMParser,i=void 0;if(e.LoadScriptHelper.trustedTypesOptIn()&&window.trustedTypes&&window.trustedTypes.createPolicy)i=window.trustedTypes.createPolicy("officejs-domparser",{createHTML:function(e){return e}}).createHTML(r);else i=r;var a=o.parseFromString(i,"text/xml"),s=a.getElementsByTagName("t")[0].attributes.getNamedItem("cid"),c=a.getElementsByTagName("t")[0].attributes.getNamedItem("oid");s&&s.nodeValue?n.userId=s.nodeValue:c&&c.nodeValue&&(n.userId=c.nodeValue),n.assetId=a.getElementsByTagName("t")[0].attributes.getNamedItem("aid").nodeValue}}catch(e){}}(f.get_eToken(),n),n.sessionId=r,OTel.OTelLogger.initialize(n),n.isPreload?(i=!0,function(){try{Microsoft.Office.WebExtension.onReadyInternal().then((function(){var t=Office,n=OfficeCore;t.addin&&t.addin.onVisibilityModeChanged&&t.addin.onVisibilityModeChanged((function(n){n.visibilityMode===t.VisibilityMode.taskpane&&e.AppTelemetry.CallOnAppActivatedIfPending()})),t.addin&&t.addin._getState&&t.addin._getState().then((function(t){n.AppRuntimeState&&t===n.AppRuntimeState.visible&&e.AppTelemetry.CallOnAppActivatedIfPending()}))}))}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception happens at registerVisibilityEventOnPreload"+t)}}()):t.onAppActivated()}},t.onAppActivated=f,t.onScriptDone=function(e,t,n,r){},t.onCallDone=function(e,t,n,r,o){},t.onMethodDone=function(e,t,n,r){},t.onPropertyDone=function(t,n){e.AppTelemetry.onCallDone("property",-1,t,n,0)},t.onCheckWACHost=function(e,t,n,r,o){},t.onEventDone=function(t,n){e.AppTelemetry.onCallDone("event",t,null,0,n)},t.onRegisterDone=function(t,n,r,o){e.AppTelemetry.onCallDone(t?"registerevent":"unregisterevent",n,null,r,o)},t.onAppClosed=function(e,t){},t.setOsfControlAppCorrelationId=function(e){u(e)},t.doAppInitializationLogging=p,t.logAppCommonMessage=function(e){},t.logAppException=function(e){},t.CallOnAppActivatedIfPending=function(){i&&(i=!1,f())},t.canSendAddinId=d,t.getCompliantAppInstanceId=h,t._isComplianceExceptedHost=g,t.isMos=m}(e.AppTelemetry||(e.AppTelemetry={}))}(OSF||(OSF={})),function(e){var t=function(){function t(){}return t.loaded=function(){return!(void 0===t.logger)},t.create=function(t){var n,r={id:t.appId,marketplaceType:t.marketplaceType,assetId:t.assetId,officeJsVersion:t.officeJSVersion,hostJsVersion:t.hostJSVersion,browserToken:t.clientId,instanceId:t.appInstanceId,sessionId:t.sessionId},o=oteljs.Contracts.Office.System.SDX.getFields("SDX",r);if("web"===OSF._OfficeAppFactory.getHostInfo().hostPlatform)n=new e.SdxWacSink;else{if(!Office.context.requirements.isSetSupported("Telemetry","1.2"))return console.error("Cannot create telemetry sink successfully"),null;n=new e.RichApiSink,this.richApiSink=n}var i=new oteljs.SimpleTelemetryLogger(void 0,o);return i.addSink(n),i.setTenantToken("Office.Extensibility.OfficeJs","db334b301e7b474db5e0f02f07c51a47-a1b5bc36-1bbe-482f-a64a-c2d9cb606706-7439",1755),oteljs.onNotification().addListener((function(e){OSF.Utility.debugLog(e.message())})),i},t.checkAndResolvePromises=function(){t.loaded()&&(t.promises.forEach((function(e){e()})),t.promises=[])},t.initialize=function(e){t.Enabled?Office.onReadyInternal().then((function(){t.loaded()||(OSF.Utility.debugLog("Creating OTelLogger"),t.logger=t.create(e),t.checkAndResolvePromises())})):t.promises=[]},t.sendTelemetryEvent=function(e){t.onTelemetryLoaded((function(){try{t.logger.sendTelemetryEvent(e)}catch(e){console.error("Cannot send telemetry event: "+JSON.stringify(e))}}))},t.sendNonStandardEvent=function(e,n){t.onTelemetryLoaded((function(){try{t.logger.sendNonStandardEvent(e,n)}catch(e){console.error("Cannot send telemetry event: "+JSON.stringify(e))}}))},t.flushTelemetryQueue=function(){var e=this;return new Office.Promise((function(n){t.onTelemetryLoaded((function(){e.richApiSink?e.richApiSink.flushTelemetryQueue().then((function(){n()})):n()}))}))},t.onTelemetryLoaded=function(e){t.Enabled&&(t.loaded()?e():t.promises.push(e))},t.promises=[],t.Enabled=!0,t}();e.OTelLogger=t}(OTel||(OTel={})),function(e){var t=function(){function e(){var e=this;this._requestIsPending=!0,this._telemetryQueue=[],this.pause(1e3).then((function(){var t=e._telemetryQueue;e._telemetryQueue=[],e._requestIsPending=!1,e.processTelemetryEvents(t)}))}return e.prototype.sendTelemetryEvent=function(e){this._telemetryQueue.push([e,1]),this._requestIsPending||this.processWorkBacklog()},e.prototype.sendNonStandardEvent=function(e,t){this._telemetryQueue.push([e,t]),this._requestIsPending||this.processWorkBacklog()},e.prototype.flushTelemetryQueue=function(){var e=this;return new Office.Promise((function(t){var n=e._telemetryQueue;e._telemetryQueue=[],e.processTelemetryEvents(n).then((function(){t()}))}))},e.prototype.processWorkBacklog=function(){var e=this;this._requestIsPending=!0;var t=this._telemetryQueue;this._telemetryQueue=[],this.processTelemetryEvents(t).then(this.waitAndProcessMore.bind(this)).catch((function(t){oteljs.logError(1,"RichApiSink Error",t),e.waitAndProcessMore.bind(e)()}))},e.prototype.waitAndProcessMore=function(){var e=this;this.pause(1e3).then((function(){e._telemetryQueue.length>0&&setTimeout((function(){return e.processWorkBacklog()}),0),e._requestIsPending=!1})).catch((function(){}))},e.prototype.processTelemetryEvents=function(e){var t=this,n=new OfficeCore.RequestContext;return e.forEach((function(e){var r=e[0],o=e[1];if(r.telemetryProperties){var i=[];t.addDataFields(i,r.dataFields);var a=r.eventContract?r.eventContract.name:"";r.eventContract&&t.addDataFields(i,r.eventContract.dataFields),1===o?n.telemetry.sendTelemetryEvent(r.telemetryProperties,r.eventName,a,oteljs.getEffectiveEventFlags(r),i):n.telemetry.sendNonStandardEvent(r.telemetryProperties,r.eventName,a,oteljs.getEffectiveEventFlags(r),i,o)}})),n.sync().catch((function(){oteljs.logNotification(2,1,(function(){return"RichApi telemetry call failed."}))}))},e.prototype.addDataFields=function(e,t){t&&t.forEach((function(t){e.push({name:t.name,value:t.value,classification:t.classification?t.classification:4,type:t.dataType})}))},e.prototype.pause=function(e){return new Office.Promise((function(t){return setTimeout(t,e)}))},e}();e.RichApiSink=t}(OTel||(OTel={})),function(e){var t=function(){function e(){}return e.prototype.sendTelemetryEvent=function(e,t){try{if(e.dataFields&&e.dataFields.filter((function(e){var t=e.classification;return t&&4!==t&&1!==t})).length>0)return;var n=OSF._OfficeAppFactory.getId(),r=OSF.AgaveHostAction.SendTelemetryEvent;OSF.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n,r,e])}catch(e){oteljs.logError(1,"AgaveWacSink",e)}},e.prototype.sendNonStandardEvent=function(e,t){try{if(1===t)throw new Error("Please call sendTelemetryEvent for events of type "+t);if(e.dataFields&&e.dataFields.filter((function(e){var t=e.classification;return t&&4!==t&&1!==t&&32!==t&&2048!==t})).length>0)return;var n=OSF._OfficeAppFactory.getId(),r=OSF.AgaveHostAction.SendNonStandardEvent;OSF.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n,r,e])}catch(e){oteljs.logError(1,"AgaveWacSink",e)}},e}();e.SdxWacSink=t}(OTel||(OTel={})),function(e){var t,n=[];function r(e,t,n){OTel.OTelLogger.onTelemetryLoaded((function(){Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.AddinSpecialPermissionRequest",dataFields:[oteljs.makeStringDataField("invocationId",e),oteljs.makeStringDataField("methodPath",t),oteljs.makeStringDataField("params",n)],eventFlags:{dataCategories:2,diagnosticLevel:110}})}))}function o(e,t,n){OTel.OTelLogger.onTelemetryLoaded((function(){Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.AddinSpecialPermissionResponse",dataFields:[oteljs.makeStringDataField("invocationId",e),oteljs.makeBooleanDataField("isSuccessful",t),oteljs.makeStringDataField("error",n?JSON.stringify({name:n.name,code:n.code,message:n.message}):void 0)],eventFlags:{dataCategories:2,diagnosticLevel:110}})}))}try{for(var i=0,a=function(e){var t=Navigator.prototype[e];t&&(Navigator.prototype[e]=function(n,a,s){if(3===arguments.length&&Function.prototype.isPrototypeOf(a)&&Function.prototype.isPrototypeOf(s)){var c=(i++).toString();return r(c,"Navigator.prototype."+e,JSON.stringify([{audio:!!n.audio,video:!!n.video}])),t.apply(this,[n,function(){return o(c,!0),a.apply(this,arguments)},function(){return o(c,!1,arguments[0]),s.apply(this,arguments)}])}return t.apply(this,arguments)},n.push("Navigator.prototype."+e))},s=0,c=["getUserMedia","webkitGetUserMedia","mozGetUserMedia"];s<c.length;s++){a(c[s])}var u=MediaDevices.prototype.getUserMedia;u&&(MediaDevices.prototype.getUserMedia=function(e){var t=(i++).toString();return 1===arguments.length&&void 0!==e?(r(t,"MediaDevices.prototype.getUserMedia",JSON.stringify([{audio:!!e.audio,video:!!e.video}])),u.apply(this,arguments).then((function(){return o(t,!0),arguments[0]}),(function(){throw o(t,!1,arguments[0]),arguments[0]}))):u.apply(this,arguments)},n.push("MediaDevices.prototype.getUserMedia"));for(var l=function(e){var t=Geolocation.prototype[e];t&&(Geolocation.prototype[e]=function(n,a,s){for(var c=[],u=3;u<arguments.length;u++)c[u-3]=arguments[u];var l=(i++).toString(),f=!1;r(l,"Geolocation.prototype."+e,JSON.stringify([]));var p=Function.prototype.isPrototypeOf(n)?function(){return f||(o(l,!0),f=!0),n.apply(this,arguments)}:n,d=Function.prototype.isPrototypeOf(a)?function(){return f||(o(l,!1,arguments[0]),f=!0),a.apply(this,arguments)}:a;return t.apply(this,[p,d,s].concat(c))},n.push("Geolocation.prototype."+e))},f=0,p=["getCurrentPosition","watchPosition"];f<p.length;f++){l(p[f])}}catch(e){t=e.toString()}OTel.OTelLogger.onTelemetryLoaded((function(){Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.AddinSpecialPermissionHookInstall",dataFields:[oteljs.makeStringDataField("hooksInstalled",JSON.stringify(n)),oteljs.makeStringDataField("error",t)],eventFlags:{dataCategories:2,diagnosticLevel:110}})}))}(Office||(Office={})),function(e){!function(e){!function(e){e.FeatureGates={},e.EventType=OSF.EventType,e.sendTelemetryEvent=function(e){OTel.OTelLogger.sendTelemetryEvent(e)},e.sendNonStandardEvent=function(e,t){OTel.OTelLogger.sendNonStandardEvent(e,t)},e.flushTelemetryQueue=function(){return OTel.OTelLogger.flushTelemetryQueue()},e.telemetrySink=OTel.OTelLogger}(e.WebExtension||(e.WebExtension={}))}(e.Office||(e.Office={}))}(Microsoft||(Microsoft={})),function(e){e.sendTelemetryEvent=function(e){Microsoft.Office.WebExtension.sendTelemetryEvent(e)},e.sendNonStandardEvent=function(e,t){Microsoft.Office.WebExtension.sendNonStandardEvent(e,t)},e.flushTelemetryQueue=function(){return Microsoft.Office.WebExtension.flushTelemetryQueue()},e.telemetrySink=Microsoft.Office.WebExtension.telemetrySink,e.isTrustedHost=function(){return __awaiter(this,void 0,void 0,(function(){var t,n,r;return __generator(this,(function(o){switch(o.label){case 0:return o.trys.push([0,6,,7]),OSF._OfficeAppFactory.getHostInfo().hostPlatform===OSF.HostInfoPlatform.web?[3,2]:[4,e.onReady()];case 1:return o.sent(),[2,!0];case 2:return null!=(t=OSF._OfficeAppFactory.getWebAppState().clientEndPoint)&&t.fHostTrusted||null!=document.referrer&&(n=OSF.OUtil.parseUrl(document.referrer,!1),"https:"==n.protocol&&OSF.XdmCommunicationManager.isHostNameValidWacDomain(n.hostname)&&!new RegExp("^"+document.domain.replace(new RegExp("\\.","g"),"\\.")+"$").test(n.hostname))?[2,!0]:null==t?[3,4]:[4,OSF.Utility.promisify((function(e){t.invoke("ContextActivationManager_getAppContextAsync",e,OSF._OfficeAppFactory.getWebAppState().id)}),1e4)];case 3:return o.sent(),[2,!0];case 4:return[2,!1];case 5:return[3,7];case 6:return r=o.sent(),OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("Exception happens at Office.isTrustedHost."+r),[2,!1];case 7:return[2]}}))}))},Microsoft.Office.WebExtension.onReadyInternal=e.onReadyInternal}(Office||(Office={}));var OfficeExtension;__extends=this&&this.__extends||function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();!function(e){var t;!function(e){e.graph="graph",e.wfe="wfe"}(t=e.RemoteEndpointType||(e.RemoteEndpointType={}));var n=function(){function e(){}return e.prototype._resolveRequestUrlAndHeaderInfo=function(){return l._createPromiseFromResult(null)},e.prototype._createRequestExecutorOrNull=function(){return null},e.prototype.getEventRegistration=function(e){return null},e}();e.SessionBase=n;var r=function(){function e(){}return e.setCustomSendRequestFunc=function(t){e.s_customSendRequestFunc=t},e.xhrSendRequestFunc=function(e){return l.createPromise((function(t,n){var r=new XMLHttpRequest;if(r.open(e.method,e.url),r.onload=function(){var e={statusCode:r.status,headers:l._parseHttpResponseHeaders(r.getAllResponseHeaders()),body:r.responseText};t(e)},r.onerror=function(){n(new o.RuntimeError({code:a.connectionFailure,httpStatusCode:r.status,message:l._getResourceString(s.connectionFailureWithStatus,r.statusText)}))},e.headers)for(var i in e.headers)r.setRequestHeader(i,e.headers[i]);r.send(l._getRequestBodyText(e))}))},e.fetchSendRequestFunc=function(e){var t=l._getRequestBodyText(e);return""===t&&(t=void 0),fetch(e.url,{method:e.method,headers:e.headers,body:t}).then((function(e){return e.text().then((function(t){var n=e.status,r={};return e.headers.forEach((function(e,t){r[t]=e})),{statusCode:n,headers:r,body:t}}))}))},e.sendRequest=function(t){e.validateAndNormalizeRequest(t);var n=e.s_customSendRequestFunc;return n||(n="undefined"!=typeof fetch?e.fetchSendRequestFunc:e.xhrSendRequestFunc),n(t)},e.setCustomSendLocalDocumentRequestFunc=function(t){e.s_customSendLocalDocumentRequestFunc=t},e.sendLocalDocumentRequest=function(t){return e.validateAndNormalizeRequest(t),(e.s_customSendLocalDocumentRequestFunc||e.officeJsSendLocalDocumentRequestFunc)(t)},e.officeJsSendLocalDocumentRequestFunc=function(e){e=l._validateLocalDocumentRequest(e);var t=l._buildRequestMessageSafeArray(e);return l.createPromise((function(e,n){OSF.DDA.RichApi.executeRichApiRequestAsync(t,(function(t){var n;n="succeeded"==t.status?{statusCode:u.getResponseStatusCode(t),headers:u.getResponseHeaders(t),body:u.getResponseBody(t)}:u.buildHttpResponseFromOfficeJsError(t.error.code,t.error.message),l.log("Response:"),l.log(JSON.stringify(n)),e(n)}))}))},e.validateAndNormalizeRequest=function(e){if(l.isNullOrUndefined(e))throw o.RuntimeError._createInvalidArgError({argumentName:"request"});l.isNullOrEmptyString(e.method)&&(e.method="GET"),e.method=e.method.toUpperCase();var t=!1;if("object"==typeof e.headers&&e.headers[c.testRequestNameHeader]&&(t=!0),!t){var n=f._getCurrentTestNameWithSequenceId();n&&(e.headers||(e.headers={}),e.headers[c.testRequestNameHeader]=n)}},e.logRequest=function(t){if(l._logEnabled){if(l.log("---HTTP Request---"),l.log(t.method+" "+t.url),t.headers)for(var n in t.headers)l.log(n+": "+t.headers[n]);e._logBodyEnabled&&l.log(l._getRequestBodyText(t))}},e.logResponse=function(t){if(l._logEnabled){if(l.log("---HTTP Response---"),l.log(""+t.statusCode),t.headers)for(var n in t.headers)l.log(n+": "+t.headers[n]);e._logBodyEnabled&&l.log(t.body)}},e._logBodyEnabled=!1,e}();e.HttpUtility=r;var o,i=function(){function e(e){var t=this;this.m_bridge=e,this.m_promiseResolver={},this.m_handlers=[],this.m_bridge.onMessageFromHost=function(e){var n=JSON.parse(e);if(3==n.type){var r=n.message;if(r&&r.entries)for(var o=0;o<r.entries.length;o++){var i=r.entries[o];if(Array.isArray(i)){var a={messageCategory:i[0],messageType:i[1],targetId:i[2],message:i[3],id:i[4]};r.entries[o]=a}}}t.dispatchMessage(n)}}return e.init=function(t){if("object"==typeof t&&t){var n=new e(t);e.s_instance=n,r.setCustomSendLocalDocumentRequestFunc((function(t){t=l._validateLocalDocumentRequest(t);var r=0;l.isReadonlyRestRequest(t.method)||(r=1);var o=t.url.indexOf("?");if(o>=0){var i=t.url.substr(o+1),a=l._parseRequestFlagsAndCustomDataFromQueryStringIfAny(i);a.flags>=0&&(r=a.flags)}"string"==typeof t.body&&(t.body=JSON.parse(t.body));var s={id:e.nextId(),type:1,flags:r,message:t};return n.sendMessageToHostAndExpectResponse(s).then((function(e){return e.message}))}));for(var o=0;o<e.s_onInitedHandlers.length;o++)e.s_onInitedHandlers[o](n)}},Object.defineProperty(e,"instance",{get:function(){return e.s_instance},enumerable:!0,configurable:!0}),e.prototype.sendMessageToHost=function(e){this.m_bridge.sendMessageToHost(JSON.stringify(e))},e.prototype.sendMessageToHostAndExpectResponse=function(e){var t=this,n=l.createPromise((function(n,r){t.m_promiseResolver[e.id]=n}));return this.m_bridge.sendMessageToHost(JSON.stringify(e)),n},e.prototype.addHostMessageHandler=function(e){this.m_handlers.push(e)},e.prototype.removeHostMessageHandler=function(e){var t=this.m_handlers.indexOf(e);t>=0&&this.m_handlers.splice(t,1)},e.onInited=function(t){e.s_onInitedHandlers.push(t),e.s_instance&&t(e.s_instance)},e.prototype.dispatchMessage=function(e){if("number"==typeof e.id){var t=this.m_promiseResolver[e.id];if(t)return t(e),void delete this.m_promiseResolver[e.id]}for(var n=0;n<this.m_handlers.length;n++)this.m_handlers[n](e)},e.nextId=function(){return e.s_nextId++},e.s_onInitedHandlers=[],e.s_nextId=1,e}();e.HostBridge=i,"object"==typeof _richApiNativeBridge&&_richApiNativeBridge&&i.init(_richApiNativeBridge),function(e){var t=function(t){function n(e){var r=t.call(this,"string"==typeof e?e:e.message)||this;if(Object.setPrototypeOf(r,n.prototype),r.name="RichApi.Error","string"==typeof e?r.message=e:(r.code=e.code,r.message=e.message,r.traceMessages=e.traceMessages||[],r.innerError=e.innerError||null,r.debugInfo=r._createDebugInfo(e.debugInfo||{}),r.httpStatusCode=e.httpStatusCode,r.data=e.data),l.isNullOrUndefined(r.httpStatusCode)||200===r.httpStatusCode){var o={};o[a.accessDenied]=401,o[a.connectionFailure]=500,o[a.generalException]=500,o[a.invalidArgument]=400,o[a.invalidObjectPath]=400,o[a.invalidOrTimedOutSession]=408,o[a.invalidRequestContext]=400,o[a.timeout]=408,o[a.valueNotLoaded]=400,r.httpStatusCode=o[r.code]}return l.isNullOrUndefined(r.httpStatusCode)&&(r.httpStatusCode=500),r}return __extends(n,t),n.prototype.toString=function(){return this.code+": "+this.message},n.prototype._createDebugInfo=function(t){var n={code:this.code,message:this.message,toString:function(){return JSON.stringify(this)}};for(var r in t)n[r]=t[r];return this.innerError&&(this.innerError instanceof e.RuntimeError?n.innerError=this.innerError.debugInfo:n.innerError=this.innerError),n},n._createInvalidArgError=function(t){return new e.RuntimeError({code:a.invalidArgument,httpStatusCode:400,message:l.isNullOrEmptyString(t.argumentName)?l._getResourceString(s.invalidArgumentGeneric):l._getResourceString(s.invalidArgument,t.argumentName),debugInfo:t.errorLocation?{errorLocation:t.errorLocation}:{},innerError:t.innerError})},n}(Error);e.RuntimeError=t}(o=e._Internal||(e._Internal={})),e.Error=o.RuntimeError;var a=function(){function e(){}return e.apiNotFound="ApiNotFound",e.accessDenied="AccessDenied",e.generalException="GeneralException",e.activityLimitReached="ActivityLimitReached",e.invalidArgument="InvalidArgument",e.connectionFailure="ConnectionFailure",e.timeout="Timeout",e.invalidOrTimedOutSession="InvalidOrTimedOutSession",e.invalidObjectPath="InvalidObjectPath",e.invalidRequestContext="InvalidRequestContext",e.valueNotLoaded="ValueNotLoaded",e.requestPayloadSizeLimitExceeded="RequestPayloadSizeLimitExceeded",e.responsePayloadSizeLimitExceeded="ResponsePayloadSizeLimitExceeded",e.writeNotSupportedWhenModalDialogOpen="WriteNotSupportedWhenModalDialogOpen",e.undoNotSupported="UndoNotSupported",e}();e.CoreErrorCodes=a;var s=function(){function e(){}return e.apiNotFoundDetails="ApiNotFoundDetails",e.connectionFailureWithStatus="ConnectionFailureWithStatus",e.connectionFailureWithDetails="ConnectionFailureWithDetails",e.invalidArgument="InvalidArgument",e.invalidArgumentGeneric="InvalidArgumentGeneric",e.timeout="Timeout",e.invalidOrTimedOutSessionMessage="InvalidOrTimedOutSessionMessage",e.invalidSheetName="InvalidSheetName",e.invalidObjectPath="InvalidObjectPath",e.invalidRequestContext="InvalidRequestContext",e.valueNotLoaded="ValueNotLoaded",e}();e.CoreResourceStrings=s;var c=function(){function e(){}return e.flags="flags",e.sourceLibHeader="SdkVersion",e.processQuery="ProcessQuery",e.localDocument="http://document.localhost/",e.localDocumentApiPrefix="http://document.localhost/_api/",e.customData="customdata",e.testRequestNameHeader="x-test-request-name",e}();e.CoreConstants=c;var u=function(){function e(){}return e.buildMessageArrayForIRequestExecutor=function(t,n,r,o,i){var a=JSON.stringify(r.Body);l.log("Request:"),l.log(a);var s={};return l._copyHeaders(r.Headers,s),s[c.sourceLibHeader]=o,e.buildRequestMessageSafeArray(t,n,"POST",c.processQuery,s,a,i)},e.buildResponseOnSuccess=function(e,t){var n={HttpStatusCode:200,ErrorCode:"",ErrorMessage:"",Headers:null,Body:null};return n.Body=JSON.parse(e),n.Headers=t,n},e.buildResponseOnError=function(t,n){var r={HttpStatusCode:500,ErrorCode:"",ErrorMessage:"",Headers:null,Body:null};return r.ErrorCode=a.generalException,r.ErrorMessage=n,t==e.OfficeJsErrorCode_ooeNoCapability?(r.ErrorCode=a.accessDenied,r.HttpStatusCode=401):t==e.OfficeJsErrorCode_ooeActivityLimitReached?(r.ErrorCode=a.activityLimitReached,r.HttpStatusCode=429):t==e.OfficeJsErrorCode_ooeInvalidOrTimedOutSession?(r.ErrorCode=a.invalidOrTimedOutSession,r.HttpStatusCode=408,r.ErrorMessage=l._getResourceString(s.invalidOrTimedOutSessionMessage)):t==e.OfficeJsErrorCode_ooeRequestPayloadSizeLimitExceeded?(r.ErrorCode=a.requestPayloadSizeLimitExceeded,r.HttpStatusCode=400):t==e.OfficeJsErrorCode_ooeResponsePayloadSizeLimitExceeded?(r.ErrorCode=a.responsePayloadSizeLimitExceeded,r.HttpStatusCode=400):t==e.OfficeJsErrorCode_ooeWriteNotSupportedWhenModalDialogOpen?(r.ErrorCode=a.writeNotSupportedWhenModalDialogOpen,r.HttpStatusCode=400):t==e.OfficeJsErrorCode_ooeInvalidSheetName?(r.ErrorCode=a.invalidRequestContext,r.HttpStatusCode=400,r.ErrorMessage=l._getResourceString(s.invalidSheetName)):t==e.OfficeJsErrorCode_ooeUndoNotSupported&&(r.ErrorCode=a.undoNotSupported,r.HttpStatusCode=400),r},e.buildHttpResponseFromOfficeJsError=function(t,n){var r=500,o={error:{}};return o.error.code=a.generalException,o.error.message=n,t===e.OfficeJsErrorCode_ooeNoCapability?(r=403,o.error.code=a.accessDenied):t===e.OfficeJsErrorCode_ooeActivityLimitReached&&(r=429,o.error.code=a.activityLimitReached),{statusCode:r,headers:{},body:JSON.stringify(o)}},e.buildRequestMessageSafeArray=function(e,t,n,r,o,i,a){var s=[];if(o)for(var c in o)s.push(c),s.push(o[c]);return[e,n,r,s,i,0,t,"","","","","",""].concat(a?["",a]:[])},e.getResponseBody=function(t){return e.getResponseBodyFromSafeArray(t.value.data)},e.getResponseHeaders=function(t){return e.getResponseHeadersFromSafeArray(t.value.data)},e.getResponseBodyFromSafeArray=function(e){var t=e[2];return"string"==typeof t?t:t.join("")},e.getResponseHeadersFromSafeArray=function(e){var t=e[1];if(!t)return null;for(var n={},r=0;r<t.length-1;r+=2)n[t[r]]=t[r+1];return n},e.getResponseStatusCode=function(t){return e.getResponseStatusCodeFromSafeArray(t.value.data)},e.getResponseStatusCodeFromSafeArray=function(e){return e[0]},e.OfficeJsErrorCode_ooeInvalidOrTimedOutSession=5012,e.OfficeJsErrorCode_ooeActivityLimitReached=5102,e.OfficeJsErrorCode_ooeNoCapability=7e3,e.OfficeJsErrorCode_ooeRequestPayloadSizeLimitExceeded=5103,e.OfficeJsErrorCode_ooeResponsePayloadSizeLimitExceeded=5104,e.OfficeJsErrorCode_ooeWriteNotSupportedWhenModalDialogOpen=5016,e.OfficeJsErrorCode_ooeInvalidSheetName=1014,e.OfficeJsErrorCode_ooeUndoNotSupported=5017,e}();e.RichApiMessageUtility=u,function(e){e.getPromiseType=function(){if("undefined"!=typeof Promise)return Promise;if(void 0!==Office&&Office.Promise)return Office.Promise;if(void 0!==OfficeExtension&&OfficeExtension.Promise)return OfficeExtension.Promise;throw new e.Error("No Promise implementation found")}}(o=e._Internal||(e._Internal={}));var l=function(){function e(){}return e.log=function(t){e._logEnabled&&"undefined"!=typeof console&&console.log&&console.log(t)},e.checkArgumentNull=function(t,n){if(e.isNullOrUndefined(t))throw o.RuntimeError._createInvalidArgError({argumentName:n})},e.isNullOrUndefined=function(e){return null===e||void 0===e},e.isUndefined=function(e){return void 0===e},e.isNullOrEmptyString=function(e){return null===e||(void 0===e||0==e.length)},e.isPlainJsonObject=function(t){if(e.isNullOrUndefined(t))return!1;if("object"!=typeof t)return!1;if("[object Object]"!==Object.prototype.toString.apply(t))return!1;if(t.constructor&&!Object.prototype.hasOwnProperty.call(t,"constructor")&&!Object.prototype.hasOwnProperty.call(t.constructor.prototype,"hasOwnProperty"))return!1;for(var n in t)if(!Object.prototype.hasOwnProperty.call(t,n))return!1;return!0},e.trim=function(e){return e.replace(new RegExp("^\\s+|\\s+$","g"),"")},e.caseInsensitiveCompareString=function(t,n){return e.isNullOrUndefined(t)?e.isNullOrUndefined(n):!e.isNullOrUndefined(n)&&t.toUpperCase()==n.toUpperCase()},e.isReadonlyRestRequest=function(t){return e.caseInsensitiveCompareString(t,"GET")},e._getResourceString=function(t,n){var r;if("undefined"!=typeof window&&window.Strings&&window.Strings.OfficeOM){var o="L_"+t,i=window.Strings.OfficeOM[o];i&&(r=i)}if(r||(r=e.s_resourceStringValues[t]),r||(r=t),!e.isNullOrUndefined(n))if(Array.isArray(n)){var a=n;r=e._formatString(r,a)}else r=r.replace("{0}",n);return r},e._formatString=function(e,t){return e.replace(/\{\d\}/g,(function(e){var n=parseInt(e.substr(1,e.length-2));if(n<t.length)return t[n];throw o.RuntimeError._createInvalidArgError({argumentName:"format"})}))},Object.defineProperty(e,"Promise",{get:function(){return o.getPromiseType()},enumerable:!0,configurable:!0}),e.createPromise=function(t){return new e.Promise(t)},e._createPromiseFromResult=function(t){return e.createPromise((function(e,n){e(t)}))},e._createPromiseFromException=function(t){return e.createPromise((function(e,n){n(t)}))},e._createTimeoutPromise=function(t){return e.createPromise((function(e,n){setTimeout((function(){e(null)}),t)}))},e._createInvalidArgError=function(e){return o.RuntimeError._createInvalidArgError(e)},e._isLocalDocumentUrl=function(t){return e._getLocalDocumentUrlPrefixLength(t)>0},e._getLocalDocumentUrlPrefixLength=function(e){for(var t=["http://document.localhost","https://document.localhost","//document.localhost"],n=e.toLowerCase().trim(),r=0;r<t.length;r++){if(n===t[r])return t[r].length;if(n.substr(0,t[r].length+1)===t[r]+"/")return t[r].length+1}return 0},e._validateLocalDocumentRequest=function(t){var n=e._getLocalDocumentUrlPrefixLength(t.url);if(n<=0)throw o.RuntimeError._createInvalidArgError({argumentName:"request"});var r=t.url.substr(n),i=r.toLowerCase();return"_api"===i?r="":"_api/"===i.substr(0,"_api/".length)&&(r=r.substr("_api/".length)),{method:t.method,url:r,headers:t.headers,body:t.body}},e._parseRequestFlagsAndCustomDataFromQueryStringIfAny=function(e){for(var t={flags:-1,customData:""},n=e.split("&"),r=0;r<n.length;r++){var o=n[r].split("=");if(o[0].toLowerCase()===c.flags){var i=parseInt(o[1]);i&=65535,t.flags=i}else o[0].toLowerCase()===c.customData&&(t.customData=decodeURIComponent(o[1]))}return t},e._getRequestBodyText=function(e){var t="";return"string"==typeof e.body?t=e.body:e.body&&"object"==typeof e.body&&(t=JSON.stringify(e.body)),t},e._parseResponseBody=function(t){if("string"==typeof t.body){var n=e.trim(t.body);return JSON.parse(n)}return t.body},e._buildRequestMessageSafeArray=function(t){var n=0;e.isReadonlyRestRequest(t.method)||(n=1);var r="";if(t.url.substr(0,c.processQuery.length).toLowerCase()===c.processQuery.toLowerCase()){var o=t.url.indexOf("?");if(o>0){var i=t.url.substr(o+1),a=e._parseRequestFlagsAndCustomDataFromQueryStringIfAny(i);a.flags>=0&&(n=a.flags),r=a.customData}}return u.buildRequestMessageSafeArray(r,n,t.method,t.url,t.headers,e._getRequestBodyText(t))},e._parseHttpResponseHeaders=function(t){var n={};if(!e.isNullOrEmptyString(t))for(var r=new RegExp("\r?\n"),o=t.split(r),i=0;i<o.length;i++){var a=o[i];if(null!=a){var s=a.indexOf(":");if(s>0){var c=a.substr(0,s),u=a.substr(s+1);c=e.trim(c),u=e.trim(u),n[c.toUpperCase()]=u}}}return n},e._parseErrorResponse=function(t){var n=e._parseErrorResponseBody(t),r=t.statusCode.toString();if(e.isNullOrUndefined(n)||"object"!=typeof n||!n.error)return e._createDefaultErrorResponse(r);var o=n.error,i=o.innerError;return i&&i.code?e._createErrorResponse(i.code,r,i.message):o.code?e._createErrorResponse(o.code,r,o.message):e._createDefaultErrorResponse(r)},e._parseErrorResponseBody=function(t){if(e.isPlainJsonObject(t.body))return t.body;if(!e.isNullOrEmptyString(t.body)){var n=e.trim(t.body);try{return JSON.parse(n)}catch(t){e.log("Error when parse "+n)}}},e._createDefaultErrorResponse=function(t){return{errorCode:a.connectionFailure,errorMessage:e._getResourceString(s.connectionFailureWithStatus,t)}},e._createErrorResponse=function(t,n,r){return{errorCode:t,errorMessage:e._getResourceString(s.connectionFailureWithDetails,[n,t,r])}},e._copyHeaders=function(e,t){if(e&&t)for(var n in e)t[n]=e[n]},e.addResourceStringValues=function(t){for(var n in t)e.s_resourceStringValues[n]=t[n]},e._logEnabled=!1,e.s_resourceStringValues={ApiNotFoundDetails:"The method or property {0} is part of the {1} requirement set, which is not available in your version of {2}.",ConnectionFailureWithStatus:"The request failed with status code of {0}.",ConnectionFailureWithDetails:"The request failed with status code of {0}, error code {1} and the following error message: {2}",InvalidArgument:"The argument '{0}' doesn't work for this situation, is missing, or isn't in the right format.",InvalidObjectPath:'The object path \'{0}\' isn\'t working for what you\'re trying to do. If you\'re using the object across multiple "context.sync" calls and outside the sequential execution of a ".run" batch, please use the "context.trackedObjects.add()" and "context.trackedObjects.remove()" methods to manage the object\'s lifetime.',InvalidRequestContext:"Cannot use the object across different request contexts.",Timeout:"The operation has timed out.",ValueNotLoaded:'The value of the result object has not been loaded yet. Before reading the value property, call "context.sync()" on the associated request context.'},e}();e.CoreUtility=l;var f=function(){function e(){}return e.setMock=function(t){e.s_isMock=t},e.isMock=function(){return e.s_isMock},e._setCurrentTestName=function(t){e.s_currentTestName=t,e.s_currentTestSequenceId=0},e._getCurrentTestNameWithSequenceId=function(){return e.s_currentTestName?(e.s_currentTestSequenceId++,e.s_currentTestName+"."+e.s_currentTestSequenceId):null},e}();e.TestUtility=f,e._internalConfig={showDisposeInfoInDebugInfo:!1,showInternalApiInDebugInfo:!1,enableEarlyDispose:!0,alwaysPolyfillClientObjectUpdateMethod:!1,alwaysPolyfillClientObjectRetrieveMethod:!1,enableConcurrentFlag:!0,enableUndoableFlag:!0,appendTypeNameToObjectPathInfo:!1,enablePreviewExecution:!1},e.config={extendedErrorLogging:!1};var p=function(){function t(){}return t.createSetPropertyAction=function(t,n,r,o,i){C.validateObjectPath(n);var a={Id:t._nextId(),ActionType:4,Name:r,ObjectPathId:n._objectPath.objectPathInfo.Id,ArgumentInfo:{}},s=[o],c=C.setMethodArguments(t,a.ArgumentInfo,s);C.validateReferencedObjectPaths(c);var u=new h(a,0,i);if(u.referencedObjectPath=n._objectPath,u.referencedArgumentObjectPaths=c,e._internalConfig.enablePreviewExecution&&0!=(16&i)){var l={Id:t._nextId(),ActionType:4,Name:r,ObjectId:"",ObjectType:"",Arguments:[o]};n._addPreviewExecutionAction(l)}return n._addAction(u)},t.createQueryAction=function(e,t,n,r){C.validateObjectPath(t);var o={Id:e._nextId(),ActionType:2,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,QueryInfo:n},i=new h(o,1,4);return i.referencedObjectPath=t._objectPath,t._addAction(i,r)},t.createQueryAsJsonAction=function(e,t,n,r){C.validateObjectPath(t);var o={Id:e._nextId(),ActionType:7,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,QueryInfo:n},i=new h(o,1,4);return i.referencedObjectPath=t._objectPath,t._addAction(i,r)},t.createUpdateAction=function(e,t,n){C.validateObjectPath(t);var r={Id:e._nextId(),ActionType:9,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,ObjectState:n},o=new h(r,0,0);return o.referencedObjectPath=t._objectPath,t._addAction(o)},t}();e.CommonActionFactory=p;var d=function(){function t(e,t){this.m_contextBase=e,this.m_objectPath=t}return Object.defineProperty(t.prototype,"_objectPath",{get:function(){return this.m_objectPath},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_context",{get:function(){return this.m_contextBase},enumerable:!0,configurable:!0}),t.prototype._addAction=function(e,t){var n=this;return void 0===t&&(t=null),l.createPromise((function(r,o){n._context._addServiceApiAction(e,t,r,o)}))},t.prototype._addPreviewExecutionAction=function(e){},t.prototype._retrieve=function(t,n){var r=e._internalConfig.alwaysPolyfillClientObjectRetrieveMethod;r||(r=!C.isSetSupported("RichApiRuntime","1.1"));var o=m._parseQueryOption(t);return r?p.createQueryAction(this._context,this,o,n):p.createQueryAsJsonAction(this._context,this,o,n)},t.prototype._recursivelyUpdate=function(t){var n=e._internalConfig.alwaysPolyfillClientObjectUpdateMethod;n||(n=!C.isSetSupported("RichApiRuntime","1.2"));try{var r=this[S.scalarPropertyNames];r||(r=[]);var i=this[S.scalarPropertyUpdateable];if(!i){i=[];for(var c=0;c<r.length;c++)i.push(!1)}var u=this[S.navigationPropertyNames];u||(u=[]);var f={},d={},h=0;for(var g in t){var m=r.indexOf(g);if(m>=0){if(!i[m])throw new o.RuntimeError({code:a.invalidArgument,httpStatusCode:400,message:l._getResourceString(I.attemptingToSetReadOnlyProperty,g),debugInfo:{errorLocation:g}});f[g]=t[g],++h}else{if(!(u.indexOf(g)>=0))throw new o.RuntimeError({code:a.invalidArgument,httpStatusCode:400,message:l._getResourceString(I.propertyDoesNotExist,g),debugInfo:{errorLocation:g}});d[g]=t[g]}}if(h>0)if(n)for(c=0;c<r.length;c++){var y=f[g=r[c]];C.isUndefined(y)||p.createSetPropertyAction(this._context,this,g,y)}else p.createUpdateAction(this._context,this,f);for(var g in d){var v=this[g],_=d[g];v._recursivelyUpdate(_)}}catch(e){throw new o.RuntimeError({code:a.invalidArgument,httpStatusCode:400,message:l._getResourceString(s.invalidArgument,"properties"),debugInfo:{errorLocation:this._className+".update"},innerError:e})}},t}();e.ClientObjectBase=d;var h=function(){function e(e,t,n){this.m_actionInfo=e,this.m_operationType=t,this.m_flags=n}return Object.defineProperty(e.prototype,"actionInfo",{get:function(){return this.m_actionInfo},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"operationType",{get:function(){return this.m_operationType},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"flags",{get:function(){return this.m_flags},enumerable:!0,configurable:!0}),e}();e.Action=h;var g=function(){function t(e,t,n,r,o,i){this.m_objectPathInfo=e,this.m_parentObjectPath=t,this.m_isCollection=n,this.m_isInvalidAfterRequest=r,this.m_isValid=!0,this.m_operationType=o,this.m_flags=i}return Object.defineProperty(t.prototype,"id",{get:function(){var e=this.m_objectPathInfo.ArgumentInfo;if(e){var t=e.Arguments;if(t)return t[0]}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"parent",{get:function(){var e=this.m_parentObjectPath;if(e)return e},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"parentId",{get:function(){return this.parent?this.parent.id:void 0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"objectPathInfo",{get:function(){return this.m_objectPathInfo},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"operationType",{get:function(){return this.m_operationType},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"flags",{get:function(){return this.m_flags},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isCollection",{get:function(){return this.m_isCollection},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isInvalidAfterRequest",{get:function(){return this.m_isInvalidAfterRequest},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"parentObjectPath",{get:function(){return this.m_parentObjectPath},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"argumentObjectPaths",{get:function(){return this.m_argumentObjectPaths},set:function(e){this.m_argumentObjectPaths=e},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isValid",{get:function(){return this.m_isValid},set:function(e){this.m_isValid=e,!e&&6===this.m_objectPathInfo.ObjectPathType&&this.m_savedObjectPathInfo&&(t.copyObjectPathInfo(this.m_savedObjectPathInfo.pathInfo,this.m_objectPathInfo),this.m_parentObjectPath=this.m_savedObjectPathInfo.parent,this.m_isValid=!0,this.m_savedObjectPathInfo=null)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"originalObjectPathInfo",{get:function(){return this.m_originalObjectPathInfo},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"getByIdMethodName",{get:function(){return this.m_getByIdMethodName},set:function(e){this.m_getByIdMethodName=e},enumerable:!0,configurable:!0}),t.prototype._updateAsNullObject=function(){this.resetForUpdateUsingObjectData(),this.m_objectPathInfo.ObjectPathType=7,this.m_objectPathInfo.Name="",this.m_parentObjectPath=null},t.prototype.saveOriginalObjectPathInfo=function(){e.config.extendedErrorLogging&&!this.m_originalObjectPathInfo&&(this.m_originalObjectPathInfo={},t.copyObjectPathInfo(this.m_objectPathInfo,this.m_originalObjectPathInfo))},t.prototype.updateUsingObjectData=function(e,n){var r=e[S.referenceId];if(!l.isNullOrEmptyString(r)){if(!this.m_savedObjectPathInfo&&!this.isInvalidAfterRequest&&t.isRestorableObjectPath(this.m_objectPathInfo.ObjectPathType)){var o={};t.copyObjectPathInfo(this.m_objectPathInfo,o),this.m_savedObjectPathInfo={pathInfo:o,parent:this.m_parentObjectPath}}return this.saveOriginalObjectPathInfo(),this.resetForUpdateUsingObjectData(),this.m_objectPathInfo.ObjectPathType=6,this.m_objectPathInfo.Name=r,delete this.m_objectPathInfo.ParentObjectPathId,void(this.m_parentObjectPath=null)}if(n){var i=n[S.collectionPropertyPath];if(!l.isNullOrEmptyString(i)&&n.context){var a=C.tryGetObjectIdFromLoadOrRetrieveResult(e);if(!l.isNullOrUndefined(a)){for(var s=i.split("."),c=n.context[s[0]],u=1;u<s.length;u++)c=c[s[u]];return this.saveOriginalObjectPathInfo(),this.resetForUpdateUsingObjectData(),this.m_parentObjectPath=c._objectPath,this.m_objectPathInfo.ParentObjectPathId=this.m_parentObjectPath.objectPathInfo.Id,this.m_objectPathInfo.ObjectPathType=5,this.m_objectPathInfo.Name="",void(this.m_objectPathInfo.ArgumentInfo.Arguments=[a])}}}var f=this.parentObjectPath&&this.parentObjectPath.isCollection,p=this.getByIdMethodName;if(f||!l.isNullOrEmptyString(p)){a=C.tryGetObjectIdFromLoadOrRetrieveResult(e);if(!l.isNullOrUndefined(a))return this.saveOriginalObjectPathInfo(),this.resetForUpdateUsingObjectData(),l.isNullOrEmptyString(p)?(this.m_objectPathInfo.ObjectPathType=5,this.m_objectPathInfo.Name=""):(this.m_objectPathInfo.ObjectPathType=3,this.m_objectPathInfo.Name=p),void(this.m_objectPathInfo.ArgumentInfo.Arguments=[a])}},t.prototype.resetForUpdateUsingObjectData=function(){this.m_isInvalidAfterRequest=!1,this.m_isValid=!0,this.m_operationType=1,this.m_flags=4,this.m_objectPathInfo.ArgumentInfo={},this.m_argumentObjectPaths=null,this.m_getByIdMethodName=null},t.isRestorableObjectPath=function(e){return 1===e||5===e||3===e||4===e},t.copyObjectPathInfo=function(e,t){t.Id=e.Id,t.ArgumentInfo=e.ArgumentInfo,t.Name=e.Name,t.ObjectPathType=e.ObjectPathType,t.ParentObjectPathId=e.ParentObjectPathId},t}();e.ObjectPath=g;var m=function(){function e(){this.m_nextId=0}return e.prototype._nextId=function(){return++this.m_nextId},e.prototype._addServiceApiAction=function(e,t,n,r){this.m_serviceApiQueue||(this.m_serviceApiQueue=new b(this)),this.m_serviceApiQueue.add(e,t,n,r)},e._parseQueryOption=function(t){var n={};if("string"==typeof t){var r=t;n.Select=C._parseSelectExpand(r)}else if(Array.isArray(t))n.Select=t;else if("object"==typeof t){var i=t;if(e.isLoadOption(i)){if("string"==typeof i.select)n.Select=C._parseSelectExpand(i.select);else if(Array.isArray(i.select))n.Select=i.select;else if(!C.isNullOrUndefined(i.select))throw o.RuntimeError._createInvalidArgError({argumentName:"option.select"});if("string"==typeof i.expand)n.Expand=C._parseSelectExpand(i.expand);else if(Array.isArray(i.expand))n.Expand=i.expand;else if(!C.isNullOrUndefined(i.expand))throw o.RuntimeError._createInvalidArgError({argumentName:"option.expand"});if("number"==typeof i.top)n.Top=i.top;else if(!C.isNullOrUndefined(i.top))throw o.RuntimeError._createInvalidArgError({argumentName:"option.top"});if("number"==typeof i.skip)n.Skip=i.skip;else if(!C.isNullOrUndefined(i.skip))throw o.RuntimeError._createInvalidArgError({argumentName:"option.skip"})}else n=e.parseStrictLoadOption(t)}else if(!C.isNullOrUndefined(t))throw o.RuntimeError._createInvalidArgError({argumentName:"option"});return n},e.isLoadOption=function(e){if(!C.isUndefined(e.select)&&("string"==typeof e.select||Array.isArray(e.select)))return!0;if(!C.isUndefined(e.expand)&&("string"==typeof e.expand||Array.isArray(e.expand)))return!0;if(!C.isUndefined(e.top)&&"number"==typeof e.top)return!0;if(!C.isUndefined(e.skip)&&"number"==typeof e.skip)return!0;for(var t in e)return!1;return!0},e.parseStrictLoadOption=function(t){var n={Select:[]};return e.parseStrictLoadOptionHelper(n,"","option",t),n},e.combineQueryPath=function(e,t,n){return 0===e.length?t:e+n+t},e.parseStrictLoadOptionHelper=function(t,n,r,i){for(var a in i){var s=i[a];if("$all"===a){if("boolean"!=typeof s)throw o.RuntimeError._createInvalidArgError({argumentName:e.combineQueryPath(r,a,".")});s&&t.Select.push(e.combineQueryPath(n,"*","/"))}else if("$top"===a){if("number"!=typeof s||n.length>0)throw o.RuntimeError._createInvalidArgError({argumentName:e.combineQueryPath(r,a,".")});t.Top=s}else if("$skip"===a){if("number"!=typeof s||n.length>0)throw o.RuntimeError._createInvalidArgError({argumentName:e.combineQueryPath(r,a,".")});t.Skip=s}else if("boolean"==typeof s)s&&t.Select.push(e.combineQueryPath(n,a,"/"));else{if("object"!=typeof s)throw o.RuntimeError._createInvalidArgError({argumentName:e.combineQueryPath(r,a,".")});e.parseStrictLoadOptionHelper(t,e.combineQueryPath(n,a,"/"),e.combineQueryPath(r,a,"."),s)}}},e}();e.ClientRequestContextBase=m;var y=function(){function e(e){this.m_objectPath=e}return e.prototype._handleResult=function(e){l.isNullOrUndefined(e)?this.m_objectPath._updateAsNullObject():this.m_objectPath.updateUsingObjectData(e,null)},e}(),v=function(){function t(e){this.m_contextBase=e,this.m_actions=[],this.m_actionResultHandler={},this.m_referencedObjectPaths={},this.m_instantiatedObjectPaths={},this.m_preSyncPromises=[],this.m_previewExecutionActions=[]}return t.prototype.addAction=function(e){this.m_actions.push(e),1==e.actionInfo.ActionType&&(this.m_instantiatedObjectPaths[e.actionInfo.ObjectPathId]=e)},t.prototype.addPreviewExecutionAction=function(e){this.m_previewExecutionActions.push(e)},Object.defineProperty(t.prototype,"hasActions",{get:function(){return this.m_actions.length>0},enumerable:!0,configurable:!0}),t.prototype._getLastAction=function(){return this.m_actions[this.m_actions.length-1]},t.prototype.ensureInstantiateObjectPath=function(e){if(e){if(this.m_instantiatedObjectPaths[e.objectPathInfo.Id])return;if(this.ensureInstantiateObjectPath(e.parentObjectPath),this.ensureInstantiateObjectPaths(e.argumentObjectPaths),!this.m_instantiatedObjectPaths[e.objectPathInfo.Id]){var t={Id:this.m_contextBase._nextId(),ActionType:1,Name:"",ObjectPathId:e.objectPathInfo.Id},n=new h(t,1,4);n.referencedObjectPath=e,this.addReferencedObjectPath(e),this.addAction(n);var r=new y(e);this.addActionResultHandler(n,r)}}},t.prototype.ensureInstantiateObjectPaths=function(e){if(e)for(var t=0;t<e.length;t++)this.ensureInstantiateObjectPath(e[t])},t.prototype.addReferencedObjectPath=function(e){if(e&&!this.m_referencedObjectPaths[e.objectPathInfo.Id]){if(!e.isValid)throw new o.RuntimeError({code:a.invalidObjectPath,httpStatusCode:400,message:l._getResourceString(s.invalidObjectPath,C.getObjectPathExpression(e)),debugInfo:{errorLocation:C.getObjectPathExpression(e)}});for(;e;)this.m_referencedObjectPaths[e.objectPathInfo.Id]=e,3==e.objectPathInfo.ObjectPathType&&this.addReferencedObjectPaths(e.argumentObjectPaths),e=e.parentObjectPath}},t.prototype.addReferencedObjectPaths=function(e){if(e)for(var t=0;t<e.length;t++)this.addReferencedObjectPath(e[t])},t.prototype.addActionResultHandler=function(e,t){this.m_actionResultHandler[e.actionInfo.Id]=t},t.prototype.aggregrateRequestFlags=function(e,t,n){return 0===t&&(e|=1,0==(2&n)&&(e&=-17),0==(8&n)&&(e&=-257),e&=-5),1&n&&(e|=2),0==(4&n)&&(e&=-5),e},t.prototype.finallyNormalizeFlags=function(t){return 0==(1&t)&&(t&=-17,t&=-257),e._internalConfig.enableConcurrentFlag||(t&=-5),e._internalConfig.enableUndoableFlag||(t&=-17),C.isSetSupported("RichApiRuntimeFlag","1.1")||(t&=-5,t&=-17),C.isSetSupported("RichApiRuntimeFlag","1.2")||(t&=-257),"number"==typeof this.m_flagsForTesting&&(t=this.m_flagsForTesting),t},t.prototype.buildRequestMessageBodyAndRequestFlags=function(){e._internalConfig.enableEarlyDispose&&t._calculateLastUsedObjectPathIds(this.m_actions);var n=276,r={};for(var o in this.m_referencedObjectPaths)n=this.aggregrateRequestFlags(n,this.m_referencedObjectPaths[o].operationType,this.m_referencedObjectPaths[o].flags),r[o]=this.m_referencedObjectPaths[o].objectPathInfo;for(var i=[],a=!1,s=0;s<this.m_actions.length;s++){var c=this.m_actions[s];3===c.actionInfo.ActionType&&c.actionInfo.Name===S.keepReference&&(a=!0),n=this.aggregrateRequestFlags(n,c.operationType,c.flags),i.push(c.actionInfo)}n=this.finallyNormalizeFlags(n);var u={AutoKeepReference:this.m_contextBase._autoCleanup&&a,Actions:i,ObjectPaths:r};return this.m_previewExecutionActions.length>0&&(u.PreviewExecutionActions=this.m_previewExecutionActions,n|=4096),{body:u,flags:n}},t.prototype.processResponse=function(e){if(e)for(var t=0;t<e.length;t++){var n=e[t],r=this.m_actionResultHandler[n.ActionId];r&&r._handleResult(n.Value)}},t.prototype.invalidatePendingInvalidObjectPaths=function(){for(var e in this.m_referencedObjectPaths)this.m_referencedObjectPaths[e].isInvalidAfterRequest&&(this.m_referencedObjectPaths[e].isValid=!1)},t.prototype._addPreSyncPromise=function(e){this.m_preSyncPromises.push(e)},Object.defineProperty(t.prototype,"_preSyncPromises",{get:function(){return this.m_preSyncPromises},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_actions",{get:function(){return this.m_actions},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_objectPaths",{get:function(){return this.m_referencedObjectPaths},enumerable:!0,configurable:!0}),t.prototype._removeKeepReferenceAction=function(e){for(var t=this.m_actions.length-1;t>=0;t--){var n=this.m_actions[t].actionInfo;if(n.ObjectPathId===e&&3===n.ActionType&&n.Name===S.keepReference){this.m_actions.splice(t,1);break}}},t._updateLastUsedActionIdOfObjectPathId=function(e,n,r){for(;n;){if(e[n.objectPathInfo.Id])return;e[n.objectPathInfo.Id]=r;var o=n.argumentObjectPaths;if(o)for(var i=o.length,a=0;a<i;a++)t._updateLastUsedActionIdOfObjectPathId(e,o[a],r);n=n.parentObjectPath}},t._calculateLastUsedObjectPathIds=function(e){for(var n={},r=e.length,o=r-1;o>=0;--o){var i=(p=e[o]).actionInfo.Id;p.referencedObjectPath&&t._updateLastUsedActionIdOfObjectPathId(n,p.referencedObjectPath,i);var a=p.referencedArgumentObjectPaths;if(a)for(var s=a.length,c=0;c<s;c++)t._updateLastUsedActionIdOfObjectPathId(n,a[c],i)}var u={};for(var l in n){var f=u[i=n[l]];f||(f=[],u[i]=f),f.push(parseInt(l))}for(o=0;o<r;o++){var p,d=u[(p=e[o]).actionInfo.Id];d&&d.length>0?p.actionInfo.L=d:p.actionInfo.L&&delete p.actionInfo.L}},t}();e.ClientRequestBase=v;var _=function(){function e(e){this.m_type=e}return Object.defineProperty(e.prototype,"value",{get:function(){if(!this.m_isLoaded)throw new o.RuntimeError({code:a.valueNotLoaded,httpStatusCode:400,message:l._getResourceString(s.valueNotLoaded),debugInfo:{errorLocation:"clientResult.value"}});return this.m_value},enumerable:!0,configurable:!0}),e.prototype._handleResult=function(e){this.m_isLoaded=!0,"object"==typeof e&&e&&e._IsNull||(1===this.m_type?this.m_value=C.adjustToDateTime(e):this.m_value=e)},e}();e.ClientResult=_;var b=function(){function e(e){this.m_context=e,this.m_actions=[]}return e.prototype.add=function(e,t,n,r){var o=this;this.m_actions.push({action:e,resultHandler:t,resolve:n,reject:r}),1===this.m_actions.length&&setTimeout((function(){return o.processActions()}),0)},e.prototype.processActions=function(){var e=this;if(0!==this.m_actions.length){var t=this.m_actions;this.m_actions=[];for(var n=new v(this.m_context),r=0;r<t.length;r++){var o=t[r];n.ensureInstantiateObjectPath(o.action.referencedObjectPath),n.ensureInstantiateObjectPaths(o.action.referencedArgumentObjectPaths),n.addAction(o.action),n.addReferencedObjectPath(o.action.referencedObjectPath),n.addReferencedObjectPaths(o.action.referencedArgumentObjectPaths)}var i=n.buildRequestMessageBodyAndRequestFlags(),a=i.body,s=i.flags,u={Url:c.localDocumentApiPrefix,Headers:null,Body:a};l.log("Request:"),l.log(JSON.stringify(a)),(new O).executeAsync(this.m_context._customData,s,u).then((function(r){e.processResponse(n,t,r)})).catch((function(e){for(var n=0;n<t.length;n++){t[n].reject(e)}}))}},e.prototype.processResponse=function(e,t,n){var r=this.getErrorFromResponse(n),o=null;n.Body.Results?o=n.Body.Results:n.Body.ProcessedResults&&n.Body.ProcessedResults.Results&&(o=n.Body.ProcessedResults.Results),o||(o=[]),this.processActionResults(e,t,o,r)},e.prototype.getErrorFromResponse=function(e){return l.isNullOrEmptyString(e.ErrorCode)?e.Body&&e.Body.Error?new o.RuntimeError({code:e.Body.Error.Code,httpStatusCode:e.Body.Error.HttpStatusCode,message:e.Body.Error.Message}):null:new o.RuntimeError({code:e.ErrorCode,httpStatusCode:e.HttpStatusCode,message:e.ErrorMessage})},e.prototype.processActionResults=function(e,t,n,r){e.processResponse(n);for(var o=0;o<t.length;o++){for(var i=t[o],a=i.action.actionInfo.Id,s=!1,c=0;c<n.length;c++)if(a==n[c].ActionId){var u=n[c].Value;i.resultHandler&&(i.resultHandler._handleResult(u),u=i.resultHandler.value),i.resolve&&i.resolve(u),s=!0;break}!s&&i.reject&&(r?i.reject(r):i.reject("No response for the action."))}},e}(),O=function(){function e(){}return e.prototype.getRequestUrl=function(e,n,r){void 0===r&&(r=t.graph.toString());var o=c.flags+"="+n.toString();switch(r){case t.graph.toString():"/"!=e.charAt(e.length-1)&&(e+="/"),e=(e+=c.processQuery)+"?"+o;break;case t.wfe.toString():e=(e=e+"&"+o)+"&wdRestPart=_api/"+c.processQuery}return e},e.prototype.executeAsync=function(n,o,i){var a=i.Headers?i.Headers[S.remoteEndpointTypeHeaderKey]:t.graph.toString(),s={method:"POST",url:this.getRequestUrl(i.Url,o,a),headers:{},body:i.Body};if(s.headers[c.sourceLibHeader]=e.SourceLibHeaderValue,s.headers["CONTENT-TYPE"]="application/json",i.Headers)for(var u in i.Headers)s.headers[u]=i.Headers[u];return(l._isLocalDocumentUrl(s.url)?r.sendLocalDocumentRequest:r.sendRequest)(s).then((function(e){var t;if(200===e.statusCode)t={HttpStatusCode:e.statusCode,ErrorCode:null,ErrorMessage:null,Headers:e.headers,Body:l._parseResponseBody(e)};else{l.log("Error Response:"+e.body);var n=l._parseErrorResponse(e);t={HttpStatusCode:e.statusCode,ErrorCode:n.errorCode,ErrorMessage:n.errorMessage,Headers:e.headers,Body:null,RawErrorResponseBody:l._parseErrorResponseBody(e)}}return t}))},e.SourceLibHeaderValue="officejs-rest",e}();e.HttpRequestExecutor=O;var S=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.collectionPropertyPath="_collectionPropertyPath",t.id="Id",t.idLowerCase="id",t.idPrivate="_Id",t.keepReference="_KeepReference",t.objectPathIdPrivate="_ObjectPathId",t.referenceId="_ReferenceId",t.items="_Items",t.itemsLowerCase="items",t.scalarPropertyNames="_scalarPropertyNames",t.scalarPropertyOriginalNames="_scalarPropertyOriginalNames",t.navigationPropertyNames="_navigationPropertyNames",t.scalarPropertyUpdateable="_scalarPropertyUpdateable",t.previewExecutionObjectId="_previewExecutionObjectId",t.remoteEndpointTypeHeaderKey="X-EndpointType",t}(c);e.CommonConstants=S;var C=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.validateObjectPath=function(e){for(var n=e._objectPath;n;){if(!n.isValid)throw new o.RuntimeError({code:a.invalidObjectPath,httpStatusCode:400,message:l._getResourceString(s.invalidObjectPath,t.getObjectPathExpression(n)),debugInfo:{errorLocation:t.getObjectPathExpression(n)}});n=n.parentObjectPath}},t.validateReferencedObjectPaths=function(e){if(e)for(var n=0;n<e.length;n++)for(var r=e[n];r;){if(!r.isValid)throw new o.RuntimeError({code:a.invalidObjectPath,httpStatusCode:400,message:l._getResourceString(s.invalidObjectPath,t.getObjectPathExpression(r))});r=r.parentObjectPath}},t._toCamelLowerCase=function(e){if(l.isNullOrEmptyString(e))return e;for(var t=0;t<e.length&&e.charCodeAt(t)>=65&&e.charCodeAt(t)<=90;)t++;return t<e.length?e.substr(0,t).toLowerCase()+e.substr(t):e.toLowerCase()},t.adjustToDateTime=function(e){if(l.isNullOrUndefined(e))return null;if("string"==typeof e)return new Date(e);if(Array.isArray(e)){for(var n=e,r=0;r<n.length;r++)n[r]=t.adjustToDateTime(n[r]);return n}throw l._createInvalidArgError({argumentName:"date"})},t.tryGetObjectIdFromLoadOrRetrieveResult=function(e){var t=e[S.id];return l.isNullOrUndefined(t)&&(t=e[S.idLowerCase]),l.isNullOrUndefined(t)&&(t=e[S.idPrivate]),t},t.getObjectPathExpression=function(e){for(var n="";e;){switch(e.objectPathInfo.ObjectPathType){case 1:n=n;break;case 2:n="new()"+(n.length>0?".":"")+n;break;case 3:n=t.normalizeName(e.objectPathInfo.Name)+"()"+(n.length>0?".":"")+n;break;case 4:n=t.normalizeName(e.objectPathInfo.Name)+(n.length>0?".":"")+n;break;case 5:n="getItem()"+(n.length>0?".":"")+n;break;case 6:n="_reference()"+(n.length>0?".":"")+n}e=e.parentObjectPath}return n},t.setMethodArguments=function(e,n,r){if(l.isNullOrUndefined(r))return null;var o=new Array,i=new Array,a=t.collectObjectPathInfos(e,r,o,i);return n.Arguments=r,a&&(n.ReferencedObjectPathIds=i),o},t.validateContext=function(e,t){if(e&&t&&t._context!==e)throw new o.RuntimeError({code:a.invalidRequestContext,httpStatusCode:400,message:l._getResourceString(s.invalidRequestContext)})},t.isSetSupported=function(e,n){return"function"==typeof t.isSetSupportedOverride?t.isSetSupportedOverride(e,n):!("undefined"!=typeof window&&window.Office&&window.Office.context&&window.Office.context.requirements)||window.Office.context.requirements.isSetSupported(e,n)},t.throwIfApiNotSupported=function(e,n,r,i){if(t._doApiNotSupportedCheck&&!t.isSetSupported(n,r)){var c=l._getResourceString(s.apiNotFoundDetails,[e,n+" "+r,i]);throw new o.RuntimeError({code:a.apiNotFound,httpStatusCode:404,message:c,debugInfo:{errorLocation:e}})}},t.calculateApiFlags=function(e,n,r){var o=window&&window.location&&window.location.href&&-1!==window.location.href.indexOf("eed0a086-3498-4f91-a377-1e0265ecc0cc");return("function"==typeof t.isSetSupportedOverride?t.isSetSupportedOverride(n,r):!o&&t.isSetSupported(n,r))||(e&=-3),e},t._parseSelectExpand=function(e){var t=[];if(!l.isNullOrEmptyString(e))for(var n=e.split(","),r=0;r<n.length;r++){var o=n[r];(o=i(o.trim())).length>0&&t.push(o)}return t;function i(e){var t=e.toLowerCase();if("items"===t||"items/"===t)return"*";return("items/"===t.substr(0,6)||"items."===t.substr(0,6))&&(e=e.substr(6)),e.replace(new RegExp("[/.]items[/.]","gi"),"/")}},t.changePropertyNameToCamelLowerCase=function(e){if(Array.isArray(e)){for(var n=[],r=0;r<e.length;r++)n.push(this.changePropertyNameToCamelLowerCase(e[r]));return n}if("object"==typeof e&&null!==e){n={};for(var o in e){var i=e[o];if(o===S.items){(n={})[S.itemsLowerCase]=this.changePropertyNameToCamelLowerCase(i);break}n[t._toCamelLowerCase(o)]=this.changePropertyNameToCamelLowerCase(i)}return n}return e},t.purifyJson=function(e){if(Array.isArray(e)){for(var t=[],n=0;n<e.length;n++)t.push(this.purifyJson(e[n]));return t}if("object"==typeof e&&null!==e){t={};for(var r in e)if(95!==r.charCodeAt(0)){var o=e[r];"object"==typeof o&&null!==o&&Array.isArray(o.items)&&(o=o.items),t[r]=this.purifyJson(o)}return t}return e},t.collectObjectPathInfos=function(e,n,r,o){for(var i=!1,a=0;a<n.length;a++)if(n[a]instanceof d){var s=n[a];t.validateContext(e,s),n[a]=s._objectPath.objectPathInfo.Id,o.push(s._objectPath.objectPathInfo.Id),r.push(s._objectPath),i=!0}else if(Array.isArray(n[a])){var c=new Array;t.collectObjectPathInfos(e,n[a],r,c)?(o.push(c),i=!0):o.push(0)}else l.isPlainJsonObject(n[a])?(o.push(0),t.replaceClientObjectPropertiesWithObjectPathIds(n[a],r)):o.push(0);return i},t.replaceClientObjectPropertiesWithObjectPathIds=function(e,n){var r,o;for(var i in e){var a=e[i];if(a instanceof d)n.push(a._objectPath),e[i]=((r={})[S.objectPathIdPrivate]=a._objectPath.objectPathInfo.Id,r);else if(Array.isArray(a))for(var s=0;s<a.length;s++)if(a[s]instanceof d){var c=a[s];n.push(c._objectPath),a[s]=((o={})[S.objectPathIdPrivate]=c._objectPath.objectPathInfo.Id,o)}else l.isPlainJsonObject(a[s])&&t.replaceClientObjectPropertiesWithObjectPathIds(a[s],n);else l.isPlainJsonObject(a)&&t.replaceClientObjectPropertiesWithObjectPathIds(a,n)}},t.normalizeName=function(e){return e.substr(0,1).toLowerCase()+e.substr(1)},t._doApiNotSupportedCheck=!1,t}(l);e.CommonUtility=C;var I=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.propertyDoesNotExist="PropertyDoesNotExist",t.attemptingToSetReadOnlyProperty="AttemptingToSetReadOnlyProperty",t}(s);e.CommonResourceStrings=I;var A=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.propertyNotLoaded="PropertyNotLoaded",t.runMustReturnPromise="RunMustReturnPromise",t.cannotRegisterEvent="CannotRegisterEvent",t.invalidOrTimedOutSession="InvalidOrTimedOutSession",t.cannotUpdateReadOnlyProperty="CannotUpdateReadOnlyProperty",t}(a);e.ErrorCodes=A;var P=function(){function e(e){this.m_callback=e}return e.prototype._handleResult=function(e){this.m_callback&&this.m_callback()},e}(),E=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),n.createMethodAction=function(t,n,r,o,i,a){J.validateObjectPath(n);var s={Id:t._nextId(),ActionType:3,Name:r,ObjectPathId:n._objectPath.objectPathInfo.Id,ArgumentInfo:{}},c=J.setMethodArguments(t,s.ArgumentInfo,i);J.validateReferencedObjectPaths(c);var u=J._fixupApiFlags(a),l=new h(s,o,u);if(l.referencedObjectPath=n._objectPath,l.referencedArgumentObjectPaths=c,n._addAction(l),e._internalConfig.enablePreviewExecution&&0!=(16&u)){var f={Id:t._nextId(),ActionType:3,Name:r,Arguments:i,ObjectId:"",ObjectType:""};n._addPreviewExecutionAction(f)}return l},n.createRecursiveQueryAction=function(e,t,n){J.validateObjectPath(t);var r={Id:e._nextId(),ActionType:6,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,RecursiveQueryInfo:n},o=new h(r,1,4);return o.referencedObjectPath=t._objectPath,t._addAction(o),o},n.createEnsureUnchangedAction=function(e,t,n){J.validateObjectPath(t);var r={Id:e._nextId(),ActionType:8,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,ObjectState:n},o=new h(r,1,4);return o.referencedObjectPath=t._objectPath,t._addAction(o),o},n.createInstantiateAction=function(e,t){J.validateObjectPath(t),e._pendingRequest.ensureInstantiateObjectPath(t._objectPath.parentObjectPath),e._pendingRequest.ensureInstantiateObjectPaths(t._objectPath.argumentObjectPaths);var n={Id:e._nextId(),ActionType:1,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id},r=new h(n,1,4);return r.referencedObjectPath=t._objectPath,t._addAction(r,new L(t),!0),r},n.createTraceAction=function(e,t,n){var r={Id:e._nextId(),ActionType:5,Name:"Trace",ObjectPathId:0},o=new h(r,1,4);return e._pendingRequest.addAction(o),n&&e._pendingRequest.addTrace(r.Id,t),o},n.createTraceMarkerForCallback=function(e,t){var r=n.createTraceAction(e,null,!1);e._pendingRequest.addActionResultHandler(r,new P(t))},n}(p);e.ActionFactory=E;var R=function(t){function n(n,r){var o=t.call(this,n,r)||this;return J.checkArgumentNull(n,"context"),o.m_context=n,o._objectPath&&(!n._processingResult&&n._pendingRequest&&(E.createInstantiateAction(n,o),n._autoCleanup&&o._KeepReference&&n.trackedObjects._autoAdd(o)),e._internalConfig.appendTypeNameToObjectPathInfo&&o._objectPath.objectPathInfo&&o._className&&(o._objectPath.objectPathInfo.T=o._className)),o}return __extends(n,t),Object.defineProperty(n.prototype,"context",{get:function(){return this.m_context},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"isNull",{get:function(){return(void 0!==this.m_isNull||!f.isMock())&&(J.throwIfNotLoaded("isNull",this._isNull,null,this._isNull),this._isNull)},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"isNullObject",{get:function(){return(void 0!==this.m_isNull||!f.isMock())&&(J.throwIfNotLoaded("isNullObject",this._isNull,null,this._isNull),this._isNull)},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isNull",{get:function(){return this.m_isNull},set:function(e){this.m_isNull=e,e&&this._objectPath&&this._objectPath._updateAsNullObject()},enumerable:!0,configurable:!0}),n.prototype._addAction=function(e,t,n){return void 0===t&&(t=null),n||(this.context._pendingRequest.ensureInstantiateObjectPath(this._objectPath),this.context._pendingRequest.ensureInstantiateObjectPaths(e.referencedArgumentObjectPaths)),this.context._pendingRequest.addAction(e),this.context._pendingRequest.addReferencedObjectPath(this._objectPath),this.context._pendingRequest.addReferencedObjectPaths(e.referencedArgumentObjectPaths),this.context._pendingRequest.addActionResultHandler(e,t),l._createPromiseFromResult(null)},n.prototype._addPreviewExecutionAction=function(e){if(!J.isUndefined(this._className)){e.ObjectType=this._className;var t=J._getPropertyValueWithoutCheckLoaded(this,D.idLowerCase);J.isUndefined(t)&&(t=J._getPropertyValueWithoutCheckLoaded(this,D.idPrivate)),J.isUndefined(t)&&(t=J._getPropertyValueWithoutCheckLoaded(this,D.previewExecutionObjectId)),e.ObjectId=t,this.context._pendingRequest.addPreviewExecutionAction(e)}},n.prototype._handleResult=function(e){this._isNull=J.isNullOrUndefined(e),this.context.trackedObjects._autoTrackIfNecessaryWhenHandleObjectResultValue(this,e)},n.prototype._handleIdResult=function(e){this._isNull=J.isNullOrUndefined(e),J.fixObjectPathIfNecessary(this,e),this.context.trackedObjects._autoTrackIfNecessaryWhenHandleObjectResultValue(this,e)},n.prototype._handleRetrieveResult=function(e,t){this._handleIdResult(e)},n.prototype._recursivelySet=function(e,t,r,i,c){var u=e instanceof n,f=e;if(u){if(Object.getPrototypeOf(this)!==Object.getPrototypeOf(e))throw o.RuntimeError._createInvalidArgError({argumentName:"properties",errorLocation:this._className+".set"});e=JSON.parse(JSON.stringify(e))}try{for(var p,d=0;d<r.length;d++)p=r[d],e.hasOwnProperty(p)&&void 0!==e[p]&&(this[p]=e[p]);for(d=0;d<i.length;d++)if(p=i[d],e.hasOwnProperty(p)&&void 0!==e[p]){var h=u?f[p]:e[p];this[p].set(h,t)}var g=!u;t&&!J.isNullOrUndefined(g)&&(g=t.throwOnReadOnly);for(d=0;d<c.length;d++)if(p=c[d],e.hasOwnProperty(p)&&void 0!==e[p]&&g)throw new o.RuntimeError({code:a.invalidArgument,httpStatusCode:400,message:l._getResourceString(V.cannotApplyPropertyThroughSetMethod,p),debugInfo:{errorLocation:p}});for(p in e)if(r.indexOf(p)<0&&i.indexOf(p)<0){var m=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(this),p);if(!m)throw new o.RuntimeError({code:a.invalidArgument,httpStatusCode:400,message:l._getResourceString(I.propertyDoesNotExist,p),debugInfo:{errorLocation:p}});if(g&&!m.set)throw new o.RuntimeError({code:a.invalidArgument,httpStatusCode:400,message:l._getResourceString(I.attemptingToSetReadOnlyProperty,p),debugInfo:{errorLocation:p}})}}catch(e){throw new o.RuntimeError({code:a.invalidArgument,httpStatusCode:400,message:l._getResourceString(s.invalidArgument,"properties"),debugInfo:{errorLocation:this._className+".set"},innerError:e})}},n}(d);e.ClientObject=R;var T=function(){function e(e){this.m_session=e}return e.prototype.executeAsync=function(e,t,n){var r={url:c.processQuery,method:"POST",headers:n.Headers,body:n.Body},o="";n.Headers&&(o=n.Headers[D.officeControlId]);var a={id:i.nextId(),type:1,flags:t,controlId:o,message:r,customData:e};return l.log(JSON.stringify(a)),this.m_session.sendMessageToHost(a).then((function(e){l.log("Received response: "+JSON.stringify(e));var t,n=e.message;if(200===n.statusCode)t={HttpStatusCode:n.statusCode,ErrorCode:null,ErrorMessage:null,Headers:n.headers,Body:l._parseResponseBody(n)};else{l.log("Error Response:"+n.body);var r=l._parseErrorResponse(n);t={HttpStatusCode:n.statusCode,ErrorCode:r.errorCode,ErrorMessage:r.errorMessage,Headers:n.headers,Body:null}}return t}))},e}(),w=function(e){function t(t){var n=e.call(this)||this;return n.m_bridge=t,n.m_bridge.addHostMessageHandler((function(e){if(3===e.type){var t=e.controlId;if(l.isNullOrEmptyString(t))H.getGenericEventRegistration(t)._handleRichApiMessage(e.message);else{var n=H.peekGenericEventRegistrationOrNull(t);n&&n._handleRichApiMessage(e.message),(n=H.peekGenericEventRegistrationOrNull(""))&&n._handleRichApiMessage(e.message)}}})),n}return __extends(t,e),t.getInstanceIfHostBridgeInited=function(){return i.instance?((l.isNullOrUndefined(t.s_instance)||t.s_instance.m_bridge!==i.instance)&&(t.s_instance=new t(i.instance)),t.s_instance):null},t.prototype._resolveRequestUrlAndHeaderInfo=function(){return l._createPromiseFromResult(null)},t.prototype._createRequestExecutorOrNull=function(){return l.log("NativeBridgeSession::CreateRequestExecutor"),new T(this)},t.prototype.getEventRegistration=function(e){return H.getGenericEventRegistration(e)},t.prototype.sendMessageToHost=function(e){return this.m_bridge.sendMessageToHostAndExpectResponse(e)},t}(n);e.HostBridgeSession=w;var x=function(t){function r(e){var i=t.call(this)||this;if(i.m_customRequestHeaders={},i.m_batchMode=0,i._onRunFinishedNotifiers=[],n._overrideSession)i.m_requestUrlAndHeaderInfoResolver=n._overrideSession;else if((J.isNullOrUndefined(e)||"string"==typeof e&&0===e.length)&&((e=r.defaultRequestUrlAndHeaders)||(e={url:c.localDocument,headers:{}})),"string"==typeof e)i.m_requestUrlAndHeaderInfo={url:e,headers:{}};else if(r.isRequestUrlAndHeaderInfoResolver(e))i.m_requestUrlAndHeaderInfoResolver=e;else{if(!r.isRequestUrlAndHeaderInfo(e))throw o.RuntimeError._createInvalidArgError({argumentName:"url"});var a=e;i.m_requestUrlAndHeaderInfo={url:a.url,headers:{}},l._copyHeaders(a.headers,i.m_requestUrlAndHeaderInfo.headers)}return!i.m_requestUrlAndHeaderInfoResolver&&i.m_requestUrlAndHeaderInfo&&l._isLocalDocumentUrl(i.m_requestUrlAndHeaderInfo.url)&&w.getInstanceIfHostBridgeInited()&&(i.m_requestUrlAndHeaderInfo=null,i.m_requestUrlAndHeaderInfoResolver=w.getInstanceIfHostBridgeInited()),i.m_requestUrlAndHeaderInfoResolver instanceof n&&(i.m_session=i.m_requestUrlAndHeaderInfoResolver),i._processingResult=!1,i._customData=D.iterativeExecutor,i.sync=i.sync.bind(i),i}return __extends(r,t),Object.defineProperty(r.prototype,"session",{get:function(){return this.m_session},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"eventRegistration",{get:function(){return this.m_session?this.m_session.getEventRegistration(this._controlId):o.officeJsEventRegistration},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"_url",{get:function(){return this.m_requestUrlAndHeaderInfo?this.m_requestUrlAndHeaderInfo.url:null},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"_pendingRequest",{get:function(){return null==this.m_pendingRequest&&(this.m_pendingRequest=new k(this)),this.m_pendingRequest},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"_controlId",{get:function(){var e=this.m_customRequestHeaders[D.officeControlId];return l.isNullOrUndefined(e)&&(e=""),e},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"debugInfo",{get:function(){return{pendingStatements:new q(this._rootObjectPropertyName,this._pendingRequest._objectPaths,this._pendingRequest._actions,e._internalConfig.showDisposeInfoInDebugInfo).process()}},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"trackedObjects",{get:function(){return this.m_trackedObjects||(this.m_trackedObjects=new G(this)),this.m_trackedObjects},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"requestHeaders",{get:function(){return this.m_customRequestHeaders},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"batchMode",{get:function(){return this.m_batchMode},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"getAdditionalHeaders",{set:function(e){this.m_getAdditionalHeaders=e},enumerable:!0,configurable:!0}),r.prototype.ensureInProgressBatchIfBatchMode=function(){if(1===this.m_batchMode&&!this.m_explicitBatchInProgress)throw J.createRuntimeError(a.generalException,l._getResourceString(V.notInsideBatch),null)},r.prototype.load=function(e,t){J.validateContext(this,e);var n=r._parseQueryOption(t);p.createQueryAction(this,e,n,e)},r.prototype.loadRecursive=function(e,t,n){if(!J.isPlainJsonObject(t))throw o.RuntimeError._createInvalidArgError({argumentName:"options"});var i={};for(var a in t)i[a]=r._parseQueryOption(t[a]);var s=E.createRecursiveQueryAction(this,e,{Queries:i,MaxDepth:n});this._pendingRequest.addActionResultHandler(s,e)},r.prototype.trace=function(e){E.createTraceAction(this,e,!0)},r.prototype._processOfficeJsErrorResponse=function(e,t){},r.prototype.ensureRequestUrlAndHeaderInfo=function(){var e=this;return J._createPromiseFromResult(null).then((function(){if(!e.m_requestUrlAndHeaderInfo)return e.m_requestUrlAndHeaderInfoResolver._resolveRequestUrlAndHeaderInfo().then((function(t){if(e.m_requestUrlAndHeaderInfo=t,e.m_requestUrlAndHeaderInfo||(e.m_requestUrlAndHeaderInfo={url:c.localDocument,headers:{}}),J.isNullOrEmptyString(e.m_requestUrlAndHeaderInfo.url)&&(e.m_requestUrlAndHeaderInfo.url=c.localDocument),e.m_requestUrlAndHeaderInfo.headers||(e.m_requestUrlAndHeaderInfo.headers={}),"function"==typeof e.m_requestUrlAndHeaderInfoResolver._createRequestExecutorOrNull){var n=e.m_requestUrlAndHeaderInfoResolver._createRequestExecutorOrNull();n&&(e._requestExecutor=n)}}))}))},r.prototype.syncPrivateMain=function(){var e=this;return this.ensureRequestUrlAndHeaderInfo().then((function(){var t=e._pendingRequest;return e.m_pendingRequest=null,e.processPreSyncPromises(t).then((function(){return e.syncPrivate(t)}))}))},r.prototype.syncPrivate=function(t){var n=this;if(f.isMock())return l._createPromiseFromResult(null);if(!t.hasActions)return this.processPendingEventHandlers(t);var r=t.buildRequestMessageBodyAndRequestFlags(),i=r.body,a=r.flags;this._requestFlagModifier&&(a|=this._requestFlagModifier),this._requestExecutor||(l._isLocalDocumentUrl(this.m_requestUrlAndHeaderInfo.url)?this._requestExecutor=new W(this):this._requestExecutor=new O);var s=this._requestExecutor,u={};l._copyHeaders(this.m_requestUrlAndHeaderInfo.headers,u),l._copyHeaders(this.m_customRequestHeaders,u),delete this.m_customRequestHeaders[D.officeScriptEventId],this.m_getAdditionalHeaders&&l._copyHeaders(this.m_getAdditionalHeaders(),u);var p=f._getCurrentTestNameWithSequenceId();p&&(u[c.testRequestNameHeader]=p);var d={Url:this.m_requestUrlAndHeaderInfo.url,Headers:u,Body:i};t.invalidatePendingInvalidObjectPaths();var h=null,g=null;return this._lastSyncStart="undefined"==typeof performance?Date.now():performance.now(),this._lastRequestFlags=a,s.executeAsync(this._customData,a,d,this._invocationId).then((function(r){return n._lastSyncEnd="undefined"==typeof performance?Date.now():performance.now(),e.config.executePerfLogFunc&&e.config.executePerfLogFunc({syncStart:n._lastSyncStart,syncEnd:n._lastSyncEnd}),h=n.processRequestExecutorResponseMessage(t,r),n.processPendingEventHandlers(t).catch((function(e){l.log("Error in processPendingEventHandlers"),l.log(JSON.stringify(e)),g=e}))})).then((function(){if(h)throw l.log("Throw error from response: "+JSON.stringify(h)),h;if(g){l.log("Throw error from ProcessEventHandler: "+JSON.stringify(g));var e=null;if(g instanceof o.RuntimeError)(e=g).traceMessages=t._responseTraceMessages;else{var n=null;n="string"==typeof g?g:g.message,J.isNullOrEmptyString(n)&&(n=l._getResourceString(V.cannotRegisterEvent)),e=new o.RuntimeError({code:A.cannotRegisterEvent,httpStatusCode:400,message:n,traceMessages:t._responseTraceMessages})}throw e}}))},r.prototype.processRequestExecutorResponseMessage=function(t,n){n.Body&&n.Body.TraceIds&&t._setResponseTraceIds(n.Body.TraceIds);var r=t._responseTraceMessages,i=null;if(n.Body){if(n.Body.Error&&n.Body.Error.ActionIndex>=0){var a=new q(this._rootObjectPropertyName,t._objectPaths,t._actions,!1,!0),s=a.processForDebugStatementInfo(n.Body.Error.ActionIndex);i={statement:s.statement,surroundingStatements:s.surroundingStatements,fullStatements:["Please enable config.extendedErrorLogging to see full statements."]},e.config.extendedErrorLogging&&(a=new q(this._rootObjectPropertyName,t._objectPaths,t._actions,!1,!1),i.fullStatements=a.process())}var c=null;if(n.Body.Results?c=n.Body.Results:n.Body.ProcessedResults&&n.Body.ProcessedResults.Results&&(c=n.Body.ProcessedResults.Results),c){this._processingResult=!0;try{t.processResponse(c)}finally{this._processingResult=!1}}}if(!J.isNullOrEmptyString(n.ErrorCode))return new o.RuntimeError({code:n.ErrorCode,httpStatusCode:n.HttpStatusCode,message:n.ErrorMessage,traceMessages:r,data:{responseBody:n.RawErrorResponseBody}});if(n.Body&&n.Body.Error){var u={errorLocation:n.Body.Error.Location};return i&&(u.statement=i.statement,u.surroundingStatements=i.surroundingStatements,u.fullStatements=i.fullStatements),new o.RuntimeError({code:n.Body.Error.Code,httpStatusCode:n.Body.Error.HttpStatusCode,message:n.Body.Error.Message,traceMessages:r,debugInfo:u})}return null},r.prototype.processPendingEventHandlers=function(e){for(var t=J._createPromiseFromResult(null),n=0;n<e._pendingProcessEventHandlers.length;n++){var r=e._pendingProcessEventHandlers[n];t=t.then(this.createProcessOneEventHandlersFunc(r,e))}return t},r.prototype.createProcessOneEventHandlersFunc=function(e,t){return function(){return e._processRegistration(t)}},r.prototype.processPreSyncPromises=function(e){for(var t=J._createPromiseFromResult(null),n=0;n<e._preSyncPromises.length;n++){var r=e._preSyncPromises[n];t=t.then(this.createProcessOneProSyncFunc(r))}return t},r.prototype.createProcessOneProSyncFunc=function(e){return function(){return e}},r.prototype.sync=function(e){return f.isMock()?l._createPromiseFromResult(e):this.syncPrivateMain().then((function(){return e}))},r.prototype.batch=function(e){var t=this;if(1!==this.m_batchMode)return l._createPromiseFromException(J.createRuntimeError(a.generalException,null,null));if(this.m_explicitBatchInProgress)return l._createPromiseFromException(J.createRuntimeError(a.generalException,l._getResourceString(V.pendingBatchInProgress),null));if(J.isNullOrUndefined(e))return J._createPromiseFromResult(null);this.m_explicitBatchInProgress=!0;var n,r,o,i=this.m_pendingRequest;this.m_pendingRequest=new k(this);try{n=e(this._rootObject,this)}catch(e){return this.m_explicitBatchInProgress=!1,this.m_pendingRequest=i,l._createPromiseFromException(e)}return"object"==typeof n&&n&&"function"==typeof n.then?o=J._createPromiseFromResult(null).then((function(){return n})).then((function(e){return t.m_explicitBatchInProgress=!1,r=t.m_pendingRequest,t.m_pendingRequest=i,e})).catch((function(e){return t.m_explicitBatchInProgress=!1,r=t.m_pendingRequest,t.m_pendingRequest=i,l._createPromiseFromException(e)})):(this.m_explicitBatchInProgress=!1,r=this.m_pendingRequest,this.m_pendingRequest=i,o=J._createPromiseFromResult(n)),o.then((function(e){return t.ensureRequestUrlAndHeaderInfo().then((function(){return t.syncPrivate(r)})).then((function(){return e}))}))},r._run=function(e,t,n,o,i,a){return void 0===n&&(n=3),void 0===o&&(o=5e3),r._runCommon("run",null,e,0,t,n,o,null,null,i,a)},r.isValidRequestInfo=function(e){return"string"==typeof e||r.isRequestUrlAndHeaderInfo(e)||r.isRequestUrlAndHeaderInfoResolver(e)},r.isRequestUrlAndHeaderInfo=function(e){return"object"==typeof e&&null!==e&&Object.getPrototypeOf(e)===Object.getPrototypeOf({})&&!J.isNullOrUndefined(e.url)},r.isRequestUrlAndHeaderInfoResolver=function(e){return"object"==typeof e&&null!==e&&"function"==typeof e._resolveRequestUrlAndHeaderInfo},r._runBatch=function(e,t,n,o,i,a,s,c,u){return void 0===a&&(a=3),void 0===s&&(s=5e3),r._runBatchCommon(0,e,t,n,a,s,o,i,c,u)},r._runExplicitBatch=function(e,t,n,o,i,a,s,c,u){return void 0===a&&(a=3),void 0===s&&(s=5e3),r._runBatchCommon(1,e,t,n,a,s,o,i,c,u)},r._runBatchCommon=function(e,t,n,o,i,a,s,c,u,l){var f,p;void 0===i&&(i=3),void 0===a&&(a=5e3);var d=null,h=null,g=null,m=0,y=null;if(n.length>0)if(r.isValidRequestInfo(n[0]))d=n[0],m=1;else if(J.isPlainJsonObject(n[0])){if(null!=(d=(y=n[0]).session)&&!r.isValidRequestInfo(d))return r.createErrorPromise(t);h=y.getAdditionalHeaders,g=y.previousObjects,m=1}if(n.length==m+1)p=n[m+0];else{if(null!=y||n.length!=m+2)return r.createErrorPromise(t);g=n[m+0],p=n[m+1]}if(null!=g)if(g instanceof R)f=function(){return g.context};else if(g instanceof r)f=function(){return g};else{if(!Array.isArray(g))return r.createErrorPromise(t);var v=g;if(0==v.length)return r.createErrorPromise(t);for(var _=0;_<v.length;_++){if(!(v[_]instanceof R))return r.createErrorPromise(t);if(v[_].context!=v[0].context)return r.createErrorPromise(t,V.invalidRequestContext)}f=function(){return v[0].context}}else f=o;var b=null;s&&(b=function(e){return s(y||{},e)});var O=null;return c&&(O=function(e){return c(y||{},e)}),r._runCommon(t,d,f,e,p,i,a,b,O,u,l,h)},r.createErrorPromise=function(e,t){return void 0===t&&(t=s.invalidArgument),l._createPromiseFromException(J.createRuntimeError(t,l._getResourceString(t),e))},r._runCommon=function(t,o,i,a,s,c,u,f,p,d,h,g){n._overrideSession&&(o=n._overrideSession);var m,y,v,_=l.createPromise((function(e,t){e()})),b=!1;return _.then((function(){if((m=i(o)).getAdditionalHeaders=g,m._autoCleanup)return new e.Promise((function(e,t){m._onRunFinishedNotifiers.push((function(){m._autoCleanup=!0,e()}))}));m._autoCleanup=!0})).then((function(){return"function"!=typeof s?r.createErrorPromise(t):(v=m.m_batchMode,m.m_batchMode=a,f&&f(m),e=s(1==a?m.batch.bind(m):m),(J.isNullOrUndefined(e)||"function"!=typeof e.then)&&J.throwError(V.runMustReturnPromise),e);var e})).then((function(e){return 1===a?e:m.sync(e)})).then((function(e){b=!0,y=e})).catch((function(e){y=e})).then((function(){var e=m.trackedObjects._retrieveAndClearAutoCleanupList();for(var t in m._autoCleanup=!1,m.m_batchMode=v,e)e[t]._objectPath.isValid=!1;var n=0;if(J._synchronousCleanup||r.isRequestUrlAndHeaderInfoResolver(o))return i();function i(){n++;var t=m.m_pendingRequest,r=m.m_batchMode,o=new k(m);m.m_pendingRequest=o,m.m_batchMode=0;try{for(var a in e)m.trackedObjects.remove(e[a]);p&&p(m)}finally{m.m_batchMode=r,m.m_pendingRequest=t}return m.syncPrivate(o).then((function(){d&&d(n)})).catch((function(){h&&h(n),n<c&&setTimeout((function(){i()}),u)}))}i()})).then((function(){m._onRunFinishedNotifiers&&m._onRunFinishedNotifiers.length>0&&m._onRunFinishedNotifiers.shift()();if(b)return y;throw y}))},r}(m);e.ClientRequestContext=x;var N=function(){function e(e,t){this.m_proxy=e,this.m_shouldPolyfill=t;var n=e[D.scalarPropertyNames],r=e[D.navigationPropertyNames],o=e[D.className],i=e[D.isCollection];if(n)for(var a=0;a<n.length;a++)J.definePropertyThrowUnloadedException(this,o,n[a]);if(r)for(a=0;a<r.length;a++)J.definePropertyThrowUnloadedException(this,o,r[a]);i&&J.definePropertyThrowUnloadedException(this,o,D.itemsLowerCase)}return Object.defineProperty(e.prototype,"$proxy",{get:function(){return this.m_proxy},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"$isNullObject",{get:function(){if(!this.m_isLoaded)throw new o.RuntimeError({code:A.valueNotLoaded,httpStatusCode:400,message:l._getResourceString(V.valueNotLoaded),debugInfo:{errorLocation:"retrieveResult.$isNullObject"}});return this.m_isNullObject},enumerable:!0,configurable:!0}),e.prototype.toJSON=function(){if(this.m_isLoaded)return this.m_isNullObject?null:(J.isUndefined(this.m_json)&&(this.m_json=J.purifyJson(this.m_value)),this.m_json)},e.prototype.toString=function(){return JSON.stringify(this.toJSON())},e.prototype._handleResult=function(e){this.m_isLoaded=!0,null===e||"object"==typeof e&&e&&e._IsNull?(this.m_isNullObject=!0,e=null):this.m_isNullObject=!1,this.m_shouldPolyfill&&(e=J.changePropertyNameToCamelLowerCase(e)),this.m_value=e,this.m_proxy._handleRetrieveResult(e,this)},e}(),D=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.getItemAt="GetItemAt",t.index="_Index",t.iterativeExecutor="IterativeExecutor",t.isTracked="_IsTracked",t.eventMessageCategory=65536,t.eventWorkbookId="Workbook",t.eventSourceRemote="Remote",t.proxy="$proxy",t.className="_className",t.isCollection="_isCollection",t.collectionPropertyPath="_collectionPropertyPath",t.objectPathInfoDoNotKeepReferenceFieldName="D",t.officeScriptEventId="X-OfficeScriptEventId",t.officeScriptFireRecordingEvent="X-OfficeScriptFireRecordingEvent",t.officeControlId="X-OfficeControlId",t}(S);e.Constants=D;var k=function(e){function t(t){var n=e.call(this,t)||this;return n.m_context=t,n.m_pendingProcessEventHandlers=[],n.m_pendingEventHandlerActions={},n.m_traceInfos={},n.m_responseTraceIds={},n.m_responseTraceMessages=[],n}return __extends(t,e),Object.defineProperty(t.prototype,"traceInfos",{get:function(){return this.m_traceInfos},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_responseTraceMessages",{get:function(){return this.m_responseTraceMessages},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_responseTraceIds",{get:function(){return this.m_responseTraceIds},enumerable:!0,configurable:!0}),t.prototype._setResponseTraceIds=function(e){if(e)for(var t=0;t<e.length;t++){var n=e[t];this.m_responseTraceIds[n]=n;var r=this.m_traceInfos[n];l.isNullOrUndefined(r)||this.m_responseTraceMessages.push(r)}},t.prototype.addTrace=function(e,t){this.m_traceInfos[e]=t},t.prototype._addPendingEventHandlerAction=function(e,t){this.m_pendingEventHandlerActions[e._id]||(this.m_pendingEventHandlerActions[e._id]=[],this.m_pendingProcessEventHandlers.push(e)),this.m_pendingEventHandlerActions[e._id].push(t)},Object.defineProperty(t.prototype,"_pendingProcessEventHandlers",{get:function(){return this.m_pendingProcessEventHandlers},enumerable:!0,configurable:!0}),t.prototype._getPendingEventHandlerActions=function(e){return this.m_pendingEventHandlerActions[e._id]},t}(v);e.ClientRequest=k;var F=function(){function e(e,t,n,r){var o=this;this.m_id=e._nextId(),this.m_context=e,this.m_name=n,this.m_handlers=[],this.m_registered=!1,this.m_eventInfo=r,this.m_callback=function(e){o.m_eventInfo.eventArgsTransformFunc(e).then((function(e){return o.fireEvent(e)}))}}return Object.defineProperty(e.prototype,"_registered",{get:function(){return this.m_registered},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"_id",{get:function(){return this.m_id},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"_handlers",{get:function(){return this.m_handlers},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"_context",{get:function(){return this.m_context},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"_callback",{get:function(){return this.m_callback},enumerable:!0,configurable:!0}),e.prototype.add=function(e){var t=E.createTraceAction(this.m_context,null,!1);return this.m_context._pendingRequest._addPendingEventHandlerAction(this,{id:t.actionInfo.Id,handler:e,operation:0}),new j(this.m_context,this,e)},e.prototype.remove=function(e){var t=E.createTraceAction(this.m_context,null,!1);this.m_context._pendingRequest._addPendingEventHandlerAction(this,{id:t.actionInfo.Id,handler:e,operation:1})},e.prototype.removeAll=function(){var e=E.createTraceAction(this.m_context,null,!1);this.m_context._pendingRequest._addPendingEventHandlerAction(this,{id:e.actionInfo.Id,handler:null,operation:2})},e.prototype._processRegistration=function(e){var t=this,n=l._createPromiseFromResult(null),r=e._getPendingEventHandlerActions(this);if(!r)return n;for(var o=[],i=0;i<this.m_handlers.length;i++)o.push(this.m_handlers[i]);var a=!1;for(i=0;i<r.length;i++)if(e._responseTraceIds[r[i].id])switch(a=!0,r[i].operation){case 0:o.push(r[i].handler);break;case 1:for(var s=o.length-1;s>=0;s--)if(o[s]===r[i].handler){o.splice(s,1);break}break;case 2:o=[]}return a&&(!this.m_registered&&o.length>0?n=n.then((function(){return t.m_eventInfo.registerFunc(t.m_callback)})).then((function(){return t.m_registered=!0})):this.m_registered&&0==o.length&&(n=n.then((function(){return t.m_eventInfo.unregisterFunc(t.m_callback)})).catch((function(e){l.log("Error when unregister event: "+JSON.stringify(e))})).then((function(){return t.m_registered=!1}))),n=n.then((function(){return t.m_handlers=o}))),n},e.prototype.fireEvent=function(e){for(var t=[],n=0;n<this.m_handlers.length;n++){var r=this.m_handlers[n],o=l._createPromiseFromResult(null).then(this.createFireOneEventHandlerFunc(r,e)).catch((function(e){l.log("Error when invoke handler: "+JSON.stringify(e))}));t.push(o)}l.Promise.all(t)},e.prototype.createFireOneEventHandlerFunc=function(e,t){return function(){return e(t)}},e}();e.EventHandlers=F;var j=function(){function e(e,t,n){this.m_context=e,this.m_allHandlers=t,this.m_handler=n}return Object.defineProperty(e.prototype,"context",{get:function(){return this.m_context},enumerable:!0,configurable:!0}),e.prototype.remove=function(){this.m_allHandlers&&this.m_handler&&(this.m_allHandlers.remove(this.m_handler),this.m_allHandlers=null,this.m_handler=null)},e}();e.EventHandlerResult=j,function(e){var t=function(){function t(){}return t.prototype.register=function(t,n,r){switch(t){case 4:return J.promisify((function(e){return Office.context.document.bindings.getByIdAsync(n,e)})).then((function(e){return J.promisify((function(t){return e.addHandlerAsync(Office.EventType.BindingDataChanged,r,t)}))}));case 3:return J.promisify((function(e){return Office.context.document.bindings.getByIdAsync(n,e)})).then((function(e){return J.promisify((function(t){return e.addHandlerAsync(Office.EventType.BindingSelectionChanged,r,t)}))}));case 2:return J.promisify((function(e){return Office.context.document.addHandlerAsync(Office.EventType.DocumentSelectionChanged,r,e)}));case 1:return J.promisify((function(e){return Office.context.document.settings.addHandlerAsync(Office.EventType.SettingsChanged,r,e)}));case 5:return OSF.DDA.RichApi.richApiMessageManager.register(r);case 13:return J.promisify((function(e){return Office.context.document.addHandlerAsync(Office.EventType.ObjectDeleted,r,{id:n},e)}));case 14:return J.promisify((function(e){return Office.context.document.addHandlerAsync(Office.EventType.ObjectSelectionChanged,r,{id:n},e)}));case 15:return J.promisify((function(e){return Office.context.document.addHandlerAsync(Office.EventType.ObjectDataChanged,r,{id:n},e)}));case 16:return J.promisify((function(e){return Office.context.document.addHandlerAsync(Office.EventType.ContentControlAdded,r,{id:n},e)}));default:throw e.RuntimeError._createInvalidArgError({argumentName:"eventId"})}},t.prototype.unregister=function(t,n,r){switch(t){case 4:return J.promisify((function(e){return Office.context.document.bindings.getByIdAsync(n,e)})).then((function(e){return J.promisify((function(t){return e.removeHandlerAsync(Office.EventType.BindingDataChanged,{handler:r},t)}))}));case 3:return J.promisify((function(e){return Office.context.document.bindings.getByIdAsync(n,e)})).then((function(e){return J.promisify((function(t){return e.removeHandlerAsync(Office.EventType.BindingSelectionChanged,{handler:r},t)}))}));case 2:return J.promisify((function(e){return Office.context.document.removeHandlerAsync(Office.EventType.DocumentSelectionChanged,{handler:r},e)}));case 1:return J.promisify((function(e){return Office.context.document.settings.removeHandlerAsync(Office.EventType.SettingsChanged,{handler:r},e)}));case 5:return J.promisify((function(e){return OSF.DDA.RichApi.richApiMessageManager.removeHandlerAsync("richApiMessage",{handler:r},e)}));case 13:return J.promisify((function(e){return Office.context.document.removeHandlerAsync(Office.EventType.ObjectDeleted,{id:n,handler:r},e)}));case 14:return J.promisify((function(e){return Office.context.document.removeHandlerAsync(Office.EventType.ObjectSelectionChanged,{id:n,handler:r},e)}));case 15:return J.promisify((function(e){return Office.context.document.removeHandlerAsync(Office.EventType.ObjectDataChanged,{id:n,handler:r},e)}));case 16:return J.promisify((function(e){return Office.context.document.removeHandlerAsync(Office.EventType.ContentControlAdded,{id:n,handler:r},e)}));default:throw e.RuntimeError._createInvalidArgError({argumentName:"eventId"})}},t}();e.officeJsEventRegistration=new t}(o=e._Internal||(e._Internal={}));var M=function(){function e(e,t){this.m_handlersByEventByTarget={},this.m_registerEventImpl=e,this.m_unregisterEventImpl=t}return e.getTargetIdOrDefault=function(e){return J.isNullOrUndefined(e)?"":e},e.prototype.getHandlers=function(t,n){n=e.getTargetIdOrDefault(n);var r=this.m_handlersByEventByTarget[t];r||(r={},this.m_handlersByEventByTarget[t]=r);var o=r[n];return o||(o=[],r[n]=o),o},e.prototype.callHandlers=function(e,t,n){for(var r=this.getHandlers(e,t),o=0;o<r.length;o++)r[o](n)},e.prototype.hasHandlers=function(e,t){return this.getHandlers(e,t).length>0},e.prototype.register=function(e,t,n){if(!n)throw o.RuntimeError._createInvalidArgError({argumentName:"handler"});var r=this.getHandlers(e,t);return r.push(n),1===r.length?this.m_registerEventImpl(e,t):J._createPromiseFromResult(null)},e.prototype.unregister=function(e,t,n){if(!n)throw o.RuntimeError._createInvalidArgError({argumentName:"handler"});for(var r=this.getHandlers(e,t),i=r.length-1;i>=0;i--)if(r[i]===n){r.splice(i,1);break}return 0===r.length?this.m_unregisterEventImpl(e,t):J._createPromiseFromResult(null)},e}();e.EventRegistration=M;var H=function(){function e(){this.m_eventRegistration=new M(this._registerEventImpl.bind(this),this._unregisterEventImpl.bind(this)),this.m_richApiMessageHandler=this._handleRichApiMessage.bind(this)}return e.prototype.ready=function(){var t=this;return this.m_ready||(e._testReadyImpl?this.m_ready=e._testReadyImpl().then((function(){t.m_isReady=!0})):i.instance?this.m_ready=J._createPromiseFromResult(null).then((function(){t.m_isReady=!0})):this.m_ready=o.officeJsEventRegistration.register(5,"",this.m_richApiMessageHandler).then((function(){t.m_isReady=!0}))),this.m_ready},Object.defineProperty(e.prototype,"isReady",{get:function(){return this.m_isReady},enumerable:!0,configurable:!0}),e.prototype.register=function(e,t,n){var r=this;return this.ready().then((function(){return r.m_eventRegistration.register(e,t,n)}))},e.prototype.unregister=function(e,t,n){var r=this;return this.ready().then((function(){return r.m_eventRegistration.unregister(e,t,n)}))},e.prototype._registerEventImpl=function(e,t){return J._createPromiseFromResult(null)},e.prototype._unregisterEventImpl=function(e,t){return J._createPromiseFromResult(null)},e.prototype._handleRichApiMessage=function(e){if(e&&e.entries)for(var t=0;t<e.entries.length;t++){var n=e.entries[t];if(n.messageCategory==D.eventMessageCategory){l._logEnabled&&l.log(JSON.stringify(n));var r=n.messageType,o=n.targetId;if(this.m_eventRegistration.hasHandlers(r,o)){var i=JSON.parse(n.message);n.isRemoteOverride&&(i.source=D.eventSourceRemote),this.m_eventRegistration.callHandlers(r,o,i)}}}},e.getGenericEventRegistration=function(t){l.isNullOrUndefined(t)&&(t="");var n=e.s_genericEventRegistrations[t];return n||(n=new e,e.s_genericEventRegistrations[t]=n),n},e.peekGenericEventRegistrationOrNull=function(t){return l.isNullOrUndefined(t)&&(t=""),e.s_genericEventRegistrations[t]},e.richApiMessageEventCategory=65536,e.s_genericEventRegistrations={},e}();e.GenericEventRegistration=H,e._testSetRichApiMessageReadyImpl=function(e){H._testReadyImpl=e},e._testTriggerRichApiMessageEvent=function(e){H.getGenericEventRegistration("")._handleRichApiMessage(e)};var U=function(e){function t(t,n,r,o){var i=e.call(this,t,n,r,o)||this;return i.m_genericEventInfo=o,i}return __extends(t,e),t.prototype.add=function(e){var t=this;0==this._handlers.length&&this.m_genericEventInfo.registerFunc&&this.m_genericEventInfo.registerFunc();var n=this._context._controlId;return H.getGenericEventRegistration(n).isReady||this._context._pendingRequest._addPreSyncPromise(H.getGenericEventRegistration(n).ready()),E.createTraceMarkerForCallback(this._context,(function(){t._handlers.push(e),1==t._handlers.length&&H.getGenericEventRegistration(n).register(t.m_genericEventInfo.eventType,t.m_genericEventInfo.getTargetIdFunc(),t._callback)})),new j(this._context,this,e)},t.prototype.remove=function(e){var t=this;1==this._handlers.length&&this.m_genericEventInfo.unregisterFunc&&this.m_genericEventInfo.unregisterFunc();var n=this._context._controlId;E.createTraceMarkerForCallback(this._context,(function(){for(var r=t._handlers,o=r.length-1;o>=0;o--)if(r[o]===e){r.splice(o,1);break}0==r.length&&H.getGenericEventRegistration(n).unregister(t.m_genericEventInfo.eventType,t.m_genericEventInfo.getTargetIdFunc(),t._callback)}))},t.prototype.removeAll=function(){},t}(F);e.GenericEventHandlers=U;var L=function(){function e(e){this.m_clientObject=e}return e.prototype._handleResult=function(e){this.m_clientObject._handleIdResult(e)},e}(),B=function(){function e(){}return e.createGlobalObjectObjectPath=function(e){var t={Id:e._nextId(),ObjectPathType:1,Name:""};return new g(t,null,!1,!1,1,4)},e.createNewObjectObjectPath=function(e,t,n,r){var o={Id:e._nextId(),ObjectPathType:2,Name:t};return new g(o,null,n,!1,1,J._fixupApiFlags(r))},e.createPropertyObjectPath=function(e,t,n,r,o,i){var a={Id:e._nextId(),ObjectPathType:4,Name:n,ParentObjectPathId:t._objectPath.objectPathInfo.Id};return new g(a,t._objectPath,r,o,1,J._fixupApiFlags(i))},e.createIndexerObjectPath=function(e,t,n){var r={Id:e._nextId(),ObjectPathType:5,Name:"",ParentObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}};return r.ArgumentInfo.Arguments=n,new g(r,t._objectPath,!1,!1,1,4)},e.createIndexerObjectPathUsingParentPath=function(e,t,n){var r={Id:e._nextId(),ObjectPathType:5,Name:"",ParentObjectPathId:t.objectPathInfo.Id,ArgumentInfo:{}};return r.ArgumentInfo.Arguments=n,new g(r,t,!1,!1,1,4)},e.createMethodObjectPath=function(e,t,n,r,o,i,a,s,c){var u={Id:e._nextId(),ObjectPathType:3,Name:n,ParentObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}},l=J.setMethodArguments(e,u.ArgumentInfo,o),f=new g(u,t._objectPath,i,a,r,J._fixupApiFlags(c));return f.argumentObjectPaths=l,f.getByIdMethodName=s,f},e.createReferenceIdObjectPath=function(e,t){var n={Id:e._nextId(),ObjectPathType:6,Name:t,ArgumentInfo:{}};return new g(n,null,!1,!1,1,4)},e.createChildItemObjectPathUsingIndexerOrGetItemAt=function(t,n,r,o,i){var a=J.tryGetObjectIdFromLoadOrRetrieveResult(o);return t&&!J.isNullOrUndefined(a)?e.createChildItemObjectPathUsingIndexer(n,r,o):e.createChildItemObjectPathUsingGetItemAt(n,r,o,i)},e.createChildItemObjectPathUsingIndexer=function(e,t,n){var r=J.tryGetObjectIdFromLoadOrRetrieveResult(n),o=o={Id:e._nextId(),ObjectPathType:5,Name:"",ParentObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}};return o.ArgumentInfo.Arguments=[r],new g(o,t._objectPath,!1,!1,1,4)},e.createChildItemObjectPathUsingGetItemAt=function(e,t,n,r){var o=n[D.index];o&&(r=o);var i={Id:e._nextId(),ObjectPathType:3,Name:D.getItemAt,ParentObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}};return i.ArgumentInfo.Arguments=[r],new g(i,t._objectPath,!1,!1,1,4)},e}();e.ObjectPathFactory=B;var W=function(){function t(e){this.m_context=e}return t.prototype.executeAsync=function(n,r,o,i){var a=this,s=u.buildMessageArrayForIRequestExecutor(n,r,o,t.SourceLibHeaderValue,i),c=this.m_context._blockWrite&&0!=(1&r);if(c)throw"Block Write: "+c;return new e.Promise((function(e,t){OSF.DDA.RichApi.executeRichApiRequestAsync(s,(function(t){var n;l.log("Response:"),l.log(JSON.stringify(t)),"succeeded"==t.status?n=u.buildResponseOnSuccess(u.getResponseBody(t),u.getResponseHeaders(t)):(n=u.buildResponseOnError(t.error.code,t.error.message),a.m_context._processOfficeJsErrorResponse(t.error.code,n)),e(n)}))}))},t.SourceLibHeaderValue="officejs",t}(),G=function(){function e(e){this._autoCleanupList={},this.m_context=e}return e.prototype.add=function(e){var t=this;Array.isArray(e)?e.forEach((function(e){return t._addCommon(e,!0)})):this._addCommon(e,!0)},e.prototype._autoAdd=function(e){this._addCommon(e,!1),this._autoCleanupList[e._objectPath.objectPathInfo.Id]=e},e.prototype._autoTrackIfNecessaryWhenHandleObjectResultValue=function(e,t){this.m_context._autoCleanup&&!e[D.isTracked]&&e!==this.m_context._rootObject&&t&&!J.isNullOrEmptyString(t[D.referenceId])&&(this._autoCleanupList[e._objectPath.objectPathInfo.Id]=e,e[D.isTracked]=!0)},e.prototype._addCommon=function(e,t){if(e[D.isTracked])t&&this.m_context._autoCleanup&&delete this._autoCleanupList[e._objectPath.objectPathInfo.Id];else{var n=e[D.referenceId];if(e._objectPath.objectPathInfo[D.objectPathInfoDoNotKeepReferenceFieldName])throw J.createRuntimeError(a.generalException,l._getResourceString(V.objectIsUntracked),null);J.isNullOrEmptyString(n)&&e._KeepReference&&(e._KeepReference(),E.createInstantiateAction(this.m_context,e),t&&this.m_context._autoCleanup&&delete this._autoCleanupList[e._objectPath.objectPathInfo.Id],e[D.isTracked]=!0)}},e.prototype.remove=function(e){var t=this;Array.isArray(e)?e.forEach((function(e){return t._removeCommon(e)})):this._removeCommon(e)},e.prototype._removeCommon=function(e){e._objectPath.objectPathInfo[D.objectPathInfoDoNotKeepReferenceFieldName]=!0,e.context._pendingRequest._removeKeepReferenceAction(e._objectPath.objectPathInfo.Id);var t=e[D.referenceId];if(!J.isNullOrEmptyString(t)){var n=this.m_context._rootObject;n._RemoveReference&&n._RemoveReference(t)}delete e[D.isTracked]},e.prototype._retrieveAndClearAutoCleanupList=function(){var e=this._autoCleanupList;return this._autoCleanupList={},e},e}();e.TrackedObjects=G;var q=function(){function t(e,t,n,r,o){e||(e="root"),this.m_globalObjName=e,this.m_referencedObjectPaths=t,this.m_actions=n,this.m_statements=[],this.m_variableNameForObjectPathMap={},this.m_variableNameToObjectPathMap={},this.m_declaredObjectPathMap={},this.m_showDispose=r,this.m_removePII=o}return t.prototype.process=function(){this.m_showDispose&&k._calculateLastUsedObjectPathIds(this.m_actions);for(var e=0;e<this.m_actions.length;e++)this.processOneAction(this.m_actions[e]);return this.m_statements},t.prototype.processForDebugStatementInfo=function(e){this.m_showDispose&&k._calculateLastUsedObjectPathIds(this.m_actions);this.m_statements=[];for(var t=-1,n=0;n<this.m_actions.length&&(this.processOneAction(this.m_actions[n]),e==n&&(t=this.m_statements.length-1),!(t>=0&&this.m_statements.length>t+5+1));n++);if(t<0)return null;var r=t-5;r<0&&(r=0);var o=t+1+5;o>this.m_statements.length&&(o=this.m_statements.length);var i=[];0!=r&&i.push("...");for(var a=r;a<t;a++)i.push(this.m_statements[a]);i.push("// >>>>>"),i.push(this.m_statements[t]),i.push("// <<<<<");for(var s=t+1;s<o;s++)i.push(this.m_statements[s]);return o<this.m_statements.length&&i.push("..."),{statement:this.m_statements[t],surroundingStatements:i}},t.prototype.processOneAction=function(e){switch(e.actionInfo.ActionType){case 1:this.processInstantiateAction(e);break;case 3:this.processMethodAction(e);break;case 2:this.processQueryAction(e);break;case 7:this.processQueryAsJsonAction(e);break;case 6:this.processRecursiveQueryAction(e);break;case 4:this.processSetPropertyAction(e);break;case 5:this.processTraceAction(e);break;case 8:this.processEnsureUnchangedAction(e);break;case 9:this.processUpdateAction(e)}},t.prototype.processInstantiateAction=function(e){var t=e.actionInfo.ObjectPathId,n=this.m_referencedObjectPaths[t],r=this.getObjVarName(t);if(this.m_declaredObjectPathMap[t]){o="// Instantiate {"+r+"}";o=this.appendDisposeCommentIfRelevant(o,e),this.m_statements.push(o)}else{var o="var "+r+" = "+this.buildObjectPathExpressionWithParent(n)+";";o=this.appendDisposeCommentIfRelevant(o,e),this.m_statements.push(o),this.m_declaredObjectPathMap[t]=r}},t.prototype.processMethodAction=function(t){var n=t.actionInfo.Name;if("_KeepReference"===n){if(!e._internalConfig.showInternalApiInDebugInfo)return;n="track"}var r=this.getObjVarName(t.actionInfo.ObjectPathId)+"."+J._toCamelLowerCase(n)+"("+this.buildArgumentsExpression(t.actionInfo.ArgumentInfo)+");";r=this.appendDisposeCommentIfRelevant(r,t),this.m_statements.push(r)},t.prototype.processQueryAction=function(e){var t=this.buildQueryExpression(e),n=this.getObjVarName(e.actionInfo.ObjectPathId)+".load("+t+");";n=this.appendDisposeCommentIfRelevant(n,e),this.m_statements.push(n)},t.prototype.processQueryAsJsonAction=function(e){var t=this.buildQueryExpression(e),n=this.getObjVarName(e.actionInfo.ObjectPathId)+".retrieve("+t+");";n=this.appendDisposeCommentIfRelevant(n,e),this.m_statements.push(n)},t.prototype.processRecursiveQueryAction=function(e){var t="";e.actionInfo.RecursiveQueryInfo&&(t=JSON.stringify(e.actionInfo.RecursiveQueryInfo));var n=this.getObjVarName(e.actionInfo.ObjectPathId)+".loadRecursive("+t+");";n=this.appendDisposeCommentIfRelevant(n,e),this.m_statements.push(n)},t.prototype.processSetPropertyAction=function(e){var t=this.getObjVarName(e.actionInfo.ObjectPathId)+"."+J._toCamelLowerCase(e.actionInfo.Name)+" = "+this.buildArgumentsExpression(e.actionInfo.ArgumentInfo)+";";t=this.appendDisposeCommentIfRelevant(t,e),this.m_statements.push(t)},t.prototype.processTraceAction=function(e){var t="context.trace();";t=this.appendDisposeCommentIfRelevant(t,e),this.m_statements.push(t)},t.prototype.processEnsureUnchangedAction=function(e){var t=this.getObjVarName(e.actionInfo.ObjectPathId)+".ensureUnchanged("+JSON.stringify(e.actionInfo.ObjectState)+");";t=this.appendDisposeCommentIfRelevant(t,e),this.m_statements.push(t)},t.prototype.processUpdateAction=function(e){var t=this.getObjVarName(e.actionInfo.ObjectPathId)+".update("+JSON.stringify(e.actionInfo.ObjectState)+");";t=this.appendDisposeCommentIfRelevant(t,e),this.m_statements.push(t)},t.prototype.appendDisposeCommentIfRelevant=function(e,t){var n=this;if(this.m_showDispose){var r=t.actionInfo.L;if(r&&r.length>0)return e+" // And then dispose {"+r.map((function(e){return n.getObjVarName(e)})).join(", ")+"}"}return e},t.prototype.buildQueryExpression=function(e){if(e.actionInfo.QueryInfo){var t={};return t.select=e.actionInfo.QueryInfo.Select,t.expand=e.actionInfo.QueryInfo.Expand,t.skip=e.actionInfo.QueryInfo.Skip,t.top=e.actionInfo.QueryInfo.Top,void 0===t.top&&void 0===t.skip&&void 0===t.expand?void 0===t.select?"":JSON.stringify(t.select):JSON.stringify(t)}return""},t.prototype.buildObjectPathExpressionWithParent=function(e){return(5==e.objectPathInfo.ObjectPathType||3==e.objectPathInfo.ObjectPathType||4==e.objectPathInfo.ObjectPathType)&&e.objectPathInfo.ParentObjectPathId?this.getObjVarName(e.objectPathInfo.ParentObjectPathId)+"."+this.buildObjectPathExpression(e):this.buildObjectPathExpression(e)},t.prototype.buildObjectPathExpression=function(e){var t=this.buildObjectPathInfoExpression(e.objectPathInfo),n=e.originalObjectPathInfo;return n&&(t=t+" /* originally "+this.buildObjectPathInfoExpression(n)+" */"),t},t.prototype.buildObjectPathInfoExpression=function(e){switch(e.ObjectPathType){case 1:return"context."+this.m_globalObjName;case 5:return"getItem("+this.buildArgumentsExpression(e.ArgumentInfo)+")";case 3:return J._toCamelLowerCase(e.Name)+"("+this.buildArgumentsExpression(e.ArgumentInfo)+")";case 2:return e.Name+".newObject()";case 7:return"null";case 4:return J._toCamelLowerCase(e.Name);case 6:return"context."+this.m_globalObjName+"._getObjectByReferenceId("+JSON.stringify(e.Name)+")"}},t.prototype.buildArgumentsExpression=function(e){var t="";if(!e.Arguments||0===e.Arguments.length)return t;if(this.m_removePII)return void 0===e.Arguments[0]?t:"...";for(var n=0;n<e.Arguments.length;n++)n>0&&(t+=", "),t+=this.buildArgumentLiteral(e.Arguments[n],e.ReferencedObjectPathIds?e.ReferencedObjectPathIds[n]:null);return"undefined"===t&&(t=""),t},t.prototype.buildArgumentLiteral=function(e,t){return"number"==typeof e&&e===t?this.getObjVarName(t):JSON.stringify(e)},t.prototype.getObjVarNameBase=function(e){var t="v",n=this.m_referencedObjectPaths[e];if(n)switch(n.objectPathInfo.ObjectPathType){case 1:t=this.m_globalObjName;break;case 4:t=J._toCamelLowerCase(n.objectPathInfo.Name);break;case 3:var r=n.objectPathInfo.Name;r.length>3&&"Get"===r.substr(0,3)&&(r=r.substr(3)),t=J._toCamelLowerCase(r);break;case 5:var o=this.getObjVarNameBase(n.objectPathInfo.ParentObjectPathId);t="s"===o.charAt(o.length-1)?o.substr(0,o.length-1):o+"Item"}return t},t.prototype.getObjVarName=function(e){if(this.m_variableNameForObjectPathMap[e])return this.m_variableNameForObjectPathMap[e];var t=this.getObjVarNameBase(e);if(!this.m_variableNameToObjectPathMap[t])return this.m_variableNameForObjectPathMap[e]=t,this.m_variableNameToObjectPathMap[t]=e,t;for(var n=1;this.m_variableNameToObjectPathMap[t+n.toString()];)n++;return t+=n.toString(),this.m_variableNameForObjectPathMap[e]=t,this.m_variableNameToObjectPathMap[t]=e,t},t}(),V=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.cannotRegisterEvent="CannotRegisterEvent",t.connectionFailureWithStatus="ConnectionFailureWithStatus",t.connectionFailureWithDetails="ConnectionFailureWithDetails",t.propertyNotLoaded="PropertyNotLoaded",t.runMustReturnPromise="RunMustReturnPromise",t.moreInfoInnerError="MoreInfoInnerError",t.cannotApplyPropertyThroughSetMethod="CannotApplyPropertyThroughSetMethod",t.invalidOperationInCellEditMode="InvalidOperationInCellEditMode",t.objectIsUntracked="ObjectIsUntracked",t.customFunctionDefintionMissing="CustomFunctionDefintionMissing",t.customFunctionImplementationMissing="CustomFunctionImplementationMissing",t.customFunctionNameContainsBadChars="CustomFunctionNameContainsBadChars",t.customFunctionNameCannotSplit="CustomFunctionNameCannotSplit",t.customFunctionUnexpectedNumberOfEntriesInResultBatch="CustomFunctionUnexpectedNumberOfEntriesInResultBatch",t.customFunctionCancellationHandlerMissing="CustomFunctionCancellationHandlerMissing",t.customFunctionInvalidFunction="CustomFunctionInvalidFunction",t.customFunctionInvalidFunctionMapping="CustomFunctionInvalidFunctionMapping",t.customFunctionWindowMissing="CustomFunctionWindowMissing",t.customFunctionDefintionMissingOnWindow="CustomFunctionDefintionMissingOnWindow",t.pendingBatchInProgress="PendingBatchInProgress",t.notInsideBatch="NotInsideBatch",t.cannotUpdateReadOnlyProperty="CannotUpdateReadOnlyProperty",t}(I);e.ResourceStrings=V,l.addResourceStringValues({CannotRegisterEvent:"The event handler cannot be registered.",PropertyNotLoaded:"The property '{0}' is not available. Before reading the property's value, call the load method on the containing object and call \"context.sync()\" on the associated request context.",RunMustReturnPromise:'The batch function passed to the ".run" method didn\'t return a promise. The function must return a promise, so that any automatically-tracked objects can be released at the completion of the batch operation. Typically, you return a promise by returning the response from "context.sync()".',InvalidOrTimedOutSessionMessage:"Your Office Online session has expired or is invalid. To continue, refresh the page.",InvalidOperationInCellEditMode:"Excel is in cell-editing mode. Please exit the edit mode by pressing ENTER or TAB or selecting another cell, and then try again.",InvalidSheetName:"The request cannot be processed because the specified worksheet cannot be found. Please try again.",CustomFunctionDefintionMissing:"A property with the name '{0}' that represents the function's definition must exist on Excel.Script.CustomFunctions.",CustomFunctionDefintionMissingOnWindow:"A property with the name '{0}' that represents the function's definition must exist on the window object.",CustomFunctionImplementationMissing:"The property with the name '{0}' on Excel.Script.CustomFunctions that represents the function's definition must contain a 'call' property that implements the function.",CustomFunctionNameContainsBadChars:"The function name may only contain letters, digits, underscores, and periods.",CustomFunctionNameCannotSplit:"The function name must contain a non-empty namespace and a non-empty short name.",CustomFunctionUnexpectedNumberOfEntriesInResultBatch:"The batching function returned a number of results that doesn't match the number of parameter value sets that were passed into it.",CustomFunctionCancellationHandlerMissing:"The cancellation handler onCanceled is missing in the function. The handler must be present as the function is defined as cancelable.",CustomFunctionInvalidFunction:"The property with the name '{0}' that represents the function's definition is not a valid function.",CustomFunctionInvalidFunctionMapping:"The property with the name '{0}' on CustomFunctionMappings that represents the function's definition is not a valid function.",CustomFunctionWindowMissing:"The window object was not found.",PendingBatchInProgress:"There is a pending batch in progress. The batch method may not be called inside another batch, or simultaneously with another batch.",NotInsideBatch:"Operations may not be invoked outside of a batch method.",CannotUpdateReadOnlyProperty:"The property '{0}' is read-only and it cannot be updated.",ObjectIsUntracked:"The object is untracked."});var J=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),n.fixObjectPathIfNecessary=function(e,t){e&&e._objectPath&&t&&e._objectPath.updateUsingObjectData(t,e)},n.load=function(e,t){return e.context.load(e,t),e},n.loadAndSync=function(e,t){return e.context.load(e,t),e.context.sync().then((function(){return e}))},n.retrieve=function(t,r){var o=e._internalConfig.alwaysPolyfillClientObjectRetrieveMethod;o||(o=!n.isSetSupported("RichApiRuntime","1.1"));var i=new N(t,o);return t._retrieve(r,i),i},n.retrieveAndSync=function(e,t){var r=n.retrieve(e,t);return e.context.sync().then((function(){return r}))},n.toJson=function(e,t,r,o){var i={};for(var a in t){void 0!==(s=t[a])&&(i[a]=s)}for(var a in r){var s;void 0!==(s=r[a])&&(s[n.fieldName_isCollection]&&void 0!==s[n.fieldName_m__items]?i[a]=s.toJSON().items:i[a]=s.toJSON())}return o&&(i.items=o.map((function(e){return e.toJSON()}))),i},n.throwError=function(e,t,n){throw new o.RuntimeError({code:e,httpStatusCode:400,message:l._getResourceString(e,t),debugInfo:n?{errorLocation:n}:void 0})},n.createRuntimeError=function(e,t,n,r,i){return new o.RuntimeError({code:e,httpStatusCode:r,message:t,debugInfo:{errorLocation:n},data:i})},n.throwIfNotLoaded=function(e,t,r,o){if(!o&&l.isUndefined(t)&&e.charCodeAt(0)!=n.s_underscoreCharCode&&!n.s_suppressPropertyNotLoadedException)throw n.createPropertyNotLoadedException(r,e)},n._getPropertyValueWithoutCheckLoaded=function(e,t){n.s_suppressPropertyNotLoadedException=!0;try{return e[t]}finally{n.s_suppressPropertyNotLoadedException=!1}},n.createPropertyNotLoadedException=function(e,t){return new o.RuntimeError({code:A.propertyNotLoaded,httpStatusCode:400,message:l._getResourceString(V.propertyNotLoaded,t),debugInfo:e?{errorLocation:e+"."+t}:void 0})},n.createCannotUpdateReadOnlyPropertyException=function(e,t){return new o.RuntimeError({code:A.cannotUpdateReadOnlyProperty,httpStatusCode:400,message:l._getResourceString(V.cannotUpdateReadOnlyProperty,t),debugInfo:e?{errorLocation:e+"."+t}:void 0})},n.promisify=function(t){return new e.Promise((function(e,n){t((function(t){"failed"==t.status?n(t.error):e(t.value)}))}))},n._addActionResultHandler=function(e,t,n){e.context._pendingRequest.addActionResultHandler(t,n)},n._handleNavigationPropertyResults=function(e,t,n){for(var r=0;r<n.length-1;r+=2)l.isUndefined(t[n[r+1]])||e[n[r]]._handleResult(t[n[r+1]])},n._fixupApiFlags=function(e){return"boolean"==typeof e&&(e=e?1:0),e},n.definePropertyThrowUnloadedException=function(e,t,r){Object.defineProperty(e,r,{configurable:!0,enumerable:!0,get:function(){throw n.createPropertyNotLoadedException(t,r)},set:function(){throw n.createCannotUpdateReadOnlyPropertyException(t,r)}})},n.defineReadOnlyPropertyWithValue=function(e,t,r){Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){return r},set:function(){throw n.createCannotUpdateReadOnlyPropertyException(null,t)}})},n.processRetrieveResult=function(e,t,r,o){if(!l.isNullOrUndefined(t))if(o){var i=t[D.itemsLowerCase];if(Array.isArray(i)){for(var a=[],s=0;s<i.length;s++){var c=o(i[s],s),u={};u[D.proxy]=c,c._handleRetrieveResult(i[s],u),a.push(u)}n.defineReadOnlyPropertyWithValue(r,D.itemsLowerCase,a)}}else{var f=e[D.scalarPropertyNames],p=e[D.navigationPropertyNames],d=e[D.className];if(f)for(s=0;s<f.length;s++){var h=t[g=f[s]];l.isUndefined(h)?n.definePropertyThrowUnloadedException(r,d,g):n.defineReadOnlyPropertyWithValue(r,g,h)}if(p)for(s=0;s<p.length;s++){var g;h=t[g=p[s]];if(l.isUndefined(h))n.definePropertyThrowUnloadedException(r,d,g);else{var m=e[g],y={};m._handleRetrieveResult(h,y),y[D.proxy]=m,Array.isArray(y[D.itemsLowerCase])&&(y=y[D.itemsLowerCase]),n.defineReadOnlyPropertyWithValue(r,g,y)}}}},n.setMockData=function(e,t,r,o){if(l.isNullOrUndefined(t))e._handleResult(t);else{if(e[D.scalarPropertyOriginalNames]){for(var i={},a=e[D.scalarPropertyOriginalNames],s=e[D.scalarPropertyNames],c=0;c<s.length;c++)void 0!==t[s[c]]&&(i[a[c]]=t[s[c]]);e._handleResult(i)}if(e[D.navigationPropertyNames]){var u=e[D.navigationPropertyNames];for(c=0;c<u.length;c++)if(void 0!==t[u[c]]){var f=e[u[c]];f.setMockData&&f.setMockData(t[u[c]])}}if(e[D.isCollection]&&r){var p=Array.isArray(t)?t:t[D.itemsLowerCase];if(Array.isArray(p)){var d=[];for(c=0;c<p.length;c++){var h=r(p,c);n.setMockData(h,p[c]),d.push(h)}o(d)}}}},n.applyMixin=function(e,t){Object.getOwnPropertyNames(t.prototype).forEach((function(n){"constructor"!==n&&Object.defineProperty(e.prototype,n,Object.getOwnPropertyDescriptor(t.prototype,n))}))},n.ensureTypeInitialized=function(e){var t=new x;new e(t,B.createNewObjectObjectPath(t,"Temp",!1,0))},n.fieldName_m__items="m__items",n.fieldName_isCollection="_isCollection",n._synchronousCleanup=!1,n.s_underscoreCharCode="_".charCodeAt(0),n.s_suppressPropertyNotLoadedException=!1,n}(C);e.Utility=J;var z=function(){function e(){}return e.invokeMethod=function(e,t,n,r,o,i){var a=E.createMethodAction(e.context,e,t,n,r,o),s=new _(i);return J._addActionResultHandler(e,a,s),s},e.invokeEnsureUnchanged=function(e,t){E.createEnsureUnchangedAction(e.context,e,t)},e.invokeSetProperty=function(e,t,n,r){E.createSetPropertyAction(e.context,e,t,n,r)},e.createRootServiceObject=function(e,t){return new e(t,B.createGlobalObjectObjectPath(t))},e.createObjectFromReferenceId=function(e,t,n){return new e(t,B.createReferenceIdObjectPath(t,n))},e.createTopLevelServiceObject=function(e,t,n,r,o){return new e(t,B.createNewObjectObjectPath(t,n,r,o))},e.createPropertyObject=function(e,t,n,r,o){var i=B.createPropertyObjectPath(t.context,t,n,r,!1,o);return new e(t.context,i)},e.createIndexerObject=function(e,t,n){var r=B.createIndexerObjectPath(t.context,t,n);return new e(t.context,r)},e.createMethodObject=function(e,t,n,r,o,i,a,s,c){var u=B.createMethodObjectPath(t.context,t,n,r,o,i,a,s,c);return new e(t.context,u)},e.createChildItemObject=function(e,t,n,r,o){var i=B.createChildItemObjectPathUsingIndexerOrGetItemAt(t,n.context,n,r,o);return new e(n.context,i)},e}();e.BatchApiHelper=z;var K=function(){function t(e){if(this.m_namespaceMap={},this.m_namespace=e.metadata.name,this.m_targetNamespaceObject=e.targetNamespaceObject,this.m_namespaceMap[this.m_namespace]=e.targetNamespaceObject,e.namespaceMap)for(var t in e.namespaceMap)this.m_namespaceMap[t]=e.namespaceMap[t];this.m_defaultApiSetName=e.metadata.defaultApiSetName,this.m_hostName=e.metadata.hostName;var n=e.metadata;if(n.enumTypes)for(var r=0;r<n.enumTypes.length;r++)this.buildEnumType(n.enumTypes[r]);if(n.apiSets){for(r=0;r<n.apiSets.length;r++){var o=n.apiSets[r];Array.isArray(o)&&(n.apiSets[r]={version:o[0],name:o[1]||this.m_defaultApiSetName})}this.m_apiSets=n.apiSets}if(this.m_strings=n.strings,n.clientObjectTypes)for(r=0;r<n.clientObjectTypes.length;r++){o=n.clientObjectTypes[r];Array.isArray(o)&&(this.ensureArraySize(o,11),n.clientObjectTypes[r]={name:this.getString(o[0]),behaviorFlags:o[1],collectionPropertyPath:this.getString(o[6]),newObjectServerTypeFullName:this.getString(o[9]),newObjectApiFlags:o[10],childItemTypeFullName:this.getString(o[7]),scalarProperties:o[2],navigationProperties:o[3],scalarMethods:o[4],navigationMethods:o[5],events:o[8]}),this.buildClientObjectType(n.clientObjectTypes[r],e.fullyInitialize)}}return t.prototype.ensureArraySize=function(e,t){for(var n=t-e.length;n>0;)e.push(0),n--},t.prototype.getString=function(e){return"number"==typeof e?e>0?this.m_strings[e-1]:null:e},t.prototype.buildEnumType=function(e){var t;if(Array.isArray(e)){(t={name:e[0],fields:e[2]}).fields||(t.fields={});var n=e[1];if(Array.isArray(n))for(var r=0;r<n.length;r++)t.fields[n[r]]=this.toSimpleCamelUpperCase(n[r])}else t=e;this.m_targetNamespaceObject[t.name]=t.fields},t.prototype.buildClientObjectType=function(n,r){var o=this,i=function(t,r){R.apply(this,arguments),o.m_targetNamespaceObject[n.name]._typeInited||(o.buildPrototype(o.m_targetNamespaceObject[n.name],n),o.m_targetNamespaceObject[n.name]._typeInited=!0),e._internalConfig.appendTypeNameToObjectPathInfo&&this._objectPath&&this._objectPath.objectPathInfo&&this._className&&(this._objectPath.objectPathInfo.T=this._className)};(this.m_targetNamespaceObject[n.name]=i,this.extendsType(i,R),this.buildNewObject(i,n),0!=(2&n.behaviorFlags)&&(i.prototype._KeepReference=function(){z.invokeMethod(this,"_KeepReference",1,[],0,0)}),0!=(32&n.behaviorFlags))&&this.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_StaticCustomize").call(null,i);r&&(this.buildPrototype(i,n),i._typeInited=!0)},t.prototype.extendsType=function(e,t){function n(){this.constructor=e}e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)},t.prototype.findObjectUnderPath=function(t,n,r){for(var o=t,i=r;i<n.length;i++){if("object"!=typeof o)throw new e.Error("Cannot find "+n.join("."));o=o[n[i]]}return o},t.prototype.getFunction=function(t){var n=this.resolveObjectByFullName(t);if("function"!=typeof n)throw new e.Error("Cannot find function or type: "+t);return n},t.prototype.resolveObjectByFullName=function(e){var t=e.split(".");if(1===t.length)return this.m_targetNamespaceObject[t[0]];var n=t[0];return n===this.m_namespace?this.findObjectUnderPath(this.m_targetNamespaceObject,t,1):this.m_namespaceMap[n]?this.findObjectUnderPath(this.m_namespaceMap[n],t,1):this.findObjectUnderPath(this.m_targetNamespaceObject,t,0)},t.prototype.evaluateSimpleExpression=function(t,n){if(J.isNullOrUndefined(t))return null;var r=t.split(".");if(3===r.length&&"OfficeExtension"===r[0]&&"Constants"===r[1])return D[r[2]];if("this"===r[0]){for(var o=n,i=1;i<r.length;i++)o="toString()"==r[i]?o.toString():"()"===r[i].substr(r[i].length-2)?o[r[i].substr(0,r[i].length-2)]():o[r[i]];return o}throw new e.Error("Cannot evaluate: "+t)},t.prototype.evaluateEventTargetId=function(e,t){return J.isNullOrEmptyString(e)?"":this.evaluateSimpleExpression(e,t)},t.prototype.isAllDigits=function(e){for(var t="0".charCodeAt(0),n="9".charCodeAt(0),r=0;r<e.length;r++)if(e.charCodeAt(r)<t||e.charCodeAt(r)>n)return!1;return!0},t.prototype.evaluateEventType=function(t){if(J.isNullOrEmptyString(t))return 0;if(this.isAllDigits(t))return parseInt(t);var n=this.resolveObjectByFullName(t);if("number"!=typeof n)throw new e.Error("Invalid event type: "+t);return n},t.prototype.buildPrototype=function(e,t){this.buildScalarProperties(e,t),this.buildNavigationProperties(e,t),this.buildScalarMethods(e,t),this.buildNavigationMethods(e,t),this.buildEvents(e,t),this.buildHandleResult(e,t),this.buildHandleIdResult(e,t),this.buildHandleRetrieveResult(e,t),this.buildLoad(e,t),this.buildRetrieve(e,t),this.buildSetMockData(e,t),this.buildEnsureUnchanged(e,t),this.buildUpdate(e,t),this.buildSet(e,t),this.buildToJSON(e,t),this.buildItems(e,t),this.buildTypeMetadataInfo(e,t),this.buildTrackUntrack(e,t),this.buildMixin(e,t)},t.prototype.toSimpleCamelUpperCase=function(e){return e.substr(0,1).toUpperCase()+e.substr(1)},t.prototype.ensureOriginalName=function(e){null===e.originalName&&(e.originalName=this.toSimpleCamelUpperCase(e.name))},t.prototype.getFieldName=function(e){return"m_"+e.name},t.prototype.throwIfApiNotSupported=function(e,t){if(this.m_apiSets&&t.apiSetInfoOrdinal>0){var n=this.m_apiSets[t.apiSetInfoOrdinal-1];n&&J.throwIfApiNotSupported(e.name+"."+t.name,n.name,n.version,this.m_hostName)}},t.prototype.buildScalarProperties=function(e,t){if(Array.isArray(t.scalarProperties))for(var n=0;n<t.scalarProperties.length;n++){var r=t.scalarProperties[n];Array.isArray(r)&&(this.ensureArraySize(r,6),t.scalarProperties[n]={name:this.getString(r[0]),behaviorFlags:r[1],apiSetInfoOrdinal:r[2],originalName:this.getString(r[3]),setMethodApiFlags:r[4],undoableApiSetInfoOrdinal:r[5]}),this.buildScalarProperty(e,t,t.scalarProperties[n])}},t.prototype.calculateApiFlags=function(e,t){if(t>0){var n=this.m_apiSets[t-1];n&&(e=C.calculateApiFlags(e,n.name,n.version))}return e},t.prototype.buildScalarProperty=function(e,n,r){this.ensureOriginalName(r);var o=this,i=this.getFieldName(r),a={get:function(){return J.throwIfNotLoaded(r.name,this[i],n.name,this._isNull),o.throwIfApiNotSupported(n,r),this[i]},enumerable:!0,configurable:!0};0==(2&r.behaviorFlags)&&(a.set=function(e){if(4&r.behaviorFlags&&o.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_"+r.originalName+"_Set").call(this,this,e).handled)return;this[i]=e;var a=o.calculateApiFlags(r.setMethodApiFlags,r.undoableApiSetInfoOrdinal);z.invokeSetProperty(this,r.originalName,e,a)}),Object.defineProperty(e.prototype,r.name,a)},t.prototype.buildNavigationProperties=function(e,t){if(Array.isArray(t.navigationProperties))for(var n=0;n<t.navigationProperties.length;n++){var r=t.navigationProperties[n];Array.isArray(r)&&(this.ensureArraySize(r,8),t.navigationProperties[n]={name:this.getString(r[0]),behaviorFlags:r[2],apiSetInfoOrdinal:r[3],originalName:this.getString(r[4]),getMethodApiFlags:r[5],setMethodApiFlags:r[6],propertyTypeFullName:this.getString(r[1]),undoableApiSetInfoOrdinal:r[7]}),this.buildNavigationProperty(e,t,t.navigationProperties[n])}},t.prototype.buildNavigationProperty=function(e,n,r){this.ensureOriginalName(r);var o=this,i=this.getFieldName(r),a={get:function(){(this[o.getFieldName(r)]||(o.throwIfApiNotSupported(n,r),this[i]=z.createPropertyObject(o.getFunction(r.propertyTypeFullName),this,r.originalName,0!=(16&r.behaviorFlags),r.getMethodApiFlags)),64&r.behaviorFlags)&&o.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_"+r.originalName+"_Get").call(this,this,this[i]);return this[i]},enumerable:!0,configurable:!0};0==(2&r.behaviorFlags)&&(a.set=function(e){if(4&r.behaviorFlags&&o.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_"+r.originalName+"_Set").call(this,this,e).handled)return;this[i]=e;var a=o.calculateApiFlags(r.setMethodApiFlags,r.undoableApiSetInfoOrdinal);z.invokeSetProperty(this,r.originalName,e,a)}),Object.defineProperty(e.prototype,r.name,a)},t.prototype.buildScalarMethods=function(e,t){if(Array.isArray(t.scalarMethods))for(var n=0;n<t.scalarMethods.length;n++){var r=t.scalarMethods[n];Array.isArray(r)&&(this.ensureArraySize(r,7),t.scalarMethods[n]={name:this.getString(r[0]),behaviorFlags:r[2],apiSetInfoOrdinal:r[3],originalName:this.getString(r[5]),apiFlags:r[4],parameterCount:r[1],undoableApiSetInfoOrdinal:r[6]}),this.buildScalarMethod(e,t,t.scalarMethods[n])}},t.prototype.buildScalarMethod=function(e,n,r){this.ensureOriginalName(r);var o=this;e.prototype[r.name]=function(){var e=[];if(64&r.behaviorFlags&&r.parameterCount>0){for(var i=0;i<r.parameterCount-1;i++)e.push(arguments[i]);var a=[];for(i=r.parameterCount-1;i<arguments.length;i++)a.push(arguments[i]);e.push(a)}else for(i=0;i<arguments.length;i++)e.push(arguments[i]);if(1&r.behaviorFlags){var s=o.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_"+r.originalName),c=[this];for(i=0;i<e.length;i++)c.push(e[i]);var u=s.apply(this,c),l=u.handled,f=u.result;if(l)return f}o.throwIfApiNotSupported(n,r);var p=0;32&r.behaviorFlags&&(p=1);var d=0;2&r.behaviorFlags&&(d=1);var h=o.calculateApiFlags(r.apiFlags,r.undoableApiSetInfoOrdinal);return z.invokeMethod(this,r.originalName,d,e,h,p)}},t.prototype.buildNavigationMethods=function(e,t){if(Array.isArray(t.navigationMethods))for(var n=0;n<t.navigationMethods.length;n++){var r=t.navigationMethods[n];Array.isArray(r)&&(this.ensureArraySize(r,9),t.navigationMethods[n]={name:this.getString(r[0]),behaviorFlags:r[3],apiSetInfoOrdinal:r[4],originalName:this.getString(r[6]),apiFlags:r[5],parameterCount:r[2],returnTypeFullName:this.getString(r[1]),returnObjectGetByIdMethodName:this.getString(r[7]),undoableApiSetInfoOrdinal:r[8]}),this.buildNavigationMethod(e,t,t.navigationMethods[n])}},t.prototype.buildNavigationMethod=function(e,n,r){this.ensureOriginalName(r);var o=this;e.prototype[r.name]=function(){var e=[];if(64&r.behaviorFlags&&r.parameterCount>0){for(var i=0;i<r.parameterCount-1;i++)e.push(arguments[i]);var a=[];for(i=r.parameterCount-1;i<arguments.length;i++)a.push(arguments[i]);e.push(a)}else for(i=0;i<arguments.length;i++)e.push(arguments[i]);if(1&r.behaviorFlags){var s=o.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_"+r.originalName),c=[this];for(i=0;i<e.length;i++)c.push(e[i]);var u=s.apply(this,c),l=u.handled,f=u.result;if(l)return f}if(o.throwIfApiNotSupported(n,r),0!=(16&r.behaviorFlags))return z.createIndexerObject(o.getFunction(r.returnTypeFullName),this,e);var p=0;2&r.behaviorFlags&&(p=1);var d=o.calculateApiFlags(r.apiFlags,r.undoableApiSetInfoOrdinal);return z.createMethodObject(o.getFunction(r.returnTypeFullName),this,r.originalName,p,e,0!=(4&r.behaviorFlags),0!=(8&r.behaviorFlags),r.returnObjectGetByIdMethodName,d)}},t.prototype.buildHandleResult=function(e,n){var r=this;e.prototype._handleResult=function(e){if(R.prototype._handleResult.call(this,e),!J.isNullOrUndefined(e)){if(J.fixObjectPathIfNecessary(this,e),8&n.behaviorFlags)r.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_HandleResult").call(this,this,e);if(n.scalarProperties)for(var o=0;o<n.scalarProperties.length;o++)J.isUndefined(e[n.scalarProperties[o].originalName])||(0!=(8&n.scalarProperties[o].behaviorFlags)?this[r.getFieldName(n.scalarProperties[o])]=J.adjustToDateTime(e[n.scalarProperties[o].originalName]):this[r.getFieldName(n.scalarProperties[o])]=e[n.scalarProperties[o].originalName]);if(n.navigationProperties){for(var i=[],a=0;a<n.navigationProperties.length;a++)i.push(n.navigationProperties[a].name),i.push(n.navigationProperties[a].originalName);J._handleNavigationPropertyResults(this,e,i)}if(0!=(1&n.behaviorFlags)){var s=r.hasIndexMethod(n);if(!J.isNullOrUndefined(e[D.items])){this.m__items=[];for(var c=e[D.items],u=r.getFunction(n.childItemTypeFullName),l=0;l<c.length;l++){var f=z.createChildItemObject(u,s,this,c[l],l);f._handleResult(c[l]),this.m__items.push(f)}}}}}},t.prototype.buildHandleRetrieveResult=function(e,t){var n=this;e.prototype._handleRetrieveResult=function(e,r){if(R.prototype._handleRetrieveResult.call(this,e,r),!J.isNullOrUndefined(e)){if(t.scalarProperties)for(var o=0;o<t.scalarProperties.length;o++)8&t.scalarProperties[o].behaviorFlags&&(J.isNullOrUndefined(e[t.scalarProperties[o].name])||(e[t.scalarProperties[o].name]=J.adjustToDateTime(e[t.scalarProperties[o].name])));if(1&t.behaviorFlags){var i=n.hasIndexMethod(t),a=n.getFunction(t.childItemTypeFullName),s=this;J.processRetrieveResult(s,e,r,(function(e,t){return z.createChildItemObject(a,i,s,e,t)}))}else J.processRetrieveResult(this,e,r)}}},t.prototype.buildHandleIdResult=function(e,n){var r=this;e.prototype._handleIdResult=function(e){if(R.prototype._handleIdResult.call(this,e),!J.isNullOrUndefined(e)){if(16&n.behaviorFlags)r.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_HandleIdResult").call(this,this,e);if(n.scalarProperties)for(var o=0;o<n.scalarProperties.length;o++){var i=n.scalarProperties[o].originalName;"Id"!==i&&"_Id"!==i&&"_ReferenceId"!==i||J.isNullOrUndefined(e[n.scalarProperties[o].originalName])||(this[r.getFieldName(n.scalarProperties[o])]=e[n.scalarProperties[o].originalName])}}}},t.prototype.buildLoad=function(e,t){e.prototype.load=function(e){return J.load(this,e)}},t.prototype.buildRetrieve=function(e,t){e.prototype.retrieve=function(e){return J.retrieve(this,e)}},t.prototype.buildNewObject=function(e,t){J.isNullOrEmptyString(t.newObjectServerTypeFullName)||(e.newObject=function(n){return z.createTopLevelServiceObject(e,n,t.newObjectServerTypeFullName,0!=(1&t.behaviorFlags),t.newObjectApiFlags)})},t.prototype.buildSetMockData=function(e,t){var n=this;if(1&t.behaviorFlags){var r=n.hasIndexMethod(t);e.prototype.setMockData=function(e){var o=this;J.setMockData(o,e,(function(e,i){return z.createChildItemObject(n.getFunction(t.childItemTypeFullName),r,o,e,i)}),(function(e){o.m__items=e}))}}else e.prototype.setMockData=function(e){J.setMockData(this,e)}},t.prototype.buildEnsureUnchanged=function(e,t){e.prototype.ensureUnchanged=function(e){z.invokeEnsureUnchanged(this,e)}},t.prototype.buildUpdate=function(e,t){e.prototype.update=function(e){this._recursivelyUpdate(e)}},t.prototype.buildSet=function(e,t){if(0==(1&t.behaviorFlags)){var n=[],r=[];if(t.scalarProperties)for(var o=0;o<t.scalarProperties.length;o++)0==(2&t.scalarProperties[o].behaviorFlags)&&0!=(1&t.scalarProperties[o].behaviorFlags)?r.push(t.scalarProperties[o].name):n.push(t.scalarProperties[o].name);var i=[];if(t.navigationProperties)for(o=0;o<t.navigationProperties.length;o++)0!=(16&t.navigationProperties[o].behaviorFlags)||0==(1&t.navigationProperties[o].behaviorFlags)||0==(32&t.navigationProperties[o].behaviorFlags)?n.push(t.navigationProperties[o].name):i.push(t.navigationProperties[o].name);0===i.length&&0===r.length||(e.prototype.set=function(e,t){this._recursivelySet(e,t,r,i,n)})}},t.prototype.buildItems=function(e,t){0!=(1&t.behaviorFlags)&&Object.defineProperty(e.prototype,"items",{get:function(){return J.throwIfNotLoaded("items",this.m__items,t.name,this._isNull),this.m__items},enumerable:!0,configurable:!0})},t.prototype.buildToJSON=function(e,t){var n=this;0==(1&t.behaviorFlags)?e.prototype.toJSON=function(){var e={};if(t.scalarProperties)for(var r=0;r<t.scalarProperties.length;r++)0!=(1&t.scalarProperties[r].behaviorFlags)&&(e[t.scalarProperties[r].name]=this[n.getFieldName(t.scalarProperties[r])]);var o={};if(t.navigationProperties)for(r=0;r<t.navigationProperties.length;r++)0!=(1&t.navigationProperties[r].behaviorFlags)&&(o[t.navigationProperties[r].name]=this[n.getFieldName(t.navigationProperties[r])]);return J.toJson(this,e,o)}:e.prototype.toJSON=function(){return J.toJson(this,{},{},this.m__items)}},t.prototype.buildTypeMetadataInfo=function(e,t){Object.defineProperty(e.prototype,"_className",{get:function(){return t.name},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"_isCollection",{get:function(){return 0!=(1&t.behaviorFlags)},enumerable:!0,configurable:!0}),J.isNullOrEmptyString(t.collectionPropertyPath)||Object.defineProperty(e.prototype,"_collectionPropertyPath",{get:function(){return t.collectionPropertyPath},enumerable:!0,configurable:!0}),t.scalarProperties&&t.scalarProperties.length>0&&(Object.defineProperty(e.prototype,"_scalarPropertyNames",{get:function(){return this.m__scalarPropertyNames||(this.m__scalarPropertyNames=t.scalarProperties.map((function(e){return e.name}))),this.m__scalarPropertyNames},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"_scalarPropertyOriginalNames",{get:function(){return this.m__scalarPropertyOriginalNames||(this.m__scalarPropertyOriginalNames=t.scalarProperties.map((function(e){return e.originalName}))),this.m__scalarPropertyOriginalNames},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"_scalarPropertyUpdateable",{get:function(){return this.m__scalarPropertyUpdateable||(this.m__scalarPropertyUpdateable=t.scalarProperties.map((function(e){return 0==(2&e.behaviorFlags)}))),this.m__scalarPropertyUpdateable},enumerable:!0,configurable:!0})),t.navigationProperties&&t.navigationProperties.length>0&&Object.defineProperty(e.prototype,"_navigationPropertyNames",{get:function(){return this.m__navigationPropertyNames||(this.m__navigationPropertyNames=t.navigationProperties.map((function(e){return e.name}))),this.m__navigationPropertyNames},enumerable:!0,configurable:!0})},t.prototype.buildTrackUntrack=function(e,t){2&t.behaviorFlags&&(e.prototype.track=function(){return this.context.trackedObjects.add(this),this},e.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this})},t.prototype.buildMixin=function(e,t){if(4&t.behaviorFlags){var n=this.getFunction(t.name+"Custom");J.applyMixin(e,n)}},t.prototype.getOnEventName=function(e){return"_"===e[0]?"_on"+e.substr(1):"on"+e},t.prototype.buildEvents=function(e,t){if(t.events)for(var n=0;n<t.events.length;n++){var r=t.events[n];Array.isArray(r)&&(this.ensureArraySize(r,7),t.events[n]={name:this.getString(r[0]),behaviorFlags:r[1],apiSetInfoOrdinal:r[2],typeExpression:this.getString(r[3]),targetIdExpression:this.getString(r[4]),register:this.getString(r[5]),unregister:this.getString(r[6])}),this.buildEvent(e,t,t.events[n])}},t.prototype.buildEvent=function(e,t,n){1&n.behaviorFlags?this.buildV0Event(e,t,n):this.buildV2Event(e,t,n)},t.prototype.buildV2Event=function(e,n,r){var o=this,i=this.getOnEventName(r.name),a=this.getFieldName(r);Object.defineProperty(e.prototype,i,{get:function(){if(!this[a]){o.throwIfApiNotSupported(n,r);var e=this,i=null;"null"!==r.register&&(i=this[r.register].bind(this));var s=null;"null"!==r.unregister&&(s=this[r.unregister].bind(this));var c=null;2&r.behaviorFlags&&(c=o.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_"+r.name+"_EventArgsTransform"));var u=o.evaluateEventType(r.typeExpression);this[a]=new U(this.context,this,r.name,{eventType:u,getTargetIdFunc:function(){return o.evaluateEventTargetId(r.targetIdExpression,e)},registerFunc:i,unregisterFunc:s,eventArgsTransformFunc:function(t){return c&&(t=c.call(e,e,t)),J._createPromiseFromResult(t)}})}return this[a]},enumerable:!0,configurable:!0})},t.prototype.buildV0Event=function(e,n,r){var o=this,i=this.getOnEventName(r.name),a=this.getFieldName(r);Object.defineProperty(e.prototype,i,{get:function(){if(!this[a]){o.throwIfApiNotSupported(n,r);var e=this,i=null;if(J.isNullOrEmptyString(r.register)){var s=o.evaluateEventType(r.typeExpression);i=function(t){var n=o.evaluateEventTargetId(r.targetIdExpression,e);return e.context.eventRegistration.register(s,n,t)}}else if("null"!==r.register){var c=o.getFunction(r.register);i=function(t){return c.call(e,e,t)}}var u=null;if(J.isNullOrEmptyString(r.unregister)){var l=o.evaluateEventType(r.typeExpression);u=function(t){var n=o.evaluateEventTargetId(r.targetIdExpression,e);return e.context.eventRegistration.unregister(l,n,t)}}else if("null"!==r.unregister){var f=o.getFunction(r.unregister);u=function(t){return f.call(e,e,t)}}var p=null;2&r.behaviorFlags&&(p=o.getFunction(t.CustomizationCodeNamespace+"."+n.name+"_"+r.name+"_EventArgsTransform"));this[a]=new F(this.context,this,r.name,{registerFunc:i,unregisterFunc:u,eventArgsTransformFunc:function(t){return p&&(t=p.call(e,e,t)),J._createPromiseFromResult(t)}})}return this[a]},enumerable:!0,configurable:!0})},t.prototype.hasIndexMethod=function(e){var t=!1;if(e.navigationMethods)for(var n=0;n<e.navigationMethods.length;n++)if(0!=(16&e.navigationMethods[n].behaviorFlags)){t=!0;break}return t},t.CustomizationCodeNamespace="_CC",t}();e.LibraryBuilder=K}(OfficeExtension||(OfficeExtension={})),function(e){var t;!function(t){t.getPromiseType=function(){if("undefined"!=typeof Promise)return Promise;if(void 0!==Office&&Office.Promise)return Office.Promise;throw new e.Error("No Promise implementation found")}}(t||(t={})),Object.defineProperty(e,"Promise",{get:function(){return t.getPromiseType()},enumerable:!0,configurable:!0})}(OfficeExtension||(OfficeExtension={}));try{if("undefined"!=typeof OfficePlatformGlobal&&void 0!==OfficePlatformGlobal.ReactNativeReka){var RichApiBridgeImpl=function(){function e(){}return e.prototype.sendMessageToHost=function(e){OfficePlatformGlobal.ReactNativeReka.RekaInstance.InvokeNative("RichApiDataService","ProcessMessageToHost",e)},e}(),RichApiBridge_1=new RichApiBridgeImpl,RichApiDataService_1=function(){function e(){}return e.prototype.Invoke=function(e,t){"ProcessMessageFromHost"===e&&RichApiBridge_1.onMessageFromHost&&RichApiBridge_1.onMessageFromHost(t)},e}();OfficePlatformGlobal.ReactNativeReka.initReka(),OfficePlatformGlobal.ReactNativeReka.RekaInstance.RegisterService("RichApiDataService",(function(){return new RichApiDataService_1})),OfficeExtension.HostBridge.init(RichApiBridge_1),OfficeExtension.HostBridgeSession.getInstanceIfHostBridgeInited()}}catch(e){}var oteljs;__assign=this&&this.__assign||function(){return(__assign=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};!function(e){function t(e,t,n,r){return{name:e,dataType:t,value:n,classification:r||4}}e.makeBooleanDataField=function(e,n,r){return t(e,1,n,r)},e.makeInt64DataField=function(e,n,r){return t(e,2,n,r)},e.makeDoubleDataField=function(e,n,r){return t(e,3,n,r)},e.makeStringDataField=function(e,n,r){return t(e,0,n,r)},e.makeGuidDataField=function(e,n,r){return t(e,4,n,r)}}(oteljs||(oteljs={})),function(e){!function(e){e[e.EssentialServiceMetadata=1]="EssentialServiceMetadata",e[e.AccountData=2]="AccountData",e[e.SystemMetadata=4]="SystemMetadata",e[e.OrganizationIdentifiableInformation=8]="OrganizationIdentifiableInformation",e[e.EndUserIdentifiableInformation=16]="EndUserIdentifiableInformation",e[e.CustomerContent=32]="CustomerContent",e[e.AccessControl=64]="AccessControl",e[e.PublicNonPersonalData=128]="PublicNonPersonalData",e[e.EndUserPseudonymousInformation=256]="EndUserPseudonymousInformation",e[e.PublicPersonalData=512]="PublicPersonalData",e[e.SupportData=1024]="SupportData",e[e.DirectMeasurementData=2048]="DirectMeasurementData",e[e.Everything=65535]="Everything"}(e.DataClassification||(e.DataClassification={})),function(e){e[e.String=0]="String",e[e.Boolean=1]="Boolean",e[e.Int64=2]="Int64",e[e.Double=3]="Double",e[e.Guid=4]="Guid"}(e.DataFieldType||(e.DataFieldType={})),function(e){e[e.NotSet=0]="NotSet",e[e.Measure=1]="Measure",e[e.Diagnostics=2]="Diagnostics",e[e.CriticalBusinessImpact=191]="CriticalBusinessImpact",e[e.CriticalCensus=192]="CriticalCensus",e[e.CriticalExperimentation=193]="CriticalExperimentation",e[e.CriticalUsage=194]="CriticalUsage"}(e.SamplingPolicy||(e.SamplingPolicy={})),function(e){e[e.NotSet=0]="NotSet",e[e.Normal=1]="Normal",e[e.High=2]="High"}(e.PersistencePriority||(e.PersistencePriority={})),function(e){e[e.NotSet=0]="NotSet",e[e.Normal=1]="Normal",e[e.High=2]="High"}(e.CostPriority||(e.CostPriority={})),function(e){e[e.NotSet=0]="NotSet",e[e.SoftwareSetup=1]="SoftwareSetup",e[e.ProductServiceUsage=2]="ProductServiceUsage",e[e.ProductServicePerformance=4]="ProductServicePerformance",e[e.DeviceConfiguration=8]="DeviceConfiguration",e[e.InkingTypingSpeech=16]="InkingTypingSpeech"}(e.DataCategories||(e.DataCategories={})),function(e){e[e.ReservedDoNotUse=0]="ReservedDoNotUse",e[e.Required=10]="Required",e[e.BasicEvent=10]="BasicEvent",e[e.Optional=100]="Optional",e[e.FullEvent=100]="FullEvent",e[e.RequiredServiceData=110]="RequiredServiceData",e[e.NecessaryServiceDataEvent=110]="NecessaryServiceDataEvent",e[e.RequiredServiceDataForEssentialServices=120]="RequiredServiceDataForEssentialServices",e[e.AlwaysOnNecessaryServiceDataEvent=120]="AlwaysOnNecessaryServiceDataEvent"}(e.DiagnosticLevel||(e.DiagnosticLevel={})),function(e){e[e.None=0]="None",e[e.MocaAddIn=1]="MocaAddIn"}(e.CustomerContentType||(e.CustomerContentType={})),function(e){e[e.Error=0]="Error",e[e.Warning=1]="Warning",e[e.Info=2]="Info",e[e.Verbose=3]="Verbose"}(e.LogLevel||(e.LogLevel={})),function(e){e[e.Core=0]="Core",e[e.Sink=1]="Sink",e[e.Transport=2]="Transport"}(e.Category||(e.Category={})),function(e){e[e.Hourly=1]="Hourly",e[e.Daily=2]="Daily"}(e.DnmInterval||(e.DnmInterval={})),function(e){e[e.ReleaseAudienceGroup=1]="ReleaseAudienceGroup",e[e.WacRing=2]="WacRing",e[e.AppName=3]="AppName",e[e.AppPlatform=4]="AppPlatform",e[e.AppVersion=5]="AppVersion"}(e.AllowedPartA||(e.AllowedPartA={})),function(e){e[e.SendTelemetryEvent=1]="SendTelemetryEvent",e[e.CustomerContent=2]="CustomerContent",e[e.DirectNumericEvent=3]="DirectNumericEvent"}(e.EventType||(e.EventType={}))}(oteljs||(oteljs={})),function(e){e.getEffectiveEventFlags=function(t){var n={costPriority:1,samplingPolicy:1,persistencePriority:1,dataCategories:0,diagnosticLevel:100};return t.eventFlags&&t.eventFlags.dataCategories||e.logNotification(0,0,(function(){return"DataCategories"})),t.eventFlags?(t.eventFlags.costPriority&&(n.costPriority=t.eventFlags.costPriority),t.eventFlags.samplingPolicy&&(n.samplingPolicy=t.eventFlags.samplingPolicy),t.eventFlags.persistencePriority&&(n.persistencePriority=t.eventFlags.persistencePriority),t.eventFlags.dataCategories&&(n.dataCategories=t.eventFlags.dataCategories),t.eventFlags.diagnosticLevel&&(n.diagnosticLevel=t.eventFlags.diagnosticLevel),n):n}}(oteljs||(oteljs={})),function(e){var t,n=(t=[],{fireEvent:function(e){t.forEach((function(t){return t(e)}))},addListener:function(e){e&&t.push(e)}});function r(e,t,r){n.fireEvent({level:e,category:t,message:r})}e.onNotification=function(){return n},e.logNotification=r,e.logError=function(e,t,n){r(0,e,(function(){var e=n instanceof Error?n.message:"";return"".concat(t,": ").concat(e)}))}}(oteljs||(oteljs={})),function(e){var t;function n(e){var t={eventName:e.eventName,eventFlags:e.eventFlags||{},telemetryProperties:e.telemetryProperties?__assign({},e.telemetryProperties):{},dataFields:e.dataFields?e.dataFields.slice():[],timestamp:e.timestamp||(new Date).getTime()};return e.eventContract&&(t.eventContract={name:e.eventContract.name,dataFields:e.eventContract.dataFields.slice()}),t}!function(e){e[e.TelemetryData=0]="TelemetryData",e[e.AnonymousData=1]="AnonymousData",e[e.CustomerContent=2]="CustomerContent"}(t||(t={})),e.SuppressNexus=-1,e.cloneEvent=n;var r=function(){function t(e,t,n){var r,o,i;this.telemetrySinks=[],this.persistentDataFields=[],this.partAFields=[],this.eventQueue=[],this.config=n||{},e&&(this.telemetrySinks=e.telemetrySinks,(r=this.persistentDataFields).push.apply(r,e.persistentDataFields),this.config=__assign(__assign({},e.getConfig()),this.config),(o=this.partAFields).push.apply(o,e.partAFields)),t&&(i=this.persistentDataFields).push.apply(i,t)}return t.prototype.addEventContentType=function(t,n){t.push(e.makeInt64DataField("EventContent.Type",n))},t.prototype.sendTelemetryEvent=function(t){var r=n(t),o=r.telemetryProperties;o.nexusTenantToken=e.SuppressNexus;var i=o.ariaTenantToken;if(!i&&(!e.fillTenantTokens(r.eventName,o)&&!i))return void e.logNotification(0,0,(function(){return"No tenant token: "+t.eventName}));this.sendTelemetryEventInternal(r,1)},t.prototype.sendNonStandardEvent=function(e,t){var r=n(e);this.sendTelemetryEventInternal(r,t)},t.prototype.sendCustomerContent=function(e){var t=n(e),r=t.telemetryProperties,o=r.customerContentVersion;return(!o||o>2)&&(r.customerContentVersion=2),r.ariaTenantToken=void 0,r.nexusTenantToken=void 0,r.dnmToken=void 0,this.addEventContentType(t.dataFields,2),this.sendTelemetryEventInternal(t,2)},t.prototype.sendDirectNumericEvent=function(t){var r=n(t),o=r.telemetryProperties;if(!o.dnmToken&&(!e.fillTenantTokens(r.eventName,o)&&!o.dnmToken))return void e.logNotification(0,0,(function(){return"No dnm token: "+r.eventName}));this.addEventContentType(r.dataFields,1),this.sendTelemetryEventInternal(r,3)},t.prototype.sendTelemetryEventInternal=function(t,n){if(2===n||!t.telemetryProperties.customerContentVersion&&!t.telemetryProperties.customerContentType){try{if(0===this.telemetrySinks.length)return void(this.config.enableQueue&&this.eventQueue.length<1e3?this.eventQueue.push([t,n]):e.logNotification(1,0,(function(){return"No telemetry sinks are attached."})));this.processTelemetryEvent(t,n)}catch(t){return void e.logError(0,"SendTelemetryEvent",t)}this.telemetrySinks.forEach((function(e){try{3===n||2===n?e.sendNonStandardEvent&&e.sendNonStandardEvent(t,n):e.sendTelemetryEvent(t)}catch(e){}}))}else e.logNotification(0,0,(function(){return"Customer content"}))},t.prototype.processTelemetryEvent=function(t,n){var r,o,i;if(t.dataFields&&(null===(i=t.dataFields)||void 0===i||i.unshift(e.makeStringDataField("OTelJS.Version",e.oteljsVersion)),3!==n&&this.persistentDataFields&&(r=t.dataFields).unshift.apply(r,this.persistentDataFields)),this.partAFields.length>0){var a=t.eventContract||{name:"",dataFields:[]};(o=a.dataFields).push.apply(o,this.partAFields),t.eventContract=a}this.config.disableValidation||e.validateTelemetryEvent(t)},t.prototype.addSink=function(e){this.telemetrySinks.push(e),this.flushQueue()},t.prototype.flushQueue=function(){var e=this.eventQueue;if(this.eventQueue=[],this.telemetrySinks.length>0)for(var t=0,n=e;t<n.length;t++){var r=n[t],o=r[0],i=r[1];this.sendTelemetryEventInternal(o,i)}},t.prototype.setTenantToken=function(t,n,r){e.setTenantTokens(t,{ariaTenantToken:n,nexusTenantToken:r})},t.prototype.setDNMToken=function(t,n){e.setTenantTokens(t,{dnmToken:n})},t.prototype.cloneEvent=function(e){return n(e)},t.prototype.getConfig=function(){return this.config},t}();e.SimpleTelemetryLogger=r}(oteljs||(oteljs={})),function(e){var t=9007199254740991,n=/^Office(\.[A-Z][a-zA-Z0-9]*){2,}$/,r=/^[a-zA-Z0-9_\.]{1,95}$/;function o(e){return r.test(e)}function i(e){e&&e.forEach((function(e){if("string"!=typeof e.name||!o(e.name))throw new Error("Invalid dataField name");2===e.dataType&&a(e.value)}))}function a(e){if("number"!=typeof e||!isFinite(e)||Math.floor(e)!==e||e<-9007199254740991||e>t)throw new Error("Invalid integer ".concat(JSON.stringify(e)))}e.validateTelemetryEvent=function(e){if(!function(e){if(!e||e.length>98)return!1;return n.test(e)}(e.eventName))throw new Error("Invalid eventName");var t=e.eventContract;if(t){if(t.name&&!o(t.name))throw new Error("Invalid eventContract");i(t.dataFields)}i(e.dataFields)},e.validateInt=a}(oteljs||(oteljs={})),function(e){var t={};e.setTenantTokens=function(n,r){"Office."===n.substring(0,7)&&"."!==n[n.length-1]?t[n]?(r.ariaTenantToken&&(t[n].ariaTenantToken=r.ariaTenantToken),r.dnmToken&&(t[n].dnmToken=r.dnmToken)):t[n]=r:e.logNotification(0,0,(function(){return"Namespace: ".concat(n)}))},e.fillTenantTokens=function(e,n){for(var r=e.length;r>0;){var o=e.substr(0,r);if(t[o]){var i=t[o];return n.ariaTenantToken=i.ariaTenantToken,n.dnmToken=i.dnmToken,!0}r=e.lastIndexOf(".",r-1)}return!1},e.clear=function(){t={}}}(oteljs||(oteljs={})),function(e){e.oteljsVersion="4.18.0"}(oteljs||(oteljs={})),function(e){var t=function(){function t(){var e=this;this._requestIsPending=!0,this._telemetryQueue=[],this._customerContentQueue=[],this.pause(1e3).then((function(){return e._requestIsPending=!1,e.processTelemetryEvents()})).catch()}return t.isSupportedByDeclaration=function(){return t.isSupportedVersion("1.2")},t.isSupportedVersion=function(e){return Office.context.requirements.isSetSupported("Telemetry",e)},t.prototype.sendCustomerContent=function(e){t.isSupportedVersion("1.3")&&(this._customerContentQueue.push(e),this.processWorkBacklog())},t.prototype.sendTelemetryEvent=function(e){this._telemetryQueue.push(e),this.processWorkBacklog()},t.prototype.processWorkBacklog=function(){var t=this;this._requestIsPending||(this._requestIsPending=!0,this.processTelemetryEvents().then((function(){t.waitAndProcessMore()})).catch((function(n){e.logError(1,"RichApiSink Error",n),t.waitAndProcessMore()})))},t.prototype.waitAndProcessMore=function(){var e=this;this.pause(1e3).then((function(){e._requestIsPending=!1,e._telemetryQueue.length>0&&setTimeout((function(){return e.processWorkBacklog()}),0)})).catch((function(){e._requestIsPending=!1}))},t.prototype.processTelemetryEvents=function(){var t=this,n=this._telemetryQueue;this._telemetryQueue=[];var r=this._customerContentQueue;this._customerContentQueue=[];var o=new OfficeCore.RequestContext,i=function(n,r){if(n.telemetryProperties){var o=[];t.addDataFields(o,n.dataFields);var i=n.eventContract?n.eventContract.name:"";n.eventContract&&t.addDataFields(o,n.eventContract.dataFields),r(n.telemetryProperties,n.eventName,i,e.getEffectiveEventFlags(n),o)}};return n.forEach((function(e){i(e,(function(e,t,n,r,i){o.telemetry.sendTelemetryEvent(e,t,n,r,i)}))})),r.forEach((function(e){i(e,(function(e,t,n,r,i){o.telemetry.sendCustomerContent(e,t,n,r,i)}))})),o.sync().catch((function(t){e.logError(1,"RichApi telemetry failed.",t)}))},t.prototype.addDataFields=function(e,t){t&&t.forEach((function(t){e.push({name:t.name,value:t.value,classification:t.classification?t.classification:4,type:4===t.dataType?0:t.dataType})}))},t.prototype.pause=function(e){return new Office.Promise((function(t){return setTimeout(t,e)}))},t}();e.RichApiSink=t}(oteljs||(oteljs={})),function(e){!function(t){!function(t){!function(t){!function(t){t.getFields=function(t,n){var r=[];return void 0!==n.id&&r.push(e.makeStringDataField("".concat(t,".Id"),n.id)),void 0!==n.version&&r.push(e.makeStringDataField("".concat(t,".Version"),n.version)),void 0!==n.instanceId&&r.push(e.makeStringDataField("".concat(t,".InstanceId"),n.instanceId)),void 0!==n.name&&r.push(e.makeStringDataField("".concat(t,".Name"),n.name)),void 0!==n.marketplaceType&&r.push(e.makeStringDataField("".concat(t,".MarketplaceType"),n.marketplaceType)),void 0!==n.sessionId&&r.push(e.makeStringDataField("".concat(t,".SessionId"),n.sessionId)),void 0!==n.browserToken&&r.push(e.makeStringDataField("".concat(t,".BrowserToken"),n.browserToken)),void 0!==n.osfRuntimeVersion&&r.push(e.makeStringDataField("".concat(t,".OsfRuntimeVersion"),n.osfRuntimeVersion)),void 0!==n.officeJsVersion&&r.push(e.makeStringDataField("".concat(t,".OfficeJsVersion"),n.officeJsVersion)),void 0!==n.hostJsVersion&&r.push(e.makeStringDataField("".concat(t,".HostJsVersion"),n.hostJsVersion)),void 0!==n.assetId&&r.push(e.makeStringDataField("".concat(t,".AssetId"),n.assetId)),void 0!==n.providerName&&r.push(e.makeStringDataField("".concat(t,".ProviderName"),n.providerName)),void 0!==n.type&&r.push(e.makeStringDataField("".concat(t,".Type"),n.type)),r}}(t.SDX||(t.SDX={}))}(t.System||(t.System={}))}(t.Office||(t.Office={}))}(e.Contracts||(e.Contracts={}))}(oteljs||(oteljs={})),function(e){var t=function(){function t(){}return t.isSupported=function(){return Office.context&&Office.context.platform?Office.context.platform===Office.PlatformType.OfficeOnline:OfficeExt&&OfficeExt.HostName&&OfficeExt.HostName.Host&&OfficeExt.HostName.Host.getInstance().getPlatform()===Office.PlatformType.OfficeOnline},t.prototype.sendTelemetryEvent=function(t,n){try{if(t.dataFields&&t.dataFields.filter((function(e){var t=e.classification;return t&&4!==t&&1!==t})).length>0)return;var r=OSF._OfficeAppFactory.getId(),o=OSF.AgaveHostAction.SendTelemetryEvent;OSF.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[r,o,t])}catch(t){e.logError(1,"AgaveWacSink",t)}},t.prototype.sendCustomerContent=function(t,n){try{if(t.dataFields&&t.dataFields.filter((function(e){var t=e.classification;return t&&4!==t&&1!==t&&32!==t})).length>0)return;var r=OSF._OfficeAppFactory.getId(),o=OSF.AgaveHostAction.SendCustomerContent;OSF.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[r,o,t])}catch(t){e.logError(1,"AgaveWacSink",t)}},t}();e.SdxWacSink=t}(oteljs||(oteljs={})),function(e){var t=function(){function t(e){this.m_activeView=e}return Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.ActiveViewChanged},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"activeView",{get:function(){return this.m_activeView.activeView},enumerable:!0,configurable:!0}),t}();e.ActiveViewChangedEventArgs=t}(OSF||(OSF={})),function(e){var t=function(){function t(e,t,n,r,o){this._requiredParameters=e,this._supportedOptions=t,this._privateStateCallbacks=n,this._checkCallArgs=r,this._displayName=o,this._requiredCount=e.length}return t.prototype.verifyArguments=function(t,n){for(var r in t){var o=t[r],i=n[r];if(o.enum)switch(typeof i){case"string":if(e.OUtil.listContainsValue(o.enum,i))break;case"undefined":throw 5007;default:throw this.getInvalidParameterString()}if(o.types&&!e.OUtil.listContainsValue(o.types,typeof i))throw this.getInvalidParameterString()}},t.prototype.extractRequiredArguments=function(t,n,r){if(t.length<this._requiredCount)throw e.Utility.createParameterException(Strings.OfficeOM.L_MissingRequiredArguments);var o,i=[];for(o=0;o<this._requiredCount;o++)i.push(t[o]);this.verifyArguments(this._requiredParameters,i);var a={};for(o=0;o<this._requiredCount;o++){var s=this._requiredParameters[o],c=i[o];if(s.verify)if(!s.verify(c,n,r))throw this.getInvalidParameterString();a[s.name]=c}return a},t.prototype.fillOptions=function(t,n,r,o){for(var i in t=t||{},this._supportedOptions)if(!e.OUtil.listContainsKey(t,i)){var a=void 0,s=this._supportedOptions[i];s.calculate&&n&&(a=s.calculate(n,r,o)),a||void 0===s.defaultValue||(a=s.defaultValue),t[i]=a}return t},t.prototype.constructCallArgs=function(e,t,n,r){var o={};for(var i in e)o[i]=e[i];for(var a in t)o[a]=t[a];for(var s in this._privateStateCallbacks)o[s]=this._privateStateCallbacks[s](n,r);return this._checkCallArgs&&(o=this._checkCallArgs(o,n,r)),o},t.prototype.getInvalidParameterString=function(){var t=this;e.OUtil.delayExecutionAndCache((function(){return e.OUtil.formatString(Strings.OfficeOM.L_InvalidParameters,t._displayName)}))},t}();e.ApiMethodCall=t}(OSF||(OSF={})),function(e){var t=function(){function t(t,n,r,o,i,a,s){this._requiredParameters=t,this._supportedOptions=n,this._privateStateCallbacks=r,this._onSucceeded=o,this._onFailed=i,this._displayName=s,this._checkCallArgs=a,this._requiredCount=t.length,this._apiMethods=new e.ApiMethodCall(t,n,r,a,s)}return t.prototype.verifyAndExtractCall=function(e,t,n){var r=this._apiMethods.extractRequiredArguments(e,t,n),o=this.extractOptions(e,r,t,n);return this._apiMethods.constructCallArgs(r,o,t,n)},t.prototype.processResponse=function(t,n,r,o){return 0==t?this._onSucceeded?this._onSucceeded(n,r,o):n:this._onFailed?this._onFailed(t,n):e.DDA.ErrorCodeManager.getErrorArgs(t)},t.prototype.getCallArgs=function(t){for(var n,r,o=t.length-1;o>=this._requiredCount;o--){var i=t[o];switch(typeof i){case"object":n=i;break;case"function":r=i}}return n=n||{},r&&(n[e.ParameterNames.Callback]=r),n},t.prototype.extractOptions=function(t,n,r,o){if(t.length>this._requiredCount+2)throw e.Utility.createParameterException(Strings.OfficeOM.L_TooManyArguments);for(var i,a,s=t.length-1;s>=this._requiredCount;s--){var c=t[s];switch(typeof c){case"object":if(i)throw e.Utility.createParameterException(Strings.OfficeOM.L_TooManyOptionalObjects);i=c;break;case"function":if(a)throw e.Utility.createParameterException(Strings.OfficeOM.L_TooManyOptionalFunction);a=c;break;default:throw e.Utility.createArgumentException(Strings.OfficeOM.L_InValidOptionalArgument)}}if(i=this._apiMethods.fillOptions(i,n,r,o),a){if(i[e.ParameterNames.Callback])throw Strings.OfficeOM.L_RedundantCallbackSpecification;i[e.ParameterNames.Callback]=a}return this._apiMethods.verifyArguments(this._supportedOptions,i),i},t}();e.AsyncMethodCall=t}(OSF||(OSF={})),function(e){!function(t){var n={};t.define=function(t){var r,o,i;n[t.method]=(o=(r=t).supportedOptions?e.OUtil.createObject(r.supportedOptions):[],i=r.privateStateCallbacks?e.OUtil.createObject(r.privateStateCallbacks):[],new e.AsyncMethodCall(r.requiredArguments||[],o,i,r.onSucceeded,r.onFailed,r.checkCallArgs,r.method))},t.get=function(e){return n[e]}}(e.AsyncMethodCalls||(e.AsyncMethodCalls={}))}(OSF||(OSF={})),function(e){e.AsyncMethods={AddColumnsAsync:"addColumnsAsync",AddFromSelectionAsync:"addFromSelectionAsync",AddFromNamedItemAsync:"addFromNamedItemAsync",AddFromPromptAsync:"addFromPromptAsync",AddHandlerAsync:"addHandlerAsync",AddRowsAsync:"addRowsAsync",BindingSelectionChanged:"bindingSelectionChanged",BindingDataChanged:"bindingDataChanged",ClearFormatsAsync:"clearFormatsAsync",CloseAsync:"close",CloseContainerAsync:"closeContainer",DeleteAllDataValuesAsync:"deleteAllDataValuesAsync",DisplayDialogAsync:"displayDialogAsync",ExecuteFeature:"executeFeature",ExecuteRichApiRequestAsync:"executeRichApiRequestAsync",GetAllAsync:"getAllAsync",GetAccessTokenAsync:"getAccessTokenAsync",GetByIdAsync:"getByIdAsync",GetDataAsync:"getDataAsync",GetDocumentCopyAsync:"getFileAsync",GetDocumentCopyChunkAsync:"getSliceAsync",GetFilePropertiesAsync:"getFilePropertiesAsync",GetSelectedDataAsync:"getSelectedDataAsync",GoToByIdAsync:"goToByIdAsync",OpenBrowserWindow:"openBrowserWindow",QueryFeature:"queryFeature",ReleaseByIdAsync:"releaseByIdAsync",RemoveHandlerAsync:"removeHandlerAsync",ReleaseDocumentCopyAsync:"closeAsync",SetDataAsync:"setDataAsync",SetFormatsAsync:"setFormatsAsync",SetSelectedDataAsync:"setSelectedDataAsync",SetTableOptionsAsync:"setTableOptionsAsync",GetOfficeThemeAsync:"getOfficeThemeAsync",GetDocumentThemeAsync:"getDocumentThemeAsync"}}(OSF||(OSF={})),function(e){!function(e){e.Subset="subset",e.BindingProperties="BindingProperties"}(e.PropertyDescriptors||(e.PropertyDescriptors={}));var t=function(){function t(e,t){this.m_bindingInstance=e,this.m_subset=t}return Object.defineProperty(t.prototype,"startRow",{get:function(){return this.m_subset.startRow},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"startColumn",{get:function(){return this.m_subset.startColumn},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"rowCount",{get:function(){return this.m_subset.rowCount},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"columnCount",{get:function(){return this.m_subset.columnCount},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.BindingSelectionChanged},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"binding",{get:function(){return this.m_bindingInstance},enumerable:!0,configurable:!0}),t}();e.BindingSelectionChangedEventArgs=t;var n=function(){function t(e){this.m_bindingInstance=e}return Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.BindingDataChanged},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"binding",{get:function(){return this.m_bindingInstance},enumerable:!0,configurable:!0}),t}();e.BindingDataChangedEventArgs=n}(OSF||(OSF={})),function(e){!function(e){e.DataPartProperties="DataPartProperties",e.DataNodeProperties="DataNodeProperties"}(e.PropertyDescriptors||(e.PropertyDescriptors={})),function(e){!function(e){!function(e){e.OldNode="OldNode",e.NewNode="NewNode",e.NextSiblingNode="NextSiblingNode",e.InUndoRedo="InUndoRedo"}(e.DataNodeEventProperties||(e.DataNodeEventProperties={}))}(e.Customxml||(e.Customxml={}))}(e.Marshaling||(e.Marshaling={})),function(e){e.DataNodeInsertedEvent="DataNodeInsertedEvent",e.DataNodeReplacedEvent="DataNodeReplacedEvent",e.DataNodeDeletedEvent="DataNodeDeletedEvent"}(e.EventDescriptors||(e.EventDescriptors={})),function(e){e.OldNode="OldNode",e.NewNode="NewNode",e.NextSiblingNode="NextSiblingNode",e.InUndoRedo="InUndoRedo"}(e.DataNodeEventProperties||(e.DataNodeEventProperties={}));var t=function(){function t(e,t){this.m_newNode=e,this.m_inUndoRedo=t}return Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.DataNodeInserted},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"newNode",{get:function(){return this.m_newNode},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"inUndoRedo",{get:function(){return this.m_inUndoRedo},enumerable:!0,configurable:!0}),t}();e.NodeInsertedEventArgs=t;var n=function(){function t(e,t,n){this.m_oldNode=e,this.m_newNode=t,this.m_inUndoRedo=n}return Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.DataNodeReplaced},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"oldNode",{get:function(){return this.m_oldNode},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"newNode",{get:function(){return this.m_newNode},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"inUndoRedo",{get:function(){return this.m_inUndoRedo},enumerable:!0,configurable:!0}),t}();e.NodeReplacedEventArgs=n;var r=function(){function t(e,t,n){this.m_oldNode=e,this.m_oldNextSibling=t,this.m_inUndoRedo=n}return Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.DataNodeDeleted},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"oldNode",{get:function(){return this.m_oldNode},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"oldNextSibling",{get:function(){return this.m_oldNextSibling},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"inUndoRedo",{get:function(){return this.m_inUndoRedo},enumerable:!0,configurable:!0}),t}();e.NodeDeletedEventArgs=r}(OSF||(OSF={})),function(e){var t=function(t){0==t[e.PropertyDescriptors.MessageType]?e.OUtil.defineEnumerableProperties(this,{type:{value:e.EventType.DialogMessageReceived},message:{value:t[e.PropertyDescriptors.MessageContent]},origin:{value:t[e.PropertyDescriptors.MessageOrigin]}}):e.OUtil.defineEnumerableProperties(this,{type:{value:e.EventType.DialogEventReceived},error:{value:t[e.PropertyDescriptors.MessageType]}})};e.DialogEventArgs=t,function(e){e.MessageType="messageType",e.MessageContent="messageContent",e.MessageOrigin="messageOrigin"}(e.PropertyDescriptors||(e.PropertyDescriptors={}))}(OSF||(OSF={})),function(e){var t=function(){function t(e){this.m_docInstance=e}return Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.DocumentSelectionChanged},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"document",{get:function(){return this.m_docInstance},enumerable:!0,configurable:!0}),t}();e.DocumentSelectionChangedEventArgs=t}(OSF||(OSF={})),function(e){var t=function(t){e.OUtil.defineEnumerableProperties(this,{type:{value:e.EventType.DialogParentMessageReceived},message:{value:t[e.PropertyDescriptors.MessageContent]},origin:{value:t[e.PropertyDescriptors.MessageOrigin]}})};e.DialogParentEventArgs=t}(OSF||(OSF={})),function(e){e.DialogShownStatus={hasDialogShown:!1,isWindowDialog:!1},function(t){var n;function r(t){return t==e.EventDispId.dispidObjectDeletedEvent||t==e.EventDispId.dispidObjectSelectionChangedEvent||t==e.EventDispId.dispidObjectDataChangedEvent||t==e.EventDispId.dispidContentControlAddedEvent}function o(t,n,r,o){if("number"!=typeof t)throw t;o||(o=n.getCallArgs(r)),s(o,t,e.DDA.ErrorCodeManager.getErrorArgs(t))}function i(t){return(e._OfficeAppFactory.getHostInfo().hostPlatform==e.HostInfoPlatform.web?e.WACDelegate:e.SafeArrayDelegate)[t]}function a(){return n||function(){n={};var t={GoToByIdAsync:82,GetSelectedDataAsync:64,SetSelectedDataAsync:65,GetDocumentCopyChunkAsync:80,ReleaseDocumentCopyAsync:81,GetDocumentCopyAsync:77,AddFromSelectionAsync:66,AddFromPromptAsync:67,AddFromNamedItemAsync:78,GetAllAsync:74,GetByIdAsync:68,ReleaseByIdAsync:69,GetDataAsync:70,SetDataAsync:71,AddRowsAsync:72,AddColumnsAsync:79,DeleteAllDataValuesAsync:73,RefreshAsync:75,SaveAsync:76,GetActiveViewAsync:83,GetFilePropertiesAsync:86,GetOfficeThemeAsync:85,GetDocumentThemeAsync:84,ClearFormatsAsync:87,SetTableOptionsAsync:88,SetFormatsAsync:89,GetUserIdentityInfoAsync:92,GetAccessTokenAsync:98,GetAuthContextAsync:99,ExecuteRichApiRequestAsync:93,AppCommandInvocationCompletedAsync:94,CloseContainerAsync:97,OpenBrowserWindow:102,CreateDocumentAsync:105,InsertFormAsync:106,ExecuteFeature:146,QueryFeature:147,AddDataPartAsync:128,GetDataPartByIdAsync:129,GetDataPartsByNameSpaceAsync:130,GetPartXmlAsync:131,GetPartNodesAsync:132,DeleteDataPartAsync:133,GetNodeValueAsync:134,GetNodeXmlAsync:135,GetRelativeNodesAsync:136,SetNodeValueAsync:137,SetNodeXmlAsync:138,AddDataPartNamespaceAsync:139,GetDataPartNamespaceAsync:140,GetDataPartPrefixAsync:141,GetNodeTextAsync:142,SetNodeTextAsync:143,GetSelectedTask:110,GetTask:112,GetWSSUrl:114,GetTaskField:115,GetSelectedResource:111,GetResourceField:113,GetProjectField:116,GetSelectedView:117,GetTaskByIndex:118,GetResourceByIndex:119,SetTaskField:120,SetResourceField:121,GetMaxTaskIndex:122,GetMaxResourceIndex:123,CreateTask:124};for(var r in t)e.AsyncMethods[r]&&(n[e.AsyncMethods[r]]=t[r]);var o={MessageParent:144,SendMessage:145};for(var r in o)e.SyncMethods[r]&&(n[e.SyncMethods[r]]=o[r]);var i={SettingsChanged:e.EventDispId.dispidSettingsChangedEvent,DocumentSelectionChanged:e.EventDispId.dispidDocumentSelectionChangedEvent,BindingSelectionChanged:e.EventDispId.dispidBindingSelectionChangedEvent,BindingDataChanged:e.EventDispId.dispidBindingDataChangedEvent,ActiveViewChanged:e.EventDispId.dispidActiveViewChangedEvent,OfficeThemeChanged:e.EventDispId.dispidOfficeThemeChangedEvent,DocumentThemeChanged:e.EventDispId.dispidDocumentThemeChangedEvent,AppCommandInvoked:e.EventDispId.dispidAppCommandInvokedEvent,DialogMessageReceived:e.EventDispId.dispidDialogMessageReceivedEvent,DialogParentMessageReceived:e.EventDispId.dispidDialogParentMessageReceivedEvent,ObjectDeleted:e.EventDispId.dispidObjectDeletedEvent,ObjectSelectionChanged:e.EventDispId.dispidObjectSelectionChangedEvent,ObjectDataChanged:e.EventDispId.dispidObjectDataChangedEvent,ContentControlAdded:e.EventDispId.dispidContentControlAddedEvent,LiveShareStateChanged:e.EventDispId.dispidLiveShareStateChangedEvent,RichApiMessage:e.EventDispId.dispidRichApiMessageEvent,DataNodeInserted:e.EventDispId.dispidDataNodeAddedEvent,DataNodeReplaced:e.EventDispId.dispidDataNodeReplacedEvent,DataNodeDeleted:e.EventDispId.dispidDataNodeDeletedEvent};for(var a in i)e.EventType[a]&&(n[e.EventType[a]]=i[a])}(),n}function s(t,n,r){var o=t[e.ParameterNames.Callback];if(o){var i,a={};a[e.DDA.AsyncResultEnum.Properties.Context]=t[e.ParameterNames.AsyncContext],0==n?a[e.DDA.AsyncResultEnum.Properties.Value]=r:(i={},r=r||e.DDA.ErrorCodeManager.getErrorArgs(5001),i[e.DDA.AsyncResultEnum.ErrorProperties.Code]=n||5001,i[e.DDA.AsyncResultEnum.ErrorProperties.Name]=r.name||r,i[e.DDA.AsyncResultEnum.ErrorProperties.Message]=r.message||r),o(new e.DDA.AsyncResult(a,i))}}t.InvokeMethod=function(t,n,r,c){var u,l;try{var f=e.AsyncMethodCalls.get(t);l=f.verifyAndExtractCall(n,r,c);var p=a()[t],d=i("executeAsync"),h=null,g=!1,m=void 0;if(window.Excel&&window.Office.context.requirements.isSetSupported("RedirectV1Api")&&(window.Excel._RedirectV1APIs=!0,u=function(t){var n=!1,r=void 0;if(void 0!==e&&e._OfficeAppFactory&&"function"==typeof e._OfficeAppFactory.getHostInfo&&e.HostInfoPlatform&&e.HostInfoPlatform.ios){var o=e._OfficeAppFactory.getHostInfo();if(o&&o.hostPlatform&&(n=o.hostPlatform===e.HostInfoPlatform.ios)&&e.AsyncMethods)for(var i=Object.keys(e.AsyncMethods),a=0;a<i.length;a++){var s=i[a];if(e.AsyncMethods[s]===t){r=s;break}}}return{isIOSPlatformDetected:n,methodId:r}}(t),g=u.isIOSPlatformDetected,m=u.methodId),window.Excel&&window.Excel._RedirectV1APIs&&(h=window.Excel._V1APIMap[g&&void 0!==m?m:t])){var y=e.OUtil.shallowCopy(l);delete y[e.ParameterNames.AsyncContext],h.preprocess&&(y=h.preprocess(y));var v=new window.Excel.RequestContext,_=h.call(v,y);v.sync().then((function(){var t=_.value,n=t.status;delete t.status,delete t["@odata.type"],h.postprocess&&(t=h.postprocess(t,y)),0!=n&&(t=e.DDA.ErrorCodeManager.getErrorArgs(n)),s(l,n,t)})).catch((function(e){s(l,13991,null)}))}else{var b;b=e.HostParameterMap.toHost(p,l);var O=(new Date).getTime();d({dispId:p,hostCallArgs:b,onCalling:function(){},onReceiving:function(){},onComplete:function(t,n){var o;o=0==t?e.HostParameterMap.fromHost(p,n):n;var i=f.processResponse(t,o,r,l);s(l,t,i),e.AppTelemetry&&e.AppTelemetry.onMethodDone(p,b,Math.abs((new Date).getTime()-O),t)}})}}catch(e){o(e,f,n,l)}},t.AddEventHandler=function(t,n,c,u){var l,f,p,d=!1;function h(t){var r;0==t&&((d?n.addObjectEventHandler(f,l[e.ParameterNames.Id],p):n.addEventHandler(f,p))||(t=13991));0!=t&&(r=e.DDA.ErrorCodeManager.getErrorArgs(t)),s(l,t,r)}try{var g=e.AsyncMethodCalls.get(e.AsyncMethods.AddHandlerAsync);if(l=g.verifyAndExtractCall(t,c,n),f=l[e.ParameterNames.EventType],p=l[e.ParameterNames.Handler],u)return void h(0);var m=a()[f],y=(d=r(m))?l[e.ParameterNames.Id]:c.id||"";if(0==(d?n.getObjectEventHandlerCount(f,y):n.getEventHandlerCount(f)))i("registerEventAsync")({eventType:f,dispId:m,targetId:y,onCalling:function(){},onReceiving:function(){},onComplete:h,onEvent:function(t){var r=e.HostParameterMap.fromHost(m,t);d?n.fireObjectEvent(y,e.manufactureEventArgs(f,y,r)):n.fireEvent(e.manufactureEventArgs(f,c,r))}});else h(0)}catch(e){o(e,g,t,l)}},t.RemoveEventHandler=function(t,n,c){var u,l,f,p=!1;function d(t){var n;0!=t&&(n=e.DDA.ErrorCodeManager.getErrorArgs(t)),s(u,t,n)}try{var h=e.AsyncMethodCalls.get(e.AsyncMethods.RemoveHandlerAsync);l=(u=h.verifyAndExtractCall(t,c,n))[e.ParameterNames.EventType],f=u[e.ParameterNames.Handler];var g,m,y=a()[l],v=(p=r(y))?u[e.ParameterNames.Id]:c.id||"";null===f?(m=p?n.clearObjectEventHandlers(l,v):n.clearEventHandlers(l),g=0):g=(m=p?n.removeObjectEventHandler(l,v,f):n.removeEventHandler(l,f))?0:5003;var _=p?n.getObjectEventHandlerCount(l,v):n.getEventHandlerCount(l);if(m&&0==_)i("unregisterEventAsync")({eventType:l,dispId:y,targetId:v,onCalling:function(){},onReceiving:function(){},onComplete:d});else d(g)}catch(e){o(e,h,t,u)}},t.OpenDialog=function(t,n,r){var c,u,l=e.EventType.DialogMessageReceived,f=e.EventType.DialogEventReceived;function p(t){if(0!=t)i=e.DDA.ErrorCodeManager.getErrorArgs(t);else{var o={};o.id=u,o.data=n;var i=d.processResponse(t,o,r,c);e.DialogShownStatus.hasDialogShown=!0,n.clearEventHandlers(l),n.clearEventHandlers(f)}s(c,t,i)}try{if(null!=l&&null!=f||p(5e3),null==e.AsyncMethods.DisplayDialogAsync)return void p(5001);var d=e.AsyncMethodCalls.get(e.AsyncMethods.DisplayDialogAsync);c=d.verifyAndExtractCall(t,r,n);var h=a()[l],g=i("openDialog");u=JSON.stringify(c),e.DialogShownStatus.hasDialogShown||(n.clearQueuedEvent(l),n.clearQueuedEvent(f),n.clearQueuedEvent(e.EventType.DialogParentMessageReceived)),g({eventType:l,dispId:h,targetId:u,onCalling:function(){},onReceiving:function(){},onComplete:p,onEvent:function(t){var o=e.HostParameterMap.fromHost(h,t),i=e.manufactureEventArgs(l,r,o);if(i.type==f){e.DDA.ErrorCodeManager.getErrorArgs(i.error);var a={};a.code=status||5001,i.error=new e.DDA.Error(a[e.DDA.AsyncResultEnum.ErrorProperties.Name],a[e.DDA.AsyncResultEnum.ErrorProperties.Message],a[e.DDA.AsyncResultEnum.ErrorProperties.Code])}n.fireOrQueueEvent(i),12006==o.messageType&&(n.clearEventHandlers(l),n.clearEventHandlers(f),n.clearEventHandlers(e.EventType.DialogParentMessageReceived),e.DialogShownStatus.hasDialogShown=!1)}})}catch(e){o(e,d,t,c)}},t.CloseDialog=function(t,n,r,s){var c,u,l;try{var f=e.AsyncMethodCalls.get(e.AsyncMethods.CloseAsync);c=f.verifyAndExtractCall(t,s,r),u=e.EventType.DialogMessageReceived,l=e.EventType.DialogEventReceived,r.clearEventHandlers(u),r.clearEventHandlers(l);var p=a()[u];i("closeDialog")({eventType:u,dispId:p,targetId:n,onCalling:function(){},onReceiving:function(){},onComplete:function(t){t,e.DialogShownStatus.hasDialogShown=!1}})}catch(e){o(e,f,t,c)}},t.MessageParent=function(t,n){var r=e.SyncMethodCalls.get(e.SyncMethods.MessageParent).verifyAndExtractCall(t,n,{});return i("messageParent")({dispId:a()[e.SyncMethods.MessageParent],hostCallArgs:r,onCalling:function(){},onReceiving:function(){}})},t.SendMessage=function(t,n,r){var o=e.SyncMethodCalls.get(e.SyncMethods.SendMessage).verifyAndExtractCall(t,r,{});return i("sendMessage")({dispId:a()[e.SyncMethods.SendMessage],hostCallArgs:o,onCalling:function(){},onReceiving:function(){}})},t.addAsyncMethods=function(t,n,r){for(var o in n){var i=n[o];t[i]||e.OUtil.defineEnumerableProperty(t,i,{value:function(n){return function(){var o=e.DispIdHost.InvokeMethod;o(n,arguments,t,r)}}(i)})}},t.addEventSupport=function(t,n,r){var o=e.AsyncMethods.AddHandlerAsync,i=e.AsyncMethods.RemoveHandlerAsync;t[o]||e.OUtil.defineEnumerableProperty(t,o,{value:function(){var o=e.DispIdHost.AddEventHandler;o(arguments,n,t,r)}}),t[i]||e.OUtil.defineEnumerableProperty(t,i,{value:function(){var r=e.DispIdHost.RemoveEventHandler;r(arguments,n,t)}})},t.issueAsyncResult=s}(e.DispIdHost||(e.DispIdHost={}))}(OSF||(OSF={})),function(e){e.manufactureEventArgs=function(t,n,r){var o;switch(t){case e.EventType.DocumentSelectionChanged:o=new e.DocumentSelectionChangedEventArgs(n);break;case e.EventType.BindingSelectionChanged:o=new e.BindingSelectionChangedEventArgs(e.manufactureBinding(r,n.document),r[e.PropertyDescriptors.Subset]);break;case e.EventType.BindingDataChanged:o=new e.BindingDataChangedEventArgs(e.manufactureBinding(r,n.document));break;case e.EventType.SettingsChanged:o=new e.SettingsChangedEventArgs(n);break;case e.EventType.ActiveViewChanged:o=new e.ActiveViewChangedEventArgs(r);break;case e.EventType.LiveShareStateChanged:o=new e.LiveShareStateChangedEventArgs(r);break;case e.EventType.OfficeThemeChanged:o=new e.DDA.Theming.OfficeThemeChangedEventArgs(r);break;case e.EventType.DocumentThemeChanged:o=new e.DDA.Theming.DocumentThemeChangedEventArgs(r);break;case e.EventType.DataNodeInserted:o=new e.NodeInsertedEventArgs(e.manufactureDataNode(r[e.DataNodeEventProperties.NewNode]),r[e.DataNodeEventProperties.InUndoRedo]);break;case e.EventType.DataNodeReplaced:o=new e.NodeReplacedEventArgs(e.manufactureDataNode(r[e.DataNodeEventProperties.OldNode]),e.manufactureDataNode(r[e.DataNodeEventProperties.NewNode]),r[e.DataNodeEventProperties.InUndoRedo]);break;case e.EventType.DataNodeDeleted:o=new e.NodeDeletedEventArgs(e.manufactureDataNode(r[e.DataNodeEventProperties.OldNode]),e.manufactureDataNode(r[e.DataNodeEventProperties.NextSiblingNode]),r[e.DataNodeEventProperties.InUndoRedo]);break;case e.EventType.DialogMessageReceived:o=new e.DialogEventArgs(r);break;case e.EventType.DialogParentMessageReceived:o=new e.DialogParentEventArgs(r)}return o}}(OSF||(OSF={})),function(e){var t="toHost",n="fromHost";!function(r){var o;r.self="self",r.dynamicTypes={},r.dynamicTypes[e.ParameterNames.Data]={toHost:function(t){if(null!=t&&void 0!==t.rows){var n={};n[e.TableDataProperties.TableRows]=t.rows,n[e.TableDataProperties.TableHeaders]=t.headers,t=n}return t},fromHost:function(e){return e}},r.dynamicTypes.sampleData=r.dynamicTypes.data;var i={};function a(e,t){var n,o;if(t.map)for(var a in o={},n=t.map){var s=n[a];s==r.self&&(s=a),o[s]=a}else n=t.toHost,o=t.fromHost;var c=i[e];if(c){var u=c.toHost;for(var l in u)n[l]=u[l];for(var f in u=c.fromHost)o[f]=u[f]}else c=i[e]={};c.toHost=n,c.fromHost=o}function s(e){l().addComplexType(e)}function c(t,o){var a=t?{}:void 0;for(var s in t){var u,f=t[s];if(e.ListType.isListType(s))for(var p in u=[],f)u.push(c(f[p],o));else if(e.OUtil.listContainsKey(r.dynamicTypes,s))u=r.dynamicTypes[s][o](f);else if(o==n&&l().preserveNesting(s))u=c(f,o);else{var d=i[s];if(d){var h=d[o];h&&void 0===(u=h[f])&&(u=f)}else u=f}a[s]=u}return a}function u(t,n,o){var a,s=i[t][o];if("toHost"==o)a=function e(t,n){var o;for(var a in n){var s;if(null!=(s=l().isComplexType(a)?e(t,i[a].toHost):t[a])){o||(o={});var c=n[a];c==r.self&&(c=a),o[c]=l().pack(a,s)}}return o}(c(n,o),s);else if("fromHost"==o){a=c(function t(n,o,a){for(var s in a||(a={}),o){var c,u,f=o[s];if(f==r.self)c=n;else{if("sourceData"==f){a[s]=n.toArray();continue}c=n[f]}if(null==c)a[s]=void 0;else if(c=l().unpack(s,c),l().isComplexType(s))u=i[s].fromHost,l().preserveNesting(s)?a[s]=t(c,u):t(c,u,a);else if(e.ListType.isListType(s)){(u={})[e.ListType.getDescriptor(s)]=r.self;var p=new Array(c.length);for(var d in c)p[d]=t(c[d],u);a[s]=p}else a[s]=c}return a}(n,s),o)}return a}function l(){if(!o){var t=e._OfficeAppFactory.getHostInfo();o=t.hostPlatform==e.HostInfoPlatform.web?new e.WebSpecialProcessor:new e.SafeArraySpecialProcessor}return o}function f(e){var t=null;if(e){t={};for(var n=e.length,r=0;r<n;r++)t[e[r].name]=e[r].value}return t}r.define=function(e){var t={},n=f(e.toHost);e.invertible?t.map=n:e.canonical?t.toHost=t.fromHost=n:(t.toHost=n,t.fromHost=f(e.fromHost)),a(e.type,t),e.isComplexType&&s(e.type)},r.toHost=function(e,n){return u(e,n,t)},r.fromHost=function(e,t){return u(e,t,n)},r.addMapping=a,r.addComplexType=s,r.getDynamicType=function(e){return l().getDynamicType(e)},r.setDynamicType=function(e,t){l().setDynamicType(e,t)},r.doMapValues=function(e,t){return c(e,t)}}(e.HostParameterMap||(e.HostParameterMap={}))}(OSF||(OSF={})),function(e){!function(t){var n={};t.setListType=function(e,t){n[e]=t},t.isListType=function(t){return e.OUtil.listContainsKey(n,t)},t.getDescriptor=function(e){return n[e]}}(e.ListType||(e.ListType={}))}(OSF||(OSF={})),function(e){var t=function(){function t(e){this.m_liveShareStateInstance=e}return Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.LiveShareStateChanged},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"liveShareState",{get:function(){return this.m_liveShareStateInstance},enumerable:!0,configurable:!0}),t}();e.LiveShareStateChangedEventArgs=t}(OSF||(OSF={})),function(e){!function(e){e.ActiveViewChanged="activeViewChanged",e.DialogMessageReceived="dialogMessageReceived",e.DialogParentMessageReceived="dialogParentMessageReceived",e.DialogParentEventReceived="dialogParentEventReceived",e.DialogEventReceived="dialogEventReceived",e.BindingDataChanged="bindingDataChanged",e.BindingSelectionChanged="bindingSelectionChanged",e.OfficeThemeChanged="officeThemeChanged",e.DocumentThemeChanged="documentThemeChanged",e.DataNodeDeleted="nodeDeleted",e.DataNodeInserted="nodeInserted",e.DataNodeReplaced="nodeReplaced",e.DocumentSelectionChanged="documentSelectionChanged",e.LiveShareStateChanged="liveShareStateChanged",e.NodeDeleted="nodeDeleted",e.NodeInserted="nodeInserted",e.NodeReplaced="nodeReplaced",e.SettingsChanged="settingsChanged"}(e.EventType||(e.EventType={}))}(Office||(Office={})),function(e){!function(e){e.TableRows="TableRows",e.TableHeaders="TableHeaders"}(e.TableDataProperties||(e.TableDataProperties={}))}(OSF||(OSF={})),function(e){!function(t){var n,r,o;function i(){try{var e=window.navigator.userAgent;return e.indexOf("MSIE ")>-1||e.indexOf("Trident/")>-1||e.indexOf("Edge/")>-1}catch(e){return u("Error happens in isInternetExplorer.",e),!1}}function a(e){if("undefined"!=typeof JSON)try{return JSON.stringify(e)}catch(e){}return""}!function(e){e.ButtonBorderColor="buttonBorderColor",e.ButtonBackgroundColor="buttonBackgroundColor"}(t.HostThemeButtonStyleKeys||(t.HostThemeButtonStyleKeys={})),function(e){e.HostButtonBorderColor="#86bfa0",e.HostButtonBackgroundColor="#d3f0e0"}(n||(n={})),function(e){e.HostButtonBorderColor="#a3bde3",e.HostButtonBackgroundColor="#d5e1f2"}(r||(r={})),function(e){e.HostButtonBorderColor="#f5ba9d",e.HostButtonBackgroundColor="#fcf0ed"}(o||(o={})),t.finalizeProperties=function(e,t){t=t||{};for(var n=Object.getOwnPropertyNames(e),r=n.length,o=0;o<r;o++){var i=n[o],a=Object.getOwnPropertyDescriptor(e,i);a.get||a.set||(a.writable=t.writable||!1),a.configurable=t.configurable||!1,a.enumerable=t.enumerable||!0,Object.defineProperty(e,i,a)}return e},t.defineEnumerableProperties=function(e,t){return function(e,t,n){for(var r in t=t||{})c(e,r,t[r],n);return e}(e,t,["enumerable"])},t.defineEnumerableProperty=function(e,t,n){return c(e,t,n,["enumerable"])},t.listContainsKey=function(e,t){for(var n in e)if(t==n)return!0;return!1},t.augmentList=function(e,t){var n=e.push?function(t,n){e.push(n)}:function(t,n){e[t]=n};for(var r in t)n(r,t[r])},t.createObject=function(e){var t=null;if(e){t={};for(var n=e.length,r=0;r<n;r++)t[e[r].name]=e[r].value}return t},t.listContainsValue=function(e,t){for(var n in e)if(t==e[n])return!0;return!1},t.shouldUseLocalStorageToPassMessage=function(){try{for(var e=["Windows NT 6.1","Windows NT 6.2","Windows NT 6.3","Windows NT 10.0"],t=window.navigator.userAgent,n=0,r=e.length;n<r;n++)if(t.indexOf(e[n])>-1)return i();return!1}catch(e){return u("Error happens in shouldUseLocalStorageToPassMessage.",e),!1}},t.isInternetExplorer=i,t.serializeObjectToString=a,t.formatString=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e,r=n[0];return r.replace(/{(\d+)}/gm,(function(e,t){var r=parseInt(t,10)+1;return void 0===n[r]?"{"+t+"}":n[r]}))},t.addHostInfoAsQueryParam=function(e,t){if(!e)return null;var n,r="#",o=(e=e.trim()||"").split(r),i=o.shift(),a=o.join(r),s=i.split("?");return s.length>1?n=i+"&_host_Info="+t:s.length>0&&(n=i+"?_host_Info="+t),a?[n,r,a].join(""):n},t.getHostnamePortionForLogging=function(e){var t=e.split("."),n=t.length;return n>=2?t[n-2]+"."+t[n-1]:1==n?t[0]:void 0},t.shallowCopy=function(e){if(null==e)return null;if(e instanceof Object){if(Array.isArray(e)){for(var t=[],n=0;n<e.length;n++)t.push(e[n]);return t}var r=e.constructor();for(var o in e)e.hasOwnProperty(o)&&(r[o]=e[o]);return r}return e},t.getXdmEventName=function(t,n){return n==e.EventType.BindingSelectionChanged||n==e.EventType.BindingDataChanged||n==e.EventType.DataNodeDeleted||n==e.EventType.DataNodeInserted||n==e.EventType.DataNodeReplaced?t+"_"+n:n},t.getCommonUI=function(){switch(Office.context.host){case Office.HostType.Excel:return n;case Office.HostType.Word:return r;case Office.HostType.PowerPoint:return o}return null},t.getDomainForUrl=function(e){if(!e)return null;var t=document.createElement("a");return t.href=e,t.protocol+"//"+t.host},t.delayExecutionAndCache=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n={calc:e[0]};return n.calc&&(n.val=n.calc.apply(this,e),delete n.calc),n.val};var s=-1;function c(e,t,n,r){for(var o in n=n||{},r){var i=r[o];null==n[i]&&(n[i]=!0)}return Object.defineProperty(e,t,n),e}function u(t,n){e.Utility.trace(t+" Exception details: "+a(n))}t.getUniqueId=function(){return(s+=1).toString()}}(e.OUtil||(e.OUtil={}))}(OSF||(OSF={})),function(e){!function(e){e.BindingType="bindingType",e.CoercionType="coercionType",e.ValueFormat="valueFormat",e.FilterType="filterType",e.Columns="columns",e.SampleData="sampleData",e.GoToType="goToType",e.SelectionMode="selectionMode",e.Id="id",e.PromptText="promptText",e.ItemName="itemName",e.FailOnCollision="failOnCollision",e.StartRow="startRow",e.StartColumn="startColumn",e.RowCount="rowCount",e.ColumnCount="columnCount",e.Rows="rows",e.OverwriteIfStale="overwriteIfStale",e.FileType="fileType",e.EventType="eventType",e.Handler="handler",e.SliceSize="sliceSize",e.SliceIndex="sliceIndex",e.ActiveView="activeView",e.Status="status",e.PlatformType="platformType",e.HostType="hostType",e.Email="email",e.OfficeTheme="officeTheme",e.DocumentTheme="documentTheme",e.ForceConsent="forceConsent",e.ForceAddAccount="forceAddAccount",e.AuthChallenge="authChallenge",e.AllowConsentPrompt="allowConsentPrompt",e.ForMSGraphAccess="forMSGraphAccess",e.AllowSignInPrompt="allowSignInPrompt",e.JsonPayload="jsonPayload",e.EnableNewHosts="enableNewHosts",e.AccountTypeFilter="accountTypeFilter",e.AddinTrustId="addinTrustId",e.Reserved="reserved",e.Tcid="tcid",e.Xml="xml",e.Namespace="namespace",e.Prefix="prefix",e.XPath="xPath",e.Text="text",e.ImageLeft="imageLeft",e.ImageTop="imageTop",e.ImageWidth="imageWidth",e.ImageHeight="imageHeight",e.TaskId="taskId",e.FieldId="fieldId",e.FieldValue="fieldValue",e.ServerUrl="serverUrl",e.ListName="listName",e.ResourceId="resourceId",e.ViewType="viewType",e.ViewName="viewName",e.GetRawValue="getRawValue",e.CellFormat="cellFormat",e.TableOptions="tableOptions",e.TaskIndex="taskIndex",e.ResourceIndex="resourceIndex",e.CustomFieldId="customFieldId",e.Url="url",e.MessageHandler="messageHandler",e.Width="width",e.Height="height",e.RequireHTTPs="requireHTTPS",e.DisplayInIframe="displayInIframe",e.HideTitle="hideTitle",e.UseDeviceIndependentPixels="useDeviceIndependentPixels",e.PromptBeforeOpen="promptBeforeOpen",e.EnforceAppDomain="enforceAppDomain",e.UrlNoHostInfo="urlNoHostInfo",e.Base64="base64",e.FormId="formId"}(e.ParameterNames||(e.ParameterNames={}))}(OSF||(OSF={})),function(e){!function(t){function n(t,n){var r=(new Date).getTime();return function(o){n.onReceiving&&n.onReceiving();var i=o.toArray?o.toArray()[0]:o;return n.onComplete&&n.onComplete(i),e.AppTelemetry&&e.AppTelemetry.onRegisterDone(t,n.dispId,Math.abs((new Date).getTime()-r),i),!0}}function r(e){var t=e;if(null!=e&&e.toArray){var n=e.toArray();t=new Array(n.length);for(var o=0;o<n.length;o++)t[o]=r(n[o])}return t}t.executeAsync=function(t){try{t.onCalling&&t.onCalling(),e._OfficeAppFactory.getClientHostController().execute(t.dispId,function t(n){var r=n;if(e.OUtil.isArray(n))for(var o=r.length,i=0;i<o;i++)r[i]=t(r[i]);else if(e.OUtil.isDate(n))r=n.getVarDate();else if("object"==typeof n&&!e.OUtil.isArray(n))for(var a in r=[],n)e.OUtil.isFunction(n[a])||(r[a]=t(n[a]));return r}(t.hostCallArgs),(function(e,n){var o,i;if("number"==typeof e?(o=[],i=e):i=(o=e.toArray())[0],1==i)return null!=(a=r(a=o[1]))&&(t._chunkResultData||(t._chunkResultData=new Array),t._chunkResultData[a[0]]=a[1]),!1;if(t.onReceiving&&t.onReceiving(),t.onComplete){var a;if(0==i){if(o.length>2){a=[];for(var s=1;s<o.length;s++)a[s-1]=o[s]}else a=o[1];if(t._chunkResultData&&null!=(a=r(a))){var c=a[a.length-1];t._chunkResultData.length==c?a[a.length-1]=t._chunkResultData:i=5001}}else a=o[1];t.onComplete(i,a)}return!0}))}catch(n){e.SafeArrayDelegate.onException(n,t)}},t.registerEventAsync=function(t){t.onCalling&&t.onCalling();var r=n(!0,t);try{e._OfficeAppFactory.getClientHostController().registerEvent(t.dispId,void 0,t.targetId,(function(n,r){t.onEvent&&t.onEvent(r),e.AppTelemetry&&e.AppTelemetry.onEventDone(t.dispId)}),r)}catch(n){e.SafeArrayDelegate.onException(n,t)}},t.unregisterEventAsync=function(t){t.onCalling&&t.onCalling();var r=n(!1,t);try{e._OfficeAppFactory.getClientHostController().unregisterEvent(t.dispId,void 0,t.targetId,r)}catch(n){e.SafeArrayDelegate.onException(n,t)}},t.onException=function(t,n){var r,o=t.number;if(o)switch(o){case-2146828218:r=7e3;break;case-2147467259:r=n.dispId==e.EventDispId.dispidDialogMessageReceivedEvent?12007:5001;break;case-2146828283:case-2147209089:r=5010;break;case-2147208704:r=5100;break;case-2146827850:default:r=5001}n.onComplete&&n.onComplete(r||5001)},t.onExceptionSyncMethod=function(e,t){var n,r=e.number;if(r)switch(r){case-2146828218:n=7e3;break;case-2146827850:default:n=5001}return n||5001},t.getOnAfterRegisterEvent=n}(e.SafeArrayDelegate||(e.SafeArrayDelegate={}))}(OSF||(OSF={})),function(e){var t=function(){function t(e){this.m_settingsInstance=e}return Object.defineProperty(t.prototype,"type",{get:function(){return e.EventType.SettingsChanged},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"settings",{get:function(){return this.m_settingsInstance},enumerable:!0,configurable:!0}),t}();e.SettingsChangedEventArgs=t}(OSF||(OSF={})),function(e){var t=function(){function t(e,t){this._complexTypes=e,this.dynamicTypes=t}return t.prototype.addComplexType=function(e){this._complexTypes.push(e)},t.prototype.getDynamicType=function(e){return this.dynamicTypes[e]},t.prototype.setDynamicType=function(e,t){this.dynamicTypes[e]=t},t.prototype.isComplexType=function(t){return e.OUtil.listContainsValue(this._complexTypes,t)},t.prototype.isDynamicType=function(t){return e.OUtil.listContainsKey(this.dynamicTypes,t)},t.prototype.preserveNesting=function(e){return!1},t.prototype.pack=function(e,t){return this.isDynamicType(e)?this.dynamicTypes[e].toHost(t):t},t.prototype.unpack=function(e,t){return this.isDynamicType(e)?this.dynamicTypes[e].fromHost(t):t},t}();e.SpecialProcessor=t}(OSF||(OSF={}));__extends=this&&this.__extends||function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();!function(e){var t=function(t){function n(){var n={};return n[e.ParameterNames.Data]={toHost:function(t){if(e.TableDataProperties&&"string"!=typeof t&&void 0!==t[e.TableDataProperties.TableRows]){var n=[];n[0]=t[e.TableDataProperties.TableRows],n[1]=t[e.TableDataProperties.TableHeaders],t=n}return t},fromHost:function(t){var n;if(t.toArray)if(2===t.dimensions())n=e.Utility.twoDVBArrayToJaggedArray(t);else{var r=t.toArray();2===r.length&&(null!=r[0]&&r[0].toArray||null!=r[1]&&r[1].toArray)?((n={})[e.TableDataProperties.TableRows]=e.Utility.twoDVBArrayToJaggedArray(r[0]),n[e.TableDataProperties.TableHeaders]=e.Utility.twoDVBArrayToJaggedArray(r[1])):n=r}else n=t;return n}},t.call(this,[],n)||this}return __extends(n,t),n.prototype.unpack=function(t,n){var r;this.isComplexType(t)||e.ListType.isListType(t)?r=void 0!==n&&void 0!==n.toArray?n.toArray():n||{}:r=this.isDynamicType(t)?this.dynamicTypes[t].fromHost(n):n;return r},n}(e.SpecialProcessor);e.SafeArraySpecialProcessor=t}(OSF||(OSF={})),function(e){var t=function(){function t(t,n,r,o,i){this._requiredCount=t.length,this._apiMethods=new e.ApiMethodCall(t,n,r,o,i),this._supportedOptions=n}return t.prototype.verifyAndExtractCall=function(e,t,n){var r=this._apiMethods.extractRequiredArguments(e,t,n),o=this.extractOptions(e,r,t,n);return this._apiMethods.constructCallArgs(r,o,t,n)},t.prototype.extractOptions=function(t,n,r,o){if(t.length>this._requiredCount+1)throw e.Utility.createParameterException(Strings.OfficeOM.L_TooManyArguments);for(var i,a=t.length-1;a>=this._requiredCount;a--){var s=t[a];switch(typeof s){case"object":if(i)throw e.Utility.createParameterException(Strings.OfficeOM.L_TooManyArguments);i=s;break;default:throw e.Utility.createArgumentException(Strings.OfficeOM.L_InValidOptionalArgument)}}return i=this._apiMethods.fillOptions(i,n,r,o),this._apiMethods.verifyArguments(this._supportedOptions,i),i},t}();e.SyncMethodCall=t}(OSF||(OSF={})),function(e){!function(t){var n={};t.define=function(t){var r,o;n[t.method]=(o=(r=t).supportedOptions?e.OUtil.createObject(r.supportedOptions):[],new e.SyncMethodCall(r.requiredArguments||[],o,r.privateStateCallbacks,r.checkCallArgs,r.method.displayName))},t.get=function(e){return n[e]}}(e.SyncMethodCalls||(e.SyncMethodCalls={}))}(OSF||(OSF={})),function(e){e.SyncMethods={MessageParent:"messageParent",MessageChild:"messageChild",SendMessage:"sendMessage",AddMessageHandler:"addEventHandler"}}(OSF||(OSF={})),function(e){!function(t){!function(t){function n(t){for(var n=[{name:e.DDA.Theming.DocumentThemeEnum.PrimaryFontColor,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.PrimaryBackgroundColor,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.SecondaryFontColor,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.SecondaryBackgroundColor,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.Accent1,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.Accent2,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.Accent3,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.Accent4,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.Accent5,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.Accent6,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.Hyperlink,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.FollowedHyperlink,needToConvertToHex:!0},{name:e.DDA.Theming.DocumentThemeEnum.HeaderLatinFont,needToConvertToHex:!1},{name:e.DDA.Theming.DocumentThemeEnum.HeaderEastAsianFont,needToConvertToHex:!1},{name:e.DDA.Theming.DocumentThemeEnum.HeaderScriptFont,needToConvertToHex:!1},{name:e.DDA.Theming.DocumentThemeEnum.HeaderLocalizedFont,needToConvertToHex:!1},{name:e.DDA.Theming.DocumentThemeEnum.BodyLatinFont,needToConvertToHex:!1},{name:e.DDA.Theming.DocumentThemeEnum.BodyEastAsianFont,needToConvertToHex:!1},{name:e.DDA.Theming.DocumentThemeEnum.BodyScriptFont,needToConvertToHex:!1},{name:e.DDA.Theming.DocumentThemeEnum.BodyLocalizedFont,needToConvertToHex:!1}],r={},o=0;o<n.length;o++)n[o].needToConvertToHex?r[n[o].name]=e.OUtil.convertIntToCssHexColor(t[n[o].name]):r[n[o].name]=t[n[o].name];return r}function r(t){var n={};if(t){var r=e.DDA.Theming.OfficeThemeEnum,o={bodyBackgroundColor:{name:r.BodyBackgroundColor,convertToHex:!0},bodyForegroundColor:{name:r.BodyForegroundColor,convertToHex:!0},controlBackgroundColor:{name:r.ControlBackgroundColor,convertToHex:!0},controlForegroundColor:{name:r.ControlForegroundColor,convertToHex:!0},primaryFontColor:{name:r.BodyForegroundColor,convertToHex:!0},primaryBackgroundColor:{name:r.BodyBackgroundColor,convertToHex:!0},secondaryFontColor:{name:r.ControlForegroundColor,convertToHex:!0},secondaryBackgroundColor:{name:r.ControlBackgroundColor,convertToHex:!0},fluentThemeData:{name:r.FluentThemeData,convertToHex:!1}};for(var i in t){var a=!1,s=i;o[i]&&(s=o[i].name,a=o[i].convertToHex),n[s]=a?e.OUtil.convertIntToCssHexColor(t[i]):t[i]}null==n[r.IsDarkTheme]&&(n[r.IsDarkTheme]=e.DDA.Theming.GetIsDarkThemeFromCSSHexColor(n[r.BodyBackgroundColor])),null==n[r.ThemeId]&&(n[r.ThemeId]=n[r.IsDarkTheme]?e.DDA.Theming.ThemeId.Black:e.DDA.Theming.ThemeId.White)}return n}!function(e){e.PrimaryFontColor="primaryFontColor",e.PrimaryBackgroundColor="primaryBackgroundColor",e.SecondaryFontColor="secondaryFontColor",e.SecondaryBackgroundColor="secondaryBackgroundColor",e.Accent1="accent1",e.Accent2="accent2",e.Accent3="accent3",e.Accent4="accent4",e.Accent5="accent5",e.Accent6="accent6",e.Hyperlink="hyperlink",e.FollowedHyperlink="followedHyperlink",e.HeaderLatinFont="headerLatinFont",e.HeaderEastAsianFont="headerEastAsianFont",e.HeaderScriptFont="headerScriptFont",e.HeaderLocalizedFont="headerLocalizedFont",e.BodyLatinFont="bodyLatinFont",e.BodyEastAsianFont="bodyEastAsianFont",e.BodyScriptFont="bodyScriptFont",e.BodyLocalizedFont="bodyLocalizedFont"}(t.DocumentThemeEnum||(t.DocumentThemeEnum={})),function(e){e.BodyBackgroundColor="bodyBackgroundColor",e.BodyForegroundColor="bodyForegroundColor",e.ControlBackgroundColor="controlBackgroundColor",e.ControlForegroundColor="controlForegroundColor",e.IsDarkTheme="isDarkTheme",e.ThemeId="themeId",e.FluentThemeData="fluentThemeData"}(t.OfficeThemeEnum||(t.OfficeThemeEnum={})),function(e){e.PrimaryFontColor="primaryFontColor",e.PrimaryBackgroundColor="primaryBackgroundColor",e.SecondaryFontColor="secondaryFontColor",e.SecondaryBackgroundColor="secondaryBackgroundColor",e.IsDarkTheme="isDarkTheme",e.ThemeId="themeId"}(t.OfficeThemeEnumWac||(t.OfficeThemeEnumWac={})),function(e){e[e.Colorful=0]="Colorful",e[e.DarkGray=1]="DarkGray",e[e.Black=2]="Black",e[e.White=3]="White"}(t.ThemeId||(t.ThemeId={})),t.ConvertToDocumentTheme=n,t.GetIsDarkThemeFromCSSHexColor=function(e){var t="#"===e.charAt(0)?e.substring(1,7):e;return.299*parseInt(t.substring(0,2),16)+.587*parseInt(t.substring(2,4),16)+.114*parseInt(t.substring(4,6),16)<186},t.ConvertToOfficeTheme=r;var o=function(t){var n=null,o=e._OfficeAppFactory.getHostInfo();n=o.hostPlatform==e.HostInfoPlatform.web?t:r(t);var i=e.DDA.Theming.OfficeThemeEnum;void 0===n[i.IsDarkTheme]&&(n.isDarkTheme=e.DDA.Theming.GetIsDarkThemeFromCSSHexColor(t[i.BodyBackgroundColor])),void 0===n[i.ThemeId]&&(n.themeId=n.isDarkTheme?e.DDA.Theming.ThemeId.Black:e.DDA.Theming.ThemeId.White),o.hostPlatform!=e.HostInfoPlatform.web&&"mac"!=o.hostPlatform.toLowerCase()&&"ios"!=o.hostPlatform.toLowerCase()||Office.context&&Office.context.officeTheme&&(Office.context.officeTheme.bodyBackgroundColor=n.bodyBackgroundColor,Office.context.officeTheme.bodyForegroundColor=n.bodyForegroundColor,Office.context.officeTheme.controlBackgroundColor=n.controlBackgroundColor,Office.context.officeTheme.controlForegroundColor=n.controlForegroundColor,Office.context.officeTheme.isDarkTheme=n.isDarkTheme,Office.context.officeTheme.themeId=n.themeId),e.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.OfficeThemeChanged},officeTheme:{value:n}})};t.OfficeThemeChangedEventArgs=o;var i=function(t){var r=n(t);e.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.DocumentThemeChanged},documentTheme:{value:r}})};t.DocumentThemeChangedEventArgs=i}(t.Theming||(t.Theming={}))}(e.DDA||(e.DDA={}))}(OSF||(OSF={})),function(e){!function(t){var n=[];t.initialize=function(){n.forEach((function(t){t.defineMethodsFunc(),e.OUtil.getHostPlatform()==e.HostInfoPlatform.web?"function"==typeof t.defineWebParameterMapFunc&&t.defineWebParameterMapFunc():"function"==typeof t.defineSafeArrayParameterMapFunc&&t.defineSafeArrayParameterMapFunc(),"function"==typeof t.initializeFunc&&t.initializeFunc()}))},t.register=function(e){n.push(e)}}(e.V10ApiFeatureRegistry||(e.V10ApiFeatureRegistry={}))}(OSF||(OSF={})),function(e){!function(t){function n(t,n){var r=(new Date).getTime();return function(o,i){var a;if(n.onReceiving&&n.onReceiving(),0!=o)switch(o){case-5:a=7e3;break;default:a=5001}else a=i?i.Error?i.Error:0:5001;n.onComplete&&n.onComplete(a),e.AppTelemetry&&e.AppTelemetry.onRegisterDone(t,n.dispId,Math.abs((new Date).getTime()-r),a)}}t.version=1,function(e){e.Data="Data",e.Properties="Properties",e.BindingRequest="DdaBindingsMethod",e.BindingResponse="Bindings",e.SingleBindingResponse="singleBindingResponse",e.GetData="DdaGetBindingData",e.AddRowsColumns="DdaAddRowsColumns",e.SetData="DdaSetBindingData",e.ClearFormats="DdaClearBindingFormats",e.SetFormats="DdaSetBindingFormats",e.SettingsRequest="DdaSettingsMethod",e.BindingEventSource="ddaBinding",e.ArrayData="ArrayData"}(t.UniqueArguments||(t.UniqueArguments={})),t.executeAsync=function(t){t.hostCallArgs||(t.hostCallArgs={}),t.hostCallArgs.DdaMethod={ControlId:e._OfficeAppFactory.getId(),Version:e.WACDelegate.version,DispatchId:t.dispId},t.hostCallArgs.__timeout__=-1,t.onCalling&&t.onCalling(),e.getClientEndPoint()&&e.getClientEndPoint().invoke("executeMethod",(function(n,r){var o;if(t.onReceiving&&t.onReceiving(),0==n)e.WACDelegate.version=r.Version,o=r.Error;else switch(n){case-5:o=7e3;break;default:o=5001}t.onComplete&&t.onComplete(o,r)}),t.hostCallArgs)},t.getOnAfterRegisterEvent=n,t.registerEventAsync=function(t){t.onCalling&&t.onCalling(),e.getClientEndPoint()&&e.getClientEndPoint().registerForEvent(e.OUtil.getXdmEventName(t.targetId,t.eventType),(function(n){t.onEvent&&t.onEvent(n),e.AppTelemetry&&e.AppTelemetry.onEventDone(t.dispId)}),n(!0,t),{controlId:e._OfficeAppFactory.getId(),eventDispId:t.dispId,targetId:t.targetId})},t.unregisterEventAsync=function(t){t.onCalling&&t.onCalling(),e.getClientEndPoint()&&e.getClientEndPoint().unregisterForEvent(e.OUtil.getXdmEventName(t.targetId,t.eventType),n(!1,t),{controlId:e._OfficeAppFactory.getId(),eventDispId:t.dispId,targetId:t.targetId})}}(e.WACDelegate||(e.WACDelegate={}))}(OSF||(OSF={})),function(e){var t=function(t){function n(){var n=[e.WACDelegate.UniqueArguments.SingleBindingResponse,e.WACDelegate.UniqueArguments.BindingRequest,e.WACDelegate.UniqueArguments.BindingResponse,e.WACDelegate.UniqueArguments.GetData,e.WACDelegate.UniqueArguments.AddRowsColumns,e.WACDelegate.UniqueArguments.SetData,e.WACDelegate.UniqueArguments.ClearFormats,e.WACDelegate.UniqueArguments.SetFormats,e.WACDelegate.UniqueArguments.SettingsRequest,e.WACDelegate.UniqueArguments.BindingEventSource];return t.call(this,n,{})||this}return __extends(n,t),n}(e.SpecialProcessor);e.WebSpecialProcessor=t}(OSF||(OSF={})),function(e){!function(t){function n(t){if(null==t||null==t)return null;var n=null,r=typeof t;return void 0!==t.rows?n=Office.CoercionType.Table:e.OUtil.isArray(t)?n=Office.CoercionType.Matrix:("string"==r||"number"==r||"boolean"==r||e.OUtil.isDate(t))&&(n=Office.CoercionType.Text),n}function r(t,r,o){return(o=o||n(t))&&o!=r&&(t=function(t,n){var r;switch(t){case Office.CoercionType.Table:r=n;break;case Office.CoercionType.Matrix:r=function(e){var t=e.rows;null!=e.headers&&t.unshift(e.headers);return t}(n);break;case Office.CoercionType.SlideRange:e.manufactureSlideRange&&null==(r=e.manufactureSlideRange(i(n)))&&(r=i(n));break;case Office.CoercionType.Text:case Office.CoercionType.Html:case Office.CoercionType.Ooxml:default:r=i(n)}return r}(r,function(e,t){null==t&&(t=n(e));var r;switch(t){case Office.CoercionType.Table:r=e;break;case Office.CoercionType.Matrix:r=new Office.TableData(e);break;case Office.CoercionType.Text:case Office.CoercionType.Html:case Office.CoercionType.Ooxml:default:r=new Office.TableData(function(e){for(var t=e.split("\n"),n=0;n<t.length;n++)t[n]=t[n].split("\t");return t}(e))}return r}(t,o))),t}function o(e){if(1==e.length&&1==e[0].length)return""+e[0][0];for(var t="",n=0;n<e.length;n++)t+=e[n].join("\t")+"\n";return t.substring(0,t.length-1)}function i(e){var t="";null!=e.headers&&(t=o([e.headers])+"\n");var n=o(e.rows);return""==n&&(t=t.substring(0,t.length-1)),t+n}e.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){},defineSafeArrayParameterMapFunc:function(){e.HostParameterMap.define({type:e.ParameterNames.CoercionType,toHost:[{name:Office.CoercionType.Text,value:0},{name:Office.CoercionType.Matrix,value:1},{name:Office.CoercionType.Table,value:2},{name:Office.CoercionType.Html,value:3},{name:Office.CoercionType.Ooxml,value:4},{name:Office.CoercionType.OoxmlPackage,value:5},{name:Office.CoercionType.PdfFile,value:6},{name:Office.CoercionType.SlideRange,value:7}]});var t=e._OfficeAppFactory.getHostInfo();t.hostPlatform!=e.HostInfoPlatform.win32&&t.hostPlatform!=e.HostInfoPlatform.mac&&t.hostPlatform!=e.HostInfoPlatform.ios&&t.hostPlatform!=e.HostInfoPlatform.android||(e.OUtil.augmentList(Office.CoercionType,{Image:"image"}),e.OUtil.augmentList(Office.CoercionType,{XmlSvg:"xmlSvg"}),e.HostParameterMap.define({type:e.ParameterNames.CoercionType,toHost:[{name:"image",value:8},{name:"xmlSvg",value:9}]}));e.HostParameterMap.define({type:e.ParameterNames.ValueFormat,toHost:[{name:Office.ValueFormat.Unformatted,value:0},{name:Office.ValueFormat.Formatted,value:1}]}),e.HostParameterMap.define({type:e.ParameterNames.FilterType,toHost:[{name:Office.FilterType.All,value:0}]})},defineWebParameterMapFunc:function(){e.OUtil.augmentList(Office.CoercionType,{Image:"image"}),e.OUtil.augmentList(Office.CoercionType,{XmlSvg:"xmlSvg"}),e.HostParameterMap.define({type:e.ParameterNames.CoercionType,toHost:[{name:Office.CoercionType.Text,value:0},{name:Office.CoercionType.Matrix,value:1},{name:Office.CoercionType.Table,value:2},{name:Office.CoercionType.Html,value:3},{name:Office.CoercionType.Ooxml,value:4},{name:Office.CoercionType.OoxmlPackage,value:5},{name:Office.CoercionType.PdfFile,value:6},{name:Office.CoercionType.SlideRange,value:7},{name:"image",value:8},{name:"xmlSvg",value:9}]}),e.HostParameterMap.define({type:e.ParameterNames.ValueFormat,toHost:[{name:Office.ValueFormat.Unformatted,value:0},{name:Office.ValueFormat.Formatted,value:1}]}),e.HostParameterMap.define({type:e.ParameterNames.FilterType,toHost:[{name:Office.FilterType.All,value:0}]})}}),t.findArrayDimensionality=function t(n){if(e.OUtil.isArray(n)){for(var r=0,o=0;o<n.length;o++)r=Math.max(r,t(n[o]));return r+1}return 0},t.getCoercionDefaultForBinding=function(e){switch(e){case Office.BindingType.Matrix:return Office.CoercionType.Matrix;case Office.BindingType.Table:return Office.CoercionType.Table;case Office.BindingType.Text:default:return Office.CoercionType.Text}},t.getBindingDefaultForCoercion=function(e){switch(e){case Office.CoercionType.Matrix:return Office.BindingType.Matrix;case Office.CoercionType.Table:return Office.BindingType.Table;case Office.CoercionType.Text:case Office.CoercionType.Html:case Office.CoercionType.Ooxml:default:return Office.BindingType.Text}},t.determineCoercionType=n,t.coerceData=r,t.serializeDynamicData=function(t){if(null!=t&&void 0!==t.rows){var n={};n[e.TableDataProperties.TableRows]=t.rows,n[e.TableDataProperties.TableHeaders]=t.headers,t=n}var r;if(e._OfficeAppFactory.getHostInfo().hostPlatform==e.HostInfoPlatform.web)return"string"!=typeof t&&void 0!==t[e.TableDataProperties.TableRows]?((r={}).Rows=t[e.TableDataProperties.TableRows],r.Headers=t[e.TableDataProperties.TableHeaders],t=r):e.DataCoercion.determineCoercionType(t)==Office.CoercionType.Text&&(t=[[t]]),t;if(e.TableDataProperties&&"string"!=typeof t&&void 0!==t[e.TableDataProperties.TableRows]){(r=[])[0]=t[e.TableDataProperties.TableRows],r[1]=t[e.TableDataProperties.TableHeaders],t=r}return t},t.deserializeDynamicData=function(t,n){var o=null;if(e._OfficeAppFactory.getHostInfo().hostPlatform==e.HostInfoPlatform.web)null!=t.Rows?((o={})[e.TableDataProperties.TableRows]=t.Rows,o[e.TableDataProperties.TableHeaders]=t.Headers):o=t,!o||null==o[e.TableDataProperties.TableRows]&&null==o[e.TableDataProperties.TableHeaders]||(o=Office.manufactureTableData(o)),o=r(o,n);else{if(2===t.length){(o={})[e.TableDataProperties.TableRows]=t[0],o[e.TableDataProperties.TableHeaders]=t[1],o=Office.manufactureTableData(o)}else o=t;o=r(o,n)}return o}}(e.DataCoercion||(e.DataCoercion={}))}(OSF||(OSF={})),function(e){!function(e){!function(e){e.MessageType="messageType",e.MessageContent="messageContent",e.MessageOrigin="messageOrigin"}(e.DialogMessageReceivedEventKeys||(e.DialogMessageReceivedEventKeys={})),function(e){e.MessageType="messageType",e.MessageContent="messageContent",e.MessageOrigin="messageOrigin"}(e.DialogParentMessageReceivedEventKeys||(e.DialogParentMessageReceivedEventKeys={})),function(e){e.MessageToParent="messageToParent",e.TargetOrigin="targetOrigin"}(e.MessageParentKeys||(e.MessageParentKeys={})),function(e){e.DialogNotificationShown="dialogNotificationShown"}(e.DialogNotificationShownEventType||(e.DialogNotificationShownEventType={})),function(e){e.MessageContent="messageContent",e.TargetOrigin="targetOrigin"}(e.SendMessageKeys||(e.SendMessageKeys={}))}(e.Marshaling||(e.Marshaling={}))}(OSF||(OSF={})),function(e){var t;!function(e){e.DialogParentMessageReceivedEvent="DialogParentMessageReceivedEvent",e.DialogMessageReceivedEvent="DialogMessageReceivedEvent"}(e.EventDescriptors||(e.EventDescriptors={})),e.DialogParentMessageEventDispatch=new e.EventDispatch([e.EventType.DialogParentMessageReceived,e.EventType.DialogParentEventReceived]),t||(t={}),e.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){e.AsyncMethodCalls.define({method:e.AsyncMethods.DisplayDialogAsync,requiredArguments:[{name:e.ParameterNames.Url,types:["string"]}],supportedOptions:[{name:e.ParameterNames.Width,value:{types:["number"],defaultValue:99}},{name:e.ParameterNames.Height,value:{types:["number"],defaultValue:99}},{name:e.ParameterNames.RequireHTTPs,value:{types:["boolean"],defaultValue:!0}},{name:e.ParameterNames.DisplayInIframe,value:{types:["boolean"],defaultValue:!1}},{name:e.ParameterNames.HideTitle,value:{types:["boolean"],defaultValue:!1}},{name:e.ParameterNames.UseDeviceIndependentPixels,value:{types:["boolean"],defaultValue:!1}},{name:e.ParameterNames.PromptBeforeOpen,value:{types:["boolean"],defaultValue:!0}},{name:e.ParameterNames.EnforceAppDomain,value:{types:["boolean"],defaultValue:!0}},{name:e.ParameterNames.UrlNoHostInfo,value:{types:["boolean"],defaultValue:!1}}],privateStateCallbacks:[],onSucceeded:function(t,n,r){var o=t[e.ParameterNames.Id],i=t[e.ParameterNames.Data],a={},s=e.AsyncMethods.CloseAsync;e.OUtil.defineEnumerableProperty(a,s,{value:function(){var t=e.DispIdHost.CloseDialog;t(arguments,o,i,a)}});var c=e.SyncMethods.AddMessageHandler;if(e.OUtil.defineEnumerableProperty(a,c,{value:function(){var t=e.SyncMethodCalls.get(e.SyncMethods.AddMessageHandler),n=t.verifyAndExtractCall(arguments,a,i),r=n[e.ParameterNames.EventType],o=n[e.ParameterNames.Handler];return i.addEventHandlerAndFireQueuedEvent(r,o)}}),!0===e.EnableSendMessageDialogAPI){var u=e.SyncMethods.SendMessage;e.OUtil.defineEnumerableProperty(a,u,{value:function(){var t=e.DispIdHost.SendMessage;return t(arguments,i,a)}})}if(!0===e.EnableMessageChildDialogAPI){var l=e.SyncMethods.MessageChild;e.OUtil.defineEnumerableProperty(a,l,{value:function(){var t=e.DispIdHost.SendMessage;return t(arguments,i,a)}})}return a},checkCallArgs:function(t,n,r){return t[e.ParameterNames.Width]<=0&&(t[e.ParameterNames.Width]=1),!t[e.ParameterNames.UseDeviceIndependentPixels]&&t[e.ParameterNames.Width]>100&&(t[e.ParameterNames.Width]=99),t[e.ParameterNames.Height]<=0&&(t[e.ParameterNames.Height]=1),!t[e.ParameterNames.UseDeviceIndependentPixels]&&t[e.ParameterNames.Height]>100&&(t[e.ParameterNames.Height]=99),t[e.ParameterNames.RequireHTTPs]||(t[e.ParameterNames.RequireHTTPs]=!0),t}}),e.AsyncMethodCalls.define({method:e.AsyncMethods.CloseAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[]}),e.SyncMethodCalls.define({method:e.SyncMethods.MessageParent,requiredArguments:[{name:e.ParameterNames.MessageToParent,types:["string","number","boolean"]}],supportedOptions:[{name:e.ParameterNames.TargetOrigin,value:{types:["string"],defaultValue:""}}]}),e.SyncMethodCalls.define({method:e.SyncMethods.AddMessageHandler,requiredArguments:[{name:e.ParameterNames.EventType,enum:e.EventType,verify:function(e,t,n){return n.supportsEvent(e)}},{name:e.ParameterNames.Handler,types:["function"]}],supportedOptions:[]}),e.SyncMethodCalls.define({method:e.SyncMethods.SendMessage,requiredArguments:[{name:e.ParameterNames.MessageContent,types:["string"]}],supportedOptions:[{name:e.ParameterNames.TargetOrigin,value:{types:["string"],defaultValue:""}}],privateStateCallbacks:[]})},defineSafeArrayParameterMapFunc:function(){e.HostParameterMap.define({type:e.EventDispId.dispidDialogMessageReceivedEvent,fromHost:[{name:e.EventDescriptors.DialogMessageReceivedEvent,value:e.HostParameterMap.self}],isComplexType:!0}),e.HostParameterMap.define({type:e.EventDescriptors.DialogMessageReceivedEvent,fromHost:[{name:e.PropertyDescriptors.MessageType,value:0},{name:e.PropertyDescriptors.MessageContent,value:1},{name:e.PropertyDescriptors.MessageOrigin,value:2}],isComplexType:!0}),e.HostParameterMap.define({type:e.EventDispId.dispidDialogParentMessageReceivedEvent,fromHost:[{name:e.EventDescriptors.DialogParentMessageReceivedEvent,value:e.HostParameterMap.self}],isComplexType:!0}),e.HostParameterMap.define({type:e.EventDescriptors.DialogParentMessageReceivedEvent,fromHost:[{name:e.PropertyDescriptors.MessageType,value:0},{name:e.PropertyDescriptors.MessageContent,value:1},{name:e.PropertyDescriptors.MessageOrigin,value:2}],isComplexType:!0})},defineWebParameterMapFunc:function(){e.HostParameterMap.define({type:e.EventDispId.dispidDialogMessageReceivedEvent,fromHost:[{name:e.EventDescriptors.DialogMessageReceivedEvent,value:e.HostParameterMap.self}]}),e.HostParameterMap.addComplexType(e.EventDescriptors.DialogMessageReceivedEvent),e.HostParameterMap.define({type:e.EventDescriptors.DialogMessageReceivedEvent,fromHost:[{name:e.PropertyDescriptors.MessageType,value:e.Marshaling.DialogMessageReceivedEventKeys.MessageType},{name:e.PropertyDescriptors.MessageContent,value:e.Marshaling.DialogMessageReceivedEventKeys.MessageContent},{name:e.PropertyDescriptors.MessageOrigin,value:e.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin}]}),e.HostParameterMap.define({type:e.EventDispId.dispidDialogParentMessageReceivedEvent,fromHost:[{name:e.EventDescriptors.DialogParentMessageReceivedEvent,value:e.HostParameterMap.self}]}),e.HostParameterMap.addComplexType(e.EventDescriptors.DialogParentMessageReceivedEvent),e.HostParameterMap.define({type:e.EventDescriptors.DialogParentMessageReceivedEvent,fromHost:[{name:e.PropertyDescriptors.MessageType,value:e.Marshaling.DialogParentMessageReceivedEventKeys.MessageType},{name:e.PropertyDescriptors.MessageContent,value:e.Marshaling.DialogParentMessageReceivedEventKeys.MessageContent},{name:e.PropertyDescriptors.MessageOrigin,value:e.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin}]}),e.HostParameterMap.define({type:144,toHost:[{name:e.ParameterNames.MessageToParent,value:e.Marshaling.MessageParentKeys.MessageToParent},{name:e.ParameterNames.TargetOrigin,value:e.Marshaling.MessageParentKeys.TargetOrigin}]}),e.HostParameterMap.define({type:145,toHost:[{name:e.ParameterNames.MessageContent,value:e.Marshaling.SendMessageKeys.MessageContent},{name:e.ParameterNames.TargetOrigin,value:e.Marshaling.MessageParentKeys.TargetOrigin}]})},initializeFunc:function(){var t=e.OUtil.isPopupWindow();e.EnableMessageChildDialogAPI=!0,"onenote"==e._OfficeAppFactory.getHostInfo().hostType?e.EnableSendMessageDialogAPI=!1:e.EnableSendMessageDialogAPI=!0;var n=Office.context.ui;if(e.OUtil.isDialog()){var r=e.SyncMethods.MessageParent;n[r]||e.OUtil.defineEnumerableProperty(n,r,{value:function(){var t=e.DispIdHost.MessageParent;return t(arguments,n)}});var o=e.SyncMethods.AddMessageHandler;n[o]||void 0===e.DialogParentMessageEventDispatch||e.DispIdHost.addEventSupport(n,e.DialogParentMessageEventDispatch,t),t&&e.WacDialogAction.registerMessageReceivedEvent()}else{var i;i=null!=e.EventType.DialogParentMessageReceived?new e.EventDispatch([e.EventType.DialogMessageReceived,e.EventType.DialogEventReceived,e.EventType.DialogParentMessageReceived]):new e.EventDispatch([e.EventType.DialogMessageReceived,e.EventType.DialogEventReceived]);var a=e.AsyncMethods.DisplayDialogAsync;n[a]||e.OUtil.defineEnumerableProperty(n,a,{value:function(){var t=e.DispIdHost.OpenDialog;t(arguments,i,n)}})}e.OUtil.finalizeProperties(n)}})}(OSF||(OSF={}));var DialogApiManager=function(){function e(){}return e.messageChildRichApiBridge=function(){if(!0===OSF.EnableMessageChildDialogAPI){var e=OSF.DispIdHost.SendMessage;return e(arguments,null,null)}},e}();__assign=this&&this.__assign||function(){return(__assign=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};!function(e){!function(e){e.Url="url",e.Width="width",e.Height="height",e.DisplayInIframe="displayInIframe",e.HideTitle="hideTitle",e.UseDeviceIndependentPixels="useDeviceIndependentPixels",e.PromptBeforeOpen="promptBeforeOpen",e.EnforceAppDomain="enforceAppDomain",e.UrlNoHostInfo="urlNoHostInfo",e.TargetOrigin="targetOrigin"}(e.ShowWindowDialogParameterKeys||(e.ShowWindowDialogParameterKeys={})),function(e){var t="excel",n="word",r="powerpoint",o="outlook",i="visio";e.getDialogCssManager=function(e){switch(e){case t:case n:case r:case o:case i:default:return new a}};var a=function(){function e(){this.overlayElementCSS=["position: absolute","top: 0","left: 0","width: 100%","height: 100%","background-color: rgba(198, 198, 198, 0.5)","z-index: 99998"],this.dialogNotificationPanelCSS=["width: 100%","height: 190px","position: absolute","z-index: 99999","background-color: rgba(255, 255, 255, 1)","left: 0px","top: 50%","margin-top: -95px"],this.newWindowNotificationTextPanelCSS=["margin: 20px 14px","font-family: Segoe UI,Arial,Verdana,sans-serif","font-size: 14px","height: 100px","line-height: 100px"],this.newWindowNotificationTextSpanCSS=["display: inline-block","line-height: normal","vertical-align: middle"],this.crossZoneNotificationTextPanelCSS=["margin: 20px 14px","font-family: Segoe UI,Arial,Verdana,sans-serif","font-size: 14px","height: 100px"],this.dialogNotificationButtonPanelCSS="margin:0px 9px",this.buttonStyleCSS=["text-align: center","width: 70px","height: 25px","font-size: 14px","font-family: Segoe UI,Arial,Verdana,sans-serif","margin: 0px 5px","border-width: 1px","border-style: solid"]}return e.prototype.getOverlayElementCSS=function(){return this.overlayElementCSS.join(";")},e.prototype.getDialogNotificationPanelCSS=function(){return this.dialogNotificationPanelCSS.join(";")},e.prototype.getNewWindowNotificationTextPanelCSS=function(){return this.newWindowNotificationTextPanelCSS.join(";")},e.prototype.getNewWindowNotificationTextSpanCSS=function(){return this.newWindowNotificationTextSpanCSS.join(";")},e.prototype.getCrossZoneNotificationTextPanelCSS=function(){return this.crossZoneNotificationTextPanelCSS.join(";")},e.prototype.getDialogNotificationButtonPanelCSS=function(){return this.dialogNotificationButtonPanelCSS},e.prototype.getDialogButtonCSS=function(){return this.buttonStyleCSS.join(";")},e}();e.DefaultDialogCSSManager=a}(e.WacCommonUICssManager||(e.WacCommonUICssManager={})),function(t){var n=null,r=null,o=null,i=null,a="osfDialogInternal:action=closeDialog",s=null,c=!1,u=-1,l="messageParentKey",f=null,p="#ababab",d="#ffffff",h="newWindowNotificaiton",g="configureBrowserLink",m="dialogNotificationTextPanel",y={dispId:e.EventDispId.dispidDialogNotificationShownInAddinEvent,eventType:e.Marshaling.DialogNotificationShownEventType.DialogNotificationShown,onComplete:null,onCalling:null};function v(t,n){var r=n.message,o=n.targetOrigin;if(o)t.postMessage(r,o);else{var i=e._OfficeAppFactory.getOfficeAppContext().get_appDomains(),a=window.location.origin;if(a||(a=window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:"")),i)for(var s=0;s<i.length&&-1!==i[s].indexOf("://");s++)t.postMessage(r,i[s]);e.XdmCommunicationManager.checkUrlWithAppDomains(i,a)||t.postMessage(r,a)}}function _(){try{i&&i.id==h&&s&&s(12009)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Error happened during executing displayDialogAsync callback."+t)}E()}function b(t,n){var r=!1,a=e.WacCommonUICssManager.getDialogCssManager(n);o=T(a),document.body.insertBefore(o,document.body.firstChild),(i=function(t,n){var r=document.createElement("div");r.style.cssText=t.getDialogNotificationPanelCSS(),N(r);var o=document.createElement("div");o.style.cssText=t.getCrossZoneNotificationTextPanelCSS(),o.id=m;var i=document.createElement("a");i.id=g,i.href="#",i.innerText=Strings.OfficeOM.L_NewWindowCrossZoneConfigureBrowserLink,i.setAttribute("onclick","window.open('https://support.microsoft.com/en-us/help/17479/windows-internet-explorer-11-change-security-privacy-settings', '_blank', 'fullscreen=1')");var a=document.createElement("span");if(Strings.OfficeOM.L_NewWindowCrossZone){var s=Strings.OfficeOM.L_NewWindowCrossZone.replace(/{1+}/gm,e.OUtil.getDomainForUrl(n)).split("{0}");a.appendChild(document.createTextNode(s[0])),a.appendChild(i),a.appendChild(document.createTextNode(s[1]))}return o.appendChild(a),r.appendChild(o),r}(a,t)).id="crossZoneNotification";var s=w(a),u=I(a,Strings.OfficeOM.L_DialogOK?Strings.OfficeOM.L_DialogOK:"OK");s.appendChild(u),i.appendChild(s),document.body.insertBefore(i,document.body.firstChild),c=!0,u.onclick=function(){E()},u.addEventListener("keydown",(function(e){9==e.keyCode?(document.getElementById(g).focus(),e.preventDefault(),e.stopPropagation()):13==e.keyCode&&(r=!0,e.preventDefault(),e.stopPropagation())}),!1),u.addEventListener("keyup",(function(e){13==e.keyCode&&r&&(r=!1,E(),e.preventDefault(),e.stopPropagation())}),!1),document.getElementById(g).addEventListener("keydown",(function(e){9==e.keyCode&&(u.focus(),e.preventDefault(),e.stopPropagation())}),!1),window.focus(),u.focus()}function O(t){if(t.source==n)try{var o=t.origin;if(!function(t,n,r){if(void 0===r&&(r=!0),!t||!n)return!1;var o=e.OUtil.parseUrl(t),i=e.OUtil.parseUrl(n),a=e._OfficeAppFactory.getOfficeAppContext().get_appDomains();if("https:"!==o.protocol)return!1;var s=o.protocol===i.protocol&&o.hostname===i.hostname&&o.port===i.port,c=e.XdmCommunicationManager.checkUrlWithAppDomains(a,t),u=s||c;return!u&&r&&(u=e.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(n,t)),u}(o,e._OfficeAppFactory.getOfficeAppContext().get_docUrl(),!0))throw new Error("Received a message from a dialog with an untrusted domain.");var i={};i[e.Marshaling.DialogMessageReceivedEventKeys.MessageType]=0,i[e.Marshaling.DialogMessageReceivedEventKeys.MessageContent]=t.data,i[e.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin]=o,r(i)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Error happened during receive message handler."+t)}}function S(t){var n=e._OfficeAppFactory.getId()+l;if(t.key==n)try{var o={};o[e.Marshaling.DialogMessageReceivedEventKeys.MessageType]=0,o[e.Marshaling.DialogMessageReceivedEventKeys.MessageContent]=t.newValue,o[e.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin]=t.origin,r(o)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Error happened during storage changed handler."+t)}}function C(t){var o=e._OfficeAppFactory.getHostInfo(),i=[o.hostType,o.hostPlatform,o.hostSpecificFileVersion,o.hostLocale,o.osfControlAppCorrelationId,"isDialog",o.disableLogging?"disableLogging":"",o.flags&e.HostInfoFlags.PublicAddin].join("$"),a=e._OfficeAppFactory.getOfficeAppContext();a.set_taskpaneUrl(window.location.origin),a.get_taskpaneUrl()||a.set_taskpaneUrl(window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:""));var c=t.url;t[e.ShowWindowDialogParameterKeys.UrlNoHostInfo]||(c=e.OUtil.addHostInfoAsQueryParam(c,i));var l=JSON.parse(window.name);l.hostInfo=i;var f=__assign({},a);if(f._appName===e.AppName.ExcelWebApp){if(!f._settings&&f._settingsFunc){var p=f._settingsFunc();f._settings=Object.keys(p).map((function(e){return[e,p[e]]}))}if(!f._hostSettings&&f._hostSettingsFunc){var d=f._hostSettingsFunc();f._hostSettings=Object.keys(d).map((function(e){return[e,d[e]]}))}l.appContext=f}else l.appContext=a;var h=t[e.ShowWindowDialogParameterKeys.Width]*screen.width/100,g=t[e.ShowWindowDialogParameterKeys.Height]*screen.height/100,m="width="+h+", height="+g+", left="+(a.get_clientWindowWidth()/2-h/2)+", top="+(a.get_clientWindowHeight()/2-g/2)+",channelmode=no,directories=no,fullscreen=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=no,titlebar=yes,toolbar=no";if(null==(n=window.open(c,e.OUtil.serializeObjectToString(l),m)))return e.AppTelemetry.logAppCommonMessage("Encountered cross zone issue in displayDialogAsync api."),R(),b(c,o.hostType),void s(12011);e.OUtil.shouldUseLocalStorageToPassMessage()?window.addEventListener("storage",S):window.addEventListener("message",O),u=window.setInterval((function(){try{if(null==n||n.closed){window.clearInterval(u),e.OUtil.shouldUseLocalStorageToPassMessage()?window.removeEventListener("storage",S):window.removeEventListener("message",O);var t={};t[e.Marshaling.DialogMessageReceivedEventKeys.MessageType]=12006,r(t)}}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Error happened during check or handle window close."+t)}}),1e3),null!=s?s(0):e.AppTelemetry&&e.AppTelemetry.logAppException("showDialogCallback can not be null.")}function I(e,t){var n=document.createElement("input");n.setAttribute("type","button"),n.style.cssText=e.getDialogButtonCSS(),n.style.borderColor=p,n.style.backgroundColor=d,n.setAttribute("value",t);var r=function(){A(n)},o=function(){P(n)};return n.addEventListener("mouseover",r),n.addEventListener("focus",r),n.addEventListener("mouseout",o),n.addEventListener("focusout",o),n}function A(t){null!=f?(t.style.borderColor=f.HostButtonBorderColor,t.style.backgroundColor=f.HostButtonBackgroundColor):e.OUtil.getCommonUI()?(t.style.borderColor=e.OUtil.getCommonUI().HostButtonBorderColor,t.style.backgroundColor=e.OUtil.getCommonUI().HostButtonBackgroundColor):t.style.backgroundColor="#ccc"}function P(e){e.style.borderColor=p,e.style.backgroundColor=d}function E(){y.onCalling=function(e){R(),x(e)},e.WACDelegate.unregisterEventAsync(y)}function R(){null!=i&&(document.body.removeChild(i),i=null),null!=o&&(document.body.removeChild(o),o=null)}function T(e){var t=document.createElement("div");return t.style.cssText=e.getOverlayElementCSS(),t}function w(e){var t=document.createElement("div");return t.style.cssText=e.getDialogNotificationButtonPanelCSS(),"rtl"==document.documentElement.getAttribute("dir")?t.style.cssFloat="left":t.style.cssFloat="right",t}function x(t){if(0!=t){var n=document.querySelectorAll(e._OfficeAppFactory.getInitializationHelper().getTabbableElements());e.OUtil.focusToFirstTabbable(n,!1)}}function N(e){e.setAttribute("role","dialog"),e.setAttribute("aria-describedby",m)}t.setHostThemeButtonStyle=function(t){var n=t.input;null!=n&&(f={HostButtonBorderColor:n[e.OUtil.HostThemeButtonStyleKeys.ButtonBorderColor],HostButtonBackgroundColor:n[e.OUtil.HostThemeButtonStyleKeys.ButtonBackgroundColor]}),t.completed()},t.removeEventListenersForDialog=function(t){!function(t){var n=this,r=function(){e._OfficeAppFactory.getWebAppState().focused||(e._OfficeAppFactory.getWebAppState().focused=!0),e.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.Select])},o=function(){e&&(e._OfficeAppFactory.getWebAppState().focused&&(e._OfficeAppFactory.getWebAppState().focused=!1),e.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.UnSelect]))},i=function(t){if(t.preventDefault=t.preventDefault||function(){t.returnValue=!1},117==t.keyCode&&(t.ctrlKey||t.metaKey)){t.preventDefault();var r=e.AgaveHostAction.CtrlF6Exit;t.shiftKey&&(r=e.AgaveHostAction.CtrlF6ExitShift),e.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,r])}else if(9==t.keyCode){t.preventDefault();var o=document.querySelectorAll(n._tabbableElements);e.OUtil.focusToNextTabbable(o,t.target||t.srcElement,t.shiftKey)||(n._hostInfo.isDialog?e.OUtil.focusToFirstTabbable(o,t.shiftKey):t.shiftKey?e.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.TabExitShift]):e.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.TabExit]))}else if(27==t.keyCode)t.preventDefault(),_(),e.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.EscExit]);else if(113==t.keyCode)t.preventDefault(),e.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.F2Exit]);else if((t.ctrlKey||t.metaKey||t.shiftKey||t.altKey)&&t.keyCode>=1&&t.keyCode<=255){var i={keyCode:t.keyCode,shiftKey:t.shiftKey,altKey:t.altKey,ctrlKey:t.ctrlKey,metaKey:t.metaKey};e.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n._webAppState.id,e.AgaveHostAction.KeyboardShortcuts,i])}},a=function(e){117==e.keyCode&&e.ctrlKey&&(e.preventDefault?e.preventDefault():e.returnValue=!1)};t?(e.OUtil.addEventListener(window,"focus",r),e.OUtil.addEventListener(window,"blur",o),e.OUtil.addEventListener(window,"keydown",i),e.OUtil.addEventListener(window,"keypress",a)):(e.OUtil.removeEventListener(window,"focus",r),e.OUtil.removeEventListener(window,"blur",o),e.OUtil.removeEventListener(window,"keydown",i),e.OUtil.removeEventListener(window,"keypress",a))}(!1),t.completed()},t.handleNewWindowDialog=function(t){try{if(!function(t){var n=e._OfficeAppFactory.getOfficeAppContext().get_appDomains(),r=t.url,o=e.XdmCommunicationManager.checkUrlWithAppDomains(n,r);if(!o)return e._OfficeAppFactory.getOfficeAppContext().get_docUrl()&&e.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(e._OfficeAppFactory.getOfficeAppContext().get_docUrl(),r);return o}(t))return void s(12004);if(!t[e.ShowWindowDialogParameterKeys.PromptBeforeOpen])return void C(t);c=!1;var n=!1,r=e._OfficeAppFactory.getHostInfo(),a=e.WacCommonUICssManager.getDialogCssManager(r.hostType),u=e.OUtil.formatString(Strings.OfficeOM.L_ShowWindowDialogNotification,e._OfficeAppFactory.getOfficeAppContext().get_addinName());o=T(a),document.body.insertBefore(o,document.body.firstChild),(i=function(e,t){var n=document.createElement("div");n.style.cssText=e.getDialogNotificationPanelCSS(),N(n);var r=document.createElement("div");r.style.cssText=e.getNewWindowNotificationTextPanelCSS(),r.id=m,"rtl"==document.documentElement.getAttribute("dir")?r.style.paddingRight="30px":r.style.paddingLeft="30px";var o=document.createElement("span");return o.style.cssText=e.getNewWindowNotificationTextSpanCSS(),o.innerText=t,r.appendChild(o),n.appendChild(r),n}(a,u)).id=h;var l=w(a),f=I(a,Strings.OfficeOM.L_ShowWindowDialogNotificationAllow),p=I(a,Strings.OfficeOM.L_ShowWindowDialogNotificationIgnore);function d(t){y.onCalling=function(e){R(),x(e),s(12009)},e.WACDelegate.unregisterEventAsync(y),t.preventDefault(),t.stopPropagation()}l.appendChild(f),l.appendChild(p),i.appendChild(l),document.body.insertBefore(i,document.body.firstChild),f.onclick=function(e){C(t),c||E(),e.preventDefault(),e.stopPropagation()},p.onclick=d,f.addEventListener("keydown",(function(e){e.shiftKey&&9==e.keyCode&&(P(f),A(p),p.focus(),e.preventDefault(),e.stopPropagation())}),!1),p.addEventListener("keydown",(function(e){e.shiftKey||9!=e.keyCode?13==e.keyCode&&(n=!0,e.preventDefault(),e.stopPropagation()):(P(p),A(f),f.focus(),e.preventDefault(),e.stopPropagation())}),!1),p.addEventListener("keyup",(function(e){13==e.keyCode&&n&&(n=!1,d(e))}),!1),window.focus(),y.onCalling=function(e){f.focus()},e.WACDelegate.registerEventAsync(y)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception happens at new window dialog."+t),s(5001)}},t.closeDialog=function(t){try{if(null!=n){var r=e._OfficeAppFactory.getOfficeAppContext().get_appDomains();if(r)for(var o=0;o<r.length&&-1!==r[o].indexOf("://");o++)n.postMessage(a,r[o]);null==n||n.closed||n.close(),e.OUtil.shouldUseLocalStorageToPassMessage()?window.removeEventListener("storage",S):window.removeEventListener("message",O),window.clearInterval(u),n=null,t(0)}else t(5001)}catch(n){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception happens at close window dialog."+n),t(5001)}},t.messageParent=function(t){var n=t.hostCallArgs[e.ParameterNames.MessageToParent],r=t.hostCallArgs[e.ParameterNames.TargetOrigin]||null;if(e.OUtil.shouldUseLocalStorageToPassMessage())try{var o=e._OfficeAppFactory.getId()+l;window.localStorage.setItem(o,n)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Error happened during messageParent method:"+t)}else v(window.opener,{message:n,targetOrigin:r})},t.sendMessage=function(t){if(null!=n){var r=t.hostCallArgs,o=r[e.ParameterNames.TargetOrigin]||null;delete r[e.ParameterNames.TargetOrigin],"string"!=typeof r&&(r=JSON.stringify(r)),v(n,{message:r,targetOrigin:o})}},t.postDialogMessage=v,t.registerMessageReceivedEvent=function(){window.addEventListener("message",(function(t){var n=t.origin;if(t.source==window.opener&&(!0===window.office_disable_receive_dialog_message_prompt||e.WacDialogAction.validateTaskpaneDomain(n,!0)))if("string"==typeof t.data&&t.data.indexOf(a)>-1)window.close();else{var r=t.data,o=typeof r;if(r&&("object"==o||"string"==o)){var i="string"==o?JSON.parse(r):r,s={};s[e.Marshaling.DialogMessageReceivedEventKeys.MessageContent]=i.messageContent,s[e.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin]=t.origin;var c=e.manufactureEventArgs(e.EventType.DialogParentMessageReceived,null,s);e.DialogParentMessageEventDispatch.fireEvent(c)}}}))},t.setHandlerAndShowDialogCallback=function(e,t){r=e,s=t},t.escDismissDialogNotification=_,t.showCrossZoneNotification=b,t.getWithExpiry=function(e,t){var n=e.getItem(t);if(!n)return"undefined";var r=JSON.parse(n);return r.expiry&&r.value?(new Date).getTime()>r.expiry?(e.removeItem(t),"undefined"):r.value:"undefined"},t.setWithExpiry=function(e,t,n){var r={value:n,expiry:(new Date).getTime()+864e5};e.setItem(t,JSON.stringify(r))},t.getLocalStorage=function(){return e.SafeStorage?new e.SafeStorage(window.localStorage):window.localStorage},t.getSessionStorage=function(){return e.SafeStorage?new e.SafeStorage(window.sessionStorage):window.sessionStorage},t.getUrlProtocolHostnamePort=function(e){var t=e.port?":"+e.port:"";return e.protocol+"//"+e.hostname+t},t.validateTaskpaneDomain=function(t,n){try{if(!t)return!1;n||(n=!0);var r=window.location.origin;r||(r=window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:""));var o=e.OUtil.parseUrl(r,!0),i=e.OUtil.parseUrl(t,!0);if(!(o.protocol&&o.hostname&&i.protocol&&i.hostname&&void 0!==i.port))return!1;var a=(y=i,(m=o).hostname==y.hostname&&m.protocol==y.protocol&&function(e,t){var n="80",r="443";return e.port==t.port||""==e.port&&"http:"==e.protocol&&t.port==n||""==e.port&&"https:"==e.protocol&&t.port==r||""==t.port&&"http:"==t.protocol&&e.port==n||""==t.port&&"https:"==t.protocol&&e.port==r}(m,y)),s=!1;if(n&&(s=e.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(t,r)),a||s)return!0;var c=this.getLocalStorage(),u=this.getSessionStorage(),l="_trusts_"+(i.protocol+"//"+i.hostname+(i.port?":"+i.port:"")),f=this.getWithExpiry(c,l),p=this.getWithExpiry(u,l);if("true"===f)return!0;if("false"===p)return!1;var d=this.getUrlProtocolHostnamePort(i),h=this.getUrlProtocolHostnamePort(o),g='You are about to send and receive potentially sensitive information from "'+h+'". Only click OK if you trust the following website recieving the sensitive information: "'+d+'".';return Strings.OfficeOM.L_ConfirmDialogApiTrustsParent&&(g=Strings.OfficeOM.L_ConfirmDialogApiTrustsParent.replace("{0}",h).replace("{1}",d)),window.confirm(g)?(this.setWithExpiry(c,l,"true"),this.setWithExpiry(u,l,"true"),!0):(this.setWithExpiry(c,l,"false"),this.setWithExpiry(u,l,"false"),!1)}catch(t){return e.AppTelemetry&&e.AppTelemetry.logAppException("Error happened during validateTaskpaneDomain method:"+t),!1}var m,y}}(e.WacDialogAction||(e.WacDialogAction={}))}(OSF||(OSF={})),function(e){!function(t){t.openDialog=function(t){try{t.onCalling&&t.onCalling();var n=e.SafeArrayDelegate.getOnAfterRegisterEvent(!0,t);e._OfficeAppFactory.getClientHostController().openDialog(t.dispId,void 0,t.targetId,(function(n,r){t.onEvent&&t.onEvent(r),e.AppTelemetry&&e.AppTelemetry.onEventDone(t.dispId)}),n)}catch(n){e.SafeArrayDelegate.onException(n,t)}},t.closeDialog=function(t){t.onCalling&&t.onCalling();var n=e.SafeArrayDelegate.getOnAfterRegisterEvent(!1,t);try{e._OfficeAppFactory.getClientHostController().closeDialog(t.dispId,void 0,t.targetId,n)}catch(n){e.SafeArrayDelegate.onException(n,t)}},t.messageParent=function(t){try{t.onCalling&&t.onCalling();var n=(new Date).getTime(),r=e._OfficeAppFactory.getClientHostController().messageParent(t.hostCallArgs);return t.onReceiving&&t.onReceiving(),e.AppTelemetry&&e.AppTelemetry.onMethodDone(t.dispId,t.hostCallArgs,Math.abs((new Date).getTime()-n),r),r}catch(t){return e.SafeArrayDelegate.onExceptionSyncMethod(t)}},t.sendMessage=function(t){try{t.onCalling&&t.onCalling();(new Date).getTime();var n=e._OfficeAppFactory.getClientHostController().sendMessage(t.hostCallArgs);return t.onReceiving&&t.onReceiving(),n}catch(t){return e.SafeArrayDelegate.onExceptionSyncMethod(t)}}}(e.SafeArrayDelegate||(e.SafeArrayDelegate={}))}(OSF||(OSF={})),function(e){!function(t){t.openDialog=function(n){var r="https://",o="http://",i=JSON.parse(n.targetId),a=t.getOnAfterRegisterEvent(!0,n);function s(t){var n={Error:t};try{a(0,n)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception happens at showDialogCallback."+t)}}if(e.DialogShownStatus.hasDialogShown)s(12007);else{var c=i[e.ShowWindowDialogParameterKeys.Url].toLowerCase(),u=window.location.href.toLowerCase();if(e.AppTelemetry){var l=!1,f=!1,p=!1,d=!1,h="",g="";if(e.OUtil){var m=e.OUtil.parseUrl(c),y=e.OUtil.parseUrl(u);l=m.protocol===y.protocol&&m.hostname===y.hostname&&m.port===y.port,h=e.OUtil.getHostnamePortionForLogging(m.hostname),l?g=h:(g=e.OUtil.getHostnamePortionForLogging(y.hostname),f=e.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(c,u),p=e.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(u,c));var v=e._OfficeAppFactory.getOfficeAppContext().get_appDomains();d=e.XdmCommunicationManager.checkUrlWithAppDomains(v,c)}var _="openDialog isInline: "+i[e.ShowWindowDialogParameterKeys.DisplayInIframe].toString()+", taskpaneHostname: "+g+", dialogHostName: "+h+", isSameDomain: "+l.toString()+", parentIsSubdomain: "+f.toString()+", childIsSubdomain: "+p.toString()+", isAppDomain: "+d.toString();e.AppTelemetry.logAppCommonMessage(_)}null!=c&&c.substr(0,r.length)===r?i[e.ShowWindowDialogParameterKeys.DisplayInIframe]?(e.DialogShownStatus.isWindowDialog=!1,e.WACDelegate.registerEventAsync(n)):(e.DialogShownStatus.isWindowDialog=!0,e.WacDialogAction.setHandlerAndShowDialogCallback((function(t){n.onEvent&&n.onEvent(t),e.AppTelemetry&&e.AppTelemetry.onEventDone(n.dispId)}),s),e.WacDialogAction.handleNewWindowDialog(i)):c.substr(0,o.length)===o?s(12005):s(12003)}},t.validateTaskpaneDomain=function(t,n){return e.WacDialogAction.validateTaskpaneDomain(t,n)},t.messageParent=function(t){var n=t.hostCallArgs.targetOrigin,r=!!n;if(r&&"*"!=n){var o=e.WacDialogAction.getLocalStorage(),i=e.WacDialogAction.getSessionStorage(),a="_trusts_",s=e.OUtil.parseUrl(n,!0);a+=s.protocol+"//"+s.hostname+(s.port?":"+s.port:""),e.WacDialogAction.setWithExpiry(o,a,"true"),e.WacDialogAction.setWithExpiry(i,a,"true")}if(null!=window.opener){if(!r){var c=e._OfficeAppFactory.getOfficeAppContext().get_taskpaneUrl();if(c){if(!e.WacDialogAction.validateTaskpaneDomain(c,!0)){var u="messageParent called but the taskpane domain is untrusted: "+c;throw e.AppTelemetry&&e.AppTelemetry.logAppException(u),new Error(u)}}else c=window.location.origin;t.hostCallArgs.targetOrigin=c}e.WacDialogAction.messageParent(t)}else{var l=window.location.origin;l||(l=window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:"")),r||(t.hostCallArgs.targetOrigin=l),e.WACDelegate.executeAsync(t)}},t.sendMessage=function(t){e.DialogShownStatus.hasDialogShown&&(e.DialogShownStatus.isWindowDialog?e.WacDialogAction.sendMessage(t):e.WACDelegate.executeAsync(t))},t.closeDialog=function(n){var r=t.getOnAfterRegisterEvent(!1,n);function o(t){var n={Error:t};try{r(0,n)}catch(t){e.AppTelemetry&&e.AppTelemetry.logAppException("Exception happens at closeDialogCallback."+t)}}e.DialogShownStatus.hasDialogShown?e.DialogShownStatus.isWindowDialog?(n.onCalling&&n.onCalling(),e.WacDialogAction.closeDialog(o)):e.WACDelegate.unregisterEventAsync(n):o(12006)}}(e.WACDelegate||(e.WACDelegate={}))}(OSF||(OSF={})),function(e){var t;t||(t={}),e.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){e.AsyncMethodCalls.define({method:e.AsyncMethods.AddHandlerAsync,requiredArguments:[{name:e.ParameterNames.EventType,enum:e.EventType,verify:function(e,t,n){return n.supportsEvent(e)}},{name:e.ParameterNames.Handler,types:["function"]}],supportedOptions:[],privateStateCallbacks:[]}),e.AsyncMethodCalls.define({method:e.AsyncMethods.RemoveHandlerAsync,requiredArguments:[{name:e.ParameterNames.EventType,enum:e.EventType,verify:function(e,t,n){return n.supportsEvent(e)}}],supportedOptions:[{name:e.ParameterNames.Handler,value:{types:["function","object"],defaultValue:null}}],privateStateCallbacks:[]})}})}(OSF||(OSF={}));__awaiter=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){e.done?o(e.value):new n((function(t){t(e.value)})).then(a,s)}c((r=r.apply(e,t||[])).next())}))},__generator=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}};!function(e){var t;e.NestedAppAuth||(e.NestedAppAuth={}),t=function(){function t(){this._events=[]}return t.prototype.postMessage=function(t){var n=this;!function(t,n){var r=e._OfficeAppFactory.getAsyncMethodExecutor(),o={toSafeArrayHost:function(){return[]},fromSafeArrayHost:function(e){return null},toWebHost:function(){return{requestPayload:t}},fromWebHost:function(e){return e.responsePayload}};r.executeAsync(209,o,n)}(t,(function(e){"succeeded"==e.status&&n._events.forEach((function(t){t(e.value)}))}))},t.prototype.addEventListener=function(e,t){"message"===e&&this._events.push(t)},t.prototype.removeEventListener=function(e,t){"message"===e&&(this._events=this._events.filter((function(e){return e!=t})))},t}(),e.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){},initializeFunc:function(){var n=e._OfficeAppFactory.getOfficeAppContext(),r=n.get_nestedAppAuthBridgeType();if(1===r)window.nestedAppAuthBridge=new t;else if(2===r&&!window.nestedAppAuthBridge){var o=n.get_topFrameOrigin();o&&e._OfficeAppFactory.getInitializationHelper().setCreateNaaBridge((function(){return function(t){return __awaiter(this,void 0,void 0,(function(){var n;return __generator(this,(function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),n=e.LoadScriptHelper.getHostBundleJsBasePath()+"webauth/hubsdknaabridge.min.js",[4,e.OUtil.loadScriptPromise(n,e.LoadScriptHelper.getTrustedTypesPolicy())];case 1:return r.sent()&&HubSdkNaaBridge.initializeBridge(t),[3,3];case 2:return r.sent(),[3,3];case 3:return[2]}}))}))}(o)}))}}})}(OSF||(OSF={})),function(e){!function(t){!function(t){t.getAuthContextAsync=function(t){function n(e){var t=e.userObjectId||"",n=e.tenantId||"",r=e.userPrincipalName||"";return{userObjectId:t,tenantId:n,userPrincipalName:r,authorityType:e.authorityType||"",authorityBaseUrl:e.authorityBaseUrl||"",puid:e.puid||"",loginHint:e.loginHint||r}}var r={toSafeArrayHost:function(){return[]},fromSafeArrayHost:function(e){try{return n(JSON.parse(e))}catch(e){return null}},toWebHost:function(){return{}},fromWebHost:function(e){return n(e)}};e._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(205,r,t)}}(t.Auth||(t.Auth={}))}(e.DDA||(e.DDA={}))}(OSF||(OSF={})),function(e){!function(t){t.getAuthContext=function(){return new e.Promise((function(t,n){OSF.DDA.Auth.getAuthContextAsync((function(r){r.status===e.AsyncResultStatus.Succeeded?t(r.value):n(r.error)}))}))}}(e.auth||(e.auth={}))}(Office||(Office={})),function(e){!function(t){!function(t){function n(t){var n=0;switch(t){case e.CoercionType.Text:n=0;break;case e.CoercionType.Matrix:n=1;break;case e.CoercionType.Table:n=2;break;case e.CoercionType.Html:n=3;break;case e.CoercionType.Ooxml:n=4;break;case e.CoercionType.OoxmlPackage:n=5;break;case e.CoercionType.PdfFile:n=6;break;case e.CoercionType.SlideRange:n=7;break;case"image":n=8;break;case"xmlSvg":n=9}return n}function r(t){var n=0;switch(t){case e.ValueFormat.Unformatted:n=0;break;case e.ValueFormat.Formatted:n=1}return n}function o(t){var n=0;switch(t){case e.FilterType.All:n=0;break;case e.FilterType.OnlyVisible:n=1}return n}t.setSelectedDataAsync=function(t,r,o){var i=null==r.coercionType?OSF.DataCoercion.determineCoercionType(t):r.coercionType;"function"==typeof r&&(o=r);var a={toSafeArrayHost:function(){var o=OSF._OfficeAppFactory.getHostInfo();return o.hostType.toLowerCase()==e.HostType.Word.toLowerCase()||o.hostType.toLowerCase()==e.HostType.PowerPoint.toLowerCase()||o.hostType.toLowerCase()==e.HostType.OneNote.toLowerCase()||o.hostType.toLowerCase()==e.HostType.Visio.toLowerCase()||"image"==i||"xmlSvg"==i?[n(i),OSF.DataCoercion.serializeDynamicData(t),null!=r.imageLeft&&r.imageLeft,null!=r.imageTop&&r.imageTop,null!=r.imageWidth&&r.imageWidth,null!=r.imageHeight&&r.imageHeight]:o.hostType.toLowerCase()==e.HostType.Excel.toLowerCase()?[n(i),OSF.DataCoercion.serializeDynamicData(t),null==r.cellFormat?[]:r.cellFormat,null==r.tableOptions?[]:r.tableOptions,null!=r.imageWidth&&r.imageWidth,null!=r.imageHeight&&r.imageHeight]:[n(i),OSF.DataCoercion.serializeDynamicData(t),null==r.cellFormat?[]:r.cellFormat,null==r.tableOptions?[]:r.tableOptions]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{DdaSetBindingData:{CoerceType:i,Data:OSF.DataCoercion.serializeDynamicData(t),CellFormat:[],TableOptions:[]}}},fromWebHost:function(e){return e}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(65,a,o,null)},t.getSelectedDataAsync=function(t,i,a){var s,c=e.ValueFormat.Unformatted,u=e.FilterType.All;"function"==typeof i?a=i:void 0!==i&&(void 0!==i.valueFormat&&(c=i.valueFormat),void 0!==i.filterType&&(u=i.filterType),void 0!==i.asyncContext&&(s=i.asyncContext));var l={toSafeArrayHost:function(){return[n(t),r(c),o(u)]},fromSafeArrayHost:function(e){return OSF.DataCoercion.deserializeDynamicData(e,t)},toWebHost:function(){return{DdaGetBindingData:{CoerceType:t,ValueFormat:c,FilterType:u}}},fromWebHost:function(e){return OSF.DataCoercion.deserializeDynamicData(e.Data,t)}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(64,l,a,s)}}(t.document||(t.document={}))}(e.context||(e.context={}))}(Office||(Office={})),function(e){var t=function(){function e(e,t){this._rows=e,this._header=t}return Object.defineProperty(e.prototype,"headers",{get:function(){return this._header},set:function(e){this._header=this.fixData(e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"rows",{get:function(){return this._rows},set:function(e){this._rows=null==e||OSF.OUtil.isArray(e)&&0==e.length?[]:this.fixData(e)},enumerable:!0,configurable:!0}),e.prototype.fixData=function(e){if(null==e||null==e)return null;try{for(var t=OSF.DataCoercion.findArrayDimensionality(e);t<2;t++)e=[e];return e}catch(e){}},e}();e.TableData=t,e.manufactureTableData=function(t){return new e.TableData(t[OSF.TableDataProperties.TableRows],t[OSF.TableDataProperties.TableHeaders])}}(Office||(Office={})),function(e){!function(t){!function(t){!function(e){e.OfficeThemeChangedEvent="OfficeThemeChangedEvent",e.DocumentThemeChangedEvent="DocumentThemeChangedEvent"}(t.EventDescriptors||(t.EventDescriptors={})),e.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){e.AsyncMethodCalls.define({method:e.AsyncMethods.GetDocumentThemeAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[],onSucceeded:e.DDA.Theming.ConvertToDocumentTheme}),e.AsyncMethodCalls.define({method:e.AsyncMethods.GetOfficeThemeAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[],onSucceeded:e.DDA.Theming.ConvertToOfficeTheme})},defineSafeArrayParameterMapFunc:function(){e.HostParameterMap.define({type:85,fromHost:[{name:e.ParameterNames.OfficeTheme,value:e.HostParameterMap.self}]}),e.HostParameterMap.define({type:e.ParameterNames.OfficeTheme,fromHost:[{name:e.DDA.Theming.OfficeThemeEnum.BodyForegroundColor,value:0},{name:e.DDA.Theming.OfficeThemeEnum.BodyBackgroundColor,value:1},{name:e.DDA.Theming.OfficeThemeEnum.ControlForegroundColor,value:2},{name:e.DDA.Theming.OfficeThemeEnum.ControlBackgroundColor,value:3},{name:e.DDA.Theming.OfficeThemeEnum.ThemeId,value:4},{name:e.DDA.Theming.OfficeThemeEnum.IsDarkTheme,value:5},{name:e.DDA.Theming.OfficeThemeEnum.FluentThemeData,value:6}],isComplexType:!0}),e.HostParameterMap.define({type:e.EventDispId.dispidOfficeThemeChangedEvent,fromHost:[{name:e.DDA.Theming.EventDescriptors.OfficeThemeChangedEvent,value:e.HostParameterMap.self}],isComplexType:!0}),e.HostParameterMap.define({type:e.DDA.Theming.EventDescriptors.OfficeThemeChangedEvent,fromHost:[{name:e.ParameterNames.OfficeTheme,value:e.HostParameterMap.self}],isComplexType:!0})},defineWebParameterMapFunc:function(){e.HostParameterMap.addComplexType(e.ParameterNames.DocumentTheme),e.HostParameterMap.addComplexType(e.ParameterNames.OfficeTheme),e.HostParameterMap.define({type:e.EventDispId.dispidOfficeThemeChangedEvent,fromHost:[{name:e.ParameterNames.OfficeTheme,value:e.HostParameterMap.self}]}),e.HostParameterMap.define({type:e.ParameterNames.OfficeTheme,fromHost:[{name:e.DDA.Theming.OfficeThemeEnum.BodyForegroundColor,value:e.DDA.Theming.OfficeThemeEnumWac.PrimaryFontColor},{name:e.DDA.Theming.OfficeThemeEnum.BodyBackgroundColor,value:e.DDA.Theming.OfficeThemeEnumWac.PrimaryBackgroundColor},{name:e.DDA.Theming.OfficeThemeEnum.ControlForegroundColor,value:e.DDA.Theming.OfficeThemeEnumWac.SecondaryFontColor},{name:e.DDA.Theming.OfficeThemeEnum.ControlBackgroundColor,value:e.DDA.Theming.OfficeThemeEnumWac.SecondaryBackgroundColor}],isComplexType:!0})},initializeFunc:function(){var n=e._OfficeAppFactory.getHostInfo(),r=n.hostType.toLowerCase();if(n.hostPlatform==e.HostInfoPlatform.web&&(r==Office.HostType.Word.toLowerCase()||r==Office.HostType.PowerPoint.toLowerCase())&&Office.context.officeTheme){var o=t.GetIsDarkThemeFromCSSHexColor(Office.context.officeTheme.bodyBackgroundColor);Office.context.officeTheme[e.DDA.Theming.OfficeThemeEnum.IsDarkTheme]=o,Office.context.officeTheme[e.DDA.Theming.OfficeThemeEnum.ThemeId]=o?e.DDA.Theming.ThemeId.Black:e.DDA.Theming.ThemeId.White}Office.context&&Office.context.themeManager&&Office.context.themeManager.InitializeAndChangeOnce()}});var n=function(){function n(){this._eventTarget=null,this._previousDocumentThemeData=null,this._previousOfficeThemeData=null,this._officeCss=null,this._asyncCallsCompleted=null,this._onAsyncCallsCompleted=null}return n.prototype.InitializeThemeManager=function(){this._eventTarget=this,e.DispIdHost.addAsyncMethods(this,[e.AsyncMethods.GetOfficeThemeAsync,e.AsyncMethods.GetDocumentThemeAsync]),e.DispIdHost.addEventSupport(this,new e.EventDispatch([Microsoft.Office.WebExtension.EventType.OfficeThemeChanged,Microsoft.Office.WebExtension.EventType.DocumentThemeChanged]))},n.prototype.InitializeAndChangeOnce=function(t){var n=this;this._officeCss=this._getOfficeThemesCss(),this._officeCss?(this._onAsyncCallsCompleted=t,this._asyncCallsCompleted={},this._asyncCallsCompleted[e.AsyncMethods.GetOfficeThemeAsync]=!1,this._asyncCallsCompleted[e.AsyncMethods.GetDocumentThemeAsync]=!1,this._getAndProcessThemeData(this._eventTarget.getOfficeThemeAsync,(function(e){n._processOfficeThemeData(e)}),e.AsyncMethods.GetOfficeThemeAsync)):t&&t()},n.prototype.isDarkTheme=function(){var e=!1;if(Office.context&&Office.context.officeTheme&&Office.context.officeTheme.bodyBackgroundColor){var n=Office.context.officeTheme.bodyBackgroundColor;e=t.GetIsDarkThemeFromCSSHexColor(n)}return e},n.prototype._getOfficeThemesCss=function(){try{return function(){for(var t="officethemes.css",n=0;n<document.styleSheets.length;n++){var r=document.styleSheets[n];if(!r.disabled&&r.href&&t==r.href.substring(r.href.length-t.length,r.href.length).toLowerCase())return r.cssRules||r.rules?r:(e.AppTelemetry&&e.AppTelemetry.logAppException("Browser styleSheet object does not implement cssRules or rules property. Viloates browser's css access rule"),null)}}()}catch(t){return e.AppTelemetry&&e.AppTelemetry.logAppException("Exception thrown when trying to read officethems.css:["+t+"]"),null}},n.prototype._changeCss=function(e,t,n){for(var r=e.cssRules?e.cssRules.length:e.rules.length,o=0;o<r;o++){var i=(e.cssRules?e.cssRules[o]:e.rules[o]).selectorText;i&&i.toLowerCase()==t.toLowerCase()&&(e.cssRules?(e.deleteRule(o),e.insertRule(i+n,o)):(e.removeRule(o),e.addRule(i,n,o)))}},n.prototype._changeDocumentThemeData=function(t){for(var n=[{name:e.DDA.Theming.DocumentThemeEnum.PrimaryFontColor,cssSelector:".office-docTheme-primary-fontColor",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.PrimaryBackgroundColor,cssSelector:".office-docTheme-primary-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.DocumentThemeEnum.SecondaryFontColor,cssSelector:".office-docTheme-secondary-fontColor",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.SecondaryBackgroundColor,cssSelector:".office-docTheme-secondary-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent1,cssSelector:".office-contentAccent1-color",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent2,cssSelector:".office-contentAccent2-color",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent3,cssSelector:".office-contentAccent3-color",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent4,cssSelector:".office-contentAccent4-color",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent5,cssSelector:".office-contentAccent5-color",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent6,cssSelector:".office-contentAccent6-color",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent1,cssSelector:".office-contentAccent1-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent2,cssSelector:".office-contentAccent2-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent3,cssSelector:".office-contentAccent3-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent4,cssSelector:".office-contentAccent4-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent5,cssSelector:".office-contentAccent5-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent6,cssSelector:".office-contentAccent6-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent1,cssSelector:".office-contentAccent1-borderColor",cssProperty:"border-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent2,cssSelector:".office-contentAccent2-borderColor",cssProperty:"border-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent3,cssSelector:".office-contentAccent3-borderColor",cssProperty:"border-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent4,cssSelector:".office-contentAccent4-borderColor",cssProperty:"border-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent5,cssSelector:".office-contentAccent5-borderColor",cssProperty:"border-color"},{name:e.DDA.Theming.DocumentThemeEnum.Accent6,cssSelector:".office-contentAccent6-borderColor",cssProperty:"border-color"},{name:e.DDA.Theming.DocumentThemeEnum.Hyperlink,cssSelector:".office-a",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.FollowedHyperlink,cssSelector:".office-a:visited",cssProperty:"color"},{name:e.DDA.Theming.DocumentThemeEnum.HeaderLatinFont,cssSelector:".office-headerFont-latin",cssProperty:"font-family"},{name:e.DDA.Theming.DocumentThemeEnum.HeaderEastAsianFont,cssSelector:".office-headerFont-eastAsian",cssProperty:"font-family"},{name:e.DDA.Theming.DocumentThemeEnum.HeaderScriptFont,cssSelector:".office-headerFont-script",cssProperty:"font-family"},{name:e.DDA.Theming.DocumentThemeEnum.HeaderLocalizedFont,cssSelector:".office-headerFont-localized",cssProperty:"font-family"},{name:e.DDA.Theming.DocumentThemeEnum.BodyLatinFont,cssSelector:".office-bodyFont-latin",cssProperty:"font-family"},{name:e.DDA.Theming.DocumentThemeEnum.BodyEastAsianFont,cssSelector:".office-bodyFont-eastAsian",cssProperty:"font-family"},{name:e.DDA.Theming.DocumentThemeEnum.BodyScriptFont,cssSelector:".office-bodyFont-script",cssProperty:"font-family"},{name:e.DDA.Theming.DocumentThemeEnum.BodyLocalizedFont,cssSelector:".office-bodyFont-localized",cssProperty:"font-family"}],r=t.type==e.EventType.DocumentThemeChanged?t.documentTheme:t,o=0;o<n.length;o++)if(null===this._previousDocumentThemeData||this._previousDocumentThemeData[n[o].name]!=r[n[o].name])if(null!=r[n[o].name]&&""!=r[n[o].name]){var i=r[n[o].name];"font-family"===n[o].cssProperty&&(i='"'+i.replace(new RegExp('"',"g"),'\\"')+'"'),this._changeCss(this._officeCss,n[o].cssSelector,"{"+n[o].cssProperty+":"+i+";}")}else this._changeCss(this._officeCss,n[o].cssSelector,"{}");this._previousDocumentThemeData=r},n.prototype._changeOfficeThemeData=function(t){for(var n=[{name:e.DDA.Theming.OfficeThemeEnum.BodyForegroundColor,cssSelector:".office-officeTheme-primary-fontColor",cssProperty:"color"},{name:e.DDA.Theming.OfficeThemeEnum.BodyBackgroundColor,cssSelector:".office-officeTheme-primary-bgColor",cssProperty:"background-color"},{name:e.DDA.Theming.OfficeThemeEnum.ControlForegroundColor,cssSelector:".office-officeTheme-secondary-fontColor",cssProperty:"color"},{name:e.DDA.Theming.OfficeThemeEnum.ControlBackgroundColor,cssSelector:".office-officeTheme-secondary-bgColor",cssProperty:"background-color"}],r=t.type==e.EventType.OfficeThemeChanged?t.officeTheme:t,o=0;o<n.length;o++)null!==this._previousOfficeThemeData&&this._previousOfficeThemeData[n[o].name]==r[n[o].name]||void 0!==r[n[o].name]&&this._changeCss(this._officeCss,n[o].cssSelector,"{"+n[o].cssProperty+":"+r[n[o].name]+";}");this._previousOfficeThemeData=r},n.prototype._getAndProcessThemeData=function(t,n,r){var o=this,i=e._OfficeAppFactory.getHostInfo();if(i&&i.hostPlatform==e.HostInfoPlatform.web){if(r==e.AsyncMethods.GetOfficeThemeAsync&&Office.context.officeTheme){var a={};a[e.DDA.Theming.OfficeThemeEnum.BodyBackgroundColor]=Office.context.officeTheme.bodyBackgroundColor,a[e.DDA.Theming.OfficeThemeEnum.BodyForegroundColor]=Office.context.officeTheme.bodyForegroundColor,a[e.DDA.Theming.OfficeThemeEnum.ControlBackgroundColor]=Office.context.officeTheme.controlBackgroundColor,a[e.DDA.Theming.OfficeThemeEnum.ControlForegroundColor]=Office.context.officeTheme.controlForegroundColor,a[e.DDA.Theming.OfficeThemeEnum.IsDarkTheme]=Office.context.officeTheme.isDarkTheme,a[e.DDA.Theming.OfficeThemeEnum.ThemeId]=Office.context.officeTheme.isDarkTheme?e.DDA.Theming.ThemeId.Black:e.DDA.Theming.ThemeId.White,a[e.DDA.Theming.OfficeThemeEnum.FluentThemeData]=Office.context.officeTheme.fluentThemeData,n(a)}}else t((function(e){if("succeeded"==e.status){var t=e.value;n(t)}o._areAllCallsCompleted(r)&&o._onAsyncCallsCompleted&&(o._onAsyncCallsCompleted(),o._onAsyncCallsCompleted=null)}))},n.prototype._processOfficeThemeData=function(e){var t=this;this._changeOfficeThemeData(e),this._eventTarget.addHandlerAsync(Microsoft.Office.WebExtension.EventType.OfficeThemeChanged,(function(e){t._changeOfficeThemeData(e)}),null)},n.prototype._processDocumentThemeData=function(e){var t=this;this._changeDocumentThemeData(e),this._eventTarget.addHandlerAsync(Microsoft.Office.WebExtension.EventType.DocumentThemeChanged,(function(e){t._changeDocumentThemeData(e)}),null)},n.prototype._areAllCallsCompleted=function(e){var t;if(!(t=this._asyncCallsCompleted))return!0;for(var n in e&&t.hasOwnProperty(e)&&(t[e]=!0),t)if(!t.hasOwnProperty(n)||!t[n])return!1;return!0},n}();t.InternalThemeHandler=n}(t.Theming||(t.Theming={}))}(e.DDA||(e.DDA={}))}(OSF||(OSF={})),function(e){!function(e){var t;OSF.definePropertyOnNamespace(e,"themeManager",(function(){return t||(t=new OSF.DDA.Theming.InternalThemeHandler).InitializeThemeManager(),t}))}(e.context||(e.context={}))}(Office||(Office={})),function(e){e.BootStrapExtension.prepareApiSurface=function(){return new Promise((function(){e.V10ApiFeatureRegistry.initialize()}))}}(OSF||(OSF={})),function(e){!function(e){function t(){try{if(void 0!==OSF&&void 0!==OSF.isOfficeReactNative&&OSF.isOfficeReactNative())return!0}catch(e){}return!1}function n(){var e="web";try{void 0!==OSF&&void 0!==OSF._OfficeAppFactory&&void 0!==OSF._OfficeAppFactory.getHostInfo&&(e=OSF._OfficeAppFactory.getHostInfo().hostPlatform)}catch(e){}return e}e.isNativeStorage=function(){var e=n();return!(function(){try{if(void 0!==OSF&&void 0!==OSF._OfficeAppFactory&&void 0!==OSF._OfficeAppFactory.getHostInfo&&OSF._OfficeAppFactory.getHostInfo().flags&OSF.HostInfoFlags.SharedApp)return!0}catch(e){}return!1}()||!(t()||"win32"===e||"mac"===e&&window._useSDXSandbox))},e.isNativeApiInfomation=function(){var e=n();return!!(t()||"win32"===e||"mac"===e&&window._useSDXSandbox)},e.isNativeDialog=function(){var e=n();return!(!t()&&"win32"!==e)}}(e.ApiHelper||(e.ApiHelper={}))}(OfficeRuntime||(OfficeRuntime={})),function(e){e.ApiHelper.isNativeApiInfomation()?e.apiInformation=t:e.apiInformation=n;var t={isSetSupported:function(e,t){if("string"!=typeof e)return!1;if(null==t&&(t="0.0.0"),void 0===global.__apiSets)return!1;var n=global.__apiSets,o=Object.keys(n).map((function(e){return e.toLowerCase()})).indexOf(e.toLowerCase());if(o>-1){var i=n[Object.keys(n)[o]];try{var a=r(t),s=void 0;if((s=Array.isArray(i)?function(e,t){for(var n=0;n<e.length;n++){var o=r(e[n]);if(o.major==t)return o}return{major:0,minor:0,patch:0}}(i,a.major):r(i)).major>0){if(s.major>a.major)return!0;if(s.major==a.major&&s.minor>a.minor)return!0;if(s.major==a.major&&s.minor==a.minor&&s.patch>=a.patch)return!0}}catch(e){return!1}}return!1}},n={isSetSupported:function(e,t){try{return!!(Office&&Office.context&&Office.context.requirements)&&Office.context.requirements.isSetSupported(e,Number(t))}catch(e){return!1}}};function r(e){var t=e.split("."),n=0,r=0,o=0;if(t.length<2&&isNaN(Number(e)))throw"version format incorrect";if(n=Number(t[0]),t.length>=2&&(r=Number(t[1])),t.length>=3&&(o=Number(t[2])),isNaN(n)||isNaN(r)||isNaN(o))throw"version format incorrect";return{major:n,minor:r,patch:o}}}(OfficeRuntime||(OfficeRuntime={}));var OfficeRuntime;__extends=this&&this.__extends||function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();!function(e){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject;var t=OfficeExtension.BatchApiHelper.createTopLevelServiceObject,n=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),r=(OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),o=(OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported,OfficeExtension.Utility.load,OfficeExtension.Utility.retrieve,OfficeExtension.Utility.toJson),i=OfficeExtension.Utility.fixObjectPathIfNecessary,a=(OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult),s=(OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags,function(e){this._dialogService=e});e.Dialog=s;var c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.close=function(){return this._dialogService.close(),OfficeExtension.CoreUtility.Promise.resolve()},t}(s),u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t.prototype.close=function(){return this._dialogService.close(),this._dialogService.context.sync()},t}(s);function l(e){return/^(\-|\+)?([0-9]+)%?$/.test(e)}function f(e){var t,n=((t={})[12002]={code:"InvalidUrl",message:"Cannot load URL, no such page or bad URL syntax."},t[12003]={code:"InvalidUrl",message:"HTTPS is required."},t[12004]={code:"Untrusted",message:"Domain is not trusted."},t[12005]={code:"InvalidUrl",message:"HTTPS is required."},t[12007]={code:"FailedToOpen",message:"Another dialog is already opened."},t);return n[e]?n[e]:{code:"Unknown",message:"An unknown error has occured with code: "+e}}e.displayWebDialog=function(t,n){return void 0===n&&(n={}),new OfficeExtension.CoreUtility.Promise((function(r,o){if(n.width&&n.height&&(!l(n.width)||!l(n.height)))throw new OfficeExtension.Error({code:"InvalidArgument",message:'Dimensions must be "number%" or number.'});var i={width:n.width?parseInt(n.width):50,height:n.height?parseInt(n.height):50,displayInIFrame:n.displayInIFrame};e.ApiHelper.isNativeDialog()?function(e,t,n,r,o){void 0===o&&(o={});var i=new OfficeExtension.ClientRequestContext,a=d.newObject(i),s=new u(a),c=a.onDialogMessage.add((function(e){switch(OfficeExtension.Utility.log("dialogMessageHandler:"+JSON.stringify(e)),e.type){case 17:e.error?n(e.error):t(s);break;case 12:o.onMessage&&o.onMessage(e.message,s);break;case 10:default:12006===e.originalErrorCode?(c&&(c.remove(),i.sync()),o.onClose&&o.onClose()):o.onRuntimeError&&(o.onRuntimeError(e.error,s),n(e.error))}return OfficeExtension.CoreUtility.Promise.resolve()}));i.sync().then((function(){return a.displayDialog(r,e),i.sync()})).catch((function(e){n(e)}))}(i,r,o,t,n):function(e,t,n,r,o){void 0===o&&(o={});var i;function a(e){"failed"===e.status?n(new OfficeExtension.Error(f(e.error.code))):((i=e.value).addEventHandler(Office.EventType.DialogMessageReceived,s),i.addEventHandler(Office.EventType.DialogEventReceived,u),t(new c(i)))}function s(e){o.onMessage&&o.onMessage(e.message,i,e.origin)}function u(e){12006===e.error?o.onClose&&o.onClose():o.onRuntimeError&&o.onRuntimeError(new OfficeExtension.Error(f(e.error)),i)}Office.context.ui.displayDialogAsync(r,e,a)}(i,r,o,t,n)}))};var p,d=function(s){function c(){return null!==s&&s.apply(this,arguments)||this}return __extends(c,s),Object.defineProperty(c.prototype,"_className",{get:function(){return"DialogService"},enumerable:!0,configurable:!0}),c.prototype.close=function(){n(this,"Close",1,[],4,0)},c.prototype.displayDialog=function(e,t){n(this,"DisplayDialog",1,[e,t],4,0)},c.prototype._handleResult=function(e){(s.prototype._handleResult.call(this,e),r(e))||i(this,e)},c.prototype._handleRetrieveResult=function(e,t){s.prototype._handleRetrieveResult.call(this,e,t),a(this,e,t)},c.newObject=function(n){return t(e.DialogService,n,"Microsoft.Dialog.DialogService",!1,4)},Object.defineProperty(c.prototype,"onDialogMessage",{get:function(){return this.m_dialogMessage||(this.m_dialogMessage=new OfficeExtension.GenericEventHandlers(this.context,this,"DialogMessage",{eventType:65536,registerFunc:function(){},unregisterFunc:function(){},getTargetIdFunc:function(){return null},eventArgsTransformFunc:function(e){var t;try{var n=JSON.parse(e.message),r=n.errorCode?new OfficeExtension.Error(f(n.errorCode)):null;t={originalErrorCode:n.errorCode,type:n.type,error:r,message:n.message,origin:n.origin}}catch(e){t={originalErrorCode:null,type:17,error:new OfficeExtension.Error({code:"GenericException",message:"Unknown error"}),message:e.message}}return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_dialogMessage},enumerable:!0,configurable:!0}),c.prototype.toJSON=function(){return o(this,{},{})},c}(OfficeExtension.ClientObject);e.DialogService=d,function(e){e[e.dialogMessageReceived=0]="dialogMessageReceived",e[e.dialogEventReceived=1]="dialogEventReceived"}(p||(p={})),function(e){e.generalException="GeneralException"}(e.DialogErrorCodes||(e.DialogErrorCodes={}))}(OfficeRuntime||(OfficeRuntime={})),function(e){!function(e){function t(e,t){try{var n=Microsoft.Office.WebExtension.FeatureGates[e];return null==n?t:"true"===n.toString().toLowerCase()}catch(e){return t}}function n(e,t){try{var n=Microsoft.Office.WebExtension.FeatureGates,r=parseInt(n[e]);return isNaN(r)?t:r}catch(e){return t}}function r(e,t){try{var n=Microsoft.Office.WebExtension.FeatureGates[e];return null==n?t:n}catch(e){return t}}e.getBooleanFeatureGate=t,e.getIntFeatureGate=n,e.getStringFeatureGate=r,e.getBooleanFeatureGateAsync=function(e,n){return Promise.resolve(t(e,n))},e.getIntFeatureGateAsync=function(e,t){return Promise.resolve(n(e,t))},e.getStringFeatureGateAsync=function(e,t){return Promise.resolve(r(e,t))}}(e.experimentation||(e.experimentation={}))}(OfficeRuntime||(OfficeRuntime={})),function(e){!function(e){var n={};function r(e){var t=e.eventName,r=e.message;n.hasOwnProperty(t)&&n[t].call(r)}e.on=function(e,o){return function(e,o){n.hasOwnProperty(e)||(n[e]=new t,function(){Office&&Office.context&&Office.context.messaging&&!Office.context.messaging.onMessage&&(Office.context.messaging.onMessage=r.bind(this))}());n[e].add(o)}(e,o),new Promise((function(e){e()}))},e.off=function(e,t){return function(e,t){n.hasOwnProperty(e)&&(t?n[e].remove(t):delete n[e])}(e,t),new Promise((function(e){e()}))},e.emit=function(e,t){return function(e,t){var n={eventName:e,message:t};Office&&Office.context&&Office.context.messaging&&Office.context.messaging.sendMessage&&Office.context.messaging.sendMessage(n)}(e,t),new Promise((function(e){e()}))}}(e.message||(e.message={}));var t=function(){function e(){this.listeners=[]}return e.prototype.add=function(e){this.listeners.push(e)},e.prototype.remove=function(e){var t=this.listeners.lastIndexOf(e);-1!==t&&this.listeners.splice(t,1)},e.prototype.call=function(e){this.listeners.forEach((function(t){return t(e)}))},e}();e.ListenerManager=t}(OfficeRuntime||(OfficeRuntime={})),function(e){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject;var t=OfficeExtension.BatchApiHelper.createTopLevelServiceObject,n=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),r=(OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),o=(OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported,OfficeExtension.Utility.load,OfficeExtension.Utility.retrieve,OfficeExtension.Utility.toJson),i=OfficeExtension.Utility.fixObjectPathIfNecessary,a=(OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult),s=(OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags,"_Office_AsyncStorage_"),c=s+"|_unusedKey_",u={getItem:function(e){return d((function(t,n){return t.multiGet(n,JSON.stringify([e]))}),(function(e){var t=JSON.parse(e);return t&&t[0]&&t[0][1]?t[0][1]:null}))},setItem:function(e,t){return d((function(n,r){return n.multiSet(r,JSON.stringify([[e,t]]))}),(function(){return null}))},removeItem:function(e){return d((function(t,n){return t.multiRemove(n,JSON.stringify([e]))}),(function(){return null}))},getItems:function(e){return d((function(t,n){return t.multiGet(n,JSON.stringify(e))}),(function(t){var n=JSON.parse(t),r={};return n&&n.forEach((function(e){var t=e[0],n=e[1];return r[t]=n,n})),e&&e.forEach((function(e){r[e]&&r[e]})),r}))},setItems:function(e){var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push([n,e[n]]);return d((function(e,n){return e.multiSet(n,JSON.stringify(t))}),(function(){return null}))},removeItems:function(e){return d((function(t,n){return t.multiRemove(n,JSON.stringify(e))}),(function(){return null}))},getKeys:function(){return d((function(e,t){return e.getAllKeys(t)}),(function(e){return JSON.parse(e)}))}},l={getItem:function(e){return m((function(){return f(e)}))},setItem:function(e,t){return g((function(){return p(e,t)}))},removeItem:function(e){return g((function(){return window.localStorage.removeItem(s+e)}))},getItems:function(e){return new Promise((function(t,n){var r={},o=[];try{h()}catch(e){n(e)}e.forEach((function(e){try{var t=f(e);r[e]=t||null}catch(e){o.push(e)}})),o.length>0?n(new Error("Unknown error.")):t(r)}))},setItems:function(e){return y(e,(function(t){return p(t,e[t])}))},removeItems:function(e){return y(e,(function(e){return window.localStorage.removeItem(s+e)}))},getKeys:function(){return m((function(){return Object.keys(window.localStorage).filter((function(e){return 0===e.indexOf(s)})).map((function(e){return e.substr(s.length)}))}))}};function f(e){return window.localStorage.getItem(s+e)}function p(e,t){window.localStorage.setItem(s+e,t)}function d(e,t){return new OfficeExtension.CoreUtility.Promise((function(n,r){var o=v.getInstance(),i=o.setCallBack((function(e,o){if(o)r(o);else{var i=t(e);n(i)}}));o.ctx.sync().then((function(){var t=o.getPersistentKvStorageService();return e(t,i),o.ctx.sync()})).catch((function(e){r(e)}))}))}function h(){p(c,null),window.localStorage.removeItem(c)}function g(e,t){return void 0===t&&(t=function(){}),new Promise((function(n,r){try{h(),e(),t(null),n()}catch(e){t(e),r(e)}}))}function m(e,t){return void 0===t&&(t=function(){}),new Promise((function(n,r){try{h();var o=e();t(null,o),n(o)}catch(e){t(e,null),r(e)}}))}function y(e,t,n){return void 0===n&&(n=function(){}),new Promise((function(r,o){var i=[];try{h()}catch(e){i.push(e)}for(var a in e)if(e.hasOwnProperty(a)||Array.isArray(e))try{Array.isArray(e)?t(e[a]):t(a)}catch(e){i.push(e)}n(i),i.length>0?o(i):r()}))}e.ApiHelper.isNativeStorage()?e.storage=u:e.storage=l;var v=function(){function e(){var e=this;this._invokeId=0,this._callDict={},this.ctx=new OfficeExtension.ClientRequestContext,this._perkvstorService=_.newObject(this.ctx),this._eventResult=this._perkvstorService.onPersistentStorageMessage.add((function(t){OfficeExtension.Utility.log("persistentKvStoragegMessageHandler:"+JSON.stringify(t));var n=e._callDict[t.invokeId];n&&(n(t.message,t.error),delete e._callDict[t.invokeId])}))}return e.getInstance=function(){return void 0===e.instance?e.instance=new e:e.instance._perkvstorService=_.newObject(e.instance.ctx),e.instance},e.prototype.getPersistentKvStorageService=function(){return this._perkvstorService},e.prototype.getCallBack=function(e){return this._callDict[e]},e.prototype.setCallBack=function(e){var t=this._invokeId;return this._callDict[this._invokeId++]=e,t},e}(),_=function(s){function c(){return null!==s&&s.apply(this,arguments)||this}return __extends(c,s),Object.defineProperty(c.prototype,"_className",{get:function(){return"PersistentKvStorageService"},enumerable:!0,configurable:!0}),c.prototype.clear=function(e){n(this,"Clear",1,[e],4,0)},c.prototype.getAllKeys=function(e){n(this,"GetAllKeys",1,[e],4,0)},c.prototype.multiGet=function(e,t){n(this,"MultiGet",1,[e,t],4,0)},c.prototype.multiRemove=function(e,t){n(this,"MultiRemove",1,[e,t],4,0)},c.prototype.multiSet=function(e,t){n(this,"MultiSet",1,[e,t],4,0)},c.prototype._handleResult=function(e){(s.prototype._handleResult.call(this,e),r(e))||i(this,e)},c.prototype._handleRetrieveResult=function(e,t){s.prototype._handleRetrieveResult.call(this,e,t),a(this,e,t)},c.newObject=function(n){return t(e.PersistentKvStorageService,n,"Microsoft.PersistentKvStorage.PersistentKvStorageService",!1,4)},Object.defineProperty(c.prototype,"onPersistentStorageMessage",{get:function(){return this.m_persistentStorageMessage||(this.m_persistentStorageMessage=new OfficeExtension.GenericEventHandlers(this.context,this,"PersistentStorageMessage",{eventType:65537,registerFunc:function(){},unregisterFunc:function(){},getTargetIdFunc:function(){return null},eventArgsTransformFunc:function(e){var t,n,r,o;try{var i=JSON.parse(e.message),a=parseInt(i.errorCode),s=0!=a?new OfficeExtension.Error((n=a,(r={})[16389]={code:"GenericException",message:"Unknown error."},r[65535]={code:"Unexcepted",message:"Catastrophic failure."},r[14]={code:"OutOfMemory",message:"Ran out of memory."},r[87]={code:"InvalidArg",message:"One or more arguments are invalid."},r[16385]={code:"NotImplemented",message:"Not implemented."},r[6]={code:"BadHandle",message:"File Handle is not Set."},r[5]={code:"AccessDenied",message:"Can't read the Storage File."},(o=r)[n]?o[n]:{code:"Unknown",message:"An unknown error has occured"})):null;t={invokeId:i.invokeId,message:i.message,error:s}}catch(e){t={invokeId:-1,message:e.message,error:new OfficeExtension.Error({code:"GenericException",message:"Unknown error"})}}return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_persistentStorageMessage},enumerable:!0,configurable:!0}),c.prototype.toJSON=function(){return o(this,{},{})},c}(OfficeExtension.ClientObject);e.PersistentKvStorageService=_,function(e){e.generalException="GeneralException"}(e.ErrorCodes||(e.ErrorCodes={}))}(OfficeRuntime||(OfficeRuntime={}));var OfficeFirstPartyDialog,OfficeFirstPartyAuth,OfficeCore,Office,OfficeFirstParty;__extends=this&&this.__extends||function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),__awaiter=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){e.done?o(e.value):new n((function(t){t(e.value)})).then(a,s)}c((r=r.apply(e,t||[])).next())}))},__generator=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},__assign=this&&this.__assign||function(){return(__assign=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};!function(e){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject;var t=OfficeExtension.BatchApiHelper.createTopLevelServiceObject,n=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),r=(OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),o=(OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported,OfficeExtension.Utility.load,OfficeExtension.Utility.retrieve,OfficeExtension.Utility.toJson),i=OfficeExtension.Utility.fixObjectPathIfNecessary,a=(OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult),s=(OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags),c=function(c){function u(){return null!==c&&c.apply(this,arguments)||this}return __extends(u,c),Object.defineProperty(u.prototype,"_className",{get:function(){return"BiShim"},enumerable:!0,configurable:!0}),u.prototype.initialize=function(e){n(this,"Initialize",0,[e],s(2,"SharedApiUndo","1.5"),0)},u.prototype.getData=function(){return n(this,"getData",1,[],4,0)},u.prototype.setVisualObjects=function(e){n(this,"setVisualObjects",0,[e],2,0)},u.prototype.setVisualObjectsToPersist=function(e){n(this,"setVisualObjectsToPersist",0,[e],2,0)},u.prototype._handleResult=function(e){(c.prototype._handleResult.call(this,e),r(e))||i(this,e)},u.prototype._handleRetrieveResult=function(e,t){c.prototype._handleRetrieveResult.call(this,e,t),a(this,e,t)},u.newObject=function(n){return t(e.BiShim,n,"Microsoft.AgaveVisual.BiShim",!1,4)},u.prototype.toJSON=function(){return o(this,{},{})},u}(OfficeExtension.ClientObject);e.BiShim=c,function(e){e.generalException="GeneralException"}(e.AgaveVisualErrorCodes||(e.AgaveVisualErrorCodes={}))}(OfficeCore||(OfficeCore={})),function(e){OfficeExtension.BatchApiHelper.createPropertyObject;var t=OfficeExtension.BatchApiHelper.createMethodObject,n=(OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject,OfficeExtension.BatchApiHelper.createTopLevelServiceObject),r=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),o=OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,i=(OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),a=OfficeExtension.Utility.isUndefined,s=OfficeExtension.Utility.throwIfNotLoaded,c=(OfficeExtension.Utility.throwIfApiNotSupported,OfficeExtension.Utility.load),u=OfficeExtension.Utility.retrieve,l=OfficeExtension.Utility.toJson,f=OfficeExtension.Utility.fixObjectPathIfNecessary,p=(OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult),d=function(o){function a(){return null!==o&&o.apply(this,arguments)||this}return __extends(a,o),Object.defineProperty(a.prototype,"_className",{get:function(){return"FlightingService"},enumerable:!0,configurable:!0}),a.prototype.getClientSessionId=function(){return r(this,"GetClientSessionId",1,[],4,0)},a.prototype.getDeferredFlights=function(){return r(this,"GetDeferredFlights",1,[],4,0)},a.prototype.getFeature=function(n,r,o,i){return t(e.ABType,this,"GetFeature",1,[n,r,o,i],!1,!1,null,4)},a.prototype.getFeatureGate=function(n,r){return t(e.ABType,this,"GetFeatureGate",1,[n,r],!1,!1,null,4)},a.prototype.resetOverride=function(e){r(this,"ResetOverride",0,[e],0,0)},a.prototype.setOverride=function(e,t,n){r(this,"SetOverride",0,[e,t,n],0,0)},a.prototype._handleResult=function(e){(o.prototype._handleResult.call(this,e),i(e))||f(this,e)},a.prototype._handleRetrieveResult=function(e,t){o.prototype._handleRetrieveResult.call(this,e,t),p(this,e,t)},a.newObject=function(t){return n(e.FlightingService,t,"Microsoft.Experiment.FlightingService",!1,4)},a.prototype.toJSON=function(){return l(this,{},{})},a}(OfficeExtension.ClientObject);e.FlightingService=d;var h=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"_className",{get:function(){return"ABType"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyNames",{get:function(){return["value"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return s("value",this._V,"ABType",this._isNull),this._V},enumerable:!0,configurable:!0}),t.prototype._handleResult=function(t){if(e.prototype._handleResult.call(this,t),!i(t)){var n=t;f(this,n),a(n.Value)||(this._V=n.Value)}},t.prototype.load=function(e){return c(this,e)},t.prototype.retrieve=function(e){return u(this,e)},t.prototype._handleRetrieveResult=function(t,n){e.prototype._handleRetrieveResult.call(this,t,n),p(this,t,n)},t.prototype.toJSON=function(){return l(this,{value:this._V},{})},t.prototype.ensureUnchanged=function(e){o(this,e)},t}(OfficeExtension.ClientObject);e.ABType=h,function(e){e.boolean="Boolean",e.integer="Integer",e.string="String"}(e.FeatureType||(e.FeatureType={})),function(e){e.generalException="GeneralException"}(e.ExperimentErrorCodes||(e.ExperimentErrorCodes={}))}(OfficeCore||(OfficeCore={})),function(e){var t,n=function(){function e(e){this._dialogService=e}return e.prototype.close=function(){return this._dialogService.close(),this._dialogService.context.sync()},e.prototype.messageChild=function(e,t){DialogApiManager&&DialogApiManager.messageChildRichApiBridge&&DialogApiManager.messageChildRichApiBridge(e,t)},e}();e.Dialog=n,e.displayWebDialog=function(t,n){return void 0===n&&(n={}),new OfficeExtension.CoreUtility.Promise((function(o,i){if(n.width&&n.height&&(!r(n.width)||!r(n.height)))throw new OfficeExtension.Error({code:"InvalidArgument",message:'Dimensions must be "number%" or number.'});var a=new OfficeExtension.ClientRequestContext,s=OfficeCore.FirstPartyDialogService.newObject(a),c=new e.Dialog(s),u=s.onDialogMessage.add((function(e){OfficeExtension.Utility.log("dialogMessageHandler:"+JSON.stringify(e));var t,r,s,l=JSON.parse(e.message),f=l.errorCode?new OfficeExtension.Error((t=l.errorCode,(r={})[12002]={code:"InvalidUrl",message:"Cannot load URL, no such page or bad URL syntax."},r[12003]={code:"InvalidUrl",message:"HTTPS is required."},r[12004]={code:"Untrusted",message:"Domain is not trusted."},r[12005]={code:"InvalidUrl",message:"HTTPS is required."},r[12007]={code:"FailedToOpen",message:"Another dialog is already opened."},(s=r)[t]?s[t]:{code:"Unknown",message:"An unknown error has occured with code: "+t})):null,p=l.type,d=l.origin,h=l.message;switch(p){case 17:f?i(f):o(c);break;case 12:n.onMessage&&n.onMessage(h,c,d);break;case 10:default:12006===l.errorCode?(u&&(u.remove(),a.sync()),n.onClose&&n.onClose()):n.onRuntimeError&&(n.onRuntimeError(f,c),i(f))}return OfficeExtension.CoreUtility.Promise.resolve()}));return a.sync().then((function(){var e={width:n.width?parseInt(n.width):50,height:n.height?parseInt(n.height):50,displayInIFrame:n.displayInIFrame,dialogTitle:n.dialogTitle,escKeyCloseDialog:void 0===n.escKeyCloseDialog||n.escKeyCloseDialog};return s.displayDialog(t,e),a.sync()})).catch((function(e){i(e)}))}));function r(e){return/^(\-|\+)?([0-9]+)%?$/.test(e)}},function(e){e[e.dialogMessageReceived=0]="dialogMessageReceived",e[e.dialogEventReceived=1]="dialogEventReceived"}(t||(t={}))}(OfficeFirstPartyDialog||(OfficeFirstPartyDialog={})),function(e){e.OfficeOnlineDomainList=["*.dod.online.office365.us","*.gov.online.office365.us","*.officeapps-df.live.com","*.officeapps.live.com","*.online.office.de","*.partner.officewebapps.cn"],e.isHostOriginTrusted=function(){if(void 0===window.external||void 0===window.external.GetContext){var t=OSF.getClientEndPoint()._targetUrl,n=t.split("/")[2].split(":")[0].split("?")[0];return 0!=t.indexOf("https:")||e.OfficeOnlineDomainList.forEach((function(e){if(0==e.indexOf("*.")&&(e=e.substring(2)),n.indexOf(e)==n.length-e.length)return!0})),!1}return!0}}(OfficeCore||(OfficeCore={})),function(e){var t=function(){function t(e){this.context=e}return Object.defineProperty(t.prototype,"roamingSettings",{get:function(){return this.m_roamingSettings||(this.m_roamingSettings=e.AuthenticationService.newObject(this.context).roamingSettings),this.m_roamingSettings},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"tap",{get:function(){return this.m_tap||(this.m_tap=e.Tap.newObject(this.context)),this.m_tap},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"skill",{get:function(){return this.m_skill||(this.m_skill=e.Skill.newObject(this.context)),this.m_skill},enumerable:!0,configurable:!0}),t}();e.FirstPartyApis=t;var n=function(n){function r(e){return n.call(this,e)||this}return __extends(r,n),Object.defineProperty(r.prototype,"firstParty",{get:function(){return this.m_firstPartyApis||(this.m_firstPartyApis=new t(this)),this.m_firstPartyApis},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"flighting",{get:function(){return this.flightingService},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"telemetry",{get:function(){return this.m_telemetry||(this.m_telemetry=e.TelemetryService.newObject(this)),this.m_telemetry},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"ribbon",{get:function(){return this.m_ribbon||(this.m_ribbon=e.DynamicRibbon.newObject(this)),this.m_ribbon},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"bi",{get:function(){return this.m_biShim||(this.m_biShim=e.BiShim.newObject(this)),this.m_biShim},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"flightingService",{get:function(){return this.m_flightingService||(this.m_flightingService=e.FlightingService.newObject(this)),this.m_flightingService},enumerable:!0,configurable:!0}),r}(OfficeExtension.ClientRequestContext);e.RequestContext=n,e.run=function(t,n){return OfficeExtension.ClientRequestContext._runBatch("OfficeCore.run",arguments,(function(t){return new e.RequestContext(t)}))}}(OfficeCore||(OfficeCore={})),function(e){!function(e){function t(){var e=new OfficeCore.RequestContext;return"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(e._customData="WacPartition"),e}e.isFeatureEnabled=function(e,n){return __awaiter(this,void 0,void 0,(function(){var r,o,i;return __generator(this,(function(a){switch(a.label){case 0:return r=t(),o=OfficeCore.License.newObject(r),i=o.isFeatureEnabled(e,n),[4,r.sync()];case 1:return a.sent(),[2,i.value]}}))}))},e.getFeatureTier=function(e,n){return __awaiter(this,void 0,void 0,(function(){var r,o,i;return __generator(this,(function(a){switch(a.label){case 0:return r=t(),o=OfficeCore.License.newObject(r),i=o.getFeatureTier(e,n),[4,r.sync()];case 1:return a.sent(),[2,i.value]}}))}))},e.isFreemiumUpsellEnabled=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,r;return __generator(this,(function(o){switch(o.label){case 0:return e=t(),n=OfficeCore.License.newObject(e),r=n.isFreemiumUpsellEnabled(),[4,e.sync()];case 1:return o.sent(),[2,r.value]}}))}))},e.launchUpsellExperience=function(e){return __awaiter(this,void 0,void 0,(function(){var n;return __generator(this,(function(r){switch(r.label){case 0:return n=t(),OfficeCore.License.newObject(n).launchUpsellExperience(e),[4,n.sync()];case 1:return r.sent(),[2]}}))}))},e.onFeatureStateChanged=function(e,n){return __awaiter(this,void 0,void 0,(function(){var r,o,i,a;return __generator(this,(function(s){switch(s.label){case 0:return r=t(),o=OfficeCore.License.newObject(r),(i=o.getLicenseFeature(e)).onStateChanged.add(n),a=function(){return i.onStateChanged.remove(n),null},[4,r.sync()];case 1:return s.sent(),[2,a]}}))}))},e.getMsaDeviceTicket=function(e,n,r){return __awaiter(this,void 0,void 0,(function(){var o,i,a;return __generator(this,(function(s){switch(s.label){case 0:return o=t(),i=OfficeCore.License.newObject(o),a=i.getMsaDeviceTicket(e,n,r),[4,o.sync()];case 1:return s.sent(),[2,a.value]}}))}))}}(e.license||(e.license={}))}(Office||(Office={})),function(e){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject,OfficeExtension.BatchApiHelper.createTopLevelServiceObject,OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod,OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined,OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported,OfficeExtension.Utility.load,OfficeExtension.Utility.retrieve,OfficeExtension.Utility.toJson,OfficeExtension.Utility.fixObjectPathIfNecessary,OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult,OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags;!function(e){e.Skill_HostSkillEvent_EventArgsTransform=function(e,t){return{type:t.type,data:t.data}}}(e._CC||(e._CC={})),function(e){e.generalException="GeneralException"}(e.SkillErrorCodes||(e.SkillErrorCodes={}));new OfficeExtension.LibraryBuilder({metadata:{version:"1.0.0",name:"OfficeCore",defaultApiSetName:"OfficeSharedApi",hostName:"Office",apiSets:[["1.1","SharedApiUndo"]],strings:["Skill","registerHostSkillEvent","unregisterHostSkillEvent"],enumTypes:[],clientObjectTypes:[[1,0,0,0,[["executeAction",3,2,0,5],["notifyPaneEvent",2,2,0,5],[2,0,0,0,3,0,1],[3,0,0,0,3,0,1],["testFireEvent",0,0,0,3,0,1]],0,0,0,[["HostSkillEvent",2,0,"65538","",2,3]],"Microsoft.SkillApi.Skill",4]]},targetNamespaceObject:e})}(OfficeCore||(OfficeCore={})),function(e){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject;var t=OfficeExtension.BatchApiHelper.createTopLevelServiceObject,n=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),r=(OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),o=(OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported),i=(OfficeExtension.Utility.load,OfficeExtension.Utility.retrieve,OfficeExtension.Utility.toJson),a=OfficeExtension.Utility.fixObjectPathIfNecessary,s=(OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult),c=(OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags,function(c){function u(){return null!==c&&c.apply(this,arguments)||this}return __extends(u,c),Object.defineProperty(u.prototype,"_className",{get:function(){return"TelemetryService"},enumerable:!0,configurable:!0}),u.prototype.sendNonStandardEvent=function(e,t,r,i,a,s){o("TelemetryService.sendNonStandardEvent","Telemetry","1.4","OfficeCore"),n(this,"SendNonStandardEvent",1,[e,t,r,i,a,s],4,0)},u.prototype.sendTelemetryEvent=function(e,t,r,o,i){n(this,"SendTelemetryEvent",1,[e,t,r,o,i],4,0)},u.prototype._handleResult=function(e){(c.prototype._handleResult.call(this,e),r(e))||a(this,e)},u.prototype._handleRetrieveResult=function(e,t){c.prototype._handleRetrieveResult.call(this,e,t),s(this,e,t)},u.newObject=function(n){return t(e.TelemetryService,n,"Microsoft.Telemetry.TelemetryService",!1,4)},u.prototype.toJSON=function(){return i(this,{},{})},u}(OfficeExtension.ClientObject));e.TelemetryService=c,function(e){e.unset="Unset",e.string="String",e.boolean="Boolean",e.int64="Int64",e.double="Double"}(e.DataFieldType||(e.DataFieldType={})),function(e){e.sendTelemetryEvent="SendTelemetryEvent",e.customerContent="CustomerContent",e.directNumericEvent="DirectNumericEvent"}(e.EventType||(e.EventType={})),function(e){e.generalException="GeneralException"}(e.TelemetryErrorCodes||(e.TelemetryErrorCodes={}))}(OfficeCore||(OfficeCore={})),function(e){var t="officeWebAuthReplyUrls",n=!1,r=null;function o(e){var t=null,n=null,r=function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return t=e.apply(void 0,n)};return{immediateCall:r,delayCall:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];n=function(){return r.apply(void 0,e)}},waitForPromise:function(){return n&&(n(),n=null),t||Promise.resolve()}}}function i(t){return __awaiter(this,void 0,void 0,(function(){var n,r;return __generator(this,(function(o){switch(o.label){case 0:return n=!1,t&&e.supportsTeamsTokenFlow?(n=!0,[3,3]):[3,1];case 1:return[4,a()];case 2:(r=o.sent()).supportsAuthToken?n=!0:t&&(n=!r.hostPageSupportsAuth),o.label=3;case 3:return[2,n]}}))}))}function a(){return Office&&Office.context&&Office.context.webAuth?r?Promise.resolve(r):new Promise((function(e,t){Office.context.webAuth.getAuthContextAsync((function(n){if("succeeded"===n.status){if(!(r=n.value)||r.isAnonymous)return void t({code:"CannotGetAuthContext",message:r?r.Error:void 0,loggableErrorMessage:"Anonymous user"});if(!r.appId)return void t({code:"CannotGetAuthContext",message:"App ID is missing from getAuthContextAsync. Please verify the WebApplicationInfo node in app manifest."});e(r)}else t({code:"CannotGetAuthContext",message:n.status,loggableErrorMessage:String(n.error.code)})}))})):Promise.reject({code:"GetAuthContextAsyncMissing",message:"Office:["+!Office+"],Office.context:["+!Office.context+"],Office.context.webAuth:["+!Office.context.webAuth+"]"})}e.authFlow="authcode",e.autoPopup=!1,e.upnCheck=!0,e.timeout=void 0,e.msal="https://alcdn.msauth.net/browser-1p/2.28.1/js/msal-browser-1p.min.js",e.debugging=!1,e.useMsal3=void 0,e.delay=0,e.delayMsal=0,e.supportsOauthManager=!1,e.supportsTeamsTokenFlow=!0,e.supportsBrowserAuth=!0;var s=o((function(r,o){return __awaiter(this,void 0,void 0,(function(){var i;return __generator(this,(function(s){switch(s.label){case 0:return e.supportsBrowserAuth?[4,a()]:[2,Promise.reject({code:"PackageNotLoaded"})];case 1:return i=s.sent(),[2,new Promise((function(a,s){try{var c="msa"===i.authorityType.toLowerCase();if(OSF.WebAuth.config={authFlow:e.authFlow,authVersion:e.authVersion?e.authVersion:null,msal:e.msal,delayWebAuth:e.delay,delayMsal:e.delayMsal,debugging:e.debugging,useMsal3:e.useMsal3,authority:e.authorityOverride?e.authorityOverride:i.authority,idp:i.authorityType.toLowerCase(),appIds:[c&&i.msaAppId?i.msaAppId:i.appId],redirectUri:r||null,upn:i.upn,puid:i.userId,prefetch:o,telemetryInstance:"otel",autoPopup:e.autoPopup,enableUpnCheck:e.upnCheck,enableConsoleLogging:e.debugging,tenantId:i.tenantId,timeout:e.timeout},OSF.WebAuth.load().then((function(e){l(e,n=!0),a()})).catch((function(e){s({code:"PackageNotLoaded",message:e instanceof Event?e.type:e,telemetryResult:e})})),"implicit"===e.authFlow){var u=r||window.location.href.split("?")[0],f=sessionStorage.getItem(t);f||""===f?f=u:f+=", "+u,f&&sessionStorage.setItem(t,f)}}catch(e){OSF.WebAuth.config=null,OSF.WebAuth.load().then((function(){a()})).catch((function(){s({code:"FailedToLoad",message:e})}))}}))]}}))}))}));var c=o((function(t,n){return __awaiter(this,void 0,void 0,(function(){var r,o;return __generator(this,(function(a){switch(a.label){case 0:if(!OSF.WebAuth||"web"!=OSF._OfficeAppFactory.getHostInfo().hostPlatform)return[3,6];a.label=1;case 1:return a.trys.push([1,5,,6]),s.delayCall(t,n),[4,i(e.supportsOauthManager)];case 2:return a.sent()?[3,4]:[4,s.waitForPromise()];case 3:a.sent(),a.label=4;case 4:return[3,6];case 5:throw r=a.sent(),l((o=r).result,!1,o),delete o.result,delete o.loggableErrorMessage,o;case 6:return[2]}}))}))}));function u(e,t){return c.immediateCall(e,t)}function l(e,t,n){void 0!==OTel&&OTel.OTelLogger.onTelemetryLoaded((function(){var r=OSF.WebAuth.config?[oteljs.makeStringDataField("IdentityProvider",OSF.WebAuth.config.idp),oteljs.makeStringDataField("AppId",OSF.WebAuth.config.appIds[0]),oteljs.makeStringDataField("Target",{authFlow:OSF.WebAuth.config.authFlow,authVersion:OSF.WebAuth.config.authVersion,msal:OSF.WebAuth.config.msal,autoPopup:OSF.WebAuth.config.autoPopup,enableUpnCheck:OSF.WebAuth.config.upnCheck}),oteljs.makeBooleanDataField("UseMsal3",!0===OSF.WebAuth.config.useMsal3)]:[],o=n&&n.loggableErrorMessage?n.loggableErrorMessage:"",i=t?[]:[oteljs.makeStringDataField("ApiErrorCode",n&&n.code?n.code:""),oteljs.makeStringDataField("Error",o||(e instanceof Event?e.type:""))],a=r.concat(i,[oteljs.makeBooleanDataField("Result",t)]);if(e&&!(e instanceof Event)&&e.Telemetry)for(var s in e.Telemetry)if(e.Telemetry[s])switch(s){case"succeeded":a.push(oteljs.makeBooleanDataField(s,e.Telemetry[s]));break;case"loadedApplicationCount":case"timeToLoad":a.push(oteljs.makeInt64DataField(s,e.Telemetry[s]));break;default:a.push(oteljs.makeStringDataField(s,e.Telemetry[s]))}OTel.OTelLogger.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.OfficeFirstPartyAuth.Load",dataFields:a,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage}})}))}function f(e,t,n,r){void 0!==OTel&&OTel.OTelLogger.onTelemetryLoaded((function(){var o=[oteljs.makeStringDataField("IdentityProvider",OSF.WebAuth.config.idp),oteljs.makeStringDataField("AppId",OSF.WebAuth.config.appIds[0]),oteljs.makeStringDataField("CorrelationId",n),oteljs.makeStringDataField("Target",{authFlow:OSF.WebAuth.config.authFlow,authVersion:OSF.WebAuth.config.authVersion,msal:OSF.WebAuth.config.msal,autoPopup:OSF.WebAuth.config.autoPopup,enableUpnCheck:OSF.WebAuth.config.upnCheck}),oteljs.makeBooleanDataField("Popup","boolean"==typeof r&&r),oteljs.makeBooleanDataField("Result",t),oteljs.makeStringDataField("Error",e instanceof Event?e.type:e.ErrorCode)];if(e&&!(e instanceof Event)&&e.Telemetry)for(var i in e.Telemetry)if(e.Telemetry[i])switch(i){case"succeeded":o.push(oteljs.makeBooleanDataField(i,e.Telemetry[i]));break;case"timeToGetToken":o.push(oteljs.makeInt64DataField(i,e.Telemetry[i]));break;default:o.push(oteljs.makeStringDataField(i,e.Telemetry[i]))}OTel.OTelLogger.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.OfficeFirstPartyAuth.GetAccessToken",dataFields:o,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage}})}))}e.load=u,e.getAccessToken=function(e,t){var r=this;return c.waitForPromise().then((function(){return new Promise((function(o,a){return __awaiter(r,void 0,void 0,(function(){var r,c,u,l,p,d,h,g,m;return __generator(this,(function(y){switch(y.label){case 0:return y.trys.push([0,10,,11]),"web"!=OSF._OfficeAppFactory.getHostInfo().hostPlatform?[3,6]:[4,i(!!e.appName)];case 1:return y.sent()?[3,3]:[4,s.waitForPromise()];case 2:return y.sent(),OSF.WebAuth&&n?(r=e.correlationId||OSF._OfficeAppFactory.getHostInfo().osfControlAppCorrelationId,OSF.WebAuth.config.appIds[0]&&OSF.WebAuth.getToken(e.resource,null,OSF.WebAuth.config.appIds[0],r,t&&t.popup?t.popup:null,e&&e.authChallenge?e.authChallenge:null).then((function(e){f(e,!0,r,!(!t||!t.popup)&&t.popup),o({accessToken:e.Token,tokenIdenityType:"msa"==OSF.WebAuth.config.idp.toLowerCase()?OfficeCore.IdentityType.microsoftAccount:OfficeCore.IdentityType.organizationAccount})})).catch((function(e){f(e,!1,r,!(!t||!t.popup)&&t.popup),a({code:e.ErrorCode,message:e instanceof Event?e.type:e.ErrorMessage})}))):(v=n,_=OSF.WebAuth.loadAttempts,void 0!==OTel&&OTel.OTelLogger.onTelemetryLoaded((function(){var e=[oteljs.makeBooleanDataField("Loaded",v),oteljs.makeInt64DataField("LoadAttempts","number"==typeof _?_:0)];OTel.OTelLogger.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.OfficeFirstPartyAuth.UnexpectedAcquire",dataFields:e,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage}})}))),[3,5];case 3:return c=new OfficeCore.RequestContext,p=OfficeCore.AuthenticationService.newObject(c),c._customData="WacPartition",u=p.getAccessToken(e,null),[4,c.sync()];case 4:y.sent(),o(u.value),y.label=5;case 5:return[3,9];case 6:return l=new OfficeCore.RequestContext,p=OfficeCore.AuthenticationService.newObject(l),d=p.onTokenReceived.add((function(e){if(!OfficeExtension.CoreUtility.isNullOrUndefined(e))if(d.remove(),l.sync().catch((function(){})),0==e.code)o(e.tokenValue);else if(OfficeExtension.CoreUtility.isNullOrUndefined(e.errorInfo))a({code:e.code});else try{a(JSON.parse(e.errorInfo))}catch(t){a({code:e.code,message:e.errorInfo})}return null})),[4,l.sync()];case 7:return y.sent(),h=p.getAccessToken(e,p._targetId),[4,l.sync()];case 8:if(y.sent(),OfficeExtension.CoreUtility.isNullOrUndefined(h.value))return[2,null];g=h.value.accessToken,OfficeExtension.CoreUtility.isNullOrUndefined(g)||o(h.value),y.label=9;case 9:return[3,11];case 10:return m=y.sent(),a(m),[3,11];case 11:return[2]}var v,_}))}))}))}))},e.getPrimaryIdentityInfo=function(){var e=new OfficeCore.RequestContext,t=OfficeCore.AuthenticationService.newObject(e);e._customData="WacPartition";var n=t.getPrimaryIdentityInfo();return e.sync().then((function(){return n.value}))},e.getIdentities=function(){var e=new OfficeCore.RequestContext,t=OfficeCore.AuthenticationService.newObject(e).getIdentities();return e.sync().then((function(){return t.value}))},e.onIdentityChanged=function(e){return __awaiter(this,void 0,void 0,(function(){var t,n,r=this;return __generator(this,(function(o){switch(o.label){case 0:return o.trys.push([0,3,,4]),"web"===OSF._OfficeAppFactory.getHostInfo().hostPlatform?[3,2]:(t=new OfficeCore.RequestContext,n=OfficeCore.AuthenticationService.newObject(t),n.onIdentityChanged.add(e),[4,t.sync()]);case 1:return o.sent(),[2,function(){return __awaiter(r,void 0,void 0,(function(){return __generator(this,(function(r){switch(r.label){case 0:return n.onIdentityChanged.remove(e),[4,t.sync()];case 1:return r.sent(),[2]}}))}))}];case 2:return[3,4];case 3:return o.sent(),[3,4];case 4:return[2,function(){return Promise.resolve()}]}}))}))},"undefined"!=typeof window&&window.OSF&&function(){try{if("undefined"==typeof window||!window.sessionStorage)return;var e=sessionStorage.getItem(t);null!==e&&-1!==e.indexOf(window.location.origin+window.location.pathname)&&u()}catch(e){console.error(e)}}()}(OfficeFirstPartyAuth||(OfficeFirstPartyAuth={})),function(e){!function(e){var t,n;!function(e){e[e.None=0]="None",e[e.Auto=1]="Auto",e[e.Force=2]="Force"}(t=e.PopupOptions||(e.PopupOptions={})),function(e){e[e.UnsupportedUserIdentity=13003]="UnsupportedUserIdentity",e[e.UserAborted=13004]="UserAborted",e[e.InteractionRequired=13005]="InteractionRequired",e[e.ClientError=13006]="ClientError",e[e.ServerError=13007]="ServerError",e[e.NotAvailable=13012]="NotAvailable",e[e.InternalError=5001]="InternalError",e[e.InvalidApiArguments=5013]="InvalidApiArguments"}(n=e.AuthErrorCode||(e.AuthErrorCode={}));var r={ACCOUNT_UNAVAILABLE:n.UnsupportedUserIdentity,USER_CANCEL:n.UserAborted,USER_INTERACTION_REQUIRED:n.InteractionRequired,PERSISTENT_ERROR:n.ClientError,NO_NETWORK:n.ServerError,TRANSIENT_ERROR:n.ServerError,NESTED_APP_AUTH_UNAVAILABLE:n.NotAvailable},o={POPUP_WINDOW_ERROR:n.ClientError,USER_CANCELLED:n.UserAborted},i="access_token",a="xms_cc",s=0,c=!1,u=!1,l=void 0,f=void 0;e.clientCapabilities=[],e.upnCheck=!0,e.timeout=void 0,e.msal="https://alcdn.msauth.net/browser-1p/2.28.1/js/msal-browser-1p.min.js",e.debugging=!1,e.delay=0,e.delayMsal=0,e.useMsal3=void 0;var p={},d=function(e){try{var t="string"==typeof e?e:e.data,o=JSON.parse(t);if(o.requestId){var i=o.requestId;if(p.hasOwnProperty(i)){var a=n.InternalError,s=p[i],c=s[0],u=s[1];delete p[i];var l=o.token;if(l&&!0===o.success&&l.access_token&&"number"==typeof l.expires_in)return void c({accessToken:l.access_token,idToken:l.id_token,expiresOn:new Date(Date.now()+1e3*l.expires_in)});var f=o.error;if(f){var d=f.status;r[d]&&(a=r[d])}u({code:a})}}}catch(e){}},h={code:n.NotAvailable};function g(t){if(0===e.clientCapabilities.length)return t;var n={};if(t)try{n=JSON.parse(t)}catch(e){}return n.hasOwnProperty(i)||(n[i]={}),n[i][a]={values:e.clientCapabilities},JSON.stringify(n)}function m(e,t){var r=e.clientId||f,i=e.correlationId||OSF.OUtil.Guid.generateNewGuid(),a=Date.now(),m=function(e){var n=function(e,n){var o=Date.now()-a;!function(e,t,n,r,o,i){if(s>0&&!n)return;s++,void 0!==OTel&&OTel.OTelLogger.onTelemetryLoaded((function(){var o=[oteljs.makeStringDataField("NestedClientId",e),oteljs.makeStringDataField("CorrelationId",t),oteljs.makeBooleanDataField("Popup",n),oteljs.makeInt64DataField("Duration",r),oteljs.makeInt64DataField("ErrorCode",i?i.code:0),oteljs.makeBooleanDataField("BridgeAvailable",v())];OTel.OTelLogger.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.NestedAppAuth.GetAccessToken",dataFields:o,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage,diagnosticLevel:oteljs.DiagnosticLevel.NecessaryServiceDataEvent}})}))}(r,i,t,o,0,n)};return e.then((function(e){n(0,null)})).catch((function(e){n(0,e)})),e};return v()?m(new Promise((function(n,o){var a=OSF.OUtil.Guid.generateNewGuid(),s=e.scopes.join(" "),u={messageType:"NestedAppAuthRequest",method:t?"GetTokenPopup":"GetToken",requestId:a,clientLibrary:"officejs",sendTime:Date.now(),tokenParams:{clientId:r,scope:s,correlationId:i,claims:g(e.claims)}};c||(nestedAppAuthBridge.addEventListener("message",d),c=!0),p[a]=[n,o],nestedAppAuthBridge.postMessage(JSON.stringify(u))}))):m(l?l.then((function(){if(!u)return Promise.reject(h);var a=e.scopes.join(" ");return a=a.replace(/(\/.default)$/,""),OSF.WebAuth.getToken(a,e.scopes,r,i,t,e.claims).then((function(e){return{accessToken:e.Token,expiresOn:e.MsalResult?e.MsalResult.expiresOn:void 0}})).catch((function(e){var t=n.InternalError,r=void 0;if(e)if(r=e.ErrorMessage,e.MsalResult&&"InteractionRequiredAuthError"===e.MsalResult.name)t=n.InteractionRequired;else if(e.ErrorCode){var i=e.ErrorCode.toUpperCase();o[i]&&(t=o[i])}return Promise.reject({code:t,description:r})}))})):Promise.reject(h))}function y(){return v()||"function"!=typeof __initializeNestedAppAuth?Promise.resolve():__initializeNestedAppAuth()}function v(){return"undefined"!=typeof nestedAppAuthBridge}function _(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,y()];case 1:return e.sent(),[2,v()]}}))}))}function b(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,new Promise((function(e){Office.context.auth.getAuthContextAsync((function(t){"succeeded"===t.status?e(t.value):e(null)}))})).catch((function(){return null}))]}))}))}e.isBridgeAvailable=v,e.isBridgeAvailableAsync=_,e.load=function(t,n,r,o){return l=l||function(t,n,r,o){return __awaiter(this,void 0,void 0,(function(){var i,a;return __generator(this,(function(s){switch(s.label){case 0:return f=t,o&&(e.clientCapabilities=o),Office&&Office.context&&Office.context.auth&&OSF.WebAuth?[4,_()]:[2];case 1:return s.sent()?[2]:[4,b()];case 2:if(!(i=s.sent()))throw h;OSF.WebAuth.config={authFlow:"authcode",authVersion:e.authVersion?e.authVersion:null,msal:e.msal,delayWebAuth:e.delay,delayMsal:e.delayMsal,debugging:e.debugging,useMsal3:e.useMsal3,authority:e.authorityOverride?e.authorityOverride:i.authorityBaseUrl,idp:"msa"===i.authorityType.toLowerCase()?"msa":"aad",appIds:[t],redirectUri:n||null,upn:i.userPrincipalName,prefetch:r,telemetryInstance:"otel",enableUpnCheck:e.upnCheck,enableConsoleLogging:e.debugging,checkActiveAccount:!0,tenantId:i.tenantId,timeout:e.timeout,clientCapabilities:o},s.label=3;case 3:return s.trys.push([3,5,,6]),[4,OSF.WebAuth.load()];case 4:return s.sent(),u=!0,[3,6];case 5:throw a=s.sent(),__assign({},h,{description:a instanceof Event?a.type:void 0});case 6:return[2]}}))}))}(t,n,r,o)},e.getAccessToken=function(e){var r=null==e.popup?t.None:e.popup;if(r===t.Auto&&!e.directUserActionCallback)throw{code:n.InvalidApiArguments};return y().then((function(){return m(e,r===t.Force).catch((function(o){if(o.code==n.InteractionRequired&&r===t.Auto&&e.directUserActionCallback)return e.directUserActionCallback().then((function(t){if(t)return m(e,!0);throw{code:n.UserAborted}})).catch((function(){throw{code:n.UserAborted}}));throw o}))}))}}(e.NestedAppAuth||(e.NestedAppAuth={}))}(OfficeFirstPartyAuth||(OfficeFirstPartyAuth={})),function(e){var t;OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject,OfficeExtension.BatchApiHelper.createTopLevelServiceObject,OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod,OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined,OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported,OfficeExtension.Utility.load,OfficeExtension.Utility.retrieve,OfficeExtension.Utility.toJson,OfficeExtension.Utility.fixObjectPathIfNecessary,OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult,OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags;!function(e){e.LicenseFeature_StateChanged_EventArgsTransform=function(e,t){var n={feature:t.featureName,isEnabled:t.isEnabled,tier:t.tierName};return t.tierName&&(n.tier=0==t.tierName?LicenseFeatureTier.unknown:1==t.tierName?LicenseFeatureTier.basic:2==t.tierName?LicenseFeatureTier.premium:t.tierName),n}}(e._CC||(e._CC={})),function(e){e.ThemeService_OfficeThemeChanged_EventArgsTransform=function(e,t){return{bodyBackgroundColor:t.bodyBackgroundColor,bodyForegroundColor:t.bodyForegroundColor,controlBackgroundColor:t.controlBackgroundColor,controlForegroundColor:t.controlForegroundColor}}}(e._CC||(e._CC={})),function(e){e[e.immediate=0]="immediate",e[e.load=3]="load"}(t=e.PersonaPromiseType||(e.PersonaPromiseType={}));var n=function(){};e.PersonaInfoAndSource=n;var r=function(){function r(){}return r.prototype.performAsyncOperation=function(e,n,r,o){var i=this;e!=t.immediate?o().then((function(e){if(e)r();else{var t=i;t.load("hostId"),t.context.sync().then((function(){var e=t.hostId;i.getPersonaLifetime().then((function(i){var a=function(s){return new OfficeExtension.CoreUtility.Promise((function(c,u){if(s.sendingPersonaHostId==e)for(var l=0;l<s.dataUpdated.length;++l){var f=s.dataUpdated[l];if(n==f)return void o().then((function(e){e&&(r(),i.onPersonaUpdated.remove(a),t.context.sync()),c(e)}))}c(!1)}))};i.onPersonaUpdated.add(a),t.context.sync()}))}))}})):r()},r.prototype.getOrganizationAsync=function(e){var t=this;return new OfficeExtension.CoreUtility.Promise((function(n,r){var o=t;t.performAsyncOperation(e,PersonaDataUpdated.organization,(function(){var e=o.organization;e.load("*"),o.context.sync().then((function(){n(e)}))}),(function(){return new OfficeExtension.CoreUtility.Promise((function(e,t){var n=o.organization;n.load("isWarmedUp"),o.context.sync().then((function(){e(n.isWarmedUp)}))}))}))}))},r.prototype.getIsPersonaInfoResolvedCheck=function(){var e=this;return new OfficeExtension.CoreUtility.Promise((function(t,n){var r=e.personaInfo;r.load("isPersonResolved"),e.context.sync().then((function(){t(r.isPersonResolved)}))}))},r.prototype.getPersonaInfoAsync=function(e){var t=this;return new OfficeExtension.CoreUtility.Promise((function(n,r){var o=t;t.performAsyncOperation(e,PersonaDataUpdated.personaInfo,(function(){var e=o.personaInfo;e.load(),o.context.sync().then((function(){n(e)}))}),(function(){return t.getIsPersonaInfoResolvedCheck()}))}))},r.prototype.getPersonaInfoWithSourceAsync=function(e){var t=this;return new OfficeExtension.CoreUtility.Promise((function(r,o){var i=t;t.performAsyncOperation(e,PersonaDataUpdated.personaInfo,(function(){var e=new n;e.info=i.personaInfo,e.info.load(),e.source=i.personaInfo.sources,e.source.load(),i.context.sync().then((function(){r(e)}))}),(function(){return t.getIsPersonaInfoResolvedCheck()}))}))},r.prototype.getUnifiedCommunicationInfo=function(e){var t=this;return new OfficeExtension.CoreUtility.Promise((function(n,r){var o=t;t.performAsyncOperation(e,PersonaDataUpdated.personaInfo,(function(){var e=o.unifiedCommunicationInfo;e.load("*"),o.context.sync().then((function(){n(e)}))}),(function(){return t.getIsPersonaInfoResolvedCheck()}))}))},r.prototype.getUnifiedGroupInfoAsync=function(e){var t=this;return new OfficeExtension.CoreUtility.Promise((function(n,r){var o=t;t.performAsyncOperation(e,PersonaDataUpdated.personaInfo,(function(){var e=o.unifiedGroupInfo;e.load("*"),o.context.sync().then((function(){n(e)}))}),(function(){return t.getIsPersonaInfoResolvedCheck()}))}))},r.prototype.getTypeAsync=function(t){var n=this;return new OfficeExtension.CoreUtility.Promise((function(r,o){var i=n;n.performAsyncOperation(t,PersonaDataUpdated.personaInfo,(function(){i.load("type"),i.context.sync().then((function(){r(e.PersonaType[i.type.valueOf()])}))}),(function(){return n.getIsPersonaInfoResolvedCheck()}))}))},r.prototype.getCustomizationsAsync=function(e){var t=this;return new OfficeExtension.CoreUtility.Promise((function(n,r){var o=t;t.performAsyncOperation(e,PersonaDataUpdated.personaInfo,(function(){var e=o.getCustomizations();o.context.sync().then((function(){n(e.value)}))}),(function(){return t.getIsPersonaInfoResolvedCheck()}))}))},r.prototype.getMembersAsync=function(e){var t=this;return new OfficeExtension.CoreUtility.Promise((function(n,r){var o=t;t.performAsyncOperation(e,PersonaDataUpdated.members,(function(){var e=o.getMembers();e.load("isWarmedUp"),o.context.sync().then((function(){n(e)}))}),(function(){return new OfficeExtension.CoreUtility.Promise((function(e,t){var n=o.getMembers();n.load("isWarmedUp"),o.context.sync().then((function(){e(n.isWarmedUp)}))}))}))}))},r.prototype.getMembershipAsync=function(e){var t=this;return new OfficeExtension.CoreUtility.Promise((function(n,r){var o=t;t.performAsyncOperation(e,PersonaDataUpdated.membership,(function(){var e=o.getMembership();e.load("*"),o.context.sync().then((function(){n(e)}))}),(function(){return new OfficeExtension.CoreUtility.Promise((function(e){var t=o.getMembership();t.load("isWarmedUp"),o.context.sync().then((function(){e(t.isWarmedUp)}))}))}))}))},r.prototype.getPersonaLifetime=function(){var e=this;return new OfficeExtension.CoreUtility.Promise((function(t,n){var r=e;r.load("instanceId"),r.context.sync().then((function(){new o(r.context,r.instanceId).getPersonaLifetime().then((function(e){t(e)}))}))}))},r}();e.PersonaCustom=r;var o=function(){function t(e,t){this.context=e,this.instanceId=t}return Object.defineProperty(t.prototype,"serviceContext",{get:function(){return this.m_serviceConext||(this.m_serviceConext=e.ServiceContext.newObject(this.context)),this.m_serviceConext},enumerable:!0,configurable:!0}),t.prototype.getPersonaLifetime=function(){var e=this;return new OfficeExtension.CoreUtility.Promise((function(t,n){var r=e.serviceContext.getPersonaLifetime(e.instanceId);e.context.sync().then((function(){r.load("instanceId"),e.context.sync().then((function(){t(r)}))}))}))},t.prototype.getInitialPersona=function(){var e=this;return new OfficeExtension.CoreUtility.Promise((function(t,n){var r=e.serviceContext.getInitialPersona(e.instanceId);e.context.sync().then((function(){t(r)}))}))},t.prototype.getLokiTokenProvider=function(){var e=this;return new OfficeExtension.CoreUtility.Promise((function(t,n){var r=e.serviceContext.getLokiTokenProvider(e.instanceId);e.context.sync().then((function(){r.load("instanceId"),e.context.sync().then((function(){t(r)}))}))}))},t}();e.PeopleApiContext=o,function(e){e.FirstPartyDialogService_DialogMessage_EventArgsTransform=function(e,t){return{message:t.message}}}(e._CC||(e._CC={}));var i=function(){function e(){}return Object.defineProperty(e.prototype,"_targetId",{get:function(){return null==this.m_targetId&&(void 0!==OSF&&OSF.OUtil?this.m_targetId=OSF.OUtil.Guid.generateNewGuid():this.m_targetId=""+this.context._nextId()),this.m_targetId},enumerable:!0,configurable:!0}),e}();e.AuthenticationServiceCustom=i,function(e){e.AuthenticationService_TokenReceived_EventArgsTransform=function(e,t){var n=t;return{tokenValue:n.tokenValue,code:n.code,errorInfo:n.errorInfo}}}(e._CC||(e._CC={})),function(e){e.ExternalCodeService_ExternalCodeExecutionCompleted_EventArgsTransform=function(e,t){return{result:t.result}},e.ExternalCodeService_ExternalCodeServiceRequestCompleted_EventArgsTransform=function(e,t){return t},e.ExternalCodeService_ExternalCodeServiceResult_EventArgsTransform=function(e,t){return t}}(e._CC||(e._CC={})),function(e){e.AddinSkillActionService_ReplyReceived_EventArgsTransform=function(e,t){return{actionCorrelationId:t.actionCorrelationId,replyMessage:t.replyMessage,resultCode:t.resultCode}}}(e._CC||(e._CC={})),function(e){e.apiNotAvailable="ApiNotAvailable",e.clientError="ClientError",e.clpSessionError="ClpSessionError",e.controlIdNotFound="ControlIdNotFound",e.docCookieError="DocCookieError",e.entryIdRequired="EntryIdRequired",e.errorPointer="ErrorPointer",e.generalException="GeneralException",e.hostIntegrationManagerError="HostIntegrationManagerError",e.hostRestartNeeded="HostRestartNeeded",e.instanceNotFound="InstanceNotFound",e.interactiveFlowAborted="InteractiveFlowAborted",e.invalidArgument="InvalidArgument",e.invalidGrant="InvalidGrant",e.invalidResourceUrl="InvalidResourceUrl",e.invalidRibbonDefinition="InvalidRibbonDefinition",e.labelingDisabledAppguard="LabelingDisabledAppguard",e.labelingDisabledNoSignedInClpCompatibleUsers="LabelingDisabledNoSignedInClpCompatibleUsers",e.labelingDisabledPrivacySettings="LabelingDisabledPrivacySettings",e.labelingDisabledProtectedView="LabelingDisabledProtectedView",e.labelingDisabledUnsupportedLabelClient="LabelingDisabledUnsupportedLabelClient",e.msoOLDocumentError="MsoOLDocumentError",e.notImplement="NotImplement",e.objectNotFound="ObjectNotFound",e.officeJSItemLabelForIdentityError="OfficeJSItemLabelForIdentityError",e.officeJSRMSLicenseError="OfficeJSRMSLicenseError",e.officeJSSessionOrDocError="OfficeJSSessionOrDocError",e.officeSolutionFrameworkHostError="OfficeSolutionFrameworkHostError",e.omworkflowUserNotFound="OMWorkflowUserNotFound",e.osfControlContainerError="OsfControlContainerError",e.outOfMemory="OutOfMemory",e.resourceNotSupported="ResourceNotSupported",e.sensitivityDocumentReadOnly="SensitivityDocumentReadOnly",e.sensitivityInsufficientPermission="SensitivityInsufficientPermission",e.sensitivityLabelDisabled="SensitivityLabelDisabled",e.sensitivityLabelingDisabled="SensitivityLabelingDisabled",e.sensitivityLabelNotFound="SensitivityLabelNotFound",e.sensitivityNewLabelSensitivityOrder="SensitivityNewLabelSensitivityOrder",e.sensitivityUnsupportedContentType="SensitivityUnsupportedContentType",e.sensitivityUnsupportedCrossTenant="SensitivityUnsupportedCrossTenant",e.sensitivityUnsupportedDke="SensitivityUnsupportedDke",e.sensitivityUnsupportedUdp="SensitivityUnsupportedUdp",e.serverError="ServerError",e.serviceUrlNotFound="ServiceUrlNotFound",e.sharedRuntimeNotAvailable="SharedRuntimeNotAvailable",e.ticketInvalidParams="TicketInvalidParams",e.ticketNetworkError="TicketNetworkError",e.ticketUnauthorized="TicketUnauthorized",e.ticketUninitialized="TicketUninitialized",e.ticketUnknownError="TicketUnknownError",e.unexpectedError="UnexpectedError",e.unsupportedUserIdentity="UnsupportedUserIdentity",e.userNotSignedIn="UserNotSignedIn"}(e.ErrorCodes||(e.ErrorCodes={})),e.Interfaces||(e.Interfaces={});new OfficeExtension.LibraryBuilder({metadata:{version:"1.0.0",name:"OfficeCore",defaultApiSetName:"OfficeSharedApi",hostName:"Office",apiSets:[["1.2","SharedApiUndo"],["1.2","SharedRuntimeInternal"],["1.1","SnapshotControl"],["1.1","SharedApiUndo"],["1.4","SharedApiUndo"],["1.2","DynamicRibbon"],["1.1","DynamicRibbonUndo"],["1.2","FirstPartyAuthentication"],["1.3","FirstPartyAuthentication"],["1.5","FirstPartyAuthentication"],["1.1","SensitivityUndo"],["1.2","SensitivityService"],["1.2","SensitivityUndo"],["1.3","SensitivityService"],["1.3","SensitivityUndo"],["1.3","SharedApiUndo"],["1.2","CopilotService"],["1.1","PrivateAPI"],["1.1","ExternalCodeServiceUndo"],["1.1","TaskPaneApi"]],strings:["DialogPage","License","LicenseFeature","MsaDeviceTicketOptions","AppRuntimePersistenceService","AppRuntimeService","ThemeService","Tap","MemberInfoList","PersonaActions","PersonaInfoSource","PersonaInfo","PersonaUnifiedCommunicationInfo","PersonaPhotoInfo","PersonaCollection","PersonaOrganizationInfo","UnifiedGroupInfo","Persona","PersonaLifetime","LokiTokenProvider","LokiTokenProviderFactory","ServiceContext","RichapiPcxFeatureChecks","Comment","CommentCollection","ExtensionLifeCycle","OfficeServicesManagerApi","LocaleApi","FirstPartyDialogService","DynamicRibbon","RibbonTab","RibbonButton","RibbonButtonCollection","ServiceUrlProvider","LinkedIn","NetworkUsage","BeforeDocumentCloseNotification","AuthenticationService","RoamingSetting","RoamingSettingCollection","SharedFilePicker","ActionService","Auth","AugLoopEventService","UndoService","UserFeedbackService","NotificationService","SensitivityService","CopilotService","PrivateApiService","ExternalCodeService","BusinessBarService","ShowSimpleDialog","DispatchApiService","DevicePermissionService","TaskpaneService","AddinSkillActionService","UnifiedStoreService","close","registerOnShow","unregisterOnShow","id","_RegisterStateChange","_UnregisterStateChange","","null","registerOfficeThemeChangedEvent","unregisterOfficeThemeChangedEvent","isWarmedUp","isWarmingUp","displayName","email","emailAddresses","sipAddresses","birthday","birthdays","title","jobInfoDepartment","companyName","office","linkedTitles","linkedDepartments","linkedCompanyNames","linkedOffices","webSites","notes","getImageUri","setPlaceholderColor","getPlaceholderUri","getImageUriWithMetadata","getCount","getItem","instanceId","dispose","_RegisterPersonaUpdatedEvent","_UnregisterPersonaUpdatedEvent","this.instanceId","_RegisterLokiTokenAvailableEvent","_UnregisterLokiTokenAvailableEvent","_RegisterIdentityUniqueIdAvailableEvent","_UnregisterIdentityUniqueIdAvailableEvent","_RegisterClientAccessTokenAvailableEvent","_UnregisterClientAccessTokenAvailableEvent","getLokiTokenProvider","registerIdentityChangedEvent","unregisterIdentityChangedEvent","_RegisterHostMessageReceivedEvent","_UnregisterHostMessageReceivedEvent","_RegisterUndoStackChangedEvent","_UnregisterUndoStackChangedEvent","_RegisterUserFeedbackUIDismissedEvent","_UnregisterUserFeedbackUIDismissedEvent","_RegisterUserFeedbackResponseEvent","_UnregisterUserFeedbackResponseEvent","_RegisterSensitivityLabelChangedEvent","_UnregisterSensitivityLabelChangedEvent","execute","_RegisterPrivateApiEvent","_UnregisterPrivateApiEvent","registerExternalCodeExecutionCompletedEvent","unregisterExternalCodeExecutionCompletedEvent","registerExternalCodeServiceRequestCompletedEvent","unregisterExternalCodeServiceRequestCompletedEvent","registerExternalCodeServiceResultEvent","unregisterExternalCodeServiceResultEvent","_RegisterReplyReceivedEvent","_UnregisterReplyReceivedEvent","_RegisterCopilotAgentEvent","_UnregisterCopilotAgentEvent","_RegisterRefreshedAcquisitionStateEvent","_UnregisterRefreshedAcquisitionStateEvent"],enumTypes:[["DialogPageEventType",[],{onShow:1}],["LicenseFeatureTier",["unknown","basic","premium"]],["LicenseEventType",[],{featureStateChanged:1}],["AppRuntimeState",["inactive","background","visible"]],["Visibility",["hidden","visible"]],["VisualSurface",["default","menus","panes","statusBar","backstage","dialogs"],{qat:"QAT"}],["ObjectType",["unknown","chart","smartArt","table","image","slide","text"],{ole:"OLE"}],["PersonaCardPerfPoint",["placeHolderRendered","initialCardRendered"]],["MessageType",[],{personaLifetimePersonaUpdatedEvent:3502,lokiTokenProviderLokiTokenAvailableEvent:3503,lokiTokenProviderIdentityUniqueIdAvailableEvent:3504,lokiTokenProviderClientAccessTokenAvailableEvent:3505}],["UnifiedCommunicationAvailability",["notSet","free","idle","busy","idleBusy","doNotDisturb","unalertable","unavailable"]],["UnifiedCommunicationStatus",["online","notOnline","away","busy","beRightBack","onThePhone","outToLunch","inAMeeting","outOfOffice","doNotDisturb","inAConference","getting","notABuddy","disconnected","notInstalled","urgentInterruptionsOnly","mayBeAvailable","idle","inPresentation"]],["UnifiedCommunicationPresence",["free","busy","idle","doNotDistrub","blocked","notSet","outOfOffice"]],["FreeBusyCalendarState",["unknown","free","busy","elsewhere","tentative","outOfOffice"]],["PersonaType",["unknown","enterprise","contact","bot","phoneOnly","oneOff","distributionList","personalDistributionList","anonymous","unifiedGroup"]],["PhoneType",["workPhone","homePhone","mobilePhone","businessFax","otherPhone"]],["AddressType",["workAddress","homeAddress","otherAddress"]],["MemberType",["unknown","individual","group"]],["PersonaDataUpdated",["hostId","type","photo","personaInfo","unifiedCommunicationInfo","organization","unifiedGroupInfo","members","membership","capabilities","customizations","viewableSources","placeholder"]],["CustomizedData",["email","workPhone","workPhone2","workFax","mobilePhone","homePhone","homePhone2","otherPhone","sipAddress","profile","office","company","workAddress","homeAddress","otherAddress","birthday"]],["CommentTextFormat",["plain","markdown","delta"]],["TimeStringFormat",["shortTime","longTime","shortDate","longDate"]],["ServiceProvider",["ariaBrowserPipeUrl","ariaUploadUrl","ariaVNextUploadUrl","lokiAutoDiscoverUrl"]],["IdentityType",["organizationAccount","microsoftAccount","unsupported"]],["AugLoopEventType",[],{onHostMessageReceivedEvent:65542}],["UndoType",[],{onUndoStackChangedEvent:65543,onCopilotOperationStartedEvent:65544}],["TriStateOption",["notSet","true","false"]],["UserFeedbackType",["like","dislike","idea","unclassified"]],["UserFeedbackUIType",["modalDialog","taskpane"]],["UserFeedbackEventType",[],{onUserFeedbackUIDismissedEvent:65546,onUserFeedbackResponseEvent:65550}],["UserFeedbackScreenshotInfoSourceType",["autoCapture","autoCaptureWithHtml2Canvas","providedAtInitialization","dynamicallyProvided"]],["UserFeedbackScreenshotInfoImageFormat",[],{jpeg:"jpeg",png:"png"}],["LabelMessageContext",[],{generic:0,firstPerson:1}],["LabelResultSeverity",[],{info:0,warning:1,error:2}],["SensitivityLabelEventType",[],{onLabelChangedEvent:65549}],["EncryptionType",[],{none:0,irmtemplate:1,irmuserDefinedPermission:2,irmencryptOnly:3,irmdoNotForward:4}],["TryUpgradeLabelError",[],{s_APPLYLABEL_OK:0,e_APPLYLABEL_FAIL:2147467259,e_APPLYLABEL_UNSUPPORTED_CROSSTENANT:2147205120,e_APPLYLABEL_DOCUMENT_READONLY:2147205119,e_APPLYLABEL_INSUFFICIENTPERMISSION:2147205118,e_APPLYLABEL_LABELDISABLED:2147205117,e_APPLYLABEL_UNSUPPORTED_UDP:2147205116,e_APPLYLABEL_LABELING_DISABLED:2147205115,e_APPLYLABEL_UNSUPPORTED_CONTENTTYPE:2147205114,e_APPLYLABEL_UNSUPPORTED_DKE:2147205113,e_APPLYLABEL_LABELNOTFOUND:2147205112,e_APPLYLABEL_USERNOTFOUND:2147220727,e_APPLYLABEL_NEWLABELSENSITIVITYORDER:2147205105}],["PrivateApiEventType",[],{onPrivateEvent:65552}],["RequestMethod",["get","post","patch","delete"]],["ResultType",["executionResult","runtimeInfo","serviceResponse"]],["ErrorCategory",["other","environment","runtime","license","user","auth","billing","invalidArg","python","service","unsupported","dataUpload"]],["BusinessBarType",["info","error","blocked","severeWarning","success","warning"]],["SimpleDialogState",[],{cancel:0,confirm:1,checkedConfirm:2}],["SimpleDialogCategory",[],{information:"information",error:"error",warning:"warning",question:"question",other:"other"}],["DevicePermissionType",[],{camera:"camera",microphone:"microphone",geolocation:"geolocation"}],["CopilotAgentEventType",[],{onCopilotAgentEvent:65556}],["UnifiedStoreEventType",[],{onRefreshedAcquisitionStateEvent:65557}]],clientObjectTypes:[[1,0,[["_Id",2]],0,[[59,0,2,0,4],["readyToShow",0,2,0,4],[60,0,2,0,4],[61,0,2,0,4],["sendMessageToHost",1,2,0,4]],0,0,0,[["OnShowEvent",0,0,"DialogPageEventType.onShow","this._Id",60,61]],"Microsoft.Office.DialogPage.DialogPage",4],[2,0,0,0,[["isFeatureEnabled",2,2,0,4],["getFeatureTier",2,2,0,4],["isFreemiumUpsellEnabled",0,2,0,4],["launchUpsellExperience",1,2,0,4],["_TestFireStateChangedEvent",1,0,0,3,0,1],["getMsaDeviceTicket",3,2,0,5]],[["getLicenseFeature",3,1,2,0,4]],0,0,0,"Microsoft.Office.Licensing.License",4],[3,0,[[62,3]],0,[[63,0,2,0,4],[64,0,2,0,4]],0,0,0,[["StateChanged",2,0,"LicenseEventType.featureStateChanged","this.id",63,64]]],[4,0,[["scopes",1,0,0,2,1]],0,0,0,0,0,0,"Microsoft.Office.Licensing.MsaDeviceTicketOptions",4],[5,0,0,0,[["setAppRuntimeStartState",1,0,0,2,0,2],["getAppRuntimeStartState",0,2,0,4]],0,0,0,0,"Microsoft.AppRuntime.AppRuntimePersistenceService",4],[6,0,0,0,[["setAppRuntimeState",1,0,0,2,0,2],["getAppRuntimeState",0,2,0,4],["setSnapshotEnabled",1,2,3,4],["getSnapshotEnabled",0,2,3,4],["getContentSnapshotAsBase64",0,2,3,4]],0,0,0,[["SnapshotImageReady",0,3,"65547",65,66,66],["VisibilityChanged",0,0,"65539",65,66,66]],"Microsoft.AppRuntime.AppRuntimeService",4],[7,0,0,0,[[67,0,0,0,2,0,4],[68,0,0,0,2,0,4],["getOfficeThemeDataForVisualSurface",1,2,0,5]],0,0,0,[["OfficeThemeChanged",2,0,"65548",65,67,68]],"Microsoft.Theme.ThemeService",4],[8,0,0,0,[["getEnterpriseUserInfo",0,2,0,5],["getMruFriendlyPath",1,2,0,5],["launchFileUrlInOfficeApp",2,2,0,5],["performLocalSearch",4,2,0,5],["readSearchCache",3,2,0,5],["writeSearchCache",3,2,0,5]],0,0,0,0,"Microsoft.TapRichApi.Tap",4],[9,0,[[69,3],[70,3]],0,[["items",0,2,0,4]],[["getPersonaForMember",18,1,2,0,4]]],[10,0,0,0,[["addContact",0,0,0,2,0,5],["editContact",0,0,0,2,0,5],["composeEmail",1,0,0,2,0,5],["composeInstantMessage",1,0,0,2,0,5],["callPhoneNumber",1,0,0,2,0,5],["pinPersonaToQuickContacts",0,0,0,2,0,5],["toggleTagForAlerts",0,0,0,2,0,5],["scheduleMeeting",0,0,0,2,0,5],["openLinkContactUx",0,0,0,2,0,5],["editContactByIdentifier",1,0,0,2,0,5],["showHoverCardForPersona",6,0,0,2,0,5],["hideHoverCardForPersona",0,0,0,2,0,5],["showContextMenu",6,0,0,2,0,5],["showContactCard",6,0,0,2,0,5],["showExpandedCard",6,0,0,2,0,5],["openGroupCalendar",0,0,0,2,0,5],["subscribeToGroup",0,0,0,2,0,5],["unsubscribeFromGroup",0,0,0,2,0,5],["getChangePhotoUrlAndOpenInBrowser",0,0,0,2,0,5],["startAudioCall",0,0,0,2,0,5],["startVideoCall",0,0,0,2,0,5],["openOutlookProperties",0,0,0,2,0,5],["editUnifiedGroup",0,0,0,2,0,5],["joinUnifiedGroup",0,0,0,2,0,5],["leaveUnifiedGroup",0,0,0,2,0,5]]],[11,0,[[71,3],[72,3],[73,3],[74,3],[75,3],[76,3],[77,3],[78,3],[79,3],[80,3],[81,3],[82,3],[83,3],[84,3],["phones",3],["addresses",3],[85,3],[86,3]]],[12,0,[[71,3],[72,3],[73,3],[74,3],[75,11],[76,11],[77,3],[78,3],[79,3],[80,3],[81,3],[82,3],[83,3],[84,3],[85,3],[86,3],["isPersonResolved",3]],[["sources",11,3,0,0,4]],[["getPhones",0,2,0,4],["getAddresses",0,2,0,4]]],[13,0,[["availability",3],["status",3],["isSelf",3],["isTagged",3],["customStatusString",3],["isBlocked",3],["presenceTooltip",3],["isOutOfOffice",3],["outOfOfficeNote",3],["timezone",3],["meetingLocation",3],["meetingSubject",3],["timezoneBias",3],["idleStartTime",11],["overallCapability",3],["isOnBuddyList",3],["presenceNote",3],["voiceMailUri",3],["availabilityText",3],["availabilityTooltip",3],["isDurationInAvailabilityText",3],["freeBusyStatus",3],["calendarState",3],["presence",3]]],[14,0,0,0,[[87,1,2,0,4,87],[88,1,0,0,2,88,5],[89,1,2,0,4,89],[90,1,2,0,4,90]]],[15,1,0,0,[[91,0,2,0,4]],[[92,18,1,18,0,4]],0,18],[16,0,[[69,3],[70,3]],[["hierarchy",15,18,0,0,4],["manager",18,2,0,0,4],["directReports",15,18,0,0,4]]],[17,0,[["description",1,0,0,2,5],["oneDrive",1,0,0,2,5],["oneNote",1,0,0,2,5],["isPublic",1,0,0,2,5],["amIOwner",1,0,0,2,5],["amIMember",1,0,0,2,5],["amISubscribed",1,0,0,2,5],["memberCount",1,0,0,2,5],["ownerCount",1,0,0,2,5],["hasGuests",1,0,0,2,5],["site",1,0,0,2,5],["planner",1,0,0,2,5],["classification",1,0,0,2,5],["subscriptionEnabled",1,0,0,2,5]]],[18,4,[["hostId",3],["type",3],["capabilities",3],["diagnosticId",3],[93,3]],[["photo",14,3,0,0,4],["personaInfo",12,3,0,0,4],["unifiedCommunicationInfo",13,3,0,0,4],["organization",16,3,0,0,4],["unifiedGroupInfo",17,35,0,0,4],["actions",10,2,0,0,4]],[["getCustomizations",0,2,0,4],["warmup",1,0,0,2,0,5],[94,0,0,0,2,0,5],["getViewableSources",0,2,0,4],["reportTimeForRender",2,0,0,2,0,5]],[["getMembers",9,0,2,0,4],["getMembership",9,0,2,0,4]]],[19,0,[[93,3]],0,[["getPolicies",0,2,0,4],[95,0,0,0,2,0,5],[96,0,0,0,2,0,5],["getTextScaleFactor",0,2,0,4]],[["getPersona",18,1,2,0,4],["getPersonaForOrgEntry",18,4,2,0,4],["getPersonaForOrgByEntryId",18,4,2,0,4]],0,0,[["PersonaUpdated",0,0,"MessageType.personaLifetimePersonaUpdatedEvent",97,95,96]]],[20,0,[["emailOrUpn",3],[93,3]],0,[["requestToken",0,0,0,2,0,5],[98,0,0,0,2,0,5],[99,0,0,0,2,0,5],["requestIdentityUniqueId",0,0,0,2,0,5],[100,0,0,0,2,0,5],[101,0,0,0,2,0,5],["requestClientAccessToken",0,0,0,2,0,5],[102,0,0,0,2,0,5],[103,0,0,0,2,0,5]],0,0,0,[["ClientAccessTokenAvailable",0,0,"MessageType.lokiTokenProviderClientAccessTokenAvailableEvent",97,102,103],["IdentityUniqueIdAvailable",0,0,"MessageType.lokiTokenProviderIdentityUniqueIdAvailableEvent",97,100,101],["LokiTokenAvailable",0,0,"MessageType.lokiTokenProviderLokiTokenAvailableEvent",97,98,99]]],[21,0,0,0,0,[[104,20,1,2,0,4]],0,0,0,"Microsoft.People.LokiTokenProviderFactory",4],[22,0,0,0,[[94,1,0,0,2,0,5],["accountEmailOrUpn",1,2,0,4],["getPersonaPolicies",0,2,0,4]],[[104,20,1,2,0,4],["getPersonaLifetime",19,1,2,0,4],["getInitialPersona",18,1,2,0,4]],0,0,0,"Microsoft.People.ServiceContext",4],[23,0,0,0,[["isAddChangePhotoLinkOnLpcPersonaImageFlightEnabled",0,2,0,4]],0,0,0,0,"Microsoft.People.RichapiPcxFeatureChecks",4],[24,0,[[62,3],["text",1,0,0,2,5],["created",11],["level",3],["resolved",1,0,0,2,5],["author",3],["mentions",3]],[["parent",24,2,0,0,4],["parentOrNullObject",24,2,0,0,4],["replies",25,19,0,0,4]],[["getRichText",1,2,0,4],["setRichText",2,0,0,2,0,5],["delete",0,0,0,2,0,5]],[["getParentOrSelf",24,0,2,0,4],["reply",24,2,0,0,2,0,0,5]]],[25,1,0,0,[[91,0,2,0,4]],[[92,24,1,18,0,4]],0,24],[26,0,0,0,[["launchExtensionComponent",3,2,0,5]],0,0,0,0,"Microsoft.OfficeSharedApi.ExtensionLifeCycle",4],[27,0,0,0,[["bindServiceToProfile",3,0,0,2,0,5]],0,0,0,0,"Microsoft.OfficeServicesManager.OfficeServicesManagerApi",4],[28,0,0,0,[["getLocaleDateTimeFormattingInfo",1,2,0,4],["formatDateTimeString",3,2,0,4]],0,0,0,0,"Microsoft.LocaleApi.LocaleApi",4],[29,0,0,0,[["displayDialog",2,2,0,5],[59,0,2,0,5]],0,0,0,[["DialogMessage",2,0,"65536",65,66,66]],"Microsoft.FirstPartyDialog.FirstPartyDialogService",4],[30,0,0,[["buttons",33,19,0,0,4]],[["executeRequestUpdate",1,2,0,4],["executeRequestCreate",1,2,6,4]],[["getButton",32,1,2,0,4],["getTab",31,1,2,0,4]],0,0,0,"Microsoft.DynamicRibbon.DynamicRibbon",4],[31,0,[[62,3]],0,[["setVisibility",1,0,0,2,0,7]]],[32,0,[[62,3],["enabled",1,0,0,2,7],["label",3]],0,[["setEnabled",1,0,0,2,0,7]]],[33,1,0,0,[[91,0,2,0,4]],[[92,32,1,18,0,4]],0,32],[34,0,0,0,[["getServiceUrl",2,2,0,4]],0,0,0,0,"Microsoft.DesktopCompliance.ServiceUrlProvider",4],[35,0,0,0,[["isEnabledForOffice",0,2,0,4],["recordLinkedInSettingsCompliance",2,0,0,2,0,5]],0,0,0,0,"Microsoft.DesktopCompliance.LinkedIn",4],[36,0,0,0,[["isInOnlineMode",0,2,0,4],["isInDisconnectedMode",0,2,0,4]],0,0,0,0,"Microsoft.DesktopCompliance.NetworkUsage",4],[37,0,0,0,[["enable",0,2,0,4],["disable",0,2,0,4]],0,0,0,[["BeforeCloseNotificationCancelled",0,0,"65540",65,66,66]],"Microsoft.BeforeDocumentCloseNotification.BeforeDocumentCloseNotification",4],[38,4,0,[["roamingSettings",40,2,0,0,4]],[["getAccessToken",2,2,0,5],["getPrimaryIdentityInfo",0,2,8,5],["getIdentities",0,2,9,5],[105,0,0,10,3,0,4],[106,0,0,10,3,0,4]],0,0,0,[["IdentityChanged",0,10,"65545",65,105,106],["TokenReceived",2,8,"3001","this._targetId",66,66]],"Microsoft.Authentication.AuthenticationService",4],[39,0,[[62,3],["value",1,0,0,2,4]]],[40,0,0,0,0,[[92,39,1,2,0,4],["getItemOrNullObject",39,1,2,0,4]]],[41,0,0,0,[["getSharedFilePickerResponse",1,2,0,4]],0,0,0,0,"Microsoft.Office.SharedFilePicker",4],[42,0,0,0,[["getShortcuts",0,2,0,4],["replaceShortcuts",1,0,0,2,0,4],["areShortcutsInUse",1,0,0,2,0,4]],0,0,0,0,"Microsoft.Office.ActionService",4],[43,0,0,0,[["getAccessTokenFirstPartyOAuth",2,2,0,5]],0,0,0,0,"Microsoft.Office.Auth",5],[44,0,0,0,[["sendMessage",1,2,0,5],[107,0,2,0,5],[108,0,2,0,5]],0,0,0,[["HostMessageReceived",0,0,"AugLoopEventType.onHostMessageReceivedEvent",65,107,108]],"Microsoft.Office.AugLoopEventService",5],[45,0,0,0,[["undo",0,0,0,3,0,5],[109,0,2,0,5],[110,0,2,0,5],["startCopilotOperation",1,0,0,3,0,5],["endCopilotOperation",1,0,0,3,0,5]],0,0,0,[["CopilotOperationStarted",0,0,"UndoType.onCopilotOperationStartedEvent",65,66,66],["UndoStackChanged",0,0,"UndoType.onUndoStackChangedEvent",65,109,110]],"Microsoft.Office.UndoService",5],[46,0,0,0,[["collectUserFeedback",4,2,0,5],[111,0,2,0,5],[112,0,2,0,5],["canCollectUserFeedback",0,2,0,5],[113,0,2,0,5],[114,0,2,0,5],["getInitializationData",0,2,0,5],["getHostScreenshot",0,2,0,5],["invokeDiagnosticsLogsUpload",1,2,0,5],["canCollectCopilotFeedback",0,2,0,5],["collectFeedbackEligibility",0,2,0,5],["checkFeedbackEligibility",1,2,0,5]],0,0,0,[["UserFeedbackResponse",0,0,"UserFeedbackEventType.onUserFeedbackResponseEvent",65,113,114],["UserFeedbackUIDismissed",0,0,"UserFeedbackEventType.onUserFeedbackUIDismissedEvent",65,111,112]],"Microsoft.Office.UserFeedbackService",5],[47,0,0,0,[["addNotification",2,0,0,3,0,1],["updateNotification",2,0,0,3,0,1],["removeNotification",1,0,0,3,0,1]],0,0,0,0,"Microsoft.Office.NotificationService",5],[48,0,0,0,[["getLabel",0,0,0,3,0,11],["tryUpgradeLabel",2,0,0,3,0,11],["getHighestSensitivityLabel",1,0,0,3,0,11],[115,0,2,0,5],[116,0,2,0,5],["getSensitivityResultDetails",2,0,12,3,0,13],["getSensitivityResultDetailsByStringErrorCode",2,0,14,3,0,15]],0,0,0,[["LabelChanged",0,0,"SensitivityLabelEventType.onLabelChangedEvent",65,115,116]],"Microsoft.Office.SensitivityService",5],[49,0,0,0,[["launchHelpPaneByQuery",1,0,0,3,0,16],["launchHelpPaneByArticleId",1,0,0,3,0,16],["launchHelpPaneByArticleIdString",1,0,0,3,0,16],["launchTaskPaneByAgentId",1,0,17,3],["getWindowClientWidth",0,0,0,3,0,16]],0,0,0,0,"Microsoft.Office.CopilotService",5],[50,0,0,0,[[117,1,0,0,3,0,18],[118,0,2,0,5],[119,0,2,0,5]],0,0,0,[["OnPrivateEvent",0,0,"PrivateApiEventType.onPrivateEvent",65,118,119]],"Microsoft.Office.PrivateApiService",5],[51,0,0,0,[["executePythonCode",1,0,0,3,0,19],["executePythonCodeAsync",1,0,0,3,0,19],[120,0,0,0,3,0,19],[121,0,0,0,3,0,19],["executePythonCodeAsync2",2,0,0,3,0,19],["sendRequestAsync",4,2,0,5],[122,0,2,0,5],[123,0,2,0,5],["getRuntimeInfoAsync",0,2,0,5],[124,0,0,0,3,0,19],[125,0,0,0,3,0,19],["getRuntimeInfoAsync2",1,2,0,5]],0,0,0,[["ExternalCodeExecutionCompleted",2,0,"65551",65,120,121],["ExternalCodeServiceRequestCompleted",2,0,"65553",65,122,123],["ExternalCodeServiceResult",2,0,"65554",65,124,125]],"Microsoft.Office.ExternalCodeService",5],[52,0,0,0,[["show",2,0,0,3,0,4],["hide",1,0,0,3,0,4]],0,0,0,0,"Microsoft.Office.BusinessBarService",5],[53,0,0,0,[["launchSimpleDialog",8,0,0,3]],0,0,0,0,"Microsoft.Office.ShowSimpleDialog",5],[54,0,0,0,[[117,2,2,0,5]],0,0,0,0,"Microsoft.Office.DispatchApiService",5],[55,0,0,0,[["requestPermissions",1,2,0,5]],0,0,0,0,"Microsoft.Office.DevicePermissionService",5],[56,0,0,0,[["notifyHeaderLoaded",0,0,0,3,0,20],[59,0,0,0,3,0,20],["move",0,0,0,3,0,20],["setWidth",1,0,0,2,0,20]],0,0,0,0,"Microsoft.Office.TaskpaneService",4],[57,0,0,0,[["invokeAction",4,2,0,5],[126,0,2,0,5],[127,0,2,0,5]],0,0,0,[["ReplyReceived",2,0,"65555",65,126,127]],"Microsoft.Office.AddinSkillActionService",5],[58,0,0,0,[["launchStoreDialogWithCopilotAgentPageShown",0,0,0,3],["refreshAcquisitionState",0,0,0,1],["getAcquisitionState",0,0,0,1],[128,0,2,0,5],[129,0,2,0,5],[130,0,2,0,5],[131,0,2,0,5]],0,0,0,[["CopilotAgentEvent",0,0,"CopilotAgentEventType.onCopilotAgentEvent",65,128,129],["RefreshedAcquisitionStateEvent",0,0,"UnifiedStoreEventType.onRefreshedAcquisitionStateEvent",65,130,131]],"Microsoft.Office.UnifiedStoreService",5]]},targetNamespaceObject:e})}(OfficeCore||(OfficeCore={})),function(e){var t,n;!function(e){e.hidden="Hidden",e.taskpane="Taskpane"}(t=e.VisibilityMode||(e.VisibilityMode={})),function(e){e.none="None",e.load="Load"}(n=e.StartupBehavior||(e.StartupBehavior={})),function(e){function r(e){var t=new OfficeCore.RequestContext;return t._requestFlagModifier|=64,e&&(t._customData="WacPartition"),t}function o(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){switch(n.label){case 0:return t=r(!0),OfficeCore.AppRuntimeService.newObject(t).setAppRuntimeState(e),[4,t.sync()];case 1:return n.sent(),[2]}}))}))}var i;e.setStartupBehavior=function(e){return __awaiter(this,void 0,void 0,(function(){var t,o;return __generator(this,(function(i){switch(i.label){case 0:if(e!==n.load&&e!==n.none)throw OfficeExtension.Utility.createRuntimeError(OfficeExtension.ErrorCodes.invalidArgument,null,null);return t=e==n.load?OfficeCore.AppRuntimeState.background:OfficeCore.AppRuntimeState.inactive,o=r(!1),OfficeCore.AppRuntimePersistenceService.newObject(o).setAppRuntimeStartState(t),[4,o.sync()];case 1:return i.sent(),[2]}}))}))},e.getStartupBehavior=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,o,i;return __generator(this,(function(a){switch(a.label){case 0:return e=r(!1),t=OfficeCore.AppRuntimePersistenceService.newObject(e),o=t.getAppRuntimeStartState(),[4,e.sync()];case 1:return a.sent(),i=o.value,[2,i==OfficeCore.AppRuntimeState.inactive?n.none:n.load]}}))}))},e.setSnapshotEnabled=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){switch(n.label){case 0:return t=r(!0),OfficeCore.AppRuntimeService.newObject(t).setSnapshotEnabled(e),[4,t.sync()];case 1:return n.sent(),[2,Promise.resolve()]}}))}))},e.getSnapshotEnabled=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,n;return __generator(this,(function(o){switch(o.label){case 0:return e=r(!0),t=OfficeCore.AppRuntimeService.newObject(e),n=t.getSnapshotEnabled(),[4,e.sync()];case 1:return o.sent(),[2,n.value]}}))}))},e.getContentSnapshotAsBase64=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,new OfficeExtension.CoreUtility.Promise((function(e,t){var n=r(!0),o=OfficeCore.AppRuntimeService.newObject(n),i=setTimeout((function(){a.remove(),n.sync().catch((function(){})),t(OfficeExtension.Utility.createRuntimeError(OfficeExtension.ErrorCodes.generalException,"timeout","getContentSnapshotAsBase64"))}),7e3),a=o.onSnapshotImageReady.add((function(r){return clearTimeout(i),a.remove(),OfficeExtension.CoreUtility.isNullOrUndefined(r)?(n.sync().catch((function(){})),t(OfficeExtension.Utility.createRuntimeError(OfficeExtension.ErrorCodes.generalException,"execution failed","getContentSnapshotAsBase64"))):(n.sync().catch((function(){})),e(r.imageBase64)),null}));n.sync().then((function(){o.getContentSnapshotAsBase64();return n.sync().then((function(){return null}))})).catch((function(e){t(e)}))}))]}))}))},e._getState=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,n;return __generator(this,(function(o){switch(o.label){case 0:return e=r(!0),t=OfficeCore.AppRuntimeService.newObject(e),n=t.getAppRuntimeState(),[4,e.sync()];case 1:return o.sent(),[2,n.value]}}))}))},e.showAsTaskpane=function(){return o(OfficeCore.AppRuntimeState.visible)},e.hide=function(){return o(OfficeCore.AppRuntimeState.background)},e.onVisibilityModeChanged=function(e){return __awaiter(this,void 0,void 0,(function(){var n,o,a=this;return __generator(this,(function(s){switch(s.label){case 0:return n=function(){if(!i){var e=r(!0);i=OfficeCore.AppRuntimeService.newObject(e)}return i}(),o=n.onVisibilityChanged.add((function(n){if(e){var r={visibilityMode:(o=n.visibility,o===OfficeCore.Visibility.visible?t.taskpane:t.hidden)};e(r)}var o;return null})),[4,n.context.sync()];case 1:return s.sent(),[2,function(){return __awaiter(a,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return o.remove(),[4,n.context.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))},function(e){function t(e){var t=new OfficeCore.RequestContext;return t._requestFlagModifier|=64,e&&(t._customData="WacPartition"),t}e.enable=function(){return __awaiter(this,void 0,void 0,(function(){var e,n;return __generator(this,(function(r){switch(r.label){case 0:return e=!1,"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(e=!0),n=t(e),OfficeCore.BeforeDocumentCloseNotification.newObject(n).enable(),[4,n.sync()];case 1:return r.sent(),[2]}}))}))},e.disable=function(){return __awaiter(this,void 0,void 0,(function(){var e,n;return __generator(this,(function(r){switch(r.label){case 0:return e=!1,"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(e=!0),n=t(e),OfficeCore.BeforeDocumentCloseNotification.newObject(n).disable(),[4,n.sync()];case 1:return r.sent(),[2]}}))}))},e.onCloseActionCancelled=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a=this;return __generator(this,(function(s){switch(s.label){case 0:return n=!1,"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(n=!0),r=t(n),o=OfficeCore.BeforeDocumentCloseNotification.newObject(r),i=o.onBeforeCloseNotificationCancelled.add((function(t){return e&&e(),null})),[4,r.sync()];case 1:return s.sent(),[2,function(){return __awaiter(a,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return i.remove(),[4,r.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))}}(e.beforeDocumentCloseNotification||(e.beforeDocumentCloseNotification={}))}(e.addin||(e.addin={}))}(Office||(Office={})),function(e){var t,n;!function(e){e.taskpane="Taskpane",e.dialog="Dialog"}(t||(t={})),function(n){function r(e){return new OfficeCore.RequestContext}!function(e){function t(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}e.close=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(n){switch(n.label){case 0:return e=t(),OfficeCore.TaskpaneService.newObject(e).close(),[4,e.sync()];case 1:return n.sent(),[2]}}))}))},e.move=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(n){switch(n.label){case 0:return e=t(),OfficeCore.TaskpaneService.newObject(e).move(),[4,e.sync()];case 1:return n.sent(),[2]}}))}))},e.notifyHeaderLoaded=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(n){switch(n.label){case 0:return e=t(),OfficeCore.TaskpaneService.newObject(e).notifyHeaderLoaded(),[4,e.sync()];case 1:return n.sent(),[2]}}))}))},e.setWidth=function(e){return __awaiter(this,void 0,void 0,(function(){var n;return __generator(this,(function(r){switch(r.label){case 0:return n=t(),OfficeCore.TaskpaneService.newObject(n).setWidth(e),[4,n.sync()];case 1:return r.sent(),[2]}}))}))}}(n.taskpane||(n.taskpane={})),n.launchTaskpane=function(n){return __awaiter(this,void 0,void 0,(function(){var o,i,a,s,c;return __generator(this,(function(u){switch(u.label){case 0:return e.context.platform&&"OfficeOnline"===e.context.platform?(o={SharedRuntimeId:n.sharedRuntimeId,SourceLocationOverrideResourceId:n.sourceLocationOverride,TaskPaneTitle:n.taskpaneTitle,TaskPaneWidth:n.taskpaneWidth},i={OptionalProperties:o,DevProperties:n.settings},e.context.extensionLifeCycle.launchExtensionComponent(null,"Taskpane",null,null,i),[3,3]):[3,1];case 1:return a=r(),s=OfficeCore.ExtensionLifeCycle.newObject(a),c=n.settings,n.settings=c&&OSF.OUtil.serializeSettings(c),s.launchExtensionComponent("",t.taskpane,n),[4,a.sync()];case 2:u.sent(),u.label=3;case 3:return[2]}}))}))},n.launchDialog=function(n){return __awaiter(this,void 0,void 0,(function(){var o,i,a,s,c;return __generator(this,(function(u){switch(u.label){case 0:return e.context.platform&&"OfficeOnline"===e.context.platform?(o={SharedRuntimeId:n.sharedRuntimeId,SourceLocationOverrideResourceId:n.sourceLocationOverride},i={OptionalProperties:o,DevProperties:n.settings},e.context.extensionLifeCycle.launchExtensionComponent(null,"SDXDialog",null,null,i),[3,3]):[3,1];case 1:return a=r(),s=OfficeCore.ExtensionLifeCycle.newObject(a),c=n.settings,n.settings=c&&OSF.OUtil.serializeSettings(c),s.launchExtensionComponent("",t.dialog,n),[4,a.sync()];case 2:u.sent(),u.label=3;case 3:return[2]}}))}))}}(n=e.ExtensionLifeCycle||(e.ExtensionLifeCycle={})),e.extensionLifeCycle=n}(Office||(Office={})),function(e){!function(e){function t(){var e=new OfficeCore.RequestContext;return"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(e._customData="WacPartition"),e}e.requestUpdate=function(e){var n=t(),r=n.ribbon;function o(e){void 0!==e.controls&&void 0!==e.controls.length&&e.controls.length&&e.controls.filter((function(e){return!!e.id})).forEach((function(e){var t=r.getButton(e.id);void 0!==e.enabled&&null!==e.enabled&&(t.enabled=e.enabled)}))}return e.tabs.filter((function(e){return!!e.id})).forEach((function(e){var t=r.getTab(e.id);void 0!==e.visible&&null!==e.visible&&t.setVisibility(e.visible),e.groups&&e.groups.length?e.groups.filter((function(e){return!!e.id})).forEach((function(e){o(e)})):o(e)})),n.sync()},e.requestCreateControls=function(e){var n,r=t();return r.ribbon.executeRequestCreate(JSON.stringify(e)),(n=250,new Promise((function(e,t){return setTimeout((function(){return e()}),n)}))).then((function(){return r.sync()}))}}(e.ribbon||(e.ribbon={}))}(Office||(Office={})),function(e){!function(e){e.requestUpdate=function(e){if(OfficeExtension&&OfficeExtension.Utility&&!OfficeExtension.Utility.isSetSupported("ContextMenuApi","1.1"))throw OfficeExtension.Utility.createRuntimeError(OfficeCore.ErrorCodes.apiNotAvailable,null,null);var t,n=(t=new OfficeCore.RequestContext,"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(t._customData="WacPartition"),t),r=n.ribbon;return e.controls.filter((function(e){return!!e.id})).forEach((function(e){var t=r.getButton(e.id);void 0!==e.enabled&&null!==e.enabled&&(t.enabled=e.enabled)})),n.sync()}}(e.contextMenu||(e.contextMenu={}))}(Office||(Office={})),function(e){var t;OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject,OfficeExtension.BatchApiHelper.createTopLevelServiceObject,OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod,OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined,OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported,OfficeExtension.Utility.load,OfficeExtension.Utility.retrieve,OfficeExtension.Utility.toJson,OfficeExtension.Utility.fixObjectPathIfNecessary,OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult,OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags;!function(e){e.generalException="GeneralException"}(t||(t={}));new OfficeExtension.LibraryBuilder({metadata:{version:"1.0.0",name:"OfficeCore",defaultApiSetName:"OfficeSharedApi",hostName:"Office",apiSets:[],strings:["AddinInternalService"],enumTypes:[],clientObjectTypes:[[1,0,0,0,[["notifyActionHandlerReady",0,2,0,4]],0,0,0,0,"Microsoft.InternalService.AddinInternalService",4]]},targetNamespaceObject:e})}(OfficeCore||(OfficeCore={})),function(e){var t;!function(t){var n,r,o=OfficeExtension.Utility.isNullOrUndefined;function i(e){if(e){var t=e.toUpperCase(),r=n.mappings[t];if(!o(r)&&"function"==typeof r)return r}throw OfficeExtension.Utility.createRuntimeError("invalidOperation","sourceData","ActionProxy._getFunction")}function a(e,t,n,r){var i=OSF._OfficeAppFactory.getHostInfo();if(i&&"web"===i.hostPlatform.toLowerCase())OSF._OfficeAppFactory.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[OSF._OfficeAppFactory.getId(),OSF.AgaveHostAction.ReportAddinSkillResult,{actionCorrelationId:e,resultCode:t,replyMessage:r}]);else{if(o(window.external))throw new OfficeExtension.Error({code:"GenericException",message:"API currently unsupported."});var a=o(OSF.MethodDispId)?OSF.DDA.MethodDispId.dispidAddinSkillActionReply:OSF.MethodDispId.dispidAddinSkillActionReply;window.external.Execute(a,[e,r,t],null)}!function(e,t){Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:e,dataFields:t,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage,diagnosticLevel:oteljs.DiagnosticLevel.Optional,samplingPolicy:oteljs.SamplingPolicy.CriticalBusinessImpact}})}("Office.Extensibility.OfficeJs.AddinSkill.ExecuteAction",[oteljs.makeStringDataField("CorrelationId",e),oteljs.makeStringDataField("Message",n),oteljs.makeInt64DataField("ResultCode",t)])}function s(e){try{OfficeExtension.Utility.log("ActionProxy._handleMessage"),OfficeExtension.Utility.checkArgumentNull(e,"args");for(var t=e.entries,n=function(e){if(2!==t[e].messageCategory)return"continue";if("string"==typeof t[e].message&&(t[e].message=JSON.parse(t[e].message)),1e3===t[e].messageType){var n=null,r=i(u=t[e].message[0]);if(t[e].message.length>=2){var s=t[e].message[1];s&&(n=function(e){if("string"==typeof e&&"{"===e[0])return!0;return!1}(s)?JSON.parse(s):s)}r.apply(null,[n])}else if(1001===t[e].messageType){n=null;var u=t[e].message[0],l=t[e].message[1],f=JSON.parse(l);n=f.message;var p=f.correlationId,d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess,h=null,g="";r=null;try{r=i(u)}catch(e){d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultNoActionFunctionMapping,g="ActionProxy._handleMessage failed to get function",c(e)}if(d==OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess&&r)try{h=r.apply(null,[n])}catch(e){d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvocationFailed,g="ActionProxy._handleMessage failed to execute function",c(e)}if(d==OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess&&o(h)?(d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultNoResultGenerated,g="No result generated"):d!=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess||"object"==typeof h&&"function"==typeof h.then||(d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvalidResultGenerated,g="Invalid result generated"),d==OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess)try{h.then((function(e){g="Successfully executed function",o(e)?(e="",d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultNoResultGenerated,g="No result generated"):"string"!=typeof e&&(e="",d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvalidResultGenerated,g="Invalid result generated"),a(p,d,g,e)}),(function(e){var t="";d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvocationFailed,g="Failed to execute function","string"==typeof e?t=e:c(e),a(p,d,g,t)}))}catch(e){d=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvalidResultGenerated,g="Invalid result generated",c(e),a(p,d,g,"")}else try{a(p,d,g,"")}catch(e){c(e)}}else OfficeExtension.Utility.log("ActionProxy._handleMessage unknown message type "+t[e].messageType)},r=0;r<t.length;r++)n(r)}catch(e){throw c(e),e}return OfficeExtension.Utility._createPromiseFromResult(null)}function c(e){var t=function(e){var t="Unknown Error";if(e)try{e.toString&&(t=e.toString()),t=t+" "+JSON.stringify(e)}catch(e){t="Unexpected Error"}return t}(e);OfficeExtension.Utility.log(t)}function u(){try{Microsoft.Office.WebExtension.onReadyInternal().then((function(){return function(){if(void 0!==OSF&&OSF.DDA&&OSF.DDA.RichApi&&OSF.DDA.RichApi.richApiMessageManager)return(new OfficeExtension.ClientRequestContext).eventRegistration.register(5,"",s)}()})).then((function(){var e,t,n=OSF._OfficeAppFactory.getHostInfo();return!0===n.isDialog||"web"===n.hostPlatform.toLowerCase()&&"word"!==n.hostType&&"excel"!==n.hostType&&"powerpoint"!==n.hostType?void 0:(e=new OfficeExtension.ClientRequestContext,t=OfficeCore.AddinInternalService.newObject(e),e._customData="WacPartition",t.notifyActionHandlerReady(),e.sync())}))}catch(e){}}OfficeExtension.Utility.log("ActionProxy.initOnce"),void 0!==e.actions&&(r=e.actions._association,n=r),"undefined"!=typeof document&&(document.readyState&&"loading"!==document.readyState?(OfficeExtension.Utility.log("ActionProxy.initOnce: document.readyState is not loading state"),u()):document.addEventListener&&document.addEventListener("DOMContentLoaded",(function(){OfficeExtension.Utility.log("ActionProxy.initOnce: DOMContentLoaded event triggered"),u()}))),OfficeExtension.HostBridge.onInited((function(e){!function(e){e.addHostMessageHandler((function(e){3===e.type&&s(e.message)}))}(e)}))}(t||(t={}))}(Office||(Office={})),function(e){!function(e){function t(e){var t=new OfficeCore.RequestContext;return e&&e.controlId&&(t.requestHeaders[OfficeExtension.Constants.officeControlId]=e.controlId),t._customData="WacPartition",t}e.SendMessage=function(e,n){return __awaiter(this,void 0,void 0,(function(){var r,o;return __generator(this,(function(i){switch(i.label){case 0:return r=void 0!==n?n:e,o=t(void 0!==n?e:void 0),OfficeCore.AugLoopEventService.newObject(o).sendMessage(r),[4,o.sync()];case 1:return i.sent(),[2]}}))}))},e.onHostMessageReceived=function(e,n){return __awaiter(this,void 0,void 0,(function(){var r,o,i,a,s=this;return __generator(this,(function(c){switch(c.label){case 0:return r=void 0!==n?n:e,o=t(void 0!==n?e:void 0),i=OfficeCore.AugLoopEventService.newObject(o),a=function(e){if(r){var t=e.data;r(t)}return null},i.onHostMessageReceived.add(a),[4,i.context.sync()];case 1:return c.sent(),[2,function(){return __awaiter(s,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return i.onHostMessageReceived.remove(a),[4,o.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))}}(e.AugLoop||(e.AugLoop={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){function t(e){return"object"==typeof e&&"string"==typeof e.controlId?e.controlId:void 0}function n(e){var t=new OfficeCore.RequestContext;return e&&(t.requestHeaders[OfficeExtension.Constants.officeControlId]=e),t._customData="SkipUndoRecording",t}var r,o={};e.undo=function(e){return __awaiter(this,void 0,void 0,(function(){var r,o,i;return __generator(this,(function(a){switch(a.label){case 0:return r=n(t(e)),o=OfficeCore.UndoService.newObject(r),i=o.undo(),[4,r.sync()];case 1:return a.sent(),[2,i.value]}}))}))},e.onUndoStackChanged=function(e,r){return __awaiter(this,void 0,void 0,(function(){var o,i,a,s=this;return __generator(this,(function(c){switch(c.label){case 0:return o=r||e,i=n(t(r?e:void 0)),(a=OfficeCore.UndoService.newObject(i)).onUndoStackChanged.add(o),[4,i.sync()];case 1:return c.sent(),[2,function(){return __awaiter(s,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return a.onUndoStackChanged.remove(o),[4,i.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))},e.startCopilotOperation=function(e){return __awaiter(this,void 0,void 0,(function(){var i,a,s,c,u,l,f,p;return __generator(this,(function(d){switch(d.label){case 0:if(void 0===(i=t(e))){if(void 0!==r)throw new Error("startCopilotOperation is already inprogress")}else if(o[i])throw new Error("startCopilotOperation is already in progress");a=function(){},s=new Promise((function(e){void 0===i?r=e:o[i]=e})),d.label=1;case 1:return d.trys.push([1,4,,5]),c=n(i),u=OfficeCore.UndoService.newObject(c),l=function(){return function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){return void 0===e?void 0!==r&&(r(),r=void 0):o[e]&&(o[e](),delete o[e]),[2]}))}))}(i)},a=function(){try{u.onCopilotOperationStarted.remove(l),c.sync()}catch(e){}},u.onCopilotOperationStarted.add(l),[4,c.sync()];case 2:return d.sent(),f=u.startCopilotOperation(""),[4,c.sync()];case 3:return d.sent(),f.value?(void 0!==i&&s.then((function(){a()})),[2,s]):(void 0===i?r=void 0:(a(),delete o[i]),[3,5]);case 4:throw p=d.sent(),void 0===i?r=void 0:(a(),delete o[i]),p;case 5:return[2]}}))}))},e.endCopilotOperation=function(e){return __awaiter(this,void 0,void 0,(function(){var r;return __generator(this,(function(o){switch(o.label){case 0:return r=n(t(e)),OfficeCore.UndoService.newObject(r).endCopilotOperation(""),[4,r.sync()];case 1:return o.sent(),[2]}}))}))}}(e.Undo||(e.Undo={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){var t;(t=e.dialogPage||(e.dialogPage={})).close=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:return e=new OfficeCore.RequestContext,OfficeCore.DialogPage.newObject(e).close(),[4,e.sync()];case 1:return t.sent(),[2]}}))}))},t.readyToShow=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:return e=new OfficeCore.RequestContext,OfficeCore.DialogPage.newObject(e).readyToShow(),[4,e.sync()];case 1:return t.sent(),[2]}}))}))},t.onShow=function(e){return __awaiter(this,void 0,void 0,(function(){var t,n,r;return __generator(this,(function(o){switch(o.label){case 0:return t=new OfficeCore.RequestContext,(n=OfficeCore.DialogPage.newObject(t)).onOnShowEvent.add(e),r=function(){return n.onOnShowEvent.remove(e),null},[4,t.sync()];case 1:return o.sent(),[2,r]}}))}))},t.sendMessageToHost=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){switch(n.label){case 0:return t=new OfficeCore.RequestContext,OfficeCore.DialogPage.newObject(t).sendMessageToHost(e),[4,t.sync()];case 1:return n.sent(),[2]}}))}))}}(Office||(Office={})),function(e){!function(e){function t(e){var t=new OfficeCore.RequestContext;return t._customData="WacPartition",t}e.CollectUserFeedback=function(e,n,r,o){return __awaiter(this,void 0,void 0,(function(){var i;return __generator(this,(function(a){switch(a.label){case 0:return i=t(),OfficeCore.UserFeedbackService.newObject(i).collectUserFeedback(e,n,r,o),[4,i.sync()];case 1:return a.sent(),[2]}}))}))},e.onUserFeedbackUIDismissed=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r,o,i=this;return __generator(this,(function(a){switch(a.label){case 0:return n=function(t){if(e){var n=t.isFeedbackSent;e(n)}return null},r=t(),(o=OfficeCore.UserFeedbackService.newObject(r)).onUserFeedbackUIDismissed.add(n),[4,o.context.sync()];case 1:return a.sent(),[2,function(){return __awaiter(i,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return o.onUserFeedbackUIDismissed.remove(n),[4,r.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))},e.CanCollectUserFeedback=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,r;return __generator(this,(function(o){switch(o.label){case 0:return e=t(),n=OfficeCore.UserFeedbackService.newObject(e),r=n.canCollectUserFeedback(),[4,e.sync()];case 1:return o.sent(),[2,r.value]}}))}))},e.onUserFeedbackResponse=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r,o,i=this;return __generator(this,(function(a){switch(a.label){case 0:return n=function(t){if(e){var n=t.responseData;e(n)}return null},r=t(),(o=OfficeCore.UserFeedbackService.newObject(r)).onUserFeedbackResponse.add(n),[4,o.context.sync()];case 1:return a.sent(),[2,function(){return __awaiter(i,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return o.onUserFeedbackResponse.remove(n),[4,r.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))},e.InvokeDiagnosticsLogsUpload=function(e){return __awaiter(this,void 0,void 0,(function(){var n;return __generator(this,(function(r){switch(r.label){case 0:return n=t(),OfficeCore.UserFeedbackService.newObject(n).invokeDiagnosticsLogsUpload(e),[4,n.sync()];case 1:return r.sent(),[2]}}))}))},e.GetInitializationData=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,r;return __generator(this,(function(o){switch(o.label){case 0:return e=t(),n=OfficeCore.UserFeedbackService.newObject(e),r=n.getInitializationData(),[4,e.sync()];case 1:return o.sent(),[2,r.value]}}))}))},e.GetHostScreenshot=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,r;return __generator(this,(function(o){switch(o.label){case 0:return e=t(),n=OfficeCore.UserFeedbackService.newObject(e),r=n.getHostScreenshot(),[4,e.sync()];case 1:return o.sent(),[2,r.value]}}))}))},e.CanCollectCopilotFeedback=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,r;return __generator(this,(function(o){switch(o.label){case 0:return e=t(),n=OfficeCore.UserFeedbackService.newObject(e),r=n.canCollectCopilotFeedback(),[4,e.sync()];case 1:return o.sent(),[2,r.value]}}))}))},e.CollectFeedbackEligibility=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,r;return __generator(this,(function(o){switch(o.label){case 0:return e=t(),n=OfficeCore.UserFeedbackService.newObject(e),r=n.collectFeedbackEligibility(),[4,e.sync()];case 1:return o.sent(),[2,r.value]}}))}))},e.CheckFeedbackEligibility=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r,o;return __generator(this,(function(i){switch(i.label){case 0:return n=t(),r=OfficeCore.UserFeedbackService.newObject(n),o=r.checkFeedbackEligibility(e),[4,n.sync()];case 1:return i.sent(),[2,o.value]}}))}))}}(e.UserFeedback||(e.UserFeedback={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){var t=function(){};function n(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}function r(e){return JSON.stringify(e instanceof t?{type:"callout",params:e.params}:{type:"custom",props:e})}e.callout=function(e){var n=new t;return n.params=e,n},e.addNotification=function(e,t){return __awaiter(this,void 0,void 0,(function(){var o,i,a;return __generator(this,(function(s){switch(s.label){case 0:return o=n(),i=OfficeCore.NotificationService.newObject(o),a=i.addNotification(r(e),function(e){return JSON.stringify(e)}(t)),[4,o.sync()];case 1:return s.sent(),[2,a.value]}}))}))},e.updateNotification=function(e,t){return __awaiter(this,void 0,void 0,(function(){var o;return __generator(this,(function(i){switch(i.label){case 0:return o=n(),OfficeCore.NotificationService.newObject(o).updateNotification(e,r(t)),[4,o.sync()];case 1:return i.sent(),[2]}}))}))},e.removeNotification=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(r){switch(r.label){case 0:return t=n(),OfficeCore.NotificationService.newObject(t).removeNotification(e),[4,t.sync()];case 1:return r.sent(),[2]}}))}))}}(e.Notification||(e.Notification={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){function t(e){var t=new OfficeCore.RequestContext;return e&&e.controlId&&(t.requestHeaders[OfficeExtension.Constants.officeControlId]=e.controlId),t._customData="WacPartition",t}e.getLabel=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r,o;return __generator(this,(function(i){switch(i.label){case 0:return n=t(e),r=OfficeCore.SensitivityService.newObject(n),o=r.getLabel(),[4,n.sync()];case 1:return i.sent(),[2,o.value]}}))}))},e.tryUpgradeLabel=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a;return __generator(this,(function(s){switch(s.label){case 0:if(n=3===e.length,2!==e.length&&3!==e.length)throw new Error("tryUpgradeLabel: Invalid number of parameters ("+e.length+")");return r=n?e[0]:void 0,o=n?e[1]:e[0],i=n?e[2]:e[1],a=t(r),OfficeCore.SensitivityService.newObject(a).tryUpgradeLabel(o,i),[4,a.sync()];case 1:return s.sent(),[2]}}))}))},e.getHighestSensitivityLabel=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a,s;return __generator(this,(function(c){switch(c.label){case 0:if(n=2===e.length,1!==e.length&&2!==e.length)throw new Error("getHighestSensitivityLabel: Invalid number of parameters ("+e.length+")");return r=n?e[0]:void 0,o=n?e[1]:e[0],i=t(r),a=OfficeCore.SensitivityService.newObject(i),s=a.getHighestSensitivityLabel(o),[4,i.sync()];case 1:return c.sent(),[2,s.value]}}))}))},e.getSensitivityResultDetails=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a,s,c;return __generator(this,(function(u){switch(u.label){case 0:if(n=3===e.length,2!==e.length&&3!==e.length)throw new Error("getSensitivityResultDetails: Invalid number of parameters ("+e.length+")");return r=n?e[0]:void 0,o=n?e[1]:e[0],i=n?e[2]:e[1],a=t(r),s=OfficeCore.SensitivityService.newObject(a),c=s.getSensitivityResultDetails(o,i),[4,a.sync()];case 1:return u.sent(),[2,c.value]}}))}))},e.getSensitivityResultDetailsByStringErrorCode=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a,s,c;return __generator(this,(function(u){switch(u.label){case 0:if(n=3===e.length,2!==e.length&&3!==e.length)throw new Error("getSensitivityResultDetails: Invalid number of parameters ("+e.length+")");return r=n?e[0]:void 0,o=n?e[1]:e[0],i=n?e[2]:e[1],a=t(r),s=OfficeCore.SensitivityService.newObject(a),c=s.getSensitivityResultDetailsByStringErrorCode(o,i),[4,a.sync()];case 1:return u.sent(),[2,c.value]}}))}))},e.onLabelChangedEvent=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a,s,c=this;return __generator(this,(function(u){switch(u.label){case 0:if(n=2===e.length,1!==e.length&&2!==e.length)throw new Error("onLabelChangedEvent: Invalid number of parameters ("+e.length+")");return r=n?e[0]:void 0,o=n?e[1]:e[0],i=function(e){if(o){var t=e.previousLabel,n=e.newLabel,r=e.context,i=e.error;o(t,n,r,i)}return null},a=t(r),(s=OfficeCore.SensitivityService.newObject(a)).onLabelChanged.add(i),[4,s.context.sync()];case 1:return u.sent(),[2,function(){return __awaiter(c,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return s.onLabelChanged.remove(i),[4,a.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))}}(e.Sensitivity||(e.Sensitivity={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){function t(e){var t=new OfficeCore.RequestContext;return t._customData="WacPartition",t}e.launchHelpPaneByQuery=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r;return __generator(this,(function(o){switch(o.label){case 0:return n=t(),r=OfficeCore.CopilotService.newObject(n),r.launchHelpPaneByQuery(e),[4,n.sync()];case 1:return o.sent(),[2]}}))}))},e.launchHelpPaneByArticleId=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r;return __generator(this,(function(o){switch(o.label){case 0:return n=t(),r=OfficeCore.CopilotService.newObject(n),r.launchHelpPaneByArticleId(e),[4,n.sync()];case 1:return o.sent(),[2]}}))}))},e.launchHelpPaneByArticleIdString=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r;return __generator(this,(function(o){switch(o.label){case 0:return n=t(),r=OfficeCore.CopilotService.newObject(n),r.launchHelpPaneByArticleIdString(e),[4,n.sync()];case 1:return o.sent(),[2]}}))}))},e.launchTaskPaneByAgentId=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r;return __generator(this,(function(o){switch(o.label){case 0:return n=t(),r=OfficeCore.CopilotService.newObject(n),r.launchTaskPaneByAgentId(e),[4,n.sync()];case 1:return o.sent(),[2]}}))}))},e.getWindowClientWidth=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,r;return __generator(this,(function(o){switch(o.label){case 0:return e=t(),n=OfficeCore.CopilotService.newObject(e),r=n.getWindowClientWidth(),[4,e.sync()];case 1:return o.sent(),[2,r.value]}}))}))}}(e.Copilot||(e.Copilot={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){function t(e){var t=new OfficeCore.RequestContext;return e&&e.controlId&&(t.requestHeaders[OfficeExtension.Constants.officeControlId]=e.controlId),t._customData="WacPartition",t}e.execute=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a,s;return __generator(this,(function(c){switch(c.label){case 0:return n=e.length>=2,r=n?e[0]:void 0,o=n?e[1]:e[0],i=t(r),a=OfficeCore.PrivateApiService.newObject(i),s=a.execute(o),[4,i.sync()];case 1:return c.sent(),[2,s.value]}}))}))},e.onPrivateEvent=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return __awaiter(this,void 0,void 0,(function(){var n,r,o,i,a,s,c=this;return __generator(this,(function(u){switch(u.label){case 0:return n=e.length>=2,r=n?e[0]:void 0,o=n?e[1]:e[0],i=function(e){if(o){var t=e.messageData;o(t)}return null},a=t(r),(s=OfficeCore.PrivateApiService.newObject(a)).onOnPrivateEvent.add(i),[4,s.context.sync()];case 1:return u.sent(),[2,function(){return __awaiter(c,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return s.onOnPrivateEvent.remove(i),[4,a.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))}}(e.PrivateApi||(e.PrivateApi={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){var t;function n(e){var t=new OfficeCore.RequestContext;return t._customData="WacPartition",t}!function(e){e.copilotAgentsPage="CopilotAgentsPage"}(t=e.DefaultPageType||(e.DefaultPageType={})),function(e){e.activated="Activated",e.removed="Removed"}(e.CopilotAgentActionType||(e.CopilotAgentActionType={})),function(e){e.host="Host",e.api="Api"}(e.RefreshAcquisitionStateTriggerType||(e.RefreshAcquisitionStateTriggerType={})),e.launchStore=function(e){return __awaiter(this,void 0,void 0,(function(){var r,o,i;return __generator(this,(function(a){switch(a.label){case 0:if(e!==t.copilotAgentsPage)throw OfficeExtension.Utility.createRuntimeError(OfficeExtension.ErrorCodes.invalidArgument,null,null);return r=n(),o=OfficeCore.UnifiedStoreService.newObject(r),e!=t.copilotAgentsPage?[3,2]:(i=o.launchStoreDialogWithCopilotAgentPageShown(),[4,r.sync()]);case 1:return a.sent(),[2,i];case 2:return[2]}}))}))},e.refreshAcquisitionState=function(e){return __awaiter(this,void 0,void 0,(function(){var t,r,o;return __generator(this,(function(i){return t=n(),r=OfficeCore.UnifiedStoreService.newObject(t),o=r.refreshAcquisitionState(),t.sync().then((function(){var t=JSON.parse(o.value);e(t)})),[2,null]}))}))},e.getAcquisitionState=function(e){return __awaiter(this,void 0,void 0,(function(){var t,r,o;return __generator(this,(function(i){return t=n(),r=OfficeCore.UnifiedStoreService.newObject(t),o=r.getAcquisitionState(),t.sync().then((function(){var t=JSON.parse(o.value);e(t)})),[2,null]}))}))},e.onCopilotAgentEvent=function(e){return __awaiter(this,void 0,void 0,(function(){var t,r,o,i=this;return __generator(this,(function(a){switch(a.label){case 0:return t=function(t){if(e){var n=JSON.parse(t.messageData),r=n.actionType,o=n.titleId;e({actionType:r,titleId:o})}return null},r=n(),(o=OfficeCore.UnifiedStoreService.newObject(r)).onCopilotAgentEvent.add(t),[4,o.context.sync()];case 1:return a.sent(),[2,function(){return __awaiter(i,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return o.onCopilotAgentEvent.remove(t),[4,r.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))},e.onRefreshedAcquisitionState=function(e){return __awaiter(this,void 0,void 0,(function(){var t,r,o,i=this;return __generator(this,(function(a){switch(a.label){case 0:return t=function(t){if(e){var n=JSON.parse(t.messageData);e(n)}return null},r=n(),(o=OfficeCore.UnifiedStoreService.newObject(r)).onRefreshedAcquisitionStateEvent.add(t),[4,o.context.sync()];case 1:return a.sent(),[2,function(){return __awaiter(i,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return o.onRefreshedAcquisitionStateEvent.remove(t),[4,r.sync()];case 1:return e.sent(),[2]}}))}))}]}}))}))}}(e.UnifiedStore||(e.UnifiedStore={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){function t(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}e.hide=function(e){return __awaiter(this,void 0,void 0,(function(){var n,r;return __generator(this,(function(o){switch(o.label){case 0:return n=t(),r=OfficeCore.BusinessBarService.newObject(n),r.hide(e),[4,n.sync()];case 1:return o.sent(),[2]}}))}))},e.show=function(e,n){return __awaiter(this,void 0,void 0,(function(){var r;return __generator(this,(function(o){switch(o.label){case 0:return r=t(),OfficeCore.BusinessBarService.newObject(r).show(e,n),[4,r.sync()];case 1:return o.sent(),[2]}}))}))}}(e.BusinessBar||(e.BusinessBar={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){e.launchSimpleDialog=function(e){return __awaiter(this,void 0,void 0,(function(){var t,n,r;return __generator(this,(function(o){switch(o.label){case 0:return t=function(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}(),n=OfficeCore.ShowSimpleDialog.newObject(t),r=n.launchSimpleDialog(e.title,e.description,e.telemetryid,e.category,e.hasButton,e.buttonLabel,e.hasCheckbox,e.checkboxLabel),[4,t.sync()];case 1:return o.sent(),[2,r.value]}}))}))}}(e.SimpleDialog||(e.SimpleDialog={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){e.execute=function(e,t){return __awaiter(this,void 0,void 0,(function(){var n,r,o;return __generator(this,(function(i){switch(i.label){case 0:return n=function(e){var t=new OfficeCore.RequestContext;return t._customData="WacPartition",t}(),r=OfficeCore.DispatchApiService.newObject(n),o=r.execute(e,t),[4,n.sync()];case 1:return i.sent(),[2,o.value]}}))}))}}(e.DispatchApi||(e.DispatchApi={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){e.camera="camera",e.microphone="microphone",e.geolocation="geolocation"}(e.DevicePermissionType||(e.DevicePermissionType={})),function(e){e.requestPermissions=function(e){return __awaiter(this,void 0,void 0,(function(){var t,n,r;return __generator(this,(function(o){switch(o.label){case 0:return t=function(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}(),n=OfficeCore.DevicePermissionService.newObject(t),r=n.requestPermissions(e),[4,t.sync()];case 1:return o.sent(),[2,r.value]}}))}))}}(e.devicePermission||(e.devicePermission={}))}(Office||(Office={})),function(e){var t;!function(e){e[e.AddinInvokeResultNotInstalled=-1]="AddinInvokeResultNotInstalled",e[e.AddinInvokeResultSkillNotFound=-2]="AddinInvokeResultSkillNotFound",e[e.AddinInvokeResultLaunchFailed=-3]="AddinInvokeResultLaunchFailed",e[e.AddinInvokeResultSuccess=0]="AddinInvokeResultSuccess",e[e.AddinInvokeResultInvocationFailed=1]="AddinInvokeResultInvocationFailed",e[e.AddinInvokeResultNoResultGenerated=2]="AddinInvokeResultNoResultGenerated",e[e.AddinInvokeResultInvalidResultGenerated=3]="AddinInvokeResultInvalidResultGenerated",e[e.AddinInvokeResultNoActionFunctionMapping=4]="AddinInvokeResultNoActionFunctionMapping"}(t=e.AddinInvokeResult||(e.AddinInvokeResult={})),function(e){var n={},r=null;function o(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}function i(e){!function(){if(null==r){r=function(e){var t=e.actionCorrelationId,r=(e.replyMessage,e.resultCode,n[t]);return null!=r&&(r.replyMessage=e.replyMessage,r.resultCode=e.resultCode,r.replyPromiseResolver()),null};var e=o();OfficeCore.AddinSkillActionService.newObject(e).onReplyReceived.add(r),e.sync().then(null,(function(e){console.log("There was an error registering the reply event listener!")}))}}();var t={correlationId:e,replyPromise:null,replyPromiseResolver:null,replyMessage:null,resultCode:0};return t.replyPromise=new Promise((function(e){t.replyPromiseResolver=e})),n[e]=t,t}e.InvokeAction=function(e,r,a){return __awaiter(this,void 0,void 0,(function(){var s,c,u,l;return __generator(this,(function(f){switch(f.label){case 0:s=o(),c=OfficeCore.AddinSkillActionService.newObject(s),u=OSF.OUtil.Guid.generateNewGuid(),l=i(u),f.label=1;case 1:return f.trys.push([1,,4,5]),c.invokeAction(e,r,a,u),[4,s.sync()];case 2:return f.sent(),[4,l.replyPromise];case 3:return f.sent(),[3,5];case 4:return function(e){delete n[e]}(u),[7];case 5:if(l.resultCode==t.AddinInvokeResultSuccess){if("string"==typeof l.replyMessage)return[2,l.replyMessage];l.resultCode=t.AddinInvokeResultInvalidResultGenerated}switch(l.resultCode){case t.AddinInvokeResultNotInstalled:throw new OfficeExtension.Error({code:"AddinNotInstalled",message:"Add-in not installed."});case t.AddinInvokeResultSkillNotFound:throw new OfficeExtension.Error({code:"SkillNotFound",message:"Skill not found in the add-in manifest."});case t.AddinInvokeResultLaunchFailed:throw new OfficeExtension.Error({code:"LaunchFailed",message:"Add-in launch failed."});case t.AddinInvokeResultInvocationFailed:throw new OfficeExtension.Error({code:"InvocationFailed",message:"Skill invocation failed."});case t.AddinInvokeResultNoResultGenerated:throw new OfficeExtension.Error({code:"NoResultGenerated",message:"No result generated."});case t.AddinInvokeResultInvalidResultGenerated:throw new OfficeExtension.Error({code:"InvalidResultGenerated",message:"Invalid result generated."});case t.AddinInvokeResultNoActionFunctionMapping:throw new OfficeExtension.Error({code:"NoActionFunctionMapping",message:"No action function mapping."});default:throw new OfficeExtension.Error({code:"UnknownError",message:"Unknown error (code = "+l.resultCode+")."})}return[2]}}))}))}}(e.AddinSkillAction||(e.AddinSkillAction={}))}(OfficeFirstParty||(OfficeFirstParty={})),function(e){!function(e){e.getofficethemedataforvisualsurface=function(e){return __awaiter(this,void 0,void 0,(function(){var t,n,r;return __generator(this,(function(o){switch(o.label){case 0:return t=function(e){var t=new OfficeCore.RequestContext;return t._customData="WacPartition",t}(),n=OfficeCore.ThemeService.newObject(t),r=n.getOfficeThemeDataForVisualSurface(e),[4,t.sync()];case 1:return o.sent(),[2,JSON.parse(r.value)]}}))}))}}(e.ThemeService||(e.ThemeService={}))}(OfficeFirstParty||(OfficeFirstParty={}));var OneNote,OSF;__extends=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();!function(e){var t="OneNote",n="OneNoteApi",r=OfficeExtension.BatchApiHelper.createPropertyObject,o=OfficeExtension.BatchApiHelper.createMethodObject,i=OfficeExtension.BatchApiHelper.createIndexerObject,a=(OfficeExtension.BatchApiHelper.createRootServiceObject,OfficeExtension.BatchApiHelper.createTopLevelServiceObject,OfficeExtension.BatchApiHelper.createChildItemObject),s=OfficeExtension.BatchApiHelper.invokeMethod,c=OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,u=OfficeExtension.BatchApiHelper.invokeSetProperty,l=OfficeExtension.Utility.isNullOrUndefined,f=OfficeExtension.Utility.isUndefined,p=OfficeExtension.Utility.throwIfNotLoaded,d=OfficeExtension.Utility.throwIfApiNotSupported,h=OfficeExtension.Utility.load,g=OfficeExtension.Utility.retrieve,m=OfficeExtension.Utility.toJson,y=OfficeExtension.Utility.fixObjectPathIfNecessary,v=OfficeExtension.Utility._handleNavigationPropertyResults,_=(OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult),b=OfficeExtension.Utility.setMockData,O=(OfficeExtension.CommonUtility.calculateApiFlags,function(i){function a(){return null!==i&&i.apply(this,arguments)||this}return __extends(a,i),Object.defineProperty(a.prototype,"_className",{get:function(){return"Application"},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyNames",{get:function(){return["_platform"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_platform"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_navigationPropertyNames",{get:function(){return["notebooks","noteTagManager","mathAssistantManager"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"mathAssistantManager",{get:function(){return d("Application.mathAssistantManager",n,"1.9",t),this._M||(this._M=r(e.MathAssistantManager,this,"MathAssistantManager",!1,4)),this._M},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"noteTagManager",{get:function(){return d("Application.noteTagManager",n,"1.3",t),this._No||(this._No=r(e.NoteTagManager,this,"NoteTagManager",!1,4)),this._No},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"notebooks",{get:function(){return this._N||(this._N=r(e.NotebookCollection,this,"Notebooks",!0,4)),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_platform",{get:function(){return p("_platform",this.__p,"Application",this._isNull),this.__p},enumerable:!0,configurable:!0}),a.prototype.set=function(e,t){this._recursivelySet(e,t,[],["mathAssistantManager"],["notebooks","noteTagManager"])},a.prototype.update=function(e){this._recursivelyUpdate(e)},a.prototype.getActiveNotebook=function(){return o(e.Notebook,this,"GetActiveNotebook",1,[],!1,!1,null,4)},a.prototype.getActiveNotebookOrNull=function(){return o(e.Notebook,this,"GetActiveNotebookOrNull",1,[],!1,!1,null,4)},a.prototype.getActiveOutline=function(){return o(e.Outline,this,"GetActiveOutline",1,[],!1,!1,null,4)},a.prototype.getActiveOutlineOrNull=function(){return o(e.Outline,this,"GetActiveOutlineOrNull",1,[],!1,!1,null,4)},a.prototype.getActivePage=function(){return o(e.Page,this,"GetActivePage",1,[],!1,!1,null,4)},a.prototype.getActivePageOrNull=function(){return o(e.Page,this,"GetActivePageOrNull",1,[],!1,!1,null,4)},a.prototype.getActiveParagraph=function(){return o(e.Paragraph,this,"GetActiveParagraph",1,[],!1,!1,null,4)},a.prototype.getActiveParagraphOrNull=function(){return o(e.Paragraph,this,"GetActiveParagraphOrNull",1,[],!1,!1,null,4)},a.prototype.getActiveSection=function(){return o(e.Section,this,"GetActiveSection",1,[],!1,!1,null,4)},a.prototype.getActiveSectionOrNull=function(){return o(e.Section,this,"GetActiveSectionOrNull",1,[],!1,!1,null,4)},a.prototype.getDecimalSeparator=function(){return d("Application.getDecimalSeparator",n,"1.17",t),s(this,"GetDecimalSeparator",0,[],0,0)},a.prototype.getMathQuizContext=function(){return d("Application.getMathQuizContext",n,"1.6",t),s(this,"GetMathQuizContext",1,[],4,0)},a.prototype.getSelectedInkStrokes=function(){return d("Application.getSelectedInkStrokes",n,"1.9",t),o(e.InkStrokeCollection,this,"GetSelectedInkStrokes",1,[],!0,!1,null,4)},a.prototype.getSelectedPages=function(){return o(e.PageCollection,this,"GetSelectedPages",1,[],!0,!1,null,4)},a.prototype.getWindowSize=function(){return s(this,"GetWindowSize",0,[],0,0)},a.prototype.insertAndEmbedLinkAtCurrentPosition=function(e){d("Application.insertAndEmbedLinkAtCurrentPosition",n,"1.12",t),s(this,"InsertAndEmbedLinkAtCurrentPosition",0,[e],0,0)},a.prototype.insertHtmlAtCurrentPosition=function(e){s(this,"InsertHtmlAtCurrentPosition",0,[e],0,0)},a.prototype.isHighContrast=function(){return d("Application.isHighContrast",n,"1.3",t),s(this,"IsHighContrast",1,[],4,0)},a.prototype.isViewingDeletedNotes=function(){return d("Application.isViewingDeletedNotes",n,"1.2",t),s(this,"IsViewingDeletedNotes",1,[],4,0)},a.prototype.navigateToPage=function(e){s(this,"NavigateToPage",1,[e],4,0)},a.prototype.navigateToPageWithClientUrl=function(t){return o(e.Page,this,"NavigateToPageWithClientUrl",1,[t],!1,!1,null,4)},a.prototype._ClientLog=function(e,t,n,r){s(this,"_ClientLog",1,[e,t,n,r],4,0)},a.prototype._CreateNotebook=function(e,r){return d("Application._CreateNotebook",n,"1.5",t),s(this,"_CreateNotebook",1,[e,r],4,0)},a.prototype._EnableControl=function(e,t){s(this,"_EnableControl",0,[e,t],0,0)},a.prototype._EnterFullScreen=function(){s(this,"_EnterFullScreen",0,[],0,0)},a.prototype._ExitFullScreen=function(){s(this,"_ExitFullScreen",0,[],0,0)},a.prototype._FocusCanvas=function(){s(this,"_FocusCanvas",0,[],0,0)},a.prototype._GetAccountInfo=function(){return s(this,"_GetAccountInfo",1,[],4,0)},a.prototype._GetAccountInfoByType=function(e){return s(this,"_GetAccountInfoByType",1,[e],4,0)},a.prototype._GetAccountInfoCollection=function(){return d("Application._GetAccountInfoCollection",n,"1.3",t),s(this,"_GetAccountInfoCollection",1,[],4,0)},a.prototype._GetControlVisibility=function(e){return s(this,"_GetControlVisibility",1,[e],4,0)},a.prototype._GetLoggingInfo=function(){return s(this,"_GetLoggingInfo",1,[],4,0)},a.prototype._GetMathPaneContent=function(){return s(this,"_GetMathPaneContent",1,[],4,0)},a.prototype._GetNodeInternalProperties=function(e){return d("Application._GetNodeInternalProperties",n,"1.3",t),s(this,"_GetNodeInternalProperties",1,[e],4,0)},a.prototype._GetObjectByReferenceId=function(e){return s(this,"_GetObjectByReferenceId",1,[e],4,0)},a.prototype._GetObjectTypeNameByReferenceId=function(e){return s(this,"_GetObjectTypeNameByReferenceId",1,[e],4,0)},a.prototype._GetRoamingSetting=function(e,t){return s(this,"_GetRoamingSetting",0,[e,t],0,0)},a.prototype._GetServiceTokenByUrl=function(e){return s(this,"_GetServiceTokenByUrl",1,[e],4,0)},a.prototype._GetServiceTokenByUserEmail=function(e,r,o){return d("Application._GetServiceTokenByUserEmail",n,"1.3",t),s(this,"_GetServiceTokenByUserEmail",1,[e,r,o],4,0)},a.prototype._GetServiceTokens=function(e){return s(this,"_GetServiceTokens",1,[e],4,0)},a.prototype._GetServiceTokensExt=function(e,t){return s(this,"_GetServiceTokensExt",1,[e,t],4,0)},a.prototype._GetServiceUrl=function(e){return s(this,"_GetServiceUrl",1,[e],4,0)},a.prototype._IsAccountEdpManaged=function(e){return d("Application._IsAccountEdpManaged",n,"1.3",t),s(this,"_IsAccountEdpManaged",1,[e],4,0)},a.prototype._IsControlEnabled=function(e){return s(this,"_IsControlEnabled",1,[e],4,0)},a.prototype._IsImmersiveReaderUwpInstalled=function(){return s(this,"_IsImmersiveReaderUwpInstalled",0,[],0,0)},a.prototype._LaunchImmersiveReaderUwp=function(e){return s(this,"_LaunchImmersiveReaderUwp",0,[e],0,0)},a.prototype._OpenKRD=function(e){d("Application._OpenKRD",n,"1.19",t),s(this,"_OpenKRD",1,[e],4,0)},a.prototype._OpenKRDV2=function(e,r){d("Application._OpenKRDV2",n,"1.22",t),s(this,"_OpenKRDV2",1,[e,r],4,0)},a.prototype._RemoveAllReferences=function(){s(this,"_RemoveAllReferences",1,[],4,0)},a.prototype._RemoveReference=function(e){s(this,"_RemoveReference",1,[e],4,0)},a.prototype._SaveRoamingSetting=function(e,t){return s(this,"_SaveRoamingSetting",0,[e,t],0,0)},a.prototype._SendDataToLearningTools=function(e,t){return s(this,"_SendDataToLearningTools",0,[e,t],0,0)},a.prototype._SendDataToLearningToolsV2=function(e,t){return s(this,"_SendDataToLearningToolsV2",0,[e,t],0,0)},a.prototype._SetControlVisibility=function(e,t){s(this,"_SetControlVisibility",0,[e,t],0,0)},a.prototype._UploadToUserInfoService=function(e,t){s(this,"_UploadToUserInfoService",1,[e,t],4,0)},a.prototype._handleResult=function(e){if(i.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t._platform)||(this.__p=t._platform),v(this,t,["mathAssistantManager","MathAssistantManager","noteTagManager","NoteTagManager","notebooks","Notebooks"])}},a.prototype.load=function(e){return h(this,e)},a.prototype.retrieve=function(e){return g(this,e)},a.prototype._handleRetrieveResult=function(e,t){i.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},a.prototype.toJSON=function(){return m(this,{},{mathAssistantManager:this._M,notebooks:this._N,noteTagManager:this._No})},a.prototype.setMockData=function(e){b(this,e)},a.prototype.ensureUnchanged=function(e){c(this,e)},a}(OfficeExtension.ClientObject));e.Application=O;var S="InkAnalysis",C=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkAnalysis"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["paragraphs","page"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"page",{get:function(){return this._P||(this._P=r(e.Page,this,"Page",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"paragraphs",{get:function(){return this._Pa||(this._Pa=r(e.InkAnalysisParagraphCollection,this,"Paragraphs",!0,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,S,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,S,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.set=function(e,t){this._recursivelySet(e,t,[],["page"],["paragraphs"])},n.prototype.update=function(e){this._recursivelyUpdate(e)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.Id)||(this._I=n.Id),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["page","Page","paragraphs","Paragraphs"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{id:this._I},{page:this._P,paragraphs:this._Pa})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.InkAnalysis=C;var I="InkAnalysisParagraph",A=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkAnalysisParagraph"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["lines","inkAnalysis"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"inkAnalysis",{get:function(){return this._In||(this._In=r(e.InkAnalysis,this,"InkAnalysis",!1,4)),this._In},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"lines",{get:function(){return this._L||(this._L=r(e.InkAnalysisLineCollection,this,"Lines",!0,4)),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,I,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,I,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.set=function(e,t){this._recursivelySet(e,t,[],["inkAnalysis"],["lines"])},n.prototype.update=function(e){this._recursivelyUpdate(e)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.Id)||(this._I=n.Id),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["inkAnalysis","InkAnalysis","lines","Lines"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{id:this._I},{inkAnalysis:this._In,lines:this._L})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.InkAnalysisParagraph=A;var P="InkAnalysisParagraphCollection",E=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkAnalysisParagraphCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,P,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,P,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,P,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.InkAnalysisParagraph,this,[t])},n.prototype.getItemAt=function(t){return o(e.InkAnalysisParagraph,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.InkAnalysisParagraph,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.InkAnalysisParagraph,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.InkAnalysisParagraph,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.InkAnalysisParagraphCollection=E;var R="InkAnalysisLine",T=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkAnalysisLine"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["words","paragraph"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"paragraph",{get:function(){return this._P||(this._P=r(e.InkAnalysisParagraph,this,"Paragraph",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"words",{get:function(){return this._W||(this._W=r(e.InkAnalysisWordCollection,this,"Words",!0,4)),this._W},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,R,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,R,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.set=function(e,t){this._recursivelySet(e,t,[],["paragraph"],["words"])},n.prototype.update=function(e){this._recursivelyUpdate(e)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.Id)||(this._I=n.Id),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["paragraph","Paragraph","words","Words"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{id:this._I},{paragraph:this._P,words:this._W})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.InkAnalysisLine=T;var w="InkAnalysisLineCollection",x=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkAnalysisLineCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,w,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,w,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,w,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.InkAnalysisLine,this,[t])},n.prototype.getItemAt=function(t){return o(e.InkAnalysisLine,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.InkAnalysisLine,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.InkAnalysisLine,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.InkAnalysisLine,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.InkAnalysisLineCollection=x;var N="InkAnalysisWord",D=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkAnalysisWord"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","wordAlternates","strokePointers","languageId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","WordAlternates","StrokePointers","LanguageId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["line"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"line",{get:function(){return this._Li||(this._Li=r(e.InkAnalysisLine,this,"Line",!1,4)),this._Li},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,N,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"languageId",{get:function(){return p("languageId",this._L,N,this._isNull),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"strokePointers",{get:function(){return p("strokePointers",this._S,N,this._isNull),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"wordAlternates",{get:function(){return p("wordAlternates",this._W,N,this._isNull),this._W},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,N,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.set=function(e,t){this._recursivelySet(e,t,[],["line"],[])},n.prototype.update=function(e){this._recursivelyUpdate(e)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.Id)||(this._I=n.Id),f(n.LanguageId)||(this._L=n.LanguageId),f(n.StrokePointers)||(this._S=n.StrokePointers),f(n.WordAlternates)||(this._W=n.WordAlternates),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["line","Line"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{id:this._I,languageId:this._L,strokePointers:this._S,wordAlternates:this._W},{line:this._Li})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.InkAnalysisWord=D;var k="InkAnalysisWordCollection",F=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkAnalysisWordCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,k,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,k,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,k,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.InkAnalysisWord,this,[t])},n.prototype.getItemAt=function(t){return o(e.InkAnalysisWord,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.InkAnalysisWord,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.InkAnalysisWord,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.InkAnalysisWord,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.InkAnalysisWordCollection=F;var j="FloatingInk",M=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"FloatingInk"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["inkStrokes","pageContent"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"inkStrokes",{get:function(){return this._In||(this._In=r(e.InkStrokeCollection,this,"InkStrokes",!0,4)),this._In},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"pageContent",{get:function(){return this._P||(this._P=r(e.PageContent,this,"PageContent",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,j,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,j,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.Id)||(this._I=n.Id),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["inkStrokes","InkStrokes","pageContent","PageContent"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{id:this._I},{inkStrokes:this._In})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.FloatingInk=M;var H=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"Meeting"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["container"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"container",{get:function(){return this._C||(this._C=r(e.Paragraph,this,"Container",!1,4)),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,"Meeting",this._isNull),this._I},enumerable:!0,configurable:!0}),n.prototype.set=function(e,t){this._recursivelySet(e,t,[],["container"],[])},n.prototype.update=function(e){this._recursivelyUpdate(e)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.Id)||(this._I=n.Id),v(this,n,["container","Container"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e.Id)||(this._I=e.Id)},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.toJSON=function(){return m(this,{id:this._I},{container:this._C})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.Meeting=H;var U="MeetingCollection",L=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"MeetingCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,U,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,U,this._isNull),this._C},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.Meeting,this,[t])},n.prototype.getItemAt=function(t){return o(e.Meeting,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.Meeting,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.Meeting,!0,o,t,n)}))},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.Meeting,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.MeetingCollection=L;var B="InkStroke",W=function(o){function i(){return null!==o&&o.apply(this,arguments)||this}return __extends(i,o),Object.defineProperty(i.prototype,"_className",{get:function(){return"InkStroke"},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_navigationPropertyNames",{get:function(){return["floatingInk","points"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"floatingInk",{get:function(){return this._F||(this._F=r(e.FloatingInk,this,"FloatingInk",!1,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"points",{get:function(){return d("InkStroke.points",n,"1.9",t),this._P||(this._P=r(e.PointCollection,this,"Points",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"id",{get:function(){return p("id",this._I,B,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,B,this._isNull),this.__R},enumerable:!0,configurable:!0}),i.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},i.prototype._handleResult=function(e){if(o.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.Id)||(this._I=t.Id),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["floatingInk","FloatingInk","points","Points"])}},i.prototype.load=function(e){return h(this,e)},i.prototype.retrieve=function(e){return g(this,e)},i.prototype._handleIdResult=function(e){o.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},i.prototype._handleRetrieveResult=function(e,t){o.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},i.prototype.track=function(){return this.context.trackedObjects.add(this),this},i.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},i.prototype.toJSON=function(){return m(this,{id:this._I},{floatingInk:this._F,points:this._P})},i.prototype.setMockData=function(e){b(this,e)},i.prototype.ensureUnchanged=function(e){c(this,e)},i}(OfficeExtension.ClientObject);e.InkStroke=W;var G="InkStrokeCollection",q=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkStrokeCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,G,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,G,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,G,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.InkStroke,this,[t])},n.prototype.getItemAt=function(t){return o(e.InkStroke,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.InkStroke,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.InkStroke,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.InkStroke,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.InkStrokeCollection=q;var V="Point",J=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"_className",{get:function(){return"Point"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","x","y"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","X","Y"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"id",{get:function(){return p("id",this._I,V,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"x",{get:function(){return p("x",this._X,V,this._isNull),this._X},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"y",{get:function(){return p("y",this._Y,V,this._isNull),this._Y},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,V,this._isNull),this.__R},enumerable:!0,configurable:!0}),t.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},t.prototype._handleResult=function(t){if(e.prototype._handleResult.call(this,t),!l(t)){var n=t;y(this,n),f(n.Id)||(this._I=n.Id),f(n.X)||(this._X=n.X),f(n.Y)||(this._Y=n.Y),f(n._ReferenceId)||(this.__R=n._ReferenceId)}},t.prototype.load=function(e){return h(this,e)},t.prototype.retrieve=function(e){return g(this,e)},t.prototype._handleIdResult=function(t){e.prototype._handleIdResult.call(this,t),l(t)||(f(t._ReferenceId)||(this.__R=t._ReferenceId),f(t.Id)||(this._I=t.Id))},t.prototype._handleRetrieveResult=function(t,n){e.prototype._handleRetrieveResult.call(this,t,n),_(this,t,n)},t.prototype.track=function(){return this.context.trackedObjects.add(this),this},t.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},t.prototype.toJSON=function(){return m(this,{id:this._I,x:this._X,y:this._Y},{})},t.prototype.setMockData=function(e){b(this,e)},t.prototype.ensureUnchanged=function(e){c(this,e)},t}(OfficeExtension.ClientObject);e.Point=J;var z="PointCollection",K=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"PointCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,z,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,z,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,z,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.Point,this,[t])},n.prototype.getItemAt=function(t){return o(e.Point,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.Point,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.Point,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.Point,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.PointCollection=K;var Q="InkWord",X=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkWord"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","wordAlternates","languageId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","WordAlternates","LanguageId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["paragraph"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"paragraph",{get:function(){return this._P||(this._P=r(e.Paragraph,this,"Paragraph",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,Q,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"languageId",{get:function(){return p("languageId",this._L,Q,this._isNull),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"wordAlternates",{get:function(){return p("wordAlternates",this._W,Q,this._isNull),this._W},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Q,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.Id)||(this._I=n.Id),f(n.LanguageId)||(this._L=n.LanguageId),f(n.WordAlternates)||(this._W=n.WordAlternates),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["paragraph","Paragraph"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{id:this._I,languageId:this._L,wordAlternates:this._W},{})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.InkWord=X;var $="InkWordCollection",Y=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"InkWordCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,$,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,$,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,$,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.InkWord,this,[t])},n.prototype.getItemAt=function(t){return o(e.InkWord,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.InkWord,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.InkWord,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.InkWord,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.InkWordCollection=Y;var Z="Notebook",ee=function(i){function a(){return null!==i&&i.apply(this,arguments)||this}return __extends(a,i),Object.defineProperty(a.prototype,"_className",{get:function(){return"Notebook"},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyNames",{get:function(){return["id","name","_ReferenceId","clientUrl","baseUrl","isVirtual","isForEducation","isReadOnly"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","Name","_ReferenceId","ClientUrl","BaseUrl","IsVirtual","IsForEducation","IsReadOnly"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_navigationPropertyNames",{get:function(){return["sections","sectionGroups","accessibilityViolations"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"accessibilityViolations",{get:function(){return d("Notebook.accessibilityViolations",n,"1.2",t),this._A||(this._A=r(e.AccessibilityViolationsByEntityCollection,this,"AccessibilityViolations",!0,4)),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"sectionGroups",{get:function(){return this._S||(this._S=r(e.SectionGroupCollection,this,"SectionGroups",!0,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"sections",{get:function(){return this._Se||(this._Se=r(e.SectionCollection,this,"Sections",!0,4)),this._Se},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"baseUrl",{get:function(){return p("baseUrl",this._B,Z,this._isNull),this._B},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"clientUrl",{get:function(){return p("clientUrl",this._C,Z,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"id",{get:function(){return p("id",this._I,Z,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isForEducation",{get:function(){return p("isForEducation",this._Is,Z,this._isNull),d("Notebook.isForEducation",n,"1.11",t),this._Is},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isReadOnly",{get:function(){return p("isReadOnly",this._IsR,Z,this._isNull),d("Notebook.isReadOnly",n,"1.11",t),this._IsR},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isVirtual",{get:function(){return p("isVirtual",this._IsV,Z,this._isNull),d("Notebook.isVirtual",n,"1.2",t),this._IsV},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"name",{get:function(){return p("name",this._N,Z,this._isNull),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Z,this._isNull),this.__R},enumerable:!0,configurable:!0}),a.prototype.addSection=function(t){return o(e.Section,this,"AddSection",0,[t],!1,!0,null,0)},a.prototype.addSectionGroup=function(t){return o(e.SectionGroup,this,"AddSectionGroup",0,[t],!1,!0,null,0)},a.prototype.canCopyDataFromAccount=function(e){return d("Notebook.canCopyDataFromAccount",n,"1.3",t),s(this,"CanCopyDataFromAccount",1,[e],4,0)},a.prototype.canCopyDataToAccount=function(e){return d("Notebook.canCopyDataToAccount",n,"1.3",t),s(this,"CanCopyDataToAccount",1,[e],4,0)},a.prototype.getRestApiId=function(){return s(this,"GetRestApiId",1,[],4,0)},a.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},a.prototype._Sync=function(){s(this,"_Sync",0,[],0,0)},a.prototype._handleResult=function(e){if(i.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.BaseUrl)||(this._B=t.BaseUrl),f(t.ClientUrl)||(this._C=t.ClientUrl),f(t.Id)||(this._I=t.Id),f(t.IsForEducation)||(this._Is=t.IsForEducation),f(t.IsReadOnly)||(this._IsR=t.IsReadOnly),f(t.IsVirtual)||(this._IsV=t.IsVirtual),f(t.Name)||(this._N=t.Name),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["accessibilityViolations","AccessibilityViolations","sectionGroups","SectionGroups","sections","Sections"])}},a.prototype.load=function(e){return h(this,e)},a.prototype.retrieve=function(e){return g(this,e)},a.prototype._handleIdResult=function(e){i.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},a.prototype._handleRetrieveResult=function(e,t){i.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},a.prototype.track=function(){return this.context.trackedObjects.add(this),this},a.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},a.prototype.toJSON=function(){return m(this,{baseUrl:this._B,clientUrl:this._C,id:this._I,isForEducation:this._Is,isReadOnly:this._IsR,isVirtual:this._IsV,name:this._N},{accessibilityViolations:this._A,sectionGroups:this._S,sections:this._Se})},a.prototype.setMockData=function(e){b(this,e)},a.prototype.ensureUnchanged=function(e){c(this,e)},a}(OfficeExtension.ClientObject);e.Notebook=ee;var te="NotebookCollection",ne=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"NotebookCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,te,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,te,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,te,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getByName=function(t){return o(e.NotebookCollection,this,"GetByName",1,[t],!0,!1,null,4)},n.prototype.getItem=function(t){return i(e.Notebook,this,[t])},n.prototype.getItemAt=function(t){return o(e.Notebook,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.Notebook,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.Notebook,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.Notebook,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.NotebookCollection=ne;var re="SectionGroup",oe=function(i){function a(){return null!==i&&i.apply(this,arguments)||this}return __extends(a,i),Object.defineProperty(a.prototype,"_className",{get:function(){return"SectionGroup"},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyNames",{get:function(){return["id","name","_ReferenceId","clientUrl","isReadOnly"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","Name","_ReferenceId","ClientUrl","IsReadOnly"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_navigationPropertyNames",{get:function(){return["notebook","parentSectionGroup","parentSectionGroupOrNull","sections","sectionGroups"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"notebook",{get:function(){return this._No||(this._No=r(e.Notebook,this,"Notebook",!1,4)),this._No},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentSectionGroup",{get:function(){return this._P||(this._P=r(e.SectionGroup,this,"ParentSectionGroup",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentSectionGroupOrNull",{get:function(){return this._Pa||(this._Pa=r(e.SectionGroup,this,"ParentSectionGroupOrNull",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"sectionGroups",{get:function(){return this._S||(this._S=r(e.SectionGroupCollection,this,"SectionGroups",!0,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"sections",{get:function(){return this._Se||(this._Se=r(e.SectionCollection,this,"Sections",!0,4)),this._Se},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"clientUrl",{get:function(){return p("clientUrl",this._C,re,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"id",{get:function(){return p("id",this._I,re,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isReadOnly",{get:function(){return p("isReadOnly",this._Is,re,this._isNull),d("SectionGroup.isReadOnly",n,"1.23",t),this._Is},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"name",{get:function(){return p("name",this._N,re,this._isNull),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,re,this._isNull),this.__R},enumerable:!0,configurable:!0}),a.prototype.addSection=function(t){return o(e.Section,this,"AddSection",0,[t],!1,!0,null,0)},a.prototype.addSectionGroup=function(t){return o(e.SectionGroup,this,"AddSectionGroup",0,[t],!1,!0,null,0)},a.prototype.getRestApiId=function(){return s(this,"GetRestApiId",1,[],4,0)},a.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},a.prototype._handleResult=function(e){if(i.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.ClientUrl)||(this._C=t.ClientUrl),f(t.Id)||(this._I=t.Id),f(t.IsReadOnly)||(this._Is=t.IsReadOnly),f(t.Name)||(this._N=t.Name),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["notebook","Notebook","parentSectionGroup","ParentSectionGroup","parentSectionGroupOrNull","ParentSectionGroupOrNull","sectionGroups","SectionGroups","sections","Sections"])}},a.prototype.load=function(e){return h(this,e)},a.prototype.retrieve=function(e){return g(this,e)},a.prototype._handleIdResult=function(e){i.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},a.prototype._handleRetrieveResult=function(e,t){i.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},a.prototype.track=function(){return this.context.trackedObjects.add(this),this},a.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},a.prototype.toJSON=function(){return m(this,{clientUrl:this._C,id:this._I,isReadOnly:this._Is,name:this._N},{sectionGroups:this._S,sections:this._Se})},a.prototype.setMockData=function(e){b(this,e)},a.prototype.ensureUnchanged=function(e){c(this,e)},a}(OfficeExtension.ClientObject);e.SectionGroup=oe;var ie="SectionGroupCollection",ae=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"SectionGroupCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,ie,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,ie,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,ie,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getByName=function(t){return o(e.SectionGroupCollection,this,"GetByName",1,[t],!0,!1,null,4)},n.prototype.getItem=function(t){return i(e.SectionGroup,this,[t])},n.prototype.getItemAt=function(t){return o(e.SectionGroup,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.SectionGroup,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.SectionGroup,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.SectionGroup,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.SectionGroupCollection=ae;var se="Section",ce=function(i){function a(){return null!==i&&i.apply(this,arguments)||this}return __extends(a,i),Object.defineProperty(a.prototype,"_className",{get:function(){return"Section"},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyNames",{get:function(){return["id","name","_ReferenceId","clientUrl","webUrl","isEncrypted","isLocked","isForQuickNotes","isReadOnly"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","Name","_ReferenceId","ClientUrl","WebUrl","IsEncrypted","IsLocked","IsForQuickNotes","IsReadOnly"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_navigationPropertyNames",{get:function(){return["notebook","parentSectionGroup","parentSectionGroupOrNull","pages"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"notebook",{get:function(){return this._No||(this._No=r(e.Notebook,this,"Notebook",!1,4)),this._No},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"pages",{get:function(){return this._P||(this._P=r(e.PageCollection,this,"Pages",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentSectionGroup",{get:function(){return this._Pa||(this._Pa=r(e.SectionGroup,this,"ParentSectionGroup",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentSectionGroupOrNull",{get:function(){return this._Par||(this._Par=r(e.SectionGroup,this,"ParentSectionGroupOrNull",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"clientUrl",{get:function(){return p("clientUrl",this._C,se,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"id",{get:function(){return p("id",this._I,se,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isEncrypted",{get:function(){return p("isEncrypted",this._Is,se,this._isNull),d("Section.isEncrypted",n,"1.2",t),this._Is},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isForQuickNotes",{get:function(){return p("isForQuickNotes",this._IsF,se,this._isNull),d("Section.isForQuickNotes",n,"1.20",t),this._IsF},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isLocked",{get:function(){return p("isLocked",this._IsL,se,this._isNull),d("Section.isLocked",n,"1.2",t),this._IsL},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isReadOnly",{get:function(){return p("isReadOnly",this._IsR,se,this._isNull),d("Section.isReadOnly",n,"1.23",t),this._IsR},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"name",{get:function(){return p("name",this._N,se,this._isNull),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"webUrl",{get:function(){return p("webUrl",this._W,se,this._isNull),this._W},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,se,this._isNull),this.__R},enumerable:!0,configurable:!0}),a.prototype.addPage=function(t){return o(e.Page,this,"AddPage",0,[t],!1,!0,null,0)},a.prototype.applyPageTemplate=function(t){return o(e.Page,this,"ApplyPageTemplate",0,[t],!1,!1,null,0)},a.prototype.copyToNotebook=function(t){return o(e.Section,this,"CopyToNotebook",0,[t],!1,!0,null,0)},a.prototype.copyToSectionGroup=function(t){return o(e.Section,this,"CopyToSectionGroup",0,[t],!1,!0,null,0)},a.prototype.delete=function(){d("Section.delete",n,"1.19",t),s(this,"Delete",0,[],0,0)},a.prototype.getDefaultTemplateName=function(){return d("Section.getDefaultTemplateName",n,"1.7",t),s(this,"GetDefaultTemplateName",0,[],0,0)},a.prototype.getRestApiId=function(){return s(this,"GetRestApiId",1,[],4,0)},a.prototype.insertSectionAsSibling=function(t,n){return o(e.Section,this,"InsertSectionAsSibling",0,[t,n],!1,!0,null,0)},a.prototype.removeDefaultTemplate=function(){d("Section.removeDefaultTemplate",n,"1.7",t),s(this,"RemoveDefaultTemplate",0,[],0,0)},a.prototype.reorderPage=function(e,r,o){d("Section.reorderPage",n,"1.24",t),s(this,"ReorderPage",0,[e,r,o],0,0)},a.prototype.setDefaultTemplate=function(e){return d("Section.setDefaultTemplate",n,"1.7",t),s(this,"SetDefaultTemplate",0,[e],0,0)},a.prototype._GetDefaultTemplateThumbnailAsync=function(e,r,o){return d("Section._GetDefaultTemplateThumbnailAsync",n,"1.7",t),s(this,"_GetDefaultTemplateThumbnailAsync",0,[e,r,o],0,0)},a.prototype._GetGeoInfo=function(){return s(this,"_GetGeoInfo",1,[],4,0)},a.prototype._GetGeoInfoAsync=function(){return s(this,"_GetGeoInfoAsync",1,[],4,0)},a.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},a.prototype._handleResult=function(e){if(i.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.ClientUrl)||(this._C=t.ClientUrl),f(t.Id)||(this._I=t.Id),f(t.IsEncrypted)||(this._Is=t.IsEncrypted),f(t.IsForQuickNotes)||(this._IsF=t.IsForQuickNotes),f(t.IsLocked)||(this._IsL=t.IsLocked),f(t.IsReadOnly)||(this._IsR=t.IsReadOnly),f(t.Name)||(this._N=t.Name),f(t.WebUrl)||(this._W=t.WebUrl),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["notebook","Notebook","pages","Pages","parentSectionGroup","ParentSectionGroup","parentSectionGroupOrNull","ParentSectionGroupOrNull"])}},a.prototype.load=function(e){return h(this,e)},a.prototype.retrieve=function(e){return g(this,e)},a.prototype._handleIdResult=function(e){i.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},a.prototype._handleRetrieveResult=function(e,t){i.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},a.prototype.track=function(){return this.context.trackedObjects.add(this),this},a.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},a.prototype.toJSON=function(){return m(this,{clientUrl:this._C,id:this._I,isEncrypted:this._Is,isForQuickNotes:this._IsF,isLocked:this._IsL,isReadOnly:this._IsR,name:this._N,webUrl:this._W},{pages:this._P})},a.prototype.setMockData=function(e){b(this,e)},a.prototype.ensureUnchanged=function(e){c(this,e)},a}(OfficeExtension.ClientObject);e.Section=ce;var ue="SectionCollection",le=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"SectionCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,ue,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,ue,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,ue,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getByName=function(t){return o(e.SectionCollection,this,"GetByName",1,[t],!0,!1,null,4)},n.prototype.getItem=function(t){return i(e.Section,this,[t])},n.prototype.getItemAt=function(t){return o(e.Section,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.Section,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.Section,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.Section,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.SectionCollection=le;var fe="Page",pe=function(i){function a(){return null!==i&&i.apply(this,arguments)||this}return __extends(a,i),Object.defineProperty(a.prototype,"_className",{get:function(){return"Page"},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyNames",{get:function(){return["id","title","pageLevel","_ReferenceId","clientUrl","webUrl","classNotebookPageSource","isReadOnly"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","Title","PageLevel","_ReferenceId","ClientUrl","WebUrl","ClassNotebookPageSource","IsReadOnly"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!1,!1,!1,!1,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_navigationPropertyNames",{get:function(){return["parentSection","contents","inkAnalysisOrNull","accessibilityViolations","transcription","meetings"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"accessibilityViolations",{get:function(){return d("Page.accessibilityViolations",n,"1.2",t),this._A||(this._A=r(e.AccessibilityViolationCollection,this,"AccessibilityViolations",!0,4)),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"contents",{get:function(){return this._Co||(this._Co=r(e.PageContentCollection,this,"Contents",!0,4)),this._Co},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"inkAnalysisOrNull",{get:function(){return this._In||(this._In=r(e.InkAnalysis,this,"InkAnalysisOrNull",!1,4)),this._In},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"meetings",{get:function(){return d("Page.meetings",n,"1.23",t),this._M||(this._M=r(e.MeetingCollection,this,"Meetings",!0,4)),this._M},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentSection",{get:function(){return this._Pa||(this._Pa=r(e.Section,this,"ParentSection",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"transcription",{get:function(){return d("Page.transcription",n,"1.13",t),this._Tr||(this._Tr=r(e.Transcription,this,"Transcription",!1,4)),this._Tr},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"classNotebookPageSource",{get:function(){return p("classNotebookPageSource",this._C,fe,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"clientUrl",{get:function(){return p("clientUrl",this._Cl,fe,this._isNull),this._Cl},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"id",{get:function(){return p("id",this._I,fe,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isReadOnly",{get:function(){return p("isReadOnly",this._Is,fe,this._isNull),d("Page.isReadOnly",n,"1.23",t),this._Is},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"pageLevel",{get:function(){return p("pageLevel",this._P,fe,this._isNull),this._P},set:function(e){this._P=e,u(this,"PageLevel",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"title",{get:function(){return p("title",this._T,fe,this._isNull),this._T},set:function(e){this._T=e,u(this,"Title",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"webUrl",{get:function(){return p("webUrl",this._W,fe,this._isNull),this._W},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,fe,this._isNull),this.__R},enumerable:!0,configurable:!0}),a.prototype.set=function(e,t){this._recursivelySet(e,t,["title","pageLevel"],["inkAnalysisOrNull"],["accessibilityViolations","contents","meetings","parentSection","transcription"])},a.prototype.update=function(e){this._recursivelyUpdate(e)},a.prototype.addOutline=function(t,n,r){return o(e.Outline,this,"AddOutline",0,[t,n,r],!1,!0,null,0)},a.prototype.analyzePage=function(){return s(this,"AnalyzePage",1,[],4,0)},a.prototype.applyTranslation=function(e){s(this,"ApplyTranslation",0,[e],0,0)},a.prototype.copyToSection=function(t){return o(e.Page,this,"CopyToSection",0,[t],!1,!0,null,0)},a.prototype.copyToSectionAndSetClassNotebookPageSource=function(t){return o(e.Page,this,"CopyToSectionAndSetClassNotebookPageSource",0,[t],!1,!0,null,0)},a.prototype.delete=function(){d("Page.delete",n,"1.19",t),s(this,"Delete",0,[],0,0)},a.prototype.getRestApiId=function(){return s(this,"GetRestApiId",1,[],4,0)},a.prototype.hasTitleContent=function(){return s(this,"HasTitleContent",1,[],4,0)},a.prototype.insertPageAsSibling=function(t,n){return o(e.Page,this,"InsertPageAsSibling",0,[t,n],!1,!0,null,0)},a.prototype._GetInternalHierarchy=function(){return d("Page._GetInternalHierarchy",n,"1.3",t),s(this,"_GetInternalHierarchy",1,[],4,0)},a.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},a.prototype._Sync=function(){s(this,"_Sync",0,[],0,0)},a.prototype._handleResult=function(e){if(i.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.ClassNotebookPageSource)||(this._C=t.ClassNotebookPageSource),f(t.ClientUrl)||(this._Cl=t.ClientUrl),f(t.Id)||(this._I=t.Id),f(t.IsReadOnly)||(this._Is=t.IsReadOnly),f(t.PageLevel)||(this._P=t.PageLevel),f(t.Title)||(this._T=t.Title),f(t.WebUrl)||(this._W=t.WebUrl),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["accessibilityViolations","AccessibilityViolations","contents","Contents","inkAnalysisOrNull","InkAnalysisOrNull","meetings","Meetings","parentSection","ParentSection","transcription","Transcription"])}},a.prototype.load=function(e){return h(this,e)},a.prototype.retrieve=function(e){return g(this,e)},a.prototype._handleIdResult=function(e){i.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},a.prototype._handleRetrieveResult=function(e,t){i.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},a.prototype.track=function(){return this.context.trackedObjects.add(this),this},a.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},a.prototype.toJSON=function(){return m(this,{classNotebookPageSource:this._C,clientUrl:this._Cl,id:this._I,isReadOnly:this._Is,pageLevel:this._P,title:this._T,webUrl:this._W},{accessibilityViolations:this._A,contents:this._Co,inkAnalysisOrNull:this._In})},a.prototype.setMockData=function(e){b(this,e)},a.prototype.ensureUnchanged=function(e){c(this,e)},a}(OfficeExtension.ClientObject);e.Page=pe;var de="PageCollection",he=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"PageCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,de,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,de,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,de,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getByTitle=function(t){return o(e.PageCollection,this,"GetByTitle",1,[t],!0,!1,null,4)},n.prototype.getItem=function(t){return i(e.Page,this,[t])},n.prototype.getItemAt=function(t){return o(e.Page,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.Page,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.Page,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.Page,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.PageCollection=he;var ge="PageContent",me=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"PageContent"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","type","_ReferenceId","left","top"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","Type","_ReferenceId","Left","Top"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["parentPage","image","outline","ink"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"image",{get:function(){return this._Im||(this._Im=r(e.Image,this,"Image",!1,4)),this._Im},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"ink",{get:function(){return this._In||(this._In=r(e.FloatingInk,this,"Ink",!1,4)),this._In},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"outline",{get:function(){return this._O||(this._O=r(e.Outline,this,"Outline",!1,4)),this._O},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"parentPage",{get:function(){return this._P||(this._P=r(e.Page,this,"ParentPage",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,ge,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"left",{get:function(){return p("left",this._L,ge,this._isNull),this._L},set:function(e){this._L=e,u(this,"Left",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"top",{get:function(){return p("top",this._T,ge,this._isNull),this._T},set:function(e){this._T=e,u(this,"Top",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"type",{get:function(){return p("type",this._Ty,ge,this._isNull),this._Ty},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,ge,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.set=function(e,t){this._recursivelySet(e,t,["left","top"],["image"],["ink","outline","parentPage"])},n.prototype.update=function(e){this._recursivelyUpdate(e)},n.prototype.delete=function(){s(this,"Delete",0,[],0,0)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.Id)||(this._I=n.Id),f(n.Left)||(this._L=n.Left),f(n.Top)||(this._T=n.Top),f(n.Type)||(this._Ty=n.Type),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["image","Image","ink","Ink","outline","Outline","parentPage","ParentPage"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{id:this._I,left:this._L,top:this._T,type:this._Ty},{image:this._Im,ink:this._In,outline:this._O})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.PageContent=me;var ye="PageContentCollection",ve=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"PageContentCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,ye,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,ye,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,ye,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.PageContent,this,[t])},n.prototype.getItemAt=function(t){return o(e.PageContent,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.PageContent,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.PageContent,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.PageContent,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.PageContentCollection=ve;var _e="Outline",be=function(i){function a(){return null!==i&&i.apply(this,arguments)||this}return __extends(a,i),Object.defineProperty(a.prototype,"_className",{get:function(){return"Outline"},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_navigationPropertyNames",{get:function(){return["pageContent","paragraphs"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"pageContent",{get:function(){return this._P||(this._P=r(e.PageContent,this,"PageContent",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"paragraphs",{get:function(){return this._Pa||(this._Pa=r(e.ParagraphCollection,this,"Paragraphs",!0,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"id",{get:function(){return p("id",this._I,_e,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,_e,this._isNull),this.__R},enumerable:!0,configurable:!0}),a.prototype.appendHtml=function(e){s(this,"AppendHtml",0,[e],0,0)},a.prototype.appendImage=function(t,n,r){return o(e.Image,this,"AppendImage",0,[t,n,r],!1,!0,null,0)},a.prototype.appendRichText=function(t){return o(e.RichText,this,"AppendRichText",0,[t],!1,!0,null,0)},a.prototype.appendTable=function(t,n,r){return o(e.Table,this,"AppendTable",0,[t,n,r],!1,!0,null,0)},a.prototype.delete=function(){d("Outline.delete",n,"1.19",t),s(this,"Delete",0,[],0,0)},a.prototype.isTitle=function(){return s(this,"IsTitle",0,[],0,0)},a.prototype.select=function(e){d("Outline.select",n,"1.19",t),s(this,"Select",0,[e],0,0)},a.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},a.prototype._handleResult=function(e){if(i.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.Id)||(this._I=t.Id),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["pageContent","PageContent","paragraphs","Paragraphs"])}},a.prototype.load=function(e){return h(this,e)},a.prototype.retrieve=function(e){return g(this,e)},a.prototype._handleIdResult=function(e){i.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},a.prototype._handleRetrieveResult=function(e,t){i.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},a.prototype.track=function(){return this.context.trackedObjects.add(this),this},a.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},a.prototype.toJSON=function(){return m(this,{id:this._I},{paragraphs:this._Pa})},a.prototype.setMockData=function(e){b(this,e)},a.prototype.ensureUnchanged=function(e){c(this,e)},a}(OfficeExtension.ClientObject);e.Outline=be;var Oe="Paragraph",Se=function(i){function a(){return null!==i&&i.apply(this,arguments)||this}return __extends(a,i),Object.defineProperty(a.prototype,"_className",{get:function(){return"Paragraph"},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyNames",{get:function(){return["id","type","_ReferenceId","clientUrl"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","Type","_ReferenceId","ClientUrl"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_navigationPropertyNames",{get:function(){return["outline","parentTableCell","parentTableCellOrNull","richText","image","table","parentParagraph","parentParagraphOrNull","paragraphs","inkWords"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"image",{get:function(){return this._Im||(this._Im=r(e.Image,this,"Image",!1,4)),this._Im},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"inkWords",{get:function(){return this._In||(this._In=r(e.InkWordCollection,this,"InkWords",!0,4)),this._In},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"outline",{get:function(){return this._O||(this._O=r(e.Outline,this,"Outline",!1,4)),this._O},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"paragraphs",{get:function(){return this._P||(this._P=r(e.ParagraphCollection,this,"Paragraphs",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentParagraph",{get:function(){return this._Pa||(this._Pa=r(e.Paragraph,this,"ParentParagraph",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentParagraphOrNull",{get:function(){return this._Par||(this._Par=r(e.Paragraph,this,"ParentParagraphOrNull",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentTableCell",{get:function(){return this._Pare||(this._Pare=r(e.TableCell,this,"ParentTableCell",!1,4)),this._Pare},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"parentTableCellOrNull",{get:function(){return this._Paren||(this._Paren=r(e.TableCell,this,"ParentTableCellOrNull",!1,4)),this._Paren},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"richText",{get:function(){return this._R||(this._R=r(e.RichText,this,"RichText",!1,4)),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"table",{get:function(){return this._T||(this._T=r(e.Table,this,"Table",!1,4)),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"clientUrl",{get:function(){return p("clientUrl",this._C,Oe,this._isNull),d("Paragraph.clientUrl",n,"1.22",t),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"id",{get:function(){return p("id",this._I,Oe,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"type",{get:function(){return p("type",this._Ty,Oe,this._isNull),this._Ty},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Oe,this._isNull),this.__R},enumerable:!0,configurable:!0}),a.prototype.set=function(e,t){this._recursivelySet(e,t,[],["richText","image","table"],["inkWords","outline","paragraphs","parentParagraph","parentParagraphOrNull","parentTableCell","parentTableCellOrNull"])},a.prototype.update=function(e){this._recursivelyUpdate(e)},a.prototype.addNoteTag=function(t,n){return o(e.NoteTag,this,"AddNoteTag",0,[t,n],!1,!0,null,0)},a.prototype.delete=function(){s(this,"Delete",0,[],0,0)},a.prototype.getParagraphInfo=function(){return s(this,"GetParagraphInfo",0,[],0,0)},a.prototype.insertHtmlAsSibling=function(e,t){s(this,"InsertHtmlAsSibling",0,[e,t],0,0)},a.prototype.insertImageAsSibling=function(t,n,r,i){return o(e.Image,this,"InsertImageAsSibling",0,[t,n,r,i],!1,!0,null,0)},a.prototype.insertRichTextAsSibling=function(t,n){return o(e.RichText,this,"InsertRichTextAsSibling",0,[t,n],!1,!0,null,0)},a.prototype.insertTableAsSibling=function(t,n,r,i){return o(e.Table,this,"InsertTableAsSibling",0,[t,n,r,i],!1,!0,null,0)},a.prototype.select=function(e){d("Paragraph.select",n,"1.19",t),s(this,"Select",0,[e],0,0)},a.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},a.prototype._handleResult=function(e){if(i.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.ClientUrl)||(this._C=t.ClientUrl),f(t.Id)||(this._I=t.Id),f(t.Type)||(this._Ty=t.Type),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["image","Image","inkWords","InkWords","outline","Outline","paragraphs","Paragraphs","parentParagraph","ParentParagraph","parentParagraphOrNull","ParentParagraphOrNull","parentTableCell","ParentTableCell","parentTableCellOrNull","ParentTableCellOrNull","richText","RichText","table","Table"])}},a.prototype.load=function(e){return h(this,e)},a.prototype.retrieve=function(e){return g(this,e)},a.prototype._handleIdResult=function(e){i.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},a.prototype._handleRetrieveResult=function(e,t){i.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},a.prototype.track=function(){return this.context.trackedObjects.add(this),this},a.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},a.prototype.toJSON=function(){return m(this,{clientUrl:this._C,id:this._I,type:this._Ty},{image:this._Im,inkWords:this._In,paragraphs:this._P,richText:this._R,table:this._T})},a.prototype.setMockData=function(e){b(this,e)},a.prototype.ensureUnchanged=function(e){c(this,e)},a}(OfficeExtension.ClientObject);e.Paragraph=Se;var Ce="ParagraphCollection",Ie=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"ParagraphCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,Ce,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,Ce,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Ce,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.Paragraph,this,[t])},n.prototype.getItemAt=function(t){return o(e.Paragraph,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.Paragraph,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.Paragraph,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.Paragraph,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.ParagraphCollection=Ie;var Ae="NoteTag",Pe=function(o){function i(){return null!==o&&o.apply(this,arguments)||this}return __extends(i,o),Object.defineProperty(i.prototype,"_className",{get:function(){return"NoteTag"},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyNames",{get:function(){return["id","type","status"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","Type","Status"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_navigationPropertyNames",{get:function(){return["tagIcon"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"tagIcon",{get:function(){return d("NoteTag.tagIcon",n,"1.3",t),this._T||(this._T=r(e.TagIcon,this,"TagIcon",!1,4)),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"id",{get:function(){return p("id",this._I,Ae,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"status",{get:function(){return p("status",this._S,Ae,this._isNull),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"type",{get:function(){return p("type",this._Ty,Ae,this._isNull),this._Ty},enumerable:!0,configurable:!0}),i.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},i.prototype._handleResult=function(e){if(o.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.Id)||(this._I=t.Id),f(t.Status)||(this._S=t.Status),f(t.Type)||(this._Ty=t.Type),v(this,t,["tagIcon","TagIcon"])}},i.prototype.load=function(e){return h(this,e)},i.prototype.retrieve=function(e){return g(this,e)},i.prototype._handleIdResult=function(e){o.prototype._handleIdResult.call(this,e),l(e)||f(e.Id)||(this._I=e.Id)},i.prototype._handleRetrieveResult=function(e,t){o.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},i.prototype.track=function(){return this.context.trackedObjects.add(this),this},i.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},i.prototype.toJSON=function(){return m(this,{id:this._I,status:this._S,type:this._Ty},{tagIcon:this._T})},i.prototype.setMockData=function(e){b(this,e)},i.prototype.ensureUnchanged=function(e){c(this,e)},i}(OfficeExtension.ClientObject);e.NoteTag=Pe;var Ee="NoteTagCollection",Re=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"NoteTagCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,Ee,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,Ee,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Ee,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.NoteTag,this,[t])},n.prototype.getItemAt=function(t){return o(e.NoteTag,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.NoteTag,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.NoteTag,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.NoteTag,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.NoteTagCollection=Re;var Te="RichText",we=function(o){function i(){return null!==o&&o.apply(this,arguments)||this}return __extends(i,o),Object.defineProperty(i.prototype,"_className",{get:function(){return"RichText"},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyNames",{get:function(){return["text","_ReferenceId","id","languageId","style"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Text","_ReferenceId","Id","LanguageId","Style"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_navigationPropertyNames",{get:function(){return["paragraph"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"paragraph",{get:function(){return this._P||(this._P=r(e.Paragraph,this,"Paragraph",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"id",{get:function(){return p("id",this._I,Te,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"languageId",{get:function(){return p("languageId",this._L,Te,this._isNull),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"style",{get:function(){return p("style",this._S,Te,this._isNull),d("RichText.style",n,"1.8",t),this._S},set:function(e){this._S=e,u(this,"Style",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"text",{get:function(){return p("text",this._T,Te,this._isNull),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Te,this._isNull),this.__R},enumerable:!0,configurable:!0}),i.prototype.set=function(e,t){this._recursivelySet(e,t,["style"],[],["paragraph"])},i.prototype.update=function(e){this._recursivelyUpdate(e)},i.prototype.getHtml=function(){return s(this,"GetHtml",1,[],4,0)},i.prototype.select=function(e){d("RichText.select",n,"1.19",t),s(this,"Select",0,[e],0,0)},i.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},i.prototype._handleResult=function(e){if(o.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.Id)||(this._I=t.Id),f(t.LanguageId)||(this._L=t.LanguageId),f(t.Style)||(this._S=t.Style),f(t.Text)||(this._T=t.Text),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["paragraph","Paragraph"])}},i.prototype.load=function(e){return h(this,e)},i.prototype.retrieve=function(e){return g(this,e)},i.prototype._handleIdResult=function(e){o.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},i.prototype._handleRetrieveResult=function(e,t){o.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},i.prototype.track=function(){return this.context.trackedObjects.add(this),this},i.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},i.prototype.toJSON=function(){return m(this,{id:this._I,languageId:this._L,style:this._S,text:this._T},{})},i.prototype.setMockData=function(e){b(this,e)},i.prototype.ensureUnchanged=function(e){c(this,e)},i}(OfficeExtension.ClientObject);e.RichText=we;var xe="Image",Ne=function(o){function i(){return null!==o&&o.apply(this,arguments)||this}return __extends(i,o),Object.defineProperty(i.prototype,"_className",{get:function(){return"Image"},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyNames",{get:function(){return["description","height","hyperlink","width","_ReferenceId","id","ocrData"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Description","Height","Hyperlink","Width","_ReferenceId","Id","OcrData"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyUpdateable",{get:function(){return[!0,!0,!0,!0,!1,!1,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_navigationPropertyNames",{get:function(){return["paragraph","pageContent"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"pageContent",{get:function(){return this._P||(this._P=r(e.PageContent,this,"PageContent",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"paragraph",{get:function(){return this._Pa||(this._Pa=r(e.Paragraph,this,"Paragraph",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"description",{get:function(){return p("description",this._D,xe,this._isNull),this._D},set:function(e){this._D=e,u(this,"Description",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"height",{get:function(){return p("height",this._H,xe,this._isNull),this._H},set:function(e){this._H=e,u(this,"Height",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"hyperlink",{get:function(){return p("hyperlink",this._Hy,xe,this._isNull),this._Hy},set:function(e){this._Hy=e,u(this,"Hyperlink",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"id",{get:function(){return p("id",this._I,xe,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"ocrData",{get:function(){return p("ocrData",this._O,xe,this._isNull),this._O},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"width",{get:function(){return p("width",this._W,xe,this._isNull),this._W},set:function(e){this._W=e,u(this,"Width",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,xe,this._isNull),this.__R},enumerable:!0,configurable:!0}),i.prototype.set=function(e,t){this._recursivelySet(e,t,["description","height","hyperlink","width"],[],["pageContent","paragraph"])},i.prototype.update=function(e){this._recursivelyUpdate(e)},i.prototype.delete=function(){d("Image.delete",n,"1.18",t),s(this,"Delete",0,[],0,0)},i.prototype.getBase64Image=function(){return s(this,"GetBase64Image",1,[],4,0)},i.prototype.select=function(e){d("Image.select",n,"1.19",t),s(this,"Select",0,[e],0,0)},i.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},i.prototype._handleResult=function(e){if(o.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.Description)||(this._D=t.Description),f(t.Height)||(this._H=t.Height),f(t.Hyperlink)||(this._Hy=t.Hyperlink),f(t.Id)||(this._I=t.Id),f(t.OcrData)||(this._O=t.OcrData),f(t.Width)||(this._W=t.Width),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["pageContent","PageContent","paragraph","Paragraph"])}},i.prototype.load=function(e){return h(this,e)},i.prototype.retrieve=function(e){return g(this,e)},i.prototype._handleIdResult=function(e){o.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},i.prototype._handleRetrieveResult=function(e,t){o.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},i.prototype.track=function(){return this.context.trackedObjects.add(this),this},i.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},i.prototype.toJSON=function(){return m(this,{description:this._D,height:this._H,hyperlink:this._Hy,id:this._I,ocrData:this._O,width:this._W},{})},i.prototype.setMockData=function(e){b(this,e)},i.prototype.ensureUnchanged=function(e){c(this,e)},i}(OfficeExtension.ClientObject);e.Image=Ne;var De="Table",ke=function(i){function a(){return null!==i&&i.apply(this,arguments)||this}return __extends(a,i),Object.defineProperty(a.prototype,"_className",{get:function(){return"Table"},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","rowCount","columnCount","borderVisible"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","RowCount","ColumnCount","BorderVisible"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_navigationPropertyNames",{get:function(){return["paragraph","rows"]},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"paragraph",{get:function(){return this._P||(this._P=r(e.Paragraph,this,"Paragraph",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"rows",{get:function(){return this._Ro||(this._Ro=r(e.TableRowCollection,this,"Rows",!0,4)),this._Ro},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"borderVisible",{get:function(){return p("borderVisible",this._B,De,this._isNull),this._B},set:function(e){this._B=e,u(this,"BorderVisible",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"columnCount",{get:function(){return p("columnCount",this._C,De,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"id",{get:function(){return p("id",this._I,De,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"rowCount",{get:function(){return p("rowCount",this._R,De,this._isNull),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,De,this._isNull),this.__R},enumerable:!0,configurable:!0}),a.prototype.set=function(e,t){this._recursivelySet(e,t,["borderVisible"],[],["paragraph","rows"])},a.prototype.update=function(e){this._recursivelyUpdate(e)},a.prototype.appendColumn=function(e){s(this,"AppendColumn",0,[e],0,0)},a.prototype.appendRow=function(t){return o(e.TableRow,this,"AppendRow",0,[t],!1,!0,null,0)},a.prototype.clear=function(){s(this,"Clear",0,[],0,0)},a.prototype.delete=function(){d("Table.delete",n,"1.19",t),s(this,"Delete",0,[],0,0)},a.prototype.getCell=function(t,n){return o(e.TableCell,this,"GetCell",1,[t,n],!1,!1,null,4)},a.prototype.insertColumn=function(e,t){s(this,"InsertColumn",0,[e,t],0,0)},a.prototype.insertRow=function(t,n){return o(e.TableRow,this,"InsertRow",0,[t,n],!1,!0,null,0)},a.prototype.select=function(e){d("Table.select",n,"1.19",t),s(this,"Select",0,[e],0,0)},a.prototype.setShadingColor=function(e){s(this,"SetShadingColor",0,[e],0,0)},a.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},a.prototype._handleResult=function(e){if(i.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.BorderVisible)||(this._B=t.BorderVisible),f(t.ColumnCount)||(this._C=t.ColumnCount),f(t.Id)||(this._I=t.Id),f(t.RowCount)||(this._R=t.RowCount),f(t._ReferenceId)||(this.__R=t._ReferenceId),v(this,t,["paragraph","Paragraph","rows","Rows"])}},a.prototype.load=function(e){return h(this,e)},a.prototype.retrieve=function(e){return g(this,e)},a.prototype._handleIdResult=function(e){i.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},a.prototype._handleRetrieveResult=function(e,t){i.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},a.prototype.track=function(){return this.context.trackedObjects.add(this),this},a.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},a.prototype.toJSON=function(){return m(this,{borderVisible:this._B,columnCount:this._C,id:this._I,rowCount:this._R},{rows:this._Ro})},a.prototype.setMockData=function(e){b(this,e)},a.prototype.ensureUnchanged=function(e){c(this,e)},a}(OfficeExtension.ClientObject);e.Table=ke;var Fe="TableRow",je=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"TableRow"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","cellCount","rowIndex"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","CellCount","RowIndex"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["cells","parentTable"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"cells",{get:function(){return this._Ce||(this._Ce=r(e.TableCellCollection,this,"Cells",!0,4)),this._Ce},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"parentTable",{get:function(){return this._P||(this._P=r(e.Table,this,"ParentTable",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"cellCount",{get:function(){return p("cellCount",this._C,Fe,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,Fe,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"rowIndex",{get:function(){return p("rowIndex",this._R,Fe,this._isNull),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Fe,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.clear=function(){s(this,"Clear",0,[],0,0)},n.prototype.insertRowAsSibling=function(t,n){return o(e.TableRow,this,"InsertRowAsSibling",0,[t,n],!1,!0,null,0)},n.prototype.setShadingColor=function(e){s(this,"SetShadingColor",0,[e],0,0)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.CellCount)||(this._C=n.CellCount),f(n.Id)||(this._I=n.Id),f(n.RowIndex)||(this._R=n.RowIndex),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["cells","Cells","parentTable","ParentTable"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{cellCount:this._C,id:this._I,rowIndex:this._R},{cells:this._Ce})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.TableRow=je;var Me="TableRowCollection",He=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"TableRowCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,Me,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,Me,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Me,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.TableRow,this,[t])},n.prototype.getItemAt=function(t){return o(e.TableRow,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.TableRow,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.TableRow,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.TableRow,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.TableRowCollection=He;var Ue="TableCell",Le=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"TableCell"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","rowIndex","cellIndex","shadingColor"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","RowIndex","CellIndex","ShadingColor"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["parentRow","paragraphs"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"paragraphs",{get:function(){return this._P||(this._P=r(e.ParagraphCollection,this,"Paragraphs",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"parentRow",{get:function(){return this._Pa||(this._Pa=r(e.TableRow,this,"ParentRow",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"cellIndex",{get:function(){return p("cellIndex",this._C,Ue,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,Ue,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"rowIndex",{get:function(){return p("rowIndex",this._R,Ue,this._isNull),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"shadingColor",{get:function(){return p("shadingColor",this._S,Ue,this._isNull),this._S},set:function(e){this._S=e,u(this,"ShadingColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Ue,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.set=function(e,t){this._recursivelySet(e,t,["shadingColor"],[],["paragraphs","parentRow"])},n.prototype.update=function(e){this._recursivelyUpdate(e)},n.prototype.appendHtml=function(e){s(this,"AppendHtml",0,[e],0,0)},n.prototype.appendImage=function(t,n,r){return o(e.Image,this,"AppendImage",0,[t,n,r],!1,!0,null,0)},n.prototype.appendRichText=function(t){return o(e.RichText,this,"AppendRichText",0,[t],!1,!0,null,0)},n.prototype.appendTable=function(t,n,r){return o(e.Table,this,"AppendTable",0,[t,n,r],!1,!0,null,0)},n.prototype.clear=function(){s(this,"Clear",0,[],0,0)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.CellIndex)||(this._C=n.CellIndex),f(n.Id)||(this._I=n.Id),f(n.RowIndex)||(this._R=n.RowIndex),f(n.ShadingColor)||(this._S=n.ShadingColor),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["paragraphs","Paragraphs","parentRow","ParentRow"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{cellIndex:this._C,id:this._I,rowIndex:this._R,shadingColor:this._S},{paragraphs:this._P})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.TableCell=Le;var Be="TableCellCollection",We=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"TableCellCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Count"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,Be,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"count",{get:function(){return p("count",this._C,Be,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Be,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getItem=function(t){return i(e.TableCell,this,[t])},n.prototype.getItemAt=function(t){return o(e.TableCell,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r.Count)||(this._C=r.Count),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.TableCell,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.TableCell,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{count:this._C},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.TableCell,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.TableCellCollection=We;var Ge="AccessibilityViolation",qe=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"_className",{get:function(){return"AccessibilityViolation"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyNames",{get:function(){return["id","type","location","name","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","Type","Location","Name","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"id",{get:function(){return p("id",this._I,Ge,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"location",{get:function(){return p("location",this._L,Ge,this._isNull),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"name",{get:function(){return p("name",this._N,Ge,this._isNull),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"type",{get:function(){return p("type",this._T,Ge,this._isNull),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Ge,this._isNull),this.__R},enumerable:!0,configurable:!0}),t.prototype.show=function(e){s(this,"Show",0,[e],0,0)},t.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},t.prototype._handleResult=function(t){if(e.prototype._handleResult.call(this,t),!l(t)){var n=t;y(this,n),f(n.Id)||(this._I=n.Id),f(n.Location)||(this._L=n.Location),f(n.Name)||(this._N=n.Name),f(n.Type)||(this._T=n.Type),f(n._ReferenceId)||(this.__R=n._ReferenceId)}},t.prototype.load=function(e){return h(this,e)},t.prototype.retrieve=function(e){return g(this,e)},t.prototype._handleIdResult=function(t){e.prototype._handleIdResult.call(this,t),l(t)||(f(t._ReferenceId)||(this.__R=t._ReferenceId),f(t.Id)||(this._I=t.Id))},t.prototype._handleRetrieveResult=function(t,n){e.prototype._handleRetrieveResult.call(this,t,n),_(this,t,n)},t.prototype.track=function(){return this.context.trackedObjects.add(this),this},t.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},t.prototype.toJSON=function(){return m(this,{id:this._I,location:this._L,name:this._N,type:this._T},{})},t.prototype.setMockData=function(e){b(this,e)},t.prototype.ensureUnchanged=function(e){c(this,e)},t}(OfficeExtension.ClientObject);e.AccessibilityViolation=qe;var Ve="AccessibilityViolationCollection",Je=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"AccessibilityViolationCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,Ve,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Ve,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getCount=function(){return s(this,"GetCount",1,[],4,0)},n.prototype.getItem=function(t){return i(e.AccessibilityViolation,this,[t])},n.prototype.getItemAt=function(t){return o(e.AccessibilityViolation,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype.isScanCompleted=function(){return s(this,"IsScanCompleted",1,[],4,0)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.AccessibilityViolation,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.AccessibilityViolation,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.AccessibilityViolation,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.AccessibilityViolationCollection=Je;var ze="AccessibilityViolationsByEntity",Ke=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"AccessibilityViolationsByEntity"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["id","entityType","entityName","violationsCount","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","EntityType","EntityName","ViolationsCount","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_navigationPropertyNames",{get:function(){return["parentSectionOrNull","parentSectionGroupOrNull"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"parentSectionGroupOrNull",{get:function(){return this._P||(this._P=r(e.SectionGroup,this,"ParentSectionGroupOrNull",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"parentSectionOrNull",{get:function(){return this._Pa||(this._Pa=r(e.Section,this,"ParentSectionOrNull",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"entityName",{get:function(){return p("entityName",this._E,ze,this._isNull),this._E},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"entityType",{get:function(){return p("entityType",this._En,ze,this._isNull),this._En},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"id",{get:function(){return p("id",this._I,ze,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"violationsCount",{get:function(){return p("violationsCount",this._V,ze,this._isNull),this._V},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,ze,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.navigate=function(){s(this,"Navigate",0,[],0,0)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(e){if(t.prototype._handleResult.call(this,e),!l(e)){var n=e;y(this,n),f(n.EntityName)||(this._E=n.EntityName),f(n.EntityType)||(this._En=n.EntityType),f(n.Id)||(this._I=n.Id),f(n.ViolationsCount)||(this._V=n.ViolationsCount),f(n._ReferenceId)||(this.__R=n._ReferenceId),v(this,n,["parentSectionGroupOrNull","ParentSectionGroupOrNull","parentSectionOrNull","ParentSectionOrNull"])}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||(f(e._ReferenceId)||(this.__R=e._ReferenceId),f(e.Id)||(this._I=e.Id))},n.prototype._handleRetrieveResult=function(e,n){t.prototype._handleRetrieveResult.call(this,e,n),_(this,e,n)},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{entityName:this._E,entityType:this._En,id:this._I,violationsCount:this._V},{parentSectionGroupOrNull:this._P,parentSectionOrNull:this._Pa})},n.prototype.setMockData=function(e){b(this,e)},n.prototype.ensureUnchanged=function(e){c(this,e)},n}(OfficeExtension.ClientObject);e.AccessibilityViolationsByEntity=Ke;var Qe="AccessibilityViolationsByEntityCollection",Xe=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return __extends(n,t),Object.defineProperty(n.prototype,"_className",{get:function(){return"AccessibilityViolationsByEntityCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"items",{get:function(){return p("items",this.m__items,Qe,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,Qe,this._isNull),this.__R},enumerable:!0,configurable:!0}),n.prototype.getCount=function(){return s(this,"GetCount",1,[],4,0)},n.prototype.getItem=function(t){return i(e.AccessibilityViolationsByEntity,this,[t])},n.prototype.getItemAt=function(t){return o(e.AccessibilityViolationsByEntity,this,"GetItemAt",1,[t],!1,!1,null,4)},n.prototype.isScanCompleted=function(){return s(this,"IsScanCompleted",1,[],4,0)},n.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},n.prototype._handleResult=function(n){if(t.prototype._handleResult.call(this,n),!l(n)){var r=n;if(y(this,r),f(r._ReferenceId)||(this.__R=r._ReferenceId),!l(r[OfficeExtension.Constants.items])){this.m__items=[];for(var o=r[OfficeExtension.Constants.items],i=0;i<o.length;i++){var s=a(e.AccessibilityViolationsByEntity,!0,this,o[i],i);s._handleResult(o[i]),this.m__items.push(s)}}}},n.prototype.load=function(e){return h(this,e)},n.prototype.retrieve=function(e){return g(this,e)},n.prototype._handleIdResult=function(e){t.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},n.prototype._handleRetrieveResult=function(n,r){var o=this;t.prototype._handleRetrieveResult.call(this,n,r),_(this,n,r,(function(t,n){return a(e.AccessibilityViolationsByEntity,!0,o,t,n)}))},n.prototype.track=function(){return this.context.trackedObjects.add(this),this},n.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},n.prototype.toJSON=function(){return m(this,{},{},this.m__items)},n.prototype.setMockData=function(t){var n=this;b(this,t,(function(t,r){return a(e.AccessibilityViolationsByEntity,!0,n,t,r)}),(function(e){return n.m__items=e}))},n}(OfficeExtension.ClientObject);e.AccessibilityViolationsByEntityCollection=Xe;var $e="TagIcon",Ye=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"_className",{get:function(){return"TagIcon"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyNames",{get:function(){return["name","type","bitmaps","noteTagShape","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Name","Type","Bitmaps","NoteTagShape","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"bitmaps",{get:function(){return p("bitmaps",this._B,$e,this._isNull),this._B},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"name",{get:function(){return p("name",this._N,$e,this._isNull),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"noteTagShape",{get:function(){return p("noteTagShape",this._No,$e,this._isNull),this._No},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"type",{get:function(){return p("type",this._T,$e,this._isNull),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,$e,this._isNull),this.__R},enumerable:!0,configurable:!0}),t.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},t.prototype._handleResult=function(t){if(e.prototype._handleResult.call(this,t),!l(t)){var n=t;y(this,n),f(n.Bitmaps)||(this._B=n.Bitmaps),f(n.Name)||(this._N=n.Name),f(n.NoteTagShape)||(this._No=n.NoteTagShape),f(n.Type)||(this._T=n.Type),f(n._ReferenceId)||(this.__R=n._ReferenceId)}},t.prototype.load=function(e){return h(this,e)},t.prototype.retrieve=function(e){return g(this,e)},t.prototype._handleIdResult=function(t){e.prototype._handleIdResult.call(this,t),l(t)||f(t._ReferenceId)||(this.__R=t._ReferenceId)},t.prototype._handleRetrieveResult=function(t,n){e.prototype._handleRetrieveResult.call(this,t,n),_(this,t,n)},t.prototype.track=function(){return this.context.trackedObjects.add(this),this},t.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},t.prototype.toJSON=function(){return m(this,{bitmaps:this._B,name:this._N,noteTagShape:this._No,type:this._T},{})},t.prototype.setMockData=function(e){b(this,e)},t.prototype.ensureUnchanged=function(e){c(this,e)},t}(OfficeExtension.ClientObject);e.TagIcon=Ye;var Ze=function(o){function i(){return null!==o&&o.apply(this,arguments)||this}return __extends(i,o),Object.defineProperty(i.prototype,"_className",{get:function(){return"NoteTagManager"},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_navigationPropertyNames",{get:function(){return["allNoteTags","featuredNoteTags"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"allNoteTags",{get:function(){return d("NoteTagManager.allNoteTags",n,"1.4",t),this._A||(this._A=r(e.NoteTagCollection,this,"AllNoteTags",!0,4)),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"featuredNoteTags",{get:function(){return d("NoteTagManager.featuredNoteTags",n,"1.4",t),this._F||(this._F=r(e.NoteTagCollection,this,"FeaturedNoteTags",!0,4)),this._F},enumerable:!0,configurable:!0}),i.prototype.getModificationResult=function(e){return s(this,"GetModificationResult",1,[e],4,0)},i.prototype.setCustomTag=function(e,t,n){return s(this,"SetCustomTag",1,[e,t,n],4,0)},i.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},i.prototype._handleResult=function(e){if(o.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),v(this,t,["allNoteTags","AllNoteTags","featuredNoteTags","FeaturedNoteTags"])}},i.prototype.load=function(e){return h(this,e)},i.prototype.retrieve=function(e){return g(this,e)},i.prototype._handleRetrieveResult=function(e,t){o.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},i.prototype.track=function(){return this.context.trackedObjects.add(this),this},i.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},i.prototype.toJSON=function(){return m(this,{},{allNoteTags:this._A,featuredNoteTags:this._F})},i.prototype.setMockData=function(e){b(this,e)},i.prototype.ensureUnchanged=function(e){c(this,e)},i}(OfficeExtension.ClientObject);e.NoteTagManager=Ze;var et="MathAssistantManager",tt=function(r){function i(){return null!==r&&r.apply(this,arguments)||this}return __extends(i,r),Object.defineProperty(i.prototype,"_className",{get:function(){return"MathAssistantManager"},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyNames",{get:function(){return["selectAndCorrectMode","settingsNumberField","settingsTrigUnitMode","sessionId","version","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyOriginalNames",{get:function(){return["SelectAndCorrectMode","SettingsNumberField","SettingsTrigUnitMode","SessionId","Version","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_scalarPropertyUpdateable",{get:function(){return[!0,!0,!0,!0,!0,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"selectAndCorrectMode",{get:function(){return p("selectAndCorrectMode",this._S,et,this._isNull),this._S},set:function(e){this._S=e,u(this,"SelectAndCorrectMode",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"sessionId",{get:function(){return p("sessionId",this._Se,et,this._isNull),d("MathAssistantManager.sessionId",n,"1.16",t),this._Se},set:function(e){this._Se=e,u(this,"SessionId",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"settingsNumberField",{get:function(){return p("settingsNumberField",this._Set,et,this._isNull),d("MathAssistantManager.settingsNumberField",n,"1.10",t),this._Set},set:function(e){this._Set=e,u(this,"SettingsNumberField",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"settingsTrigUnitMode",{get:function(){return p("settingsTrigUnitMode",this._Sett,et,this._isNull),d("MathAssistantManager.settingsTrigUnitMode",n,"1.10",t),this._Sett},set:function(e){this._Sett=e,u(this,"SettingsTrigUnitMode",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"version",{get:function(){return p("version",this._V,et,this._isNull),d("MathAssistantManager.version",n,"1.16",t),this._V},set:function(e){this._V=e,u(this,"Version",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,et,this._isNull),d("MathAssistantManager._ReferenceId",n,"1.21",t),this.__R},enumerable:!0,configurable:!0}),i.prototype.set=function(e,t){this._recursivelySet(e,t,["selectAndCorrectMode","settingsNumberField","settingsTrigUnitMode","sessionId","version"],[],[])},i.prototype.update=function(e){this._recursivelyUpdate(e)},i.prototype.convertInkStrokesToTypesetMath=function(e){s(this,"ConvertInkStrokesToTypesetMath",1,[e],4,0)},i.prototype.getActiveInkStrokes=function(){return o(e.InkStrokeCollection,this,"GetActiveInkStrokes",1,[],!0,!1,null,4)},i.prototype.getActiveMathMLs=function(){return s(this,"GetActiveMathMLs",1,[],4,0)},i.prototype.getAlternateInkStrokes=function(){return o(e.InkStrokeCollection,this,"GetAlternateInkStrokes",1,[],!0,!1,null,4)},i.prototype.getFeatureStates=function(){return d("MathAssistantManager.getFeatureStates",n,"1.14",t),s(this,"GetFeatureStates",1,[],4,0)},i.prototype.initialize=function(){s(this,"Initialize",1,[],4,0)},i.prototype.onClosing=function(){s(this,"OnClosing",1,[],4,0)},i.prototype.registerAlterationSelectedEvent=function(){s(this,"RegisterAlterationSelectedEvent",0,[],0,0)},i.prototype.registerInkSelectedForCorrectionEvent=function(){s(this,"RegisterInkSelectedForCorrectionEvent",0,[],0,0)},i.prototype.registerResetEvent=function(){s(this,"RegisterResetEvent",0,[],0,0)},i.prototype.registerRestrictionsCalculatedEvent=function(){s(this,"RegisterRestrictionsCalculatedEvent",0,[],0,0)},i.prototype.runMathImmersiveReader=function(e){d("MathAssistantManager.runMathImmersiveReader",n,"1.15",t),s(this,"RunMathImmersiveReader",1,[e],4,0)},i.prototype.showAlternatesMenu=function(e,t){s(this,"ShowAlternatesMenu",1,[e,t],4,0)},i.prototype.unregisterAlterationSelectedEvent=function(){s(this,"UnregisterAlterationSelectedEvent",0,[],0,0)},i.prototype.unregisterInkSelectedForCorrectionEvent=function(){s(this,"UnregisterInkSelectedForCorrectionEvent",0,[],0,0)},i.prototype.unregisterResetEvent=function(){s(this,"UnregisterResetEvent",0,[],0,0)},i.prototype.unregisterRestrictionsCalculatedEvent=function(){s(this,"UnregisterRestrictionsCalculatedEvent",0,[],0,0)},i.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},i.prototype._handleResult=function(e){if(r.prototype._handleResult.call(this,e),!l(e)){var t=e;y(this,t),f(t.SelectAndCorrectMode)||(this._S=t.SelectAndCorrectMode),f(t.SessionId)||(this._Se=t.SessionId),f(t.SettingsNumberField)||(this._Set=t.SettingsNumberField),f(t.SettingsTrigUnitMode)||(this._Sett=t.SettingsTrigUnitMode),f(t.Version)||(this._V=t.Version),f(t._ReferenceId)||(this.__R=t._ReferenceId)}},i.prototype.load=function(e){return h(this,e)},i.prototype.retrieve=function(e){return g(this,e)},i.prototype._handleIdResult=function(e){r.prototype._handleIdResult.call(this,e),l(e)||f(e._ReferenceId)||(this.__R=e._ReferenceId)},i.prototype._handleRetrieveResult=function(e,t){r.prototype._handleRetrieveResult.call(this,e,t),_(this,e,t)},Object.defineProperty(i.prototype,"onAlterationSelected",{get:function(){var e=this;return this.m_alterationSelected||(this.m_alterationSelected=new OfficeExtension.GenericEventHandlers(this.context,this,"AlterationSelected",{eventType:14,registerFunc:function(){return e.registerAlterationSelectedEvent()},unregisterFunc:function(){return e.unregisterAlterationSelectedEvent()},getTargetIdFunc:function(){return e._ReferenceId},eventArgsTransformFunc:function(e){var t={firstLevelIndex:e.firstLevelIndex,mathML:e.mathML,secondLevelIndex:e.secondLevelIndex,strokeIds:e.strokeIds};return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_alterationSelected},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"onInkSelectedForCorrection",{get:function(){var e=this;return this.m_inkSelectedForCorrection||(this.m_inkSelectedForCorrection=new OfficeExtension.GenericEventHandlers(this.context,this,"InkSelectedForCorrection",{eventType:15,registerFunc:function(){return e.registerInkSelectedForCorrectionEvent()},unregisterFunc:function(){return e.unregisterInkSelectedForCorrectionEvent()},getTargetIdFunc:function(){return e._ReferenceId},eventArgsTransformFunc:function(e){var t={isInSnCMode:e.isInSnCMode};return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_inkSelectedForCorrection},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"onReset",{get:function(){var e=this;return this.m_reset||(this.m_reset=new OfficeExtension.GenericEventHandlers(this.context,this,"Reset",{eventType:17,registerFunc:function(){return e.registerResetEvent()},unregisterFunc:function(){return e.unregisterResetEvent()},getTargetIdFunc:function(){return e._ReferenceId},eventArgsTransformFunc:function(e){return OfficeExtension.Utility._createPromiseFromResult({})}})),this.m_reset},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"onRestrictionsCalculated",{get:function(){var e=this;return this.m_restrictionsCalculated||(this.m_restrictionsCalculated=new OfficeExtension.GenericEventHandlers(this.context,this,"RestrictionsCalculated",{eventType:16,registerFunc:function(){return e.registerRestrictionsCalculatedEvent()},unregisterFunc:function(){return e.unregisterRestrictionsCalculatedEvent()},getTargetIdFunc:function(){return e._ReferenceId},eventArgsTransformFunc:function(e){var t={isGraphingEnabled:e.isGraphingEnabled,isKeyGraphFeaturesEnabled:e.isKeyGraphFeaturesEnabled,isSolvingEnabled:e.isSolvingEnabled,isStepByStepEnabled:e.isStepByStepEnabled};return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_restrictionsCalculated},enumerable:!0,configurable:!0}),i.prototype.track=function(){return this.context.trackedObjects.add(this),this},i.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},i.prototype.toJSON=function(){return m(this,{selectAndCorrectMode:this._S,sessionId:this._Se,settingsNumberField:this._Set,settingsTrigUnitMode:this._Sett,version:this._V},{})},i.prototype.setMockData=function(e){b(this,e)},i.prototype.ensureUnchanged=function(e){c(this,e)},i}(OfficeExtension.ClientObject);e.MathAssistantManager=tt;var nt="Transcription",rt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"_className",{get:function(){return"Transcription"},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","data"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Data"]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"data",{get:function(){return p("data",this._D,nt,this._isNull),this._D},set:function(e){this._D=e,u(this,"Data",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"_ReferenceId",{get:function(){return p("_ReferenceId",this.__R,nt,this._isNull),this.__R},enumerable:!0,configurable:!0}),t.prototype.set=function(e,t){this._recursivelySet(e,t,["data"],[],[])},t.prototype.update=function(e){this._recursivelyUpdate(e)},t.prototype.exists=function(){return s(this,"Exists",1,[],4,0)},t.prototype.notify=function(e,t){s(this,"Notify",1,[e,t],4,0)},t.prototype._KeepReference=function(){s(this,"_KeepReference",1,[],4,0)},t.prototype._handleResult=function(t){if(e.prototype._handleResult.call(this,t),!l(t)){var n=t;y(this,n),f(n.Data)||(this._D=n.Data),f(n._ReferenceId)||(this.__R=n._ReferenceId)}},t.prototype.load=function(e){return h(this,e)},t.prototype.retrieve=function(e){return g(this,e)},t.prototype._handleIdResult=function(t){e.prototype._handleIdResult.call(this,t),l(t)||f(t._ReferenceId)||(this.__R=t._ReferenceId)},t.prototype._handleRetrieveResult=function(t,n){e.prototype._handleRetrieveResult.call(this,t,n),_(this,t,n)},t.prototype.track=function(){return this.context.trackedObjects.add(this),this},t.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},t.prototype.toJSON=function(){return m(this,{data:this._D},{})},t.prototype.setMockData=function(e){b(this,e)},t.prototype.ensureUnchanged=function(e){c(this,e)},t}(OfficeExtension.ClientObject);e.Transcription=rt,function(e){e.notebook="Notebook",e.sectionGroup="SectionGroup",e.section="Section",e.page="Page",e.pageContent="PageContent"}(e.EntityType||(e.EntityType={})),function(e){e.before="Before",e.after="After"}(e.InsertLocation||(e.InsertLocation={})),function(e){e.other="Other",e.web="Web",e.uwp="UWP",e.win32="Win32",e.mac="Mac",e.ios="IOS"}(e.Platform||(e.Platform={})),function(e){e.outline="Outline",e.image="Image",e.ink="Ink",e.other="Other"}(e.PageContentType||(e.PageContentType={})),function(e){e.richText="RichText",e.image="Image",e.table="Table",e.ink="Ink",e.other="Other"}(e.ParagraphType||(e.ParagraphType={})),function(e){e.unknown="Unknown",e.toDo="ToDo",e.important="Important",e.question="Question",e.contact="Contact",e.address="Address",e.phoneNumber="PhoneNumber",e.website="Website",e.idea="Idea",e.critical="Critical",e.toDoPriority1="ToDoPriority1",e.toDoPriority2="ToDoPriority2"}(e.NoteTagType||(e.NoteTagType={})),function(e){e.unknown="Unknown",e.normal="Normal",e.completed="Completed",e.disabled="Disabled",e.outlookTask="OutlookTask",e.taskNotSyncedYet="TaskNotSyncedYet",e.taskRemoved="TaskRemoved"}(e.NoteTagStatus||(e.NoteTagStatus={})),function(e){e.form="Form",e.entity="Entity",e.graph="Graph",e.oneService="OneService",e.classNotebooks="ClassNotebooks",e.mathSolver="MathSolver",e.mathRecognizer="MathRecognizer",e.roamingSettings="RoamingSettings"}(e.ServiceId||(e.ServiceId={})),function(e){e.selection="Selection",e.activeProfile="ActiveProfile",e.liveId="LiveId",e.orgId="OrgId",e.adal="ADAL",e.notebook="Notebook"}(e.IdentityFilter||(e.IdentityFilter={})),function(e){e.none="None",e.number="Number",e.bullet="Bullet"}(e.ListType||(e.ListType={})),function(e){e.other="Other",e.liveId="LiveId",e.orgId="OrgId",e.adal="ADAL"}(e.AccountType||(e.AccountType={})),function(e){e.trace="Trace",e.data="Data",e.exception="Exception",e.warning="Warning"}(e.LogLevel||(e.LogLevel={})),function(e){e.defaultFlag="DefaultFlag",e.criticalFlag="CriticalFlag",e.measureFlag="MeasureFlag"}(e.EventFlag||(e.EventFlag={})),function(e){e.none="None",e.arabic="Arabic",e.ucroman="UCRoman",e.lcroman="LCRoman",e.ucletter="UCLetter",e.lcletter="LCLetter",e.ordinal="Ordinal",e.cardtext="Cardtext",e.ordtext="Ordtext",e.hex="Hex",e.chiManSty="ChiManSty",e.dbNum1="DbNum1",e.dbNum2="DbNum2",e.aiueo="Aiueo",e.iroha="Iroha",e.dbChar="DbChar",e.sbChar="SbChar",e.dbNum3="DbNum3",e.dbNum4="DbNum4",e.circlenum="Circlenum",e.darabic="DArabic",e.daiueo="DAiueo",e.diroha="DIroha",e.arabicLZ="ArabicLZ",e.bullet="Bullet",e.ganada="Ganada",e.chosung="Chosung",e.gb1="GB1",e.gb2="GB2",e.gb3="GB3",e.gb4="GB4",e.zodiac1="Zodiac1",e.zodiac2="Zodiac2",e.zodiac3="Zodiac3",e.tpeDbNum1="TpeDbNum1",e.tpeDbNum2="TpeDbNum2",e.tpeDbNum3="TpeDbNum3",e.tpeDbNum4="TpeDbNum4",e.chnDbNum1="ChnDbNum1",e.chnDbNum2="ChnDbNum2",e.chnDbNum3="ChnDbNum3",e.chnDbNum4="ChnDbNum4",e.korDbNum1="KorDbNum1",e.korDbNum2="KorDbNum2",e.korDbNum3="KorDbNum3",e.korDbNum4="KorDbNum4",e.hebrew1="Hebrew1",e.arabic1="Arabic1",e.hebrew2="Hebrew2",e.arabic2="Arabic2",e.hindi1="Hindi1",e.hindi2="Hindi2",e.hindi3="Hindi3",e.thai1="Thai1",e.thai2="Thai2",e.numInDash="NumInDash",e.lcrus="LCRus",e.ucrus="UCRus",e.lcgreek="LCGreek",e.ucgreek="UCGreek",e.lim="Lim",e.custom="Custom"}(e.NumberType||(e.NumberType={})),function(e){e.preinstallClassNotebook="PreinstallClassNotebook",e.distributePageId="DistributePageId",e.distributeSection="DistributeSection",e.reviewStudentWork="ReviewStudentWork",e.openTabForCreateClassNotebook="OpenTabForCreateClassNotebook",e.openTabForManageStudent="OpenTabForManageStudent",e.openTabForManageTeacher="OpenTabForManageTeacher",e.openTabForGetNotebookLink="OpenTabForGetNotebookLink",e.openTabForTeacherTraining="OpenTabForTeacherTraining",e.openTabForAddinGuide="OpenTabForAddinGuide",e.openTabForEducationBlog="OpenTabForEducationBlog",e.openTabForEducatorCommunity="OpenTabForEducatorCommunity",e.openTabToSendFeedback="OpenTabToSendFeedback",e.openTabForViewKnowledgeBase="OpenTabForViewKnowledgeBase",e.openTabForSuggestingFeature="OpenTabForSuggestingFeature",e.manageClasses="ManageClasses",e.distributePageMenu="DistributePageMenu",e.distributeSectionMenu="DistributeSectionMenu",e.reviewStudentWorkMenu="ReviewStudentWorkMenu"}(e.ControlId||(e.ControlId={})),function(e){e.none="None",e.missingAltText="MissingAltText",e.tableWithNoHeaderRow="TableWithNoHeaderRow",e.untitledPage="UntitledPage",e.unnamedSection="UnnamedSection",e.unnamedSectionGroup="UnnamedSectionGroup",e.nonDescriptiveAltText="NonDescriptiveAltText",e.nestedTable="NestedTable",e.headingOutOfOrder="HeadingOutOfOrder",e.extraOutline="ExtraOutline",e.extraWhitespace="ExtraWhitespace",e.noHeadingsInALongDocument="NoHeadingsInALongDocument",e.insufficientTextContrast="InsufficientTextContrast"}(e.AccessibilityViolationType||(e.AccessibilityViolationType={})),function(e){e.none="None",e.onHighlight="OnHighlight",e.onMultipleParagraphs="OnMultipleParagraphs",e.onOutline="OnOutline",e.onPage="OnPage",e.onParagraph="OnParagraph",e.onParagraphBegin="OnParagraphBegin",e.onParagraphEnd="OnParagraphEnd",e.onTable="OnTable",e.withinParagraph="WithinParagraph"}(e.AccessibilityViolationLocation||(e.AccessibilityViolationLocation={})),function(e){e.static="Static",e.interactive="Interactive"}(e.TagIconType||(e.TagIconType={})),function(e){e.success="Success",e.pending="Pending",e.invalidIdentity="InvalidIdentity",e.previousStorageError="PreviousStorageError",e.storageError="StorageError",e.alreadyExists="AlreadyExists",e.invalidGUID="InvalidGUID",e.invalidLabel="InvalidLabel"}(e.TagModificationResult||(e.TagModificationResult={})),function(e){e.accessDenied="AccessDenied",e.corruptedContent="CorruptedContent",e.generalException="GeneralException",e.invalidArgument="InvalidArgument",e.invalidOperation="InvalidOperation",e.invalidState="InvalidState",e.itemNotFound="ItemNotFound",e.notImplemented="NotImplemented",e.notSupported="NotSupported",e.operationAborted="OperationAborted"}(e.ErrorCodes||(e.ErrorCodes={})),e.Interfaces||(e.Interfaces={})}(OneNote||(OneNote={})),function(e){var t=function(t){function n(n){var r=t.call(this,n)||this;return r.m_onenote=new e.Application(r,OfficeExtension.ObjectPathFactory.createGlobalObjectObjectPath(r)),r._rootObject=r.m_onenote,r}return __extends(n,t),Object.defineProperty(n.prototype,"application",{get:function(){return this.m_onenote},enumerable:!0,configurable:!0}),n}(OfficeCore.RequestContext);e.RequestContext=t,e.run=function(t,n){return OfficeExtension.ClientRequestContext._runBatch("OneNote.run",arguments,(function(){return new e.RequestContext}))}}(OneNote||(OneNote={})),function(e){if(!function(){try{return"object"==typeof process&&"[object process]"===String(process)}catch(e){return!1}}()&&!e.isOfficeReactNative()){try{e.Flights=e.OUtil.parseFlights(!0),e.DisabledChangeGates=e.OUtil.parseDisabledChangeGates(!0)}catch(e){}function t(){OSFPerformance.hostSpecificFileName=e.LoadScriptHelper.getHostBundleJsName(),Office.onReadyInternal((function(){OSFPerfUtil.sendPerformanceTelemetry()})),e._OfficeAppFactory.getHostInfo().hostLocale&&setTimeout((function(){e.OUtil.ensureOfficeStringsJs().catch((function(e){console.error(e)}))}),0)}e._OfficeAppFactory.bootstrap((function(){}),(function(e){e instanceof Error?console.warn(e.message):console.warn(JSON.stringify(e))})),"complete"===document.readyState||"interactive"===document.readyState?t():window.addEventListener("DOMContentLoaded",(function(e){t()}))}}(OSF||(OSF={})),OSFPerformance.hostInitializationEnd=OSFPerformance.now(),OSFPerformance.totalJSHeapSize=OSFPerformance.getTotalJSHeapSize(),OSFPerformance.usedJSHeapSize=OSFPerformance.getUsedJSHeapSize(),OSFPerformance.jsHeapSizeLimit=OSFPerformance.getJSHeapSizeLimit();
//NULL-TERMINATED �R 0�R� *�H��
��R�0�R�10
`�He 0\
+�7�N0L0
+�70 ��� 010
`�He :>[@ �R��?���>m^�qby�?�S�^�r��
�0��0���3 H��ߡ��w 0
*�H��
0��10 UUS10U
Washington10URedmond10U
Microsoft Corporation1200U)Microsoft Root Certificate Authority 20100
240808213623Z
350623220401Z0_10 UUS10U
Microsoft Corporation100.U'Microsoft Windows Code Signing PCA 20240�"0
*�H��
� 0�
� �}k}'�v*.���4��+m�T� ���d��h(e;9_R]F?\���z�����^z] i��_0Oio=NA���W}���`H�?u�I��G�W����,֕oQ���Fl`v�mNdBP
{���9� tP�܍�b��_k��;�3�
�9b��7�7�L��A��S�5�3���=�4�"�]�����\�zc��م����ayL�]5�:��{zc0�AZo�sXP�D��K�'9�nn���8Q�8�e���ju��NRx�F��nh�ϴ��ٲV���Pl��:9���L%�,�3����UN�`�?;}��O�J�OF
�v���aB��� �%fN�g+��^$N��e~�<��u`�����+^�s�G�G��V_�g�q-��%TQ���I���;U�f3�ȧW��&��y ��p�)l:��IS�� O��,��1§��
t1�K@��� ι��u+��9(�uժ�_�/x���J u0\5�:���ߤ�� (� ��F0�B0U��0 +�7 0U����4�ګ�e����0 +�7
S u b C A0U�0�0U#0��Vˏ�\bh�=��[�Κ�0VUO0M0K�I�G�Ehttp://crl.microsoft.com/pki/crl/products/MicRooCerAut_2010-06-23.crl0Z+N0L0J+0�>http://www.microsoft.com/pki/certs/MicRooCerAut_2010-06-23.crt0
*�H��
� C_��?�锌;\��h���T4�1 L������E��pj3!�Θ�A~L�"�0))��?���E)�κE��'�T�X��ٖ���Tx*:Қj�;:�7o�Sn>�Ą�|�$�����.9`�qҬ1��i ��jcG���᨞7_��
��eN�/k�ц���o�Ly�Ni(��e�F5g
��[q���ZI}��!?�2��Ke��MԦGc�:�s��QI!!w��\�yMx�J�*�g4��?#��~�������v̋��Z����9PXGd��M��r�l� ��q���1��g�B��0�')��*E���]l�ߥ�NtX1�A�=|�����
m5�߈��!�9#�0&8��d4;��q�y�!=N�Q��O��QV�~崀�y .�c�~�xD�ɻۣ��
��1~`���m~iˈLH����}�UK��4�.'��5
���rw�>]�T�*� ��D��d)�Uw0�-0��3 ¼��x?"� �0
*�H��
0_10 UUS10U
Microsoft Corporation100.U'Microsoft Windows Code Signing PCA 20240
250619180325Z
260618180325Z0t10 UUS10U
Washington10URedmond10U
Microsoft Corporation10UMicrosoft Corporation0�"0
*�H��
� 0�
� �T'�V�W�`/�vE�7H~;�X:V�a�+�O;�Y�D�:�����~X�mg�/�L�#�܀R<�О��4ia�.�T*��V�ԆI�6�N<���C�M��*��\���h���ɫ�f��n�n�
��s�f�g
"k�9������|��I�����NH� $�p�*S�"�D��[�A�Fݧ�TC����U��(��^��b��}���h�R+<^ ���Le�k�8P�I�!��L��0*�H��m��B��B�C�:52`/�ѸGyV�o�������j����_ɸ��$��.�O#��ϋ�\X6��7�9w�:�|0����9��%Ir�ТO�*�i������
Ѳ�Go���p�Qz�4(�Gd���J���I*��K9և^1��-
*x�ӕbh79��^�'�-w׳�����B3����x+��������r9[sbu�j�
ѷ�"�XG���8��6V�6���$���c=�a�j��,����B�M�� ���0��0U��0,U%%0#+
+�7=+�7L0U�0 0U��2� ����F$+�{���rP�0TUM0K�I0G1-0+U$Microsoft Ireland Operations Limited10U
500814+5055740U#0�����4�ګ�e����0jUc0a0_�]�[�Yhttp://www.microsoft.com/pkiops/crl/Microsoft%20Windows%20Code%20Signing%20PCA%202024.crl0w+k0i0g+0�[http://www.microsoft.com/pkiops/certs/Microsoft%20Windows%20Code%20Signing%20PCA%202024.crt0
*�H��
� \NN�
~�H��>