Mini Kabibi Habibi

Current Path : C:/Program Files/Microsoft Office/root/Office16/
Upload File :
Current File : C:/Program Files/Microsoft Office/root/Office16/word-launchevent-host.win32.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||{}),(OSF||(OSF={})).definePropertyOnNamespace=function(e,t,n){Object.defineProperty(e,t,{get:function(){return n()},configurable:!0,enumerable:!0})},OSFPerformance.hostInitializationStart=OSFPerformance.now(),function(e){var t;function n(){return t.m_association||(t.m_association=new OSF.Association),t.m_association}(t=e.actions||(e.actions={})).m_association=t.m_association,t.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}})}),n().associate.apply(n(),arguments)},OSF.definePropertyOnNamespace(t,"_association",n)}(Office=Office||{}),function(e){var t;(t=e.AgaveHostAction||(e.AgaveHostAction={}))[t.Select=0]="Select",t[t.UnSelect=1]="UnSelect",t[t.CancelDialog=2]="CancelDialog",t[t.InsertAgave=3]="InsertAgave",t[t.CtrlF6In=4]="CtrlF6In",t[t.CtrlF6Exit=5]="CtrlF6Exit",t[t.CtrlF6ExitShift=6]="CtrlF6ExitShift",t[t.SelectWithError=7]="SelectWithError",t[t.NotifyHostError=8]="NotifyHostError",t[t.RefreshAddinCommands=9]="RefreshAddinCommands",t[t.PageIsReady=10]="PageIsReady",t[t.TabIn=11]="TabIn",t[t.TabInShift=12]="TabInShift",t[t.TabExit=13]="TabExit",t[t.TabExitShift=14]="TabExitShift",t[t.EscExit=15]="EscExit",t[t.F2Exit=16]="F2Exit",t[t.ExitNoFocusable=17]="ExitNoFocusable",t[t.ExitNoFocusableShift=18]="ExitNoFocusableShift",t[t.MouseEnter=19]="MouseEnter",t[t.MouseLeave=20]="MouseLeave",t[t.UpdateTargetUrl=21]="UpdateTargetUrl",t[t.InstallCustomFunctions=22]="InstallCustomFunctions",t[t.SendTelemetryEvent=23]="SendTelemetryEvent",t[t.UninstallCustomFunctions=24]="UninstallCustomFunctions",t[t.SendMessage=25]="SendMessage",t[t.LaunchExtensionComponent=26]="LaunchExtensionComponent",t[t.StopExtensionComponent=27]="StopExtensionComponent",t[t.RestartExtensionComponent=28]="RestartExtensionComponent",t[t.EnableTaskPaneHeaderButton=29]="EnableTaskPaneHeaderButton",t[t.DisableTaskPaneHeaderButton=30]="DisableTaskPaneHeaderButton",t[t.TaskPaneHeaderButtonClicked=31]="TaskPaneHeaderButtonClicked",t[t.RemoveAppCommandsAddin=32]="RemoveAppCommandsAddin",t[t.RefreshRibbonGallery=33]="RefreshRibbonGallery",t[t.GetOriginalControlId=34]="GetOriginalControlId",t[t.OfficeJsReady=35]="OfficeJsReady",t[t.InsertDevManifest=36]="InsertDevManifest",t[t.InsertDevManifestError=37]="InsertDevManifestError",t[t.SendCustomerContent=38]="SendCustomerContent",t[t.KeyboardShortcuts=39]="KeyboardShortcuts",t[t.CloseSDXDialog=42]="CloseSDXDialog",t[t.ResizeSDXDialog=43]="ResizeSDXDialog",t[t.SendNonStandardEvent=44]="SendNonStandardEvent"}(OSF=OSF||{}),function(o){var e=(t.prototype.initializeEventHandler=function(e){var t=this;this.addHandlerAsync(o.EventType.AppCommandInvoked,function(e){t._processAppCommandInvocation(e)},e)},t.prototype.appCommandInvocationCompletedAsync=function(t,n,r,e){o._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}},e)},t.prototype.addHandlerAsync=function(e,t,n){o.EventHelper.addEventHandler(e,t,n,this._eventDispatch,void 0,o.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(n){var e,r,o=this;try{e=JSON.parse(n.eventObjStr),r=JSON.parse(n.eventObjStr)}catch(e){}return r=r||{},(e=e||{}).completed=function(e){r.completedContext=e;var t=JSON.stringify(r);o._invokeAppCommandCompletedMethod(n.appCommandId,0,t)},e},t.initialize=function(){null==t._instance&&(t._instance=new t).initializeEventHandler(function(e){e.status!==Office.AsyncResultStatus.Succeeded&&console.error("Cannot initialize app command: "+JSON.stringify(e))})},t._instance=null,t);function t(){var r=this;this._processAppCommandInvocation=function(e){var t=r._verifyManifestCallback(e.callbackName);if(0==t.errorCode){var n=r._constructEventObjectForCallback(e);n?window.setTimeout(function(){t.callback(n)},0):r._invokeAppCommandCompletedMethod(e.appCommandId,5001,"")}else r._invokeAppCommandCompletedMethod(e.appCommandId,t.errorCode,"")},this._eventDispatch=new o.EventDispatch([{type:o.EventType.AppCommandInvoked,id:o.EventDispId.dispidAppCommandInvokedEvent,getTargetId:function(){return""},fromSafeArrayHost:function(e){return{type:o.EventType.AppCommandInvoked,appCommandId:e[0],callbackName:e[1],eventObjStr:e[2]}},fromWebHost:function(e){return{type:o.EventType.AppCommandInvoked,appCommandId:e[0],callbackName:e[1],eventObjStr:e[2]}}}])}o.AppCommandManager=e}(OSF=OSF||{}),function(e){var t;(t=e.AppName||(e.AppName={}))[t.Unsupported=0]="Unsupported",t[t.Excel=1]="Excel",t[t.Word=2]="Word",t[t.PowerPoint=4]="PowerPoint",t[t.Outlook=8]="Outlook",t[t.ExcelWebApp=16]="ExcelWebApp",t[t.WordWebApp=32]="WordWebApp",t[t.OutlookWebApp=64]="OutlookWebApp",t[t.Project=128]="Project",t[t.AccessWebApp=256]="AccessWebApp",t[t.PowerpointWebApp=512]="PowerpointWebApp",t[t.ExcelIOS=1024]="ExcelIOS",t[t.Sway=2048]="Sway",t[t.WordIOS=4096]="WordIOS",t[t.PowerPointIOS=8192]="PowerPointIOS",t[t.Access=16384]="Access",t[t.Lync=32768]="Lync",t[t.OutlookIOS=65536]="OutlookIOS",t[t.OneNoteWebApp=131072]="OneNoteWebApp",t[t.OneNote=262144]="OneNote",t[t.ExcelWinRT=524288]="ExcelWinRT",t[t.WordWinRT=1048576]="WordWinRT",t[t.PowerpointWinRT=2097152]="PowerpointWinRT",t[t.OutlookAndroid=4194304]="OutlookAndroid",t[t.OneNoteWinRT=8388608]="OneNoteWinRT",t[t.ExcelAndroid=8388609]="ExcelAndroid",t[t.VisioWebApp=8388610]="VisioWebApp",t[t.OneNoteIOS=8388611]="OneNoteIOS",t[t.WordAndroid=8388613]="WordAndroid",t[t.PowerpointAndroid=8388614]="PowerpointAndroid",t[t.Visio=8388615]="Visio",t[t.OneNoteAndroid=4194305]="OneNoteAndroid"}(OSF=OSF||{}),function(e){var t=(n.prototype.associate=function(e,t){function n(e){"undefined"!=typeof console&&console.warn&&console.warn(e)}if(1==arguments.length&&"object"==typeof e&&e){var r=e;for(var o in r)this.associate(o,r[o])}else if(2==arguments.length){var i=e,a=t;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")},n.prototype.onchange=function(e){e&&this.m_onchangeHandlers.push(e)},Object.defineProperty(n.prototype,"mappings",{get:function(){return this.m_mappings},enumerable:!0,configurable:!0}),n);function n(){this.m_mappings={},this.m_onchangeHandlers=[]}e.Association=t}(OSF=OSF||{}),function(e){var t=(n.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)}},n);function n(){}e.AsyncMethodExecutor=t}(OSF=OSF||{}),function(d){var e=(t.prototype.handleSafeArrayHostResponse=function(e,t,n,r,o,i,a){var s,c;if(1==(c="number"==typeof(e=d.Utility.fromSafeArray(e))?(s=[],e):(s=e)[0]))return null!=(l=s[1])&&(n[l[0]]=l[1]),!1;if(r){var l;if(0==c){if(2<s.length){l=[];for(var u=1;u<s.length;u++)l[u-1]=s[u]}else l=s[1];if(0<n.length&&null!=l){var p=l[l.length-1];n.length==p?l[l.length-1]=n:c=5001}}else l=s[1];var f=null;0==c&&(f=o.fromSafeArrayHost(l)),this._asyncMethodExecutor.invokeCallback(i,r,c,f,a)}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);function t(e){this._asyncMethodExecutor=e}d.AsyncMethodExecutorHelper=e}(OSF=OSF||{}),function(e){!function(e){var t,n,r,o;t=e.AsyncResultEnum||(e.AsyncResultEnum={}),(n=t.Properties||(t.Properties={})).Context="Context",n.Value="Value",n.Status="Status",n.Error="Error",(r=t.ErrorCode||(t.ErrorCode={}))[r.Success=0]="Success",r[r.Failed=1]="Failed",(o=t.ErrorProperties||(t.ErrorProperties={})).Name="Name",o.Message="Message",o.Code="Code";function i(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 a(t.Name,t.Message,t.Code))}e.AsyncResult=i;var a=function(e,t,n){this.name=e,this.message=t,this.code=n};e.Error=a}(e.DDA||(e.DDA={}))}(OSF=OSF||{}),function(n){var e;(e=n.BootStrapExtension||(n.BootStrapExtension={})).createWebClientHostControllerHelper=function(e,t){return new n.WebClientHostControllerHelper(e,t)},e.createAsyncMethodExecutorHelper=function(e){return new n.AsyncMethodExecutorHelper(e)}}(OSF=OSF||{}),function(e){var t;(t=e.ConstantNames||(e.ConstantNames={})).DefaultLocale="en-us",t.OfficeJS="office.js",t.OfficeDebugJS="office.debug.js",t.OfficeStringsId="OFFICESTRINGS",t.OfficeJsId="OFFICEJS",t.HostFileId="HOST",t.OfficeStringJS="office_strings.js",t.OfficeStringDebugJS="office_strings.debug.js",t.FileVersion="0.0.0.0"}(OSF=OSF||{}),function(e){var t=(n.NotificationConversationIdSuffix="_ntf",n);function n(){}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){var t,n,r,o;t=e.DDA||(e.DDA={}),n=t.ErrorCodeManager||(t.ErrorCodeManager={}),o=!(r={}),n.getErrorArgs=function(e){var t;o||(t=Strings.OfficeOM,r[1e3]={name:t.L_InvalidCoercion,message:t.L_CoercionTypeNotSupported},r[1001]={name:t.L_DataReadError,message:t.L_GetSelectionNotSupported},r[1002]={name:t.L_InvalidCoercion,message:t.L_CoercionTypeNotMatchBinding},r[1003]={name:t.L_DataReadError,message:t.L_InvalidGetRowColumnCounts},r[1004]={name:t.L_DataReadError,message:t.L_SelectionNotSupportCoercionType},r[1005]={name:t.L_DataReadError,message:t.L_InvalidGetStartRowColumn},r[1006]={name:t.L_DataReadError,message:t.L_NonUniformPartialGetNotSupported},r[1008]={name:t.L_DataReadError,message:t.L_GetDataIsTooLarge},r[1009]={name:t.L_DataReadError,message:t.L_FileTypeNotSupported},r[1010]={name:t.L_DataReadError,message:t.L_GetDataParametersConflict},r[1011]={name:t.L_DataReadError,message:t.L_InvalidGetColumns},r[1012]={name:t.L_DataReadError,message:t.L_InvalidGetRows},r[1013]={name:t.L_DataReadError,message:t.L_InvalidReadForBlankRow},r[2e3]={name:t.L_DataWriteError,message:t.L_UnsupportedDataObject},r[2001]={name:t.L_DataWriteError,message:t.L_CannotWriteToSelection},r[2002]={name:t.L_DataWriteError,message:t.L_DataNotMatchSelection},r[2003]={name:t.L_DataWriteError,message:t.L_OverwriteWorksheetData},r[2004]={name:t.L_DataWriteError,message:t.L_DataNotMatchBindingSize},r[2005]={name:t.L_DataWriteError,message:t.L_InvalidSetStartRowColumn},r[2006]={name:t.L_InvalidFormat,message:t.L_InvalidDataFormat},r[2007]={name:t.L_InvalidDataObject,message:t.L_DataNotMatchCoercionType},r[2008]={name:t.L_InvalidDataObject,message:t.L_DataNotMatchBindingType},r[2009]={name:t.L_DataWriteError,message:t.L_SetDataIsTooLarge},r[2010]={name:t.L_DataWriteError,message:t.L_NonUniformPartialSetNotSupported},r[2011]={name:t.L_DataWriteError,message:t.L_InvalidSetColumns},r[2012]={name:t.L_DataWriteError,message:t.L_InvalidSetRows},r[2013]={name:t.L_DataWriteError,message:t.L_SetDataParametersConflict},r[3e3]={name:t.L_BindingCreationError,message:t.L_SelectionCannotBound},r[3002]={name:t.L_InvalidBindingError,message:t.L_BindingNotExist},r[3003]={name:t.L_BindingCreationError,message:t.L_BindingToMultipleSelection},r[3004]={name:t.L_BindingCreationError,message:t.L_InvalidSelectionForBindingType},r[3005]={name:t.L_InvalidBindingOperation,message:t.L_OperationNotSupportedOnThisBindingType},r[3006]={name:t.L_BindingCreationError,message:t.L_NamedItemNotFound},r[3007]={name:t.L_BindingCreationError,message:t.L_MultipleNamedItemFound},r[3008]={name:t.L_BindingCreationError,message:t.L_InvalidNamedItemForBindingType},r[3009]={name:t.L_InvalidBinding,message:t.L_UnknownBindingType},r[3010]={name:t.L_InvalidBindingOperation,message:t.L_OperationNotSupportedOnMatrixData},r[3011]={name:t.L_InvalidBinding,message:t.L_InvalidColumnsForBinding},r[4e3]={name:t.L_ReadSettingsError,message:t.L_SettingNameNotExist},r[4001]={name:t.L_SaveSettingsError,message:t.L_SettingsCannotSave},r[4002]={name:t.L_SettingsStaleError,message:t.L_SettingsAreStale},r[5e3]={name:t.L_HostError,message:t.L_OperationNotSupported},r[5001]={name:t.L_InternalError,message:t.L_InternalErrorDescription},r[5002]={name:t.L_PermissionDenied,message:t.L_DocumentReadOnly},r[5003]={name:t.L_EventRegistrationError,message:t.L_EventHandlerNotExist},r[5004]={name:t.L_InvalidAPICall,message:t.L_InvalidApiCallInContext},r[5005]={name:t.L_ShuttingDown,message:t.L_ShuttingDown},r[5007]={name:t.L_UnsupportedEnumeration,message:t.L_UnsupportedEnumerationMessage},r[5008]={name:t.L_IndexOutOfRange,message:t.L_IndexOutOfRange},r[5009]={name:t.L_APINotSupported,message:t.L_BrowserAPINotSupported},r[5011]={name:t.L_APICallFailed,message:t.L_RequestTimeout},r[5012]={name:t.L_InvalidOrTimedOutSession,message:t.L_InvalidOrTimedOutSessionMessage},r[5013]={name:t.L_APICallFailed,message:t.L_InvalidApiArgumentsMessage},r[5015]={name:t.L_APICallFailed,message:t.L_WorkbookHiddenMessage},r[5016]={name:t.L_APICallFailed,message:t.L_WriteNotSupportedWhenModalDialogOpen},r[5017]={name:t.L_APICallFailed,message:t.L_UndoNotSupportedMessage},r[5100]={name:t.L_APICallFailed,message:t.L_TooManyIncompleteRequests},r[5101]={name:t.L_APICallFailed,message:t.L_RequestTokenUnavailable},r[5102]={name:t.L_APICallFailed,message:t.L_ActivityLimitReached},r[5103]={name:t.L_APICallFailed,message:t.L_RequestPayloadSizeLimitExceededMessage},r[5104]={name:t.L_APICallFailed,message:t.L_ResponsePayloadSizeLimitExceededMessage},r[6e3]={name:t.L_InvalidNode,message:t.L_CustomXmlNodeNotFound},r[6100]={name:t.L_CustomXmlError,message:t.L_CustomXmlError},r[6101]={name:t.L_CustomXmlExceedQuotaName,message:t.L_CustomXmlExceedQuotaMessage},r[6102]={name:t.L_CustomXmlOutOfDateName,message:t.L_CustomXmlOutOfDateMessage},r[7e3]={name:t.L_PermissionDenied,message:t.L_NoCapability},r[7001]={name:t.L_CannotNavigateTo,message:t.L_CannotNavigateTo},r[7002]={name:t.L_SpecifiedIdNotExist,message:t.L_SpecifiedIdNotExist},r[7004]={name:t.L_NavOutOfBound,message:t.L_NavOutOfBound},r[2014]={name:t.L_DataWriteReminder,message:t.L_CellDataAmountBeyondLimits},r[8e3]={name:t.L_MissingParameter,message:t.L_ElementMissing},r[8001]={name:t.L_PermissionDenied,message:t.L_NoCapability},r[8010]={name:t.L_InvalidValue,message:t.L_InvalidCellsValue},r[8011]={name:t.L_InvalidValue,message:t.L_InvalidTableOptionValue},r[8012]={name:t.L_InvalidValue,message:t.L_InvalidFormatValue},r[8020]={name:t.L_OutOfRange,message:t.L_RowIndexOutOfRange},r[8021]={name:t.L_OutOfRange,message:t.L_ColIndexOutOfRange},r[8022]={name:t.L_OutOfRange,message:t.L_FormatValueOutOfRange},r[8023]={name:t.L_FormattingReminder,message:t.L_CellFormatAmountBeyondLimits},r[1e4]={name:t.L_UserNotSignedIn,message:t.L_UserNotSignedIn},r[11e3]={name:t.L_MemoryLimit,message:t.L_CloseFileBeforeRetrieve},r[11001]={name:t.L_NetworkProblem,message:t.L_NetworkProblemRetrieveFile},r[11002]={name:t.L_InvalidValue,message:t.L_SliceSizeNotSupported},r[12007]={name:t.L_DisplayDialogError,message:t.L_DialogAlreadyOpened},r[12e3]={name:t.L_IndexOutOfRange,message:t.L_IndexOutOfRange},r[12001]={name:t.L_IndexOutOfRange,message:t.L_IndexOutOfRange},r[12002]={name:t.L_DisplayDialogError,message:t.L_NetworkProblem},r[12003]={name:t.L_DialogNavigateError,message:t.L_DialogInvalidScheme},r[12004]={name:t.L_DisplayDialogError,message:t.L_DialogAddressNotTrusted},r[12005]={name:t.L_DisplayDialogError,message:t.L_DialogRequireHTTPS},r[12009]={name:t.L_DisplayDialogError,message:t.L_UserClickIgnore},r[12011]={name:t.L_DisplayDialogError,message:t.L_NewWindowCrossZoneErrorString},r[13e3]={name:t.L_APINotSupported,message:t.L_InvalidSSOAddinMessage},r[13001]={name:t.L_UserNotSignedIn,message:t.L_UserNotSignedIn},r[13002]={name:t.L_UserAborted,message:t.L_UserAbortedMessage},r[13003]={name:t.L_UnsupportedUserIdentity,message:t.L_UnsupportedUserIdentityMessage},r[13004]={name:t.L_InvalidResourceUrl,message:t.L_InvalidResourceUrlMessage},r[13005]={name:t.L_InvalidGrant,message:t.L_InvalidGrantMessage},r[13006]={name:t.L_SSOClientError,message:t.L_SSOClientErrorMessage},r[13007]={name:t.L_SSOServerError,message:t.L_SSOServerErrorMessage},r[13008]={name:t.L_AddinIsAlreadyRequestingToken,message:t.L_AddinIsAlreadyRequestingTokenMessage},r[13009]={name:t.L_SSOUserConsentNotSupportedByCurrentAddinCategory,message:t.L_SSOUserConsentNotSupportedByCurrentAddinCategoryMessage},r[13010]={name:t.L_SSOConnectionLostError,message:t.L_SSOConnectionLostErrorMessage},r[13012]={name:t.L_APINotSupported,message:t.L_SSOUnsupportedPlatform},r[13013]={name:t.L_APICallFailed,message:t.L_RequestTokenUnavailable},r[5014]={name:t.L_OperationCancelledError,message:t.L_OperationCancelledErrorMessage},o=!0);var n=r[e];return n?(n.name||(n.name=r[5001].name),n.message||(n.message=r[5001].message)):n=r[5001],n},n.addErrorMessage=function(e,t){r[e]=t}}(OSF=OSF||{}),function(e){var t=(n.prototype.getSupportedEvents=function(){var e=[];for(var t in this._eventHandlers)e.push(t);return e},n.prototype.supportsEvent=function(e){for(var t in this._eventHandlers)if(e==t)return!0;return!1},n.prototype.hasEventHandler=function(e,t){var n=this._eventHandlers[e];if(n&&0<n.length)for(var r=0;r<n.length;r++)if(n[r]===t)return!0;return!1},n.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))},n.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},n.prototype.removeEventHandler=function(e,t){var n=this._eventHandlers[e];if(n&&0<n.length)for(var r=0;r<n.length;r++)if(n[r]===t)return n.splice(r,1),!0;return!1},n.prototype.clearEventHandlers=function(e){return void 0!==this._eventHandlers[e]&&0<this._eventHandlers[e].length&&(this._eventHandlers[e]=[],!0)},n.prototype.getEventHandlerCount=function(e){return null!=this._eventHandlers[e]?this._eventHandlers[e].length:-1},n.prototype.getEventInfo=function(e){return this._eventInfos[e]},n.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},n.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},n.prototype.fireQueuedEvent=function(e){if(e&&this._eventHandlers[e]){var t=this._eventHandlers[e],n=this._queuedEventsArgs[e];if(0<t.length){for(var r=t[0];0<n.length;)r(n.shift());return!0}}return!1},n.prototype.clearQueuedEvent=function(e){e&&this._eventHandlers[e]&&this._queuedEventsArgs[e]&&(this._queuedEventsArgs[e]=[])},n);function n(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]=[]}}e.EventDispatch=t}(OSF=OSF||{}),function(e){var t;(t=e.EventDispId||(e.EventDispId={})).dispidEventMin=0,t.dispidInitializeEvent=0,t.dispidSettingsChangedEvent=1,t.dispidDocumentSelectionChangedEvent=2,t.dispidBindingSelectionChangedEvent=3,t.dispidBindingDataChangedEvent=4,t.dispidDocumentOpenEvent=5,t.dispidDocumentCloseEvent=6,t.dispidActiveViewChangedEvent=7,t.dispidDocumentThemeChangedEvent=8,t.dispidOfficeThemeChangedEvent=9,t.dispidDialogMessageReceivedEvent=10,t.dispidDialogNotificationShownInAddinEvent=11,t.dispidDialogParentMessageReceivedEvent=12,t.dispidObjectDeletedEvent=13,t.dispidObjectSelectionChangedEvent=14,t.dispidObjectDataChangedEvent=15,t.dispidContentControlAddedEvent=16,t.dispidLiveShareStateChangedEvent=17,t.dispidActivationStatusChangedEvent=32,t.dispidRichApiMessageEvent=33,t.dispidAppCommandInvokedEvent=39,t.dispidOnSdxSendMessageEvent=40,t.dispidDataNodeAddedEvent=60,t.dispidDataNodeReplacedEvent=61,t.dispidDataNodeDeletedEvent=62}(OSF=OSF||{}),function(d){var e=(h.addEventHandler=function(t,n,r,o,i,e){var a=0;function s(e){0==e&&(o.hasEventHandler(t,n)||o.addEventHandler(t,n)||(e=5010)),d._OfficeAppFactory.getAsyncMethodExecutor().invokeCallback(a,r,e,null,i)}var c=o.getEventInfo(t);if(c)try{if(e)return void s(0);a=c.id;var l=c.getTargetId();0==o.getEventHandlerCount(t)?d._OfficeAppFactory.getAsyncMethodExecutor().registerEventAsync(a,c.type,l,function(e){o.fireEvent(e)},c,function(e){s(d.Utility.getErrorCodeFromAsyncResult(e))},i):s(0)}catch(e){h.onException(a,e,r)}else s(5010)},h.removeEventHandler=function(e,t,n,r,o,i){var a=0;function s(e){d._OfficeAppFactory.getAsyncMethodExecutor().invokeCallback(a,n,e,null,o)}var c=r.getEventInfo(e);if(c)try{a=c.id;var l=c.getTargetId(),u=0,p=!0;u=null===t?(p=r.clearEventHandlers(e),0):(p=r.removeEventHandler(e,t))?0:5003;var f=r.getEventHandlerCount(e);p&&0==f?d._OfficeAppFactory.getAsyncMethodExecutor().unregisterEventAsync(a,c.type,l,function(e){s(d.Utility.getErrorCodeFromAsyncResult(e))},o):s(u)}catch(e){h.onException(a,e,n)}else s(5010)},h.onException=function(e,t,n){if("number"!=typeof t)throw t;d._OfficeAppFactory.getAsyncMethodExecutor().invokeCallback(e,n,t,null)},h);function h(){}d.EventHelper=e}(OSF=OSF||{}),function(e){var t;(t=e.EventType||(e.EventType={})).ActiveViewChanged="activeViewChanged",t.AppCommandInvoked="appCommandInvoked",t.RichApiMessage="richApiMessage",t.DocumentSelectionChanged="documentSelectionChanged",t.BindingSelectionChanged="bindingSelectionChanged",t.BindingDataChanged="bindingDataChanged",t.OfficeThemeChanged="officeThemeChanged",t.DocumentThemeChanged="documentThemeChanged",t.LiveShareStateChanged="liveShareStateChanged",t.DataNodeDeleted="nodeDeleted",t.DataNodeInserted="nodeInserted",t.DataNodeReplaced="nodeReplaced",t.DialogMessageReceived="dialogMessageReceived",t.DialogParentMessageReceived="dialogParentMessageReceived",t.DialogParentEventReceived="dialogParentEventReceived",t.DialogEventReceived="dialogEventReceived",t.NodeDeleted="nodeDeleted",t.NodeInserted="nodeInserted",t.NodeReplaced="nodeReplaced",t.SettingsChanged="settingsChanged"}(OSF=OSF||{}),function(e){var t,n;function r(){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()}t=e.HostName||(e.HostName={}),r.prototype.capitalizeFirstLetter=function(e){return e?e[0].toUpperCase()+e.slice(1).toLowerCase():e},r.getInstance=function(){return void 0===r.hostObj&&(r.hostObj=new r),r.hostObj},r.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},r.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},r.prototype.getDefaultVersion=function(){return this.getHost()?"16.0.0000.0000":null},r.prototype.getDiagnostics=function(e){return{host:this.getHost(),version:e||this.getDefaultVersion(),platform:this.getPlatform()}},n=r,t.Host=n}(OSF=OSF||{}),function(e){var t;(t=e.HostInfoFlags||(e.HostInfoFlags={}))[t.SharedApp=1]="SharedApp",t[t.CustomFunction=2]="CustomFunction",t[t.ProtectedDocDisable=4]="ProtectedDocDisable",t[t.ExperimentJsEnabled=8]="ExperimentJsEnabled",t[t.PublicAddin=16]="PublicAddin",t[t.BundleJsEnabled=32]="BundleJsEnabled",t[t.IsMos=64]="IsMos",t[t.IsMonarch=128]="IsMonarch"}(OSF=OSF||{}),function(e){var t;(t=e.HostInfoHostType||(e.HostInfoHostType={})).excel="excel",t.word="word"}(OSF=OSF||{}),function(e){var t;(t=e.HostInfoPlatform||(e.HostInfoPlatform={})).web="web",t.winrt="winrt",t.win32="win32",t.mac="mac",t.ios="ios",t.android="android"}(OSF=OSF||{}),function(i){var e=(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(e){var t=i.OUtil.getSessionStorage();if(t){var n=t.getItem(i._OfficeAppFactory.getCachedSessionSettingsKey());n?e=JSON.parse(n):(n=JSON.stringify(e),t.setItem(i._OfficeAppFactory.getCachedSessionSettingsKey(),n))}var r=i.OUtil.deserializeSettings(e),o=this.createClientSettingsManager();return new Office.Settings(r,o)},t.prototype.prepareApiSurface=function(e){var t=e.get_featureGates();t&&(Microsoft.Office.WebExtension.FeatureGates=t),i.BootStrapExtension.prepareApiSurface&&i.BootStrapExtension.prepareApiSurface(),i.BootStrapExtension.prepareHostSpecificSurface&&i.BootStrapExtension.prepareHostSpecificSurface(),OSFPerformance.createOMEnd=OSFPerformance.now()},t.prototype.getTabbableElements=function(){return null},t);function t(e,t,n,r){this._hostInfo=e,this._webAppState=t,this._context=n,this._hostFacade=r}i.InitializationHelper=e}(OSF=OSF||{}),function(e){var t;(t=e.InitializationReason||(e.InitializationReason={})).Inserted="inserted",t.DocumentOpened="documentOpened"}(OSF=OSF||{}),function(l){!function(e){var i,t=null,n=!1,d=["excel","word","powerpoint","onenote","outlook","visio","office-common","office.common","office","officebase"],h=[".js",".debug.js"],g="_osfDisableHostCheck",o=function(){try{return document.currentScript}catch(e){return null}}();function r(){return a(),i.trustedTypesOptIn}function a(){if(!i){function e(e){var t=null!=e?e.src:null;if(!t)return null;for(var n=t.toLowerCase(),r=0;r<d.length;r++)for(var o=0;o<h.length;o++){var i=d[r]+h[o],a=n.indexOf(i);if(0<=a&&(0===a||"/"===t.charAt(a-1)||"\\"===t.charAt(a-1))&&(a+i.length===t.length||"?"===t.charAt(a+i.length))){var s=t.substring(0,a),c=0<n.indexOf(".debug.js",a),l=e.getAttribute("data-is-sdx"),u="1"===l||"true"===l,p=e.getAttribute("data-enable-trusted-types"),f="1"===p||"true"===p;return{basePath:s,name:i,isDebugJs:c,isSdx:u,disableHostCheck:window.hasOwnProperty(g)&&!0===window[g],trustedTypesOptIn:f}}}return null}if(!(i=e(o))){for(var t=document.getElementsByTagName("script"),n=t.length,r=0;r<n;r++)if(i=e(t[r]))return;i={basePath:"",name:"",isDebugJs:!1,isSdx:!1,disableHostCheck:!1,trustedTypesOptIn:!1}}}}e.getHostBundleJsBasePath=function(){return a(),i.basePath},e.getHostBundleJsName=function(){return a(),i.name},e.getOfficeStringJsName=function(){return a(),i.isDebugJs?l.ConstantNames.OfficeStringDebugJS:l.ConstantNames.OfficeStringJS},e.isSdx=function(){return a(),i.isSdx},e.disableHostCheck=function(){return a(),i.disableHostCheck},e.trustedTypesOptIn=r,e.loadScriptWithBasename=function(e,t,n){a();var r=e+(i.isDebugJs?".debug.js":".js");r=r.toLowerCase();var o=i.basePath+r;l.OUtil.loadScript(o,t,c())};var s=["https://alcdn.msauth.net/browser-1p/2.28.1/js/msal-browser-1p.min.js"];function c(){if(!n){n=!0;try{if(!r()||!window.trustedTypes||!window.trustedTypes.createPolicy)return null;var e=o.src,i=new URL(e).origin.toLowerCase();if(!i)return null;t=window.trustedTypes.createPolicy("officejs",{createScriptURL:function(e){var t=e.toLowerCase(),n=new URL(t).origin;if(i&&i===n)return e;for(var r=0,o=s;r<o.length;r++){if(t===o[r])return e}throw new Error("Untrusted script URL")}})}catch(e){}}return t}e.getTrustedTypesPolicy=c}(l.LoadScriptHelper||(l.LoadScriptHelper={}))}(OSF=(OSF=OSF||{})||{}),function(r){var e;((e=r.DDA||(r.DDA={})).Auth||(e.Auth={})).getAuthContextAsync=function(e){function t(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 n={toSafeArrayHost:function(){return[]},fromSafeArrayHost:function(e){try{return t(JSON.parse(e))}catch(e){return null}},toWebHost:function(){return{}},fromWebHost:function(e){return t(e)}};r._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(205,n,e)}}(OSF=OSF||{}),function(e){var t,n;(n=t=e.LiveShareStateParams||(e.LiveShareStateParams={}))[n.MaxLiveShareStateDataSizeInBytes=1024]="MaxLiveShareStateDataSizeInBytes";var r=(o.prototype.get=function(){return this._liveShareState},o.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},o.prototype.addHandlerAsync=function(e,t,n){OSF.EventHelper.addEventHandler(e,t,n,this._eventDispatch)},o.prototype.removeHandlerAsync=function(e,t,n){OSF.EventHelper.removeEventHandler(e,t,n,this._eventDispatch)},o);function o(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}}}])}e.LiveShareState=r}(Office=Office||{}),function(e){var o={"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},i={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,t){if(void 0===t&&(t="en-us"),!e)return t;var n;if((e=e.toLowerCase())in o)n=e;else{var r=e.split("-",1);r&&0<r.length&&(n=i[r[0]])}return n=n||t}}(OSF=OSF||{}),function(e){e.OfficeOM||(e.OfficeOM={})}(Strings=Strings||{}),function(o){var i,e;(i=o.OUtil||(o.OUtil={})).ensureOfficeStringsJs=function(){return e=e||(1==o.OUtil.getLibraryReleaseVehicle()?new Office.Promise(function(e,t){e()}):new Office.Promise(function(n,r){if(o._OfficeAppFactory.getHostInfo().hostLocale){var e=o.LoadScriptHelper.getHostBundleJsBasePath()+o._OfficeAppFactory.getHostInfo().hostLocale+"/"+o.LoadScriptHelper.getOfficeStringJsName();o.OUtil.loadScript(e,function(e){if(e)n();else{var t=o.LoadScriptHelper.getHostBundleJsBasePath()+o.ConstantNames.DefaultLocale+"/"+o.LoadScriptHelper.getOfficeStringJsName();i.loadScript(t,function(e){e?n():r(new Error("Cannot load "+o.ConstantNames.OfficeStringJS))},o.LoadScriptHelper.getTrustedTypesPolicy())}},o.LoadScriptHelper.getTrustedTypesPolicy())}else r(new Error("No host locale"))}))}}(OSF=OSF||{}),function(u){var e,t,n;e=u.context||(u.context={}),t=e.document||(e.document={}),OSF.definePropertyOnNamespace(t,"url",function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_docUrl()}),OSF.definePropertyOnNamespace(t,"mode",function(){return 0==OSF._OfficeAppFactory.getOfficeAppContext().get_clientMode()?u.DocumentMode.ReadOnly:u.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(e,t,n,r){var o={};o[u.GoToType.Binding]=0,o[u.GoToType.NamedItem]=1,o[u.GoToType.Slide]=2,o[u.GoToType.Index]=3;var i={};i[u.SelectionMode.Default]=0,i[u.SelectionMode.Selected]=1,i[u.SelectionMode.None]=2;var a=o[t],s=0,c=r;"function"==typeof n?c=n:void 0!==n&&(s=i[n]);var l={toSafeArrayHost:function(){return[e,a,s]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{DdaGoToByIdMethod:{Id:e,GoToType:a,SelectionMode:s}}},fromWebHost:function(e){return e}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(82,l,c)}}(Office=Office||{}),function(e){var t,n;t=e.context||(e.context={}),(n=t.messaging||(t.messaging={})).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)}},n.registerOnMessageEventHandler=function(r){if(OSF._OfficeAppFactory.getHostInfo().hostPlatform==OSF.HostInfoPlatform.web)n.onMessage=r;else{OSF._OfficeAppFactory.getClientHostController().registerEvent(OSF.EventDispId.dispidOnSdxSendMessageEvent,"","",function(e,t){var n=t.toArray();r(JSON.parse(n[0]))},null)}}}(Office=Office||{}),function(r){var e,t,o;e=r.context||(r.context={}),OSF.definePropertyOnNamespace(e,"contentLanguage",function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_dataLocale()}),OSF.definePropertyOnNamespace(e,"displayLanguage",function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_appUILocale()}),OSF.definePropertyOnNamespace(e,"partitionKey",function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_partitionKey()}),OSF.definePropertyOnNamespace(e,"isDialog",function(){return OSF._OfficeAppFactory.getHostInfo().isDialog}),OSF.definePropertyOnNamespace(e,"touchEnabled",function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_touchEnabled()}),OSF.definePropertyOnNamespace(e,"commerceAllowed",function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_commerceAllowed()}),OSF.definePropertyOnNamespace(e,"host",function(){return OSF.HostName.Host.getInstance().getHost()}),OSF.definePropertyOnNamespace(e,"platform",function(){return OSF.HostName.Host.getInstance().getPlatform()}),OSF.definePropertyOnNamespace(e,"diagnostics",function(){return OSF.HostName.Host.getInstance().getDiagnostics(OSF._OfficeAppFactory.getOfficeAppContext().get_hostFullVersion())}),OSF.definePropertyOnNamespace(e,"requirements",function(){if(!t){var e=OSF._OfficeAppFactory.getOfficeAppContext();e&&(t=e.get_isDialog()?OSF.Requirement.RequirementsMatrixFactory.getDefaultDialogRequirementMatrix(e):OSF.Requirement.RequirementsMatrixFactory.getDefaultRequirementMatrix(e))}return t}),OSF.definePropertyOnNamespace(e,"officeTheme",function(){var e=OSF._OfficeAppFactory.getOfficeAppContext().get_officeThemeFunc();return e?"function"==typeof e?e():e:void 0}),OSF.definePropertyOnNamespace(e,"webAuth",function(){if(OSF.DDA.WebAuth)return OSF.DDA.WebAuth}),OSF.definePropertyOnNamespace(e,"auth",function(){if(OSF.DDA.Auth)return OSF.DDA.Auth}),OSF.definePropertyOnNamespace(e,"license",function(){return OSF._OfficeAppFactory.getOfficeAppContext().get_eToken()}),OSF.definePropertyOnNamespace(e,"hostSettings",function(){if(!o){var e=OSF._OfficeAppFactory.getOfficeAppContext().get_hostSettingsFunc();if(void 0!==e){var t=e(),n=OSF.OUtil.deserializeSettings(t);o=new r.Settings(n,void 0)}}return o})}(Office=Office||{}),function(e){var t;((t=e.context||(e.context={})).ribbonGallery||(t.ribbonGallery={})).refreshRibbon=function(e){OSF.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[OSF._OfficeAppFactory.getWebAppState().id,OSF.AgaveHostAction.RefreshRibbonGallery,e])}}(Office=Office||{}),function(e){var t,n;t=e.context||(e.context={}),(n=t.ui||(t.ui={})).taskPaneAction||(n.taskPaneAction={})}(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(n){function t(){n._officeOnReadyState.officeOnReadyPromise||(n._officeOnReadyState.officeOnReadyPromise=new n.Promise(function(e,t){n._officeOnReadyState.officeOnReadyPromiseResolve=e}))}function r(e){return t(),e&&(n._officeOnReadyState.officeOnReadyFired?e(n._officeOnReadyState.officeOnReadyHostAndPlatformInfo):n._officeOnReadyState.officeOnReadyCallbacks.push(e)),n._officeOnReadyState.officeOnReadyPromise}n._officeOnReadyState=n._officeOnReadyState||{isOfficeOnReadyCalled:!1,officeOnReadyPromise:null,officeOnReadyPromiseResolve:null,officeOnReadyCallbacks:[],officeOnReadyHostAndPlatformInfo:null,officeOnReadyFired:!1},n.initialize=n.initialize,n.onReadyInternal=r,n.onReady=function(e){return n._officeOnReadyState.isOfficeOnReadyCalled=!0,r(e)},n.fireOnReady=function(e){for(t(),n._officeOnReadyState.officeOnReadyHostAndPlatformInfo=__assign({},e),n._officeOnReadyState.officeOnReadyFired=!0,OSFPerformance.officeOnReady=OSFPerformance.now();0<n._officeOnReadyState.officeOnReadyCallbacks.length;)n._officeOnReadyState.officeOnReadyCallbacks.shift()(n._officeOnReadyState.officeOnReadyHostAndPlatformInfo);n._officeOnReadyState.officeOnReadyPromiseResolve(n._officeOnReadyState.officeOnReadyHostAndPlatformInfo),n._officeOnReadyState.isOfficeOnReadyCalled||OSF.OUtil.waitForFunction(function(){return"function"==typeof n.initialize},function(e){e&&n.initialize(OSF._OfficeAppFactory.getOfficeAppContext().get_reason())},400,50)}}(Office=Office||{}),function(w){var e=(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);function t(e,t,n,r,o,i,a,s,c,l,u,p,f,d,h,g,m,y,_,b,v,O,C,P,S,A,I,R,T,E,N,D,x){this._id=e,this._appName=t,this._appVersion=n,this._appUILocale=r,this._dataLocale=o,this._docUrl=i,this._clientMode=a,this._settingsFunc=s,this._reason=c,this._osfControlType=l,this._eToken=u,this._correlationId=p,this._appInstanceId=f,this._touchEnabled=d,this._commerceAllowed=h,this._appMinorVersion=g,this._requirementMatrix=m,this._hostCustomMessage=y,this._hostFullVersion=_,this._isDialog=w.OUtil.isDialog(),this._clientWindowHeight=b,this._clientWindowWidth=v,this._addinName=O,this._appDomains=C,this._dialogRequirementMatrix=P,this._featureGates=S,this._officeThemeFunc=A,this._initialDisplayMode=I,this._isFromWacAutomation=R,this._wopiHostOriginForSingleSignOn=T,this._hostSettingsFunc=E,this._isWeb=N,this._nestedAppAuthBridgeType=D,this._partitionKey=x}w.OfficeAppContext=e}(OSF=OSF||{}),function(l){(l._OfficeAppFactory||(l._OfficeAppFactory={})).retrieveHostInfo=function(){var e={isO15:!0,isRichClient:!0,hostType:"",hostPlatform:"",hostSpecificFileVersion:"",hostLocale:"",osfControlAppCorrelationId:"",isDialog:!1,disableLogging:!1,flags:0},t="_host_Info",n=null;try{if(window.external=window.external||{},"undefined"!=typeof agaveHost&&agaveHost.GetHostInfo&&(window.external.GetHostInfo=function(){return agaveHost.GetHostInfo()}),window.external.GetHostInfo){var r=window.external.GetHostInfo();if("isDialog"==r)e.isO15=!0,e.isDialog=!0;else{var o=r.split(t+"=");n=1<o.length?o[1]:r}}}catch(e){l.Utility.log(JSON.stringify(e))}if(!n)try{var i=window.name;if(i){var a=JSON.parse(i);n=a?a.hostInfo:null}}catch(e){l.Utility.log(JSON.stringify(e))}n=n||l.Utility.getQueryStringValue(t);var s=l.OUtil.getSessionStorage();if(!n&&s.getItem("hostInfoValue")&&(n=s.getItem("hostInfoValue")),n){n=decodeURIComponent(n),e.isO15=!1;var c=n.split("$");void 0===c[2]&&(c=n.split("|")),e.hostType=void 0===c[0]?"":c[0].toLowerCase(),e.hostPlatform=void 0===c[1]?"":c[1].toLowerCase(),e.hostSpecificFileVersion=void 0===c[2]?"":c[2].toLowerCase(),e.hostLocale=void 0===c[3]?"":c[3].toLowerCase(),e.osfControlAppCorrelationId=void 0===c[4]?"":c[4],"telemetry"==e.osfControlAppCorrelationId&&(e.osfControlAppCorrelationId=""),e.isDialog=void 0!==c[5]&&"isDialog"==c[5],e.disableLogging=void 0!==c[6]&&"disableLogging"==c[6],e.flags="string"==typeof c[7]&&0<c[7].length?parseInt(c[7]):0,s.setItem("hostInfoValue",n)}else e.isO15=!0,e.hostLocale=l.Utility.getQueryStringValue("locale");return e}}(OSF=OSF||{}),function(f){var e;!function(e){var t,n,r,o,i,a,s,c,l;"undefined"!=typeof window&&(window.location&&(t=window.location.hash,n=window.location.search),r=window.name);var u={0:"Unknown",1:"Hidden",2:"Taskpane",3:"Dialog"};function p(e,t){f.AppCommandManager.initialize();var n=e.get_appName(),r=null;0!=(o.flags&f.HostInfoFlags.SharedApp)&&(r={visibilityMode:u[e.get_initialDisplayMode()]}),Office.fireOnReady({host:f.HostName.Host.getInstance().getHost(n),platform:f.HostName.Host.getInstance().getPlatform(n),addin:r}),o.hostPlatform==f.HostInfoPlatform.web&&null!=i.clientEndPoint&&i.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i.id,f.AgaveHostAction.OfficeJsReady,Date.now()]),t(e)}e.bootstrap=function(t,n){if(i={id:null,webAppUrl:null,conversationID:null,clientEndPoint:null,wnd:window.parent,focused:!1,serviceEndPoint:null},o=e.retrieveHostInfo(),function(){0;try{if(o.disableLogging)return 0;window.external=window.external||{},void 0===window.external.GetLoggingAllowed||window.external.GetLoggingAllowed()}catch(e){}}(),function(){if(o.hostPlatform===f.HostInfoPlatform.web)a=new f.WebInitializationHelper(o,i,null,null);else if(o.hostPlatform===f.HostInfoPlatform.win32)a=new f.RichClientInitializationHelper(o,i,null,null);else if(o.hostPlatform===f.HostInfoPlatform.ios||o.hostPlatform===f.HostInfoPlatform.mac){if(!(window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.Agave))throw f.Utility.createNotImplementedException();a=new f.WebkitInitializationHelper(o,i,null,null)}else o.hostPlatform===f.HostInfoPlatform.android||o.hostPlatform===f.HostInfoPlatform.winrt?a=new f.WebViewInitializationHelper(o,i,null,null):console.warn("Office.js is loaded inside in unknown host or platform "+o.hostPlatform)}(),a){o.hostPlatform===f.HostInfoPlatform.web&&a.saveAndSetDialogInfo(f.Utility.getQueryStringValue("_host_Info")),a.setAgaveHostCommunication(),OSFPerformance.getAppContextStart=OSFPerformance.now();a.getAppContext(window,function(e){OSFPerformance.getAppContextEnd=OSFPerformance.now(),f.AppTelemetry.initialize(e),c=e,l=a.createClientHostController(),s=a.createAsyncMethodExecutor(),a.prepareApiSurface(e),f.BootStrapExtension.onGetAppContext?f.BootStrapExtension.onGetAppContext(e,i.wnd).then(function(){p(e,t)}):p(e,t)},function(e){n(e)})}else n(new Error("Office.js cannot be initialized."))},e.getWindowName=function(){return r},e.getWindowLocationHash=function(){return t},e.getWindowLocationSearch=function(){return n},e.getAsyncMethodExecutor=function(){return s},e.getOfficeAppContext=function(){return c},e.getHostInfo=function(){return o},e.getCachedSessionSettingsKey=function(){return(null!=i.conversationID?i.conversationID:c.get_appInstanceId())+"CachedSessionSettings"},e.getWebAppState=function(){return i},e.getId=function(){return i.id},e.getInitializationHelper=function(){return a},e.getClientHostController=function(){return l}}(e=f._OfficeAppFactory||(f._OfficeAppFactory={})),f.getClientEndPoint=function(){return e.getWebAppState().clientEndPoint}}(OSF=OSF||{}),function(e){var t,n,r,o,i,a,s,c,l,u,p,f,d;(t=e.AsyncResultStatus||(e.AsyncResultStatus={})).Succeeded="succeeded",t.Failed="failed",(n=e.DocumentMode||(e.DocumentMode={})).ReadOnly="readOnly",n.ReadWrite="readWrite",(r=e.HostType||(e.HostType={})).Word="Word",r.Excel="Excel",r.PowerPoint="PowerPoint",r.Outlook="Outlook",r.OneNote="OneNote",r.Project="Project",r.Access="Access",r.Visio="Visio",(o=e.InitializationReason||(e.InitializationReason={})).Inserted="inserted",o.DocumentOpened="documentOpened",(i=e.PlatformType||(e.PlatformType={})).PC="PC",i.OfficeOnline="OfficeOnline",i.Mac="Mac",i.iOS="iOS",i.Android="Android",i.Universal="Universal",(a=e.GoToType||(e.GoToType={})).Binding="binding",a.NamedItem="namedItem",a.Slide="slide",a.Index="index",(s=e.SelectionMode||(e.SelectionMode={})).Default="default",s.Selected="selected",s.None="none",(c=e.ValueFormat||(e.ValueFormat={})).Unformatted="unformatted",c.Formatted="formatted",(l=e.FileType||(e.FileType={})).Text="text",l.Compressed="compressed",l.Pdf="pdf",e.CoercionType={Html:"html",Matrix:"matrix",Ooxml:"ooxml",OoxmlPackage:"ooxmlPackage",PdfFile:"pdfFile",SlideRange:"slideRange",Table:"table",Text:"text"},(u=e.BindingType||(e.BindingType={})).Table="table",u.Text="text",u.Matrix="matrix",(p=e.FilterType||(e.FilterType={})).OnlyVisible="onlyVisible",p.All="all",(f=e.Table||(e.Table={}))[f.All=0]="All",f[f.Data=1]="Data",f[f.Headers=2]="Headers",(d=e.ActiveView||(e.ActiveView={})).Read="read",d.Edit="edit"}(Office=Office||{});var OSFPerfUtil,__extends=this&&this.__extends||function(){var r=function(e,t){return(r=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])})(e,t)};return function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}}();(OfficeExt||(OfficeExt={})).appSpecificCheckOrigin=function(e,t,n,r){return!1},function(A){var a=(e.prototype.getMethod=function(){return this._method},e.prototype.getInvokeType=function(){return this._invokeType},e.prototype.getBlockingFlag=function(){return this._blockingOthers},e);function e(e,t,n){this._method=e,this._invokeType=t,this._blockingOthers=n}A.XdmMethodObject=a;var s=(t.prototype.getRegisterMethodObject=function(){return this._registerMethodObject},t.prototype.getUnregisterMethodObject=function(){return this._unregisterMethodObject},t);function t(e,t){this._registerMethodObject=e,this._unregisterMethodObject=t}A.XdmEventMethodObject=s;var n=(r.prototype.registerMethod=function(e,t,n,r){if(0!==n&&1!==n)throw A.Utility.createArgumentException("invokeType");var o=new a(t,n,r);this._methodObjectList[e]=o},r.prototype.unregisterMethod=function(e){delete this._methodObjectList[e]},r.prototype.registerEvent=function(e,t,n){var r=new s(new a(t,4,!1),new a(n,5,!1));this._methodObjectList[e]=r},r.prototype.registerEventEx=function(e,t,n,r,o){var i=new s(new a(t,n,!1),new a(r,o,!1));this._methodObjectList[e]=i},r.prototype.unregisterEvent=function(e){this.unregisterMethod(e)},r.prototype.registerConversation=function(e,t,n){if(A.Utility.xdmDebugLog("registerConversation: cId="+e+" Url="+t),n){if(!Array.isArray(n))throw A.Utility.createArgumentException("appDomains");this._appDomains[e]=n}this._conversations[e]={url:t}},r.prototype.unregisterConversation=function(e){delete this._conversations[e]},r.prototype.setPolicyManager=function(e){if(!e.checkPermission)throw A.Utility.createArgumentException("policyManager");this._policyManager=e},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);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}A.XdmServiceEndPoint=n;var l,o,I,R,T,E,N,D,x,i,c=(Object.defineProperty(u.prototype,"targetUrl",{get:function(){return this._targetUrl},enumerable:!0,configurable:!0}),Object.defineProperty(u.prototype,"hostTrustCheckStatus",{get:function(){return this._hostTrustCheckStatus},set:function(e){this._hostTrustCheckStatus=e},enumerable:!0,configurable:!0}),Object.defineProperty(u.prototype,"fHostTrusted",{get:function(){return this._fHostTrusted},enumerable:!0,configurable:!0}),Object.defineProperty(u.prototype,"checkStatusLogged",{get:function(){return this._checkStatusLogged},set:function(e){this._checkStatusLogged=e},enumerable:!0,configurable:!0}),Object.defineProperty(u.prototype,"checkReceiverOriginAndRun",{get:function(){return this._checkReceiverOriginAndRun},set:function(e){this._checkReceiverOriginAndRun=e},enumerable:!0,configurable:!0}),u.prototype.invoke=function(i,a,s){function e(){var t=c._callingIndex++,e=new Date,n={callback:a,createdOn:e.getTime()};s&&"object"==typeof s&&"number"==typeof s.__timeout__&&(n.timeout=s.__timeout__,delete s.__timeout__),c._callbackList[t]=n;try{if(3!==c._hostTrustCheckStatus&&"ContextActivationManager_getAppContextAsync"!==i)throw"Access Denied";var r=new m(i,0,c._conversationId,t,s),o=B.envelope(r);c._targetWindow.postMessage(o,c._targetUrl),l._startMethodTimeoutTimer()}catch(e){try{null!==a&&a(-1,e)}finally{delete c._callbackList[t]}}}var c=this;this._checkReceiverOriginAndRun?this._checkReceiverOriginAndRun(e):(this._hostTrustCheckStatus=3,e())},u.prototype.registerForEvent=function(e,t,n,r){var o=this._callingIndex++,i=new Date;this._callbackList[o]={callback:n,createdOn:i.getTime()};try{var a=new m(e,1,this._conversationId,o,r),s=B.envelope(a);this._targetWindow.postMessage(s,this._targetUrl),l._startMethodTimeoutTimer(),this._eventHandlerList[e]=t}catch(e){try{null!==n&&n(-1,e)}finally{delete this._callbackList[o]}}},u.prototype.unregisterForEvent=function(e,t,n){var r=this._callingIndex++,o=new Date;this._callbackList[r]={callback:t,createdOn:o.getTime()};try{var i=new m(e,2,this._conversationId,r,n),a=B.envelope(i);this._targetWindow.postMessage(a,this._targetUrl),l._startMethodTimeoutTimer()}catch(e){try{null!==t&&t(-1,e)}finally{delete this._callbackList[r]}}finally{delete this._eventHandlerList[e]}},u);function u(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}function w(){null!==T?N||(0<I.length?F(I.shift()):(clearInterval(T),T=null)):A.Utility.xdmDebugLog("channel is not ready.")}function F(e){N=e.getInvokeBlockingFlag(),e.invoke(),R=(new Date).getTime()}function j(){N=!1}function k(e,t){var n=!1;if(!(t&&"null"!==t&&t.length&&e&&e instanceof Array&&e.length))return n;for(var r=0;r<e.length&&!n;r++)if(-1!==e[r].indexOf("://")){var o=A.OUtil.parseUrl(t,!0);n=L(A.OUtil.parseUrl(e[r],!0),o)}return n}function M(e){if(!e||"null"===e)return!1;var t=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===A.OUtil.getCustomOfficeInitializationSettings().trustAllCloudEnvironments&&t.push("^partner\\.outlook\\.cn$","^.*\\.partner\\.officewebapps\\.cn$"),new RegExp(t.join("|")).test(e)}function H(e,t){if(!e||!t||"null"===e||"null"===t)return!1;var n=A.OUtil.parseUrl(e,!0),r=A.OUtil.parseUrl(t,!0);if(null==n||null==r)return!1;var o=n.protocol===r.protocol,i=n.port===r.port,a=r.hostname,s=n.hostname,c=a===s,l=!1;return!c&&a.length>s.length+1&&(l=a.slice(-(s.length+1))==="."+s),i&&o&&(c||l)}function L(e,t){return e.hostname==t.hostname&&e.protocol==t.protocol&&e.port==t.port}function p(t){if(""!=t.data){var n,e=t.data;try{n=B.unenvelope(e)}catch(e){return}if(A.Utility.xdmDebugLog(e),0===n._messageType){var r=null==t.origin||"null"===t.origin?n._origin:t.origin;try{var o=function(e){for(var t in D)if(D[t]._conversations[e])return D[t];throw A.Utility.createArgumentException("conversationId")}(n._conversationId);A.Utility.xdmDebugLog("_receive: request, origin="+r+" sourceURL:"+o._conversations[n._conversationId]);var i=o._conversations[n._conversationId];A.Utility.xdmDebugLog("_receive: request, origin="+r+" sourceURL:"+i.url);var a=[i.url].concat(o._appDomains[n._conversationId]);if(!k(a,t.origin))if(!OfficeExt.appSpecificCheckOrigin(a,t,n._origin,k))if(!H(i.url,t.origin))throw"Failed origin check";var s=o.getPolicyManager();if(s&&!s.checkPermission(n._conversationId,n._actionName,n._data))throw"Access Denied";var c=function(e,t){var n=e._methodObjectList[t._actionName];if(!n)throw A.Utility.xdmDebugLog("The specified method is not registered on service endpoint:"+t._actionName),A.Utility.createArgumentException("messageObject");return 0===t._actionType?n:1===t._actionType?n.getRegisterMethodObject():n.getUnregisterMethodObject()}(o,n),l=new W(t.source,r,n._actionName,n._conversationId,n._correlationId,j),u=new G(c,n._data,l,o._eventHandlerProxyList,n._conversationId,n._actionName),p=!0;null==T&&((null==R||(new Date).getTime()-R>E)&&!N?(F(u),p=!1):T=setInterval(w,E)),p&&(S=u,I.push(S))}catch(e){o&&o._onHandleRequestError&&o._onHandleRequestError(n,e);var f=-2;"Access Denied"==e&&(f=-5);var d=new U(n._actionName,n._conversationId,n._correlationId,f,0,e),h=B.envelope(d),g=!1;try{g=!(!t.source||!t.source.postMessage)}catch(e){}var m=!1;if(window.location.href&&t.origin&&"null"!==t.origin&&H(window.location.href,t.origin))m=!0;else if(t.origin&&"null"!==t.origin)m=M(A.OUtil.parseUrl(t.origin,!0).hostname);g&&m&&t.source.postMessage(h,r)}}else{if(1!==n._messageType)return;var y=(C=n._conversationId,(P=x[C])||A.Utility.xdmDebugLog("Unknown conversation Id."),P);if(!y)return;if(A.Utility.xdmDebugLog("_receive: response, origin="+t.origin+" targetURL:"+y._targetUrl),v=y._targetUrl,O=t.origin,!(v&&O&&"null"!==v&&"null"!==O&&v.length&&O.length&&L(A.OUtil.parseUrl(v,!0),A.OUtil.parseUrl(O,!0))))throw"Failed orgin check";if(3==y._hostTrustCheckStatus&&(y._fHostTrusted=!0),0===n._responseType){var _=y._callbackList[n._correlationId];if(_)try{_.callback&&_.callback(n._errorCode,n._data)}finally{delete y._callbackList[n._correlationId]}}else{var b=y._eventHandlerList[n._actionName];null!=b&&b(n._data)}}}var v,O,C,P,S}function f(){i||(function(e){if(window.addEventListener)window.addEventListener("message",e,!1);else{if(!(-1<navigator.userAgent.indexOf("MSIE")&&window.attachEvent))throw A.Utility.xdmDebugLog("Browser doesn't support the required API."),A.Utility.createArgumentException("Browser");window.attachEvent("onmessage",e)}}(p),i=!0)}A.XdmClientEndPoint=c,o=l=A.XdmCommunicationManager||(A.XdmCommunicationManager={}),I=[],T=R=null,N=!(E=10),D={},i=!(x={}),o.connect=function(e,t,n){var r=x[e];return r||(f(),r=new c(e,t,n),x[e]=r),r},o.getClientEndPoint=function(e){return x[e]},o.createServiceEndPoint=function(e){f();var t=new n(e);return D[e]=t},o.getServiceEndPoint=function(e){return D[e]},o.deleteClientEndPoint=function(e){delete x[e]},o.deleteServiceEndPoint=function(e){delete D[e]},o.checkUrlWithAppDomains=function(e,t){return k(e,t)},o.isTargetSubdomainOfSourceLocation=function(e,t){return H(e,t)},o._setMethodTimeout=function(e){0},o._startMethodTimeoutTimer=function(){},o.isHostNameValidWacDomain=function(e){return M(e)};var d=(h.prototype.getActionName=function(){return this._actionName},h.prototype.getConversationId=function(){return this._conversationId},h.prototype.getCorrelationId=function(){return this._correlationId},h.prototype.getOrigin=function(){return this._origin},h.prototype.getData=function(){return this._data},h.prototype.getMessageType=function(){return this._messageType},h);function h(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}var g,m=(__extends(y,g=d),y.prototype.getActionType=function(){return this._actionType},y);function y(e,t,n,r,o){var i=g.call(this,0,e,n,r,o)||this;return i._actionType=t,i}var _,U=(__extends(b,_=d),b.prototype.getErrorCode=function(){return this._errorCode},b.prototype.getResponseType=function(){return this._responseType},b);function b(e,t,n,r,o,i){var a=_.call(this,1,e,t,n,i)||this;return a._errorCode=r,a._responseType=o,a}var B=(v.envelope=function(e){return JSON.stringify(e)},v.unenvelope=function(e){return JSON.parse(e)},v);function v(){}var O=(C.prototype.getRequesterWindow=function(){return this._requesterWindow},C.prototype.getRequesterUrl=function(){return this._requesterUrl},C.prototype.getActionName=function(){return this._actionName},C.prototype.getConversationId=function(){return this._conversationId},C.prototype.getCorrelationId=function(){return this._correlationId},C.prototype.getSend=function(){return this._send},C.prototype.setResultCode=function(e){this._invokeResultCode=e},C);function C(e,t,n,r,o,i){var a=this;this._invokeResultCode=0,this._requesterWindow=e,this._requesterUrl=t,this._actionName=n,this._conversationId=r,this._correlationId=o,this._invokeResultCode=0,this._responseType=i,this._send=function(e){try{var t=new U(a._actionName,a._conversationId,a._correlationId,a._invokeResultCode,a._responseType,e),n=B.envelope(t);a._requesterWindow.postMessage(n,a._requesterUrl),A.Utility.xdmDebugLog("_send: requestUrl="+a._requesterUrl+" _actionName:"+a._actionName)}catch(e){A.Utility.xdmDebugLog("ResponseSender._send error:"+e.message)}}}var P,W=(__extends(S,P=O),S);function S(e,t,n,r,o,i){var a=P.call(this,e,t,n,r,o,0)||this;return a._postCallbackHandler=i,a._send=function(e,t){null!=t&&(a._invokeResultCode=t);try{var n=new U(a._actionName,a._conversationId,a._correlationId,a._invokeResultCode,a._responseType,e),r=B.envelope(n);a._requesterWindow.postMessage(r,a._requesterUrl),a._postCallbackHandler()}catch(e){A.Utility.xdmDebugLog("InvokeCompleteCallback._send error:"+e.message)}},a}var G=(q.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)}},q.prototype.getInvokeBlockingFlag=function(){return this._methodObject.getBlockingFlag()},q.prototype._createEventHandlerProxyObject=function(e){return new O(e.getRequesterWindow(),e.getRequesterUrl(),e.getActionName(),e.getConversationId(),e.getCorrelationId(),1)},q);function q(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}}(OSF=OSF||{}),function(){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)]:[]}(OSFPerfUtil||(OSFPerfUtil={})).sendPerformanceTelemetry=function(){if(OSF.AppTelemetry.enableTelemetry&&"undefined"!=typeof performance&&performance.getEntriesByType){var n,r,o=OSF.LoadScriptHelper.getHostBundleJsName().toLowerCase();performance.getEntriesByType("resource").forEach(function(e){var t=e.name.toLowerCase();OSF.Utility.stringEndsWith(t,o)?n=e:(OSF.Utility.stringEndsWith(t,OSF.ConstantNames.OfficeDebugJS)||OSF.Utility.stringEndsWith(t,OSF.ConstantNames.OfficeJS))&&(r=e)}),OTel.OTelLogger.onTelemetryLoaded(function(){var e=[];n&&(e=e.concat(t(n,"HostJs"))),r&&(e=e.concat(t(r,"OfficeJs"))),e=e.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))]),Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.JSPerformanceTelemetryV06",dataFields:e,eventFlags:{dataCategories:2,diagnosticLevel:110}})})}}}(),function(e){var t,n,r,o,i,l;t=e.OUtil||(e.OUtil={}),l={},o=t.Guid||(t.Guid={}),i=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],o.generateNewGuid=function(){for(var e="",t=(new Date).getTime(),n=0;n<32&&0<t;n++)8!=n&&12!=n&&16!=n&&20!=n||(e+="-"),e+=i[t%16],t=Math.floor(t/16);for(;n<32;n++)8!=n&&12!=n&&16!=n&&20!=n||(e+="-"),e+=i[Math.floor(16*Math.random())];return e},t.loadScript=function(n,e,t,r){if(n&&e){var o=window.document,i=l[n];if(i)i.loaded?e(!0):i.pendingCallbacks.push(e);else{var a=o.createElement("script");a.type="text/javascript",i={loaded:!1,pendingCallbacks:[e],timer:null},l[n]=i;function s(){null!=i.timer&&(clearTimeout(i.timer),delete i.timer),i.loaded=!0;for(var e=i.pendingCallbacks.length,t=0;t<e;t++){i.pendingCallbacks.shift()(!0)}}function c(){delete l[n],null!=i.timer&&(clearTimeout(i.timer),delete i.timer);for(var e=i.pendingCallbacks.length,t=0;t<e;t++){i.pendingCallbacks.shift()(!1)}}a.readyState?a.onreadystatechange=function(){"loaded"!=a.readyState&&"complete"!=a.readyState||(a.onreadystatechange=null,s())}:a.onload=s,a.onerror=c,r=r||3e4,i.timer=setTimeout(c,r),a.setAttribute("crossOrigin","anonymous"),a.src=t?t.createScriptURL(n):n,o.getElementsByTagName("head")[0].appendChild(a)}}},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):0<i?(o=window.setTimeout(a,r),i--):(window.clearTimeout(o),t(!1))};a()}}(OSF=OSF||{}),function(_){_.Flights=[],_.DisabledChangeGates=[];_.FlightTreatmentNames={EnableMsal3SsoApi:"Microsoft.Office.SharedOnline.EnableMsal3SsoApi"},function(p){var a="&_flights=",s="&_disabledChangeGates=",c="_flights=",l="_disabledChangeGates=",f="&";function o(e,t){return e.substr(0,t.length)===t}function u(e,t,n,r){return o(e,t+"//"+n+":"+r)||o(e,n+":"+r)}p.isArray=function(e){return"[object Array]"===Object.prototype.toString.apply(e)},p.isFunction=function(e){return"[object Function]"===Object.prototype.toString.apply(e)},p.isDate=function(e){return"[object Date]"===Object.prototype.toString.apply(e)},p.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)}},p.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)}};function d(e){var t=[];try{t=JSON.parse(e)}catch(e){}return Array.isArray(t)||(t=[]),t}function h(e,t,n){try{var r=JSON.parse(t),o=null!=r?r[n]:null,i=p.getSessionStorage();if(!e&&i&&null!=r){var a=r.baseFrameName+n;o?i.setItem(a,o):o=i.getItem(a)}return o}catch(e){return null}}function g(e,t,n,r,o){var i=o.split(e),a=1<i.length?i[i.length-1]:null;n&&null!=a&&(0<=a.indexOf(f)&&(a=a.split(f)[0]),a=decodeURIComponent(a));var s=p.getSessionStorage();if(!r&&s){var c=window.name.indexOf(t);if(-1<c){var l=window.name.indexOf(";",c);-1==l&&(l=window.name.length);var u=window.name.substring(c,l);a?s.setItem(u,a):a=s.getItem(u)}}return a}function n(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 m(e){if(e=n(e,"/"),e=n(e,"?"),"https://"==(e=n(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 y(e){var t,n,r=[],o=[],i=e.length;for(t=0;t<i;t++)(n=e[t]).tabIndex?0<n.tabIndex?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)}p.serializeSettings=function(e){var t={};for(var n in e){var r=e[n];try{r=JSON.stringify(r,function(e,t){return _.OUtil.isDate(this[e])?"Date("+this[e].getTime()+")":t}),t[n]=r}catch(e){}}return t},p.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&&6<t.length&&"Date("===t.slice(0,5)&&")"===t.slice(-1)&&(n=new Date(parseInt(t.slice(5,-1))))?n:t}),t[n]=r}catch(e){}}return t},p.convertIntToCssHexColor=function(e){return"#"+(Number(e)+16777216).toString(16).slice(-6)},p.parseAppContextFromWindowName=function(e,t){return p.parseInfoFromWindowName(e,t,"appContext")},p.parseHostInfoFromWindowName=function(e,t){return _.OUtil.parseInfoFromWindowName(e,t,"hostInfo")},p.parseXdmInfo=function(e){var t=p.parseXdmInfoWithGivenFragment(e,window.location.hash);return t=t||p.parseXdmInfoFromWindowName(e,window.name)},p.parseXdmInfoFromWindowName=function(e,t){return _.OUtil.parseInfoFromWindowName(e,t,"xdmInfo")},p.parseXdmInfoWithGivenFragment=function(e,t){return _.OUtil.parseInfoWithGivenFragment("&_xdm_Info=","_xdm_",!1,e,t)},p.parseFlights=function(e){var t,n,r,o,i=(t=e,n=window.location.hash,d(g(a,c,!0,t,n)));return 0==i.length&&(r=e,o=window.name,i=d(h(r,o,"flights"))),i},p.parseDisabledChangeGates=function(e){var t,n,r,o,i=(t=e,n=window.location.hash,d(g(s,l,!0,t,n)));return 0==i.length&&(r=e,o=window.name,i=d(h(r,o,"disabledChangeGates"))),i},p.checkFlight=function(e){return _.Flights&&0<=_.Flights.indexOf(e)},p.isChangeGateEnabled=function(e){return!_.DisabledChangeGates||-1===_.DisabledChangeGates.indexOf(e)},p.parseInfoFromWindowName=h,p.parseInfoWithGivenFragment=g,p.getConversationId=function(){var e=window.location.search,t=null;if(e){var n=e.indexOf("&");(t=0<n?e.substring(1,n):e.substr(1))&&"="===t.charAt(t.length-1)&&(t=(t=t.substring(0,t.length-1))&&decodeURIComponent(t))}return t},p.getInfoItems=function(e){var t=e.split("$");return void 0===t[1]&&(t=e.split("|")),void 0===t[1]&&(t=e.split("%7C")),t},p.getXdmFieldValue=function(e,t){var n="",r=_.OUtil.parseXdmInfo(t);if(r){var o=_.OUtil.getInfoItems(r);if(null!=o&&3<=o.length)switch(e){case"ConversationUrl":n=o[2];break;case"AppId":n=o[1]}}return n},p.parseUrl=function(e,t){if(void 0===t&&(t=!1),void 0!==e&&e){var n,r,o="NotHttps",i="undefined"!=typeof window&&void 0!==window.navigator&&0<window.navigator.userAgent.indexOf("Trident"),a=("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(i){var s=document.createElement("a");if(s.href=e,!(s&&s.protocol&&s.host&&s.hostname&&s.href&&m(s.href).toLowerCase()===m(e).toLowerCase()))throw"InvalidUrl";if(_.OUtil.checkFlight(2)&&t&&"https:"!=s.protocol)throw new Error(o);var c=(r=s,(n=e)&&r?"https:"==r.protocol&&u(n,"https:",r.hostname,"443")?":443":"http:"==r.protocol&&u(n,"http:",r.hostname,"80")?":80":"":"");a.protocol=s.protocol,a.hostname=s.hostname,a.port=c?"":s.port,a.host=c?s.hostname:s.host,a.pathname=(i?"/":"")+s.pathname,a.search=s.search,a.hash=s.hash,a.isPortPartOfUrl=u(e,s.protocol,s.hostname,s.port)}else{var l=new URL(e);if(l&&l.protocol&&l.host&&l.hostname){if(_.OUtil.checkFlight(2)&&t&&"https:"!=l.protocol)throw new Error(o);a.protocol=l.protocol,a.hostname=l.hostname,a.port=l.port,a.host=l.host,a.pathname=l.pathname,a.search=l.search,a.hash=l.hash,a.isPortPartOfUrl=l.host.lastIndexOf(":"+l.port)==l.host.length-l.port.length-1}}}catch(e){if(e.message===o)throw e}return a}},p.focusToFirstTabbable=function(e,t){function n(e){c=!0}var r,o,i,a,s,c=!1;if(e=y(e),r=t?e.length-1:0,0===e.length)return null;for(;!c&&0<=r&&r<e.length;)o=e[r],window.focus(),o.addEventListener("focus",n),o.focus(),o.removeEventListener("focus",n),i=e.length,s=t,r=(a=r)<0||i<a||0===a&&s||a===i-1&&!s?-1:s?a-1:a+1,c||o!==document.activeElement||(c=!0);return c?o:null},p.focusToNextTabbable=function(e,t,n){function r(e){c=!0}function o(e,t,n){return!(t<0||e<t)&&(0!==t||!n)&&(t!==e-1||n)?n?t-1:t+1:-1}var i,a,s,c=!1;if(i=function(e,t){for(var n=0;n<e.length;n++)if(e[n]===t)return n;return-1}(e=y(e),t),(a=o(e.length,i,n))<0)return null;for(;!c&&0<=a&&a<e.length;)(s=e[a]).addEventListener("focus",r),s.focus(),s.removeEventListener("focus",r),a=o(e.length,a,n),c||s!==document.activeElement||(c=!0);return c?s:null},p.defineMethodOnNamespace=function(e,t,n){e[t]=n},p.isDialog=function(){return _._OfficeAppFactory.getHostInfo().isDialog},p.isPopupWindow=function(){return _.OUtil.isDialog()&&_._OfficeAppFactory.getHostInfo().hostPlatform==_.HostInfoPlatform.web&&null!=window.opener},p.getHostPlatform=function(){return _._OfficeAppFactory.getHostInfo().hostPlatform},p.getCustomOfficeInitializationSettings=function(){return"object"==typeof officeInitializationSettings?officeInitializationSettings:{}};var t=0;p.getLibraryReleaseVehicle=function(){return t},p.setLibraryReleaseVehicle=function(e){t=e}}(_.OUtil||(_.OUtil={}))}(OSF=OSF||{}),function(e){var t;(t=e.ParameterNames||(e.ParameterNames={})).Callback="callback",t.AsyncContext="asyncContext",t.Data="data",t.MessageToParent="messageToParent",t.MessageContent="messageContent",t.MessageOrigin="messageOrigin",t.TargetOrigin="targetOrigin",t.AppCommandInvocationCompletedData="appCommandInvocationCompletedData"}(OSF=OSF||{}),function(h){!function(e){function t(){}e.RequirementVersion=t;var c=(n.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(0<o.major&&o.major>i.major)return!0;if(0<o.major&&0<=o.minor&&o.major==i.major&&o.minor>=i.minor)return!0}catch(e){return!1}}return!1},n.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]),2<=t.length&&(r=Number(t[1])),isNaN(n)||isNaN(r))throw"version format incorrect";return{minor:r,major:n}},n);function n(e){this._setMap=e}e.RequirementMatrix=c;var l=(r.prototype._addSetMap=function(e){for(var t in e)this._sets[t]=e[t]},r);function r(e){this._sets=e}e.DefaultSetRequirement=l;var o,u=(__extends(i,o=l),i);function i(){return o.call(this,{dialogapi:1.1})||this}e.DefaultRequiredDialogSetRequirement=u;var a,p=(__extends(s,a=l),s);function s(){return a.call(this,{dialogorigin:1.1})||this}e.DefaultOptionalDialogSetRequirement=p;var f=(d.getDefaultRequirementMatrix=function(e){var t=void 0,n=e.get_requirementMatrix();if(null!=n&&0<n.length){var r=JSON.parse(e.get_requirementMatrix().toLowerCase());if(h._OfficeAppFactory.getHostInfo().hostPlatform==h.HostInfoPlatform.web)try{var o="dialogorigin";r.hasOwnProperty(o)||(r[o]=1.1)}catch(e){}t=new c(new l(r))}else t=new c(new l({}));return t},d.getDefaultDialogRequirementMatrix=function(e){var t=void 0,n=e.get_dialogRequirementMatrix();if(null!=n&&0<n.length){var r=JSON.parse(e.get_requirementMatrix().toLowerCase());t=new l(r)}else{t=new u;var o=e.get_requirementMatrix();if(null!=o&&0<o.length&&"undefined"!=typeof JSON){for(var i in r=JSON.parse(o.toLowerCase()),t._sets)r.hasOwnProperty(i)&&(t._sets[i]=r[i]);var a=new p;for(var i in a._sets)r.hasOwnProperty(i)&&(t._sets[i]=r[i])}}if(h._OfficeAppFactory.getHostInfo().hostPlatform==h.HostInfoPlatform.web)try{var s="dialogorigin";!t._sets.hasOwnProperty(s)&&window.opener&&(t._sets[s]=1.1)}catch(e){}return new c(t)},d);function d(){}e.RequirementsMatrixFactory=f}(h.Requirement||(h.Requirement={}))}(OSF=OSF||{}),function(r){var e,t,n;e=r.DDA||(r.DDA={}),(t=e.RichApi||(e.RichApi={})).executeRichApiRequestAsync=function(e,t){var n={toSafeArrayHost:function(){return[e]},fromSafeArrayHost:function(e){return{data:e}},toWebHost:function(){return{ArrayData:e}},fromWebHost:function(e){return{data:e.Data}}};r._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(93,n,t)},Object.defineProperty(t,"richApiMessageManager",{get:function(){return n=n||new r.RichApiMessageManager}})}(OSF=OSF||{}),function(o){var e=(n.transferEventArgument=function(e){var t=[];if(e)for(var n=0;n<e.length;n++){var r=e[n];r.toArray&&(r=r.toArray()),t.push({messageCategory:r[0],messageType:r[1],targetId:r[2],message:r[3],id:r[4],isRemoteOverride:r[5]})}return{type:o.EventType.RichApiMessage,entries:t}},n.prototype.addHandlerAsync=function(e,t,n){o.EventHelper.addEventHandler(e,t,n,this._eventDispatch)},n.prototype.removeHandlerAsync=function(e,t,n){o.EventHelper.removeEventHandler(e,t,n,this._eventDispatch)},n.prototype.register=function(e){var r=this;return this._registerPromise||(this._registerPromise=new Office.Promise(function(t,n){r.addHandlerAsync(o.EventType.RichApiMessage,function(t){r._registerHandlers.forEach(function(e){e&&e(t)})},function(e){"failed"==e.status?n(e.error):t()})})),this._registerPromise.then(function(){r._registerHandlers.push(e)})},n);function n(){this._registerHandlers=[],this._eventDispatch=new o.EventDispatch([{type:o.EventType.RichApiMessage,id:o.EventDispId.dispidRichApiMessageEvent,getTargetId:function(){return""},fromSafeArrayHost:function(e){return n.transferEventArgument(e)},fromWebHost:function(e){var t=e.ArrayData;return n.transferEventArgument(t)}}])}o.RichApiMessageManager=e}(OSF=OSF||{}),function(n){var e=(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(e){throw n.Utility.createNotImplementedException()},t.prototype.resizeSdxDialog=function(e,t){throw n.Utility.createNotImplementedException()},t);function t(){}n.RichClientHostController=e}(OSF=OSF||{}),function(j){var t,e=(t=j.InitializationHelper,__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."),j.Utility.trace(t),null;this._osfControlContext=window.external.GetContext()}catch(e){return console.error("Error when call window.external.GetContext() :"+JSON.stringify(e)),j.Utility.trace(t),null}}return this._osfControlContext},n.prototype.getAppContext=function(e,t,n){var r=this,o=this.getOsfControlContext();if(o){var i,a,s,c,l,u,p,f,d,h,g,m,y,_,b,v,O,C,P,S,A,I,R,T,E,N,D=0,x=!1;if((w=j.Utility.externalNativeFunctionExists)(typeof o.GetContextDataInJson)&&"undefined"!=typeof OsfOMToken&&OsfOMToken?((E=o.GetContextDataInJson(OsfOMToken))&&(N=JSON.parse(E)),N?(i=N.appType,a=N.solutionRef,s=N.versionMajor,c=N.versionMinor,l=N.uiLocale,u=N.dataLocale,p=N.docUrl,f=N.clientMode,d=N.activationMode,g=N.controlType,m=N.eToken,y=N.correlationId,_=N.appInstanceId,b=N.touchEnabled,v=o.commerceAllowed,O=N.requirementMatrix,P=N.hostFullVersion,S=N.requirementMatrix,(F=N.featureGates)&&(A=JSON.parse(F)),D=N.initialDisplayMode,I=function(){var e={};if(N.settings)try{var t=JSON.parse(N.settings);if(t)for(var n=[t.names,t.values],r=n[0],o=n[1],i=0;i<r.length;i++)e[r[i]]=o[i]}catch(e){j.Utility.trace("Exception while parsing settings. Details: "+e)}return e},R=function(){var e=N.themeInfo;return r.getOfficeThemeFromInfoString(e)}):x=!0):x=!0,x){i=o.GetAppType(),a=o.GetSolutionRef(),s=o.GetAppVersionMajor(),c=o.GetAppVersionMinor(),l=o.GetAppUILocale(),u=o.GetAppDataLocale(),p=o.GetDocUrl(),f=o.GetAppCapabilities(),d=o.GetActivationMode(),g=o.GetControlIntegrationLevel();try{m=o.GetSolutionToken()}catch(e){}var w;if((w=j.Utility.externalNativeFunctionExists)(typeof o.GetCorrelationId)&&(y=o.GetCorrelationId()),w(typeof o.GetInstanceId)&&(_=o.GetInstanceId()),w(typeof o.GetTouchEnabled)&&(b=o.GetTouchEnabled()),w(typeof o.GetCommerceAllowed)&&(v=o.GetCommerceAllowed()),w(typeof o.GetSupportedMatrix)&&(O=o.GetSupportedMatrix()),w(typeof o.GetHostCustomMessage)&&(C=o.GetHostCustomMessage()),w(typeof o.GetHostFullVersion)&&(P=o.GetHostFullVersion()),w(typeof o.GetDialogRequirementMatrix)&&(S=o.GetDialogRequirementMatrix()),w(typeof o.GetFeaturesForSolution))try{var F;(F=o.GetFeaturesForSolution())&&(A=JSON.parse(F))}catch(e){j.Utility.trace("Exception while creating the SDX FeatureGates object. Details: "+e)}w(typeof o.GetInitialDisplayMode)&&(D=o.GetInitialDisplayMode()),I=function(){return r.getSerializedSettings()},R=function(){return r.getOfficeTheme()},T=function(){return r.getSerializedHostSettings()}}h=2===d?Office.InitializationReason.DocumentOpened:Office.InitializationReason.Inserted,m=m?m.toString():"",t(new j.OfficeAppContext(a,i,s,l,u,p,f,I,h,g,m,y,_,b,v,c,O,C,P,void 0,void 0,void 0,void 0,S,A,R,D,void 0,void 0,T,!1,void 0,void 0))}else n(new Error("The Office.js is loaded outside of Office client"))},n.prototype.createClientHostController=function(){if(!this._clientHostController){if(this._hostInfo.hostPlatform!==j.HostInfoPlatform.win32)throw j.Utility.createNotImplementedException();this._clientHostController=new j.Win32RichClientHostController}return this._clientHostController},n.prototype.createAsyncMethodExecutor=function(){return new j.SafeArrayAsyncMethodExecutor(this._clientHostController)},n.prototype.createClientSettingsManager=function(){return new j.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(e){var t=null;if(e)try{t=JSON.parse(e)}catch(e){j.AppTelemetry&&j.AppTelemetry.logAppException("Exception while parsing officeThemeInfo. Details: "+e)}var n={};if(t){var r={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 o in t){var i=!1,a=o;r[o]&&(a=r[o].name,i=r[o].convertToHex),n[a]=i?j.OUtil.convertIntToCssHexColor(t[o]):t[o]}}return n},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);function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.officeThemeTimeStamp=null,e.officeTheme=null,e}j.RichClientInitializationHelper=e}(OSF=OSF||{}),function(e){var t=(n.prototype.read=function(o){var i,e=this._osfClientContext;function t(){var e=[],t=[];i.Read(e,t);for(var n={},r=0;r<e.length;r++)n[e[r]]=t[r];o&&o(0,n)}(i="undefined"!=typeof OsfOMToken&&OsfOMToken?e.GetSettings(OsfOMToken):e.GetSettings()).RefreshAsync?i.RefreshAsync(function(){t()}):t()},n.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))},n);function n(e){this._osfClientContext=e}e.RichClientSettingsManager=t}(OSF=OSF||{}),function(l){var n,e=(n=l.AsyncMethodExecutor,__extends(t,n),t.prototype.executeAsync=function(r,o,i,a){var s=this;try{var c=new Array;this._clientHostController.execute(r,o.toSafeArrayHost(),function(e,t){var n=l.Utility.fromSafeArray(e);return s._asyncMethodExecutorHelper.handleSafeArrayHostResponse(n,t,c,i,o,r,a)})}catch(e){this.onException(e,r,i)}},t.prototype.registerEventAsync=function(r,e,t,o,i,a,s){var c=this;try{this._clientHostController.registerEvent(r,e,t,function(e,t){var n=l.Utility.fromSafeArray(t),r=i.fromSafeArrayHost(n);o(r)},function(e){var t,n=l.Utility.fromSafeArray(e);return t="number"==typeof n?n:n[0],c.invokeCallback(r,a,t,null,s),!0})}catch(e){this.onException(e,r,a)}},t.prototype.unregisterEventAsync=function(o,e,t,i,a){var s=this;try{this._clientHostController.unregisterEvent(o,e,t,function(e,t){var n,r=l.Utility.fromSafeArray(e);return n="number"==typeof r?r:r[0],s.invokeCallback(o,i,n,null,a),!0})}catch(e){this.onException(e,o,i)}},t.prototype.onException=function(e,t,n){var r,o=e.number;if(o)switch(o){case-2146828218:r=7e3;break;case-2147467259:r=t==l.EventDispId.dispidDialogMessageReceivedEvent?12007:5001;break;case-2146828283:case-2147209089:r=5010;break;case-2147208704:r=5100;break;case-2146827850:default:r=5001}n&&this.invokeCallback(t,n,r||5001,null)},t);function t(e){var t=n.call(this)||this;return t._clientHostController=e,t._asyncMethodExecutorHelper=l.BootStrapExtension.createAsyncMethodExecutorHelper(t),t}l.SafeArrayAsyncMethodExecutor=e}(OSF=OSF||{}),function(e){var t=(n.prototype.getItem=function(e){try{return this._internalStorage&&this._internalStorage.getItem(e)}catch(e){return null}},n.prototype.setItem=function(e,t){try{this._internalStorage&&this._internalStorage.setItem(e,t)}catch(e){}},n.prototype.clear=function(){try{this._internalStorage&&this._internalStorage.clear()}catch(e){}},n.prototype.removeItem=function(e){try{this._internalStorage&&this._internalStorage.removeItem(e)}catch(e){}},n.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},n);function n(e){this._internalStorage=e}e.SafeStorage=t}(OSF=OSF||{}),function(i){var e=(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(n){var e=this._clientSettingsManager,t=OSF.OUtil.serializeSettings(this._settings);e.write(t,function(e){var t=OSF.Utility.asyncResultFromErrorCode(e);n&&n(t)})},t.prototype.refreshAsync=function(r){var o=this;this._clientSettingsManager.read(function(e,t){var n=OSF.Utility.asyncResultFromErrorCode(e);n.status===i.AsyncResultStatus.Succeeded&&(o._settings=OSF.OUtil.deserializeSettings(t),n.value=o),r&&r(n)})},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);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}}}])}i.Settings=e}(Office=Office||{});var OSFWebkit,OTel,Microsoft,__awaiter=this&&this.__awaiter||function(i,a,s,c){return new(s=s||Promise)(function(e,t){function n(e){try{o(c.next(e))}catch(e){t(e)}}function r(e){try{o(c.throw(e))}catch(e){t(e)}}function o(t){t.done?e(t.value):new s(function(e){e(t.value)}).then(n,r)}o((c=c.apply(i,a||[])).next())})},__generator=this&&this.__generator||function(n,r){var o,i,a,e,s={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return e={next:t(0),throw:t(1),return:t(2)},"function"==typeof Symbol&&(e[Symbol.iterator]=function(){return this}),e;function t(t){return function(e){return function(t){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,i&&(a=2&t[0]?i.return:t[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,t[1])).done)return a;switch(i=0,a&&(t=[2&t[0],a.value]),t[0]){case 0:case 1:a=t;break;case 4:return s.label++,{value:t[1],done:!1};case 5:s.label++,i=t[1],t=[0];continue;case 7:t=s.ops.pop(),s.trys.pop();continue;default:if(!(a=0<(a=s.trys).length&&a[a.length-1])&&(6===t[0]||2===t[0])){s=0;continue}if(3===t[0]&&(!a||t[1]>a[0]&&t[1]<a[3])){s.label=t[1];break}if(6===t[0]&&s.label<a[1]){s.label=a[1],a=t;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(t);break}a[2]&&s.ops.pop(),s.trys.pop();continue}t=r.call(n,s)}catch(e){t=[6,e],i=0}finally{o=a=0}if(5&t[0])throw t[1];return{value:t[0]?t[1]:void 0,done:!0}}([t,e])}}};!function(c){var e=(t.isSovereignVersion=function(){return"undefined"!=typeof isOsfSovereignVersion&&!0===isOsfSovereignVersion},t.prototype.getEnvironmentName=function(){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return[4,this.getConfig()];case 1:return[2,null!=(t=e.sent())&&t.envName?t.envName:null]}})})},t.prototype.getEnvironmentType=function(){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return[4,this.getConfig()];case 1:return[2,null!=(t=e.sent())&&t.envType?t.envType:null]}})})},t.prototype.getTrustedHostOrigins=function(){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return[4,this.getConfig()];case 1:return[2,null!=(t=e.sent())?t.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(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return n?n===window.location.hostname?[2,!0]:[4,this.getTrustedHostOrigins()]:[2,!1];case 1:return(t=e.sent())&&0!=t.length?[2,new RegExp(t.join("|")).test(n)]:[2,!1]}})})},t.prototype.getConfigPath=function(){var e=c.LoadScriptHelper.getHostBundleJsBasePath();if(e){var t=(e=e.toLowerCase()).indexOf("/lib/");if(-1<t)return e.toLowerCase().substring(0,t+"/lib/".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(e){switch(e.label){case 0:if(!(t=this.getConfigPath()))return[3,2];if(n=c.OUtil.getLocalStorage(),r=t+"_cache",o=n.getItem(r),i=null,o){try{i=JSON.parse(o)}catch(e){}if(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=e.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(t){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return e.trys.push([0,3,,4]),[4,fetch(t)];case 1:return[4,e.sent().json()];case 2:return[2,e.sent()];case 3:return e.sent(),[3,4];case 4:return[2,null]}})})},t);function t(){}c.SovereignHelper=e}(OSF=OSF||{}),function(e){var t;function n(e){return void 0===e||null===e}(t=e.Utility||(e.Utility={})).createParameterException=function(e){return new Error("Parameter count mismatch: "+e)},t.createArgumentException=function(e){return new Error("Invalid argument "+e)},t.createNotImplementedException=function(){return new Error("Not implemented yet")},t.log=function(e){console.log(e)},t.trace=function(e){console.log(e)},t.debugLog=function(e){console.log(e)},t.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},t.isNullOrUndefined=n,t.isNullOrEmpty=function(e){return!!n(e)||0===e.length},t.isInUnittest=function(){return"boolean"==typeof g_osfUnittest&&g_osfUnittest}}(OSF=OSF||{}),function(e){var n;function t(e){return new Promise(e)}function i(e){var t=e,n=1;if(("object"==typeof e||"unknown"==typeof e)&&null!=e&&e.toArray)if(e.dimensions&&(n=e.dimensions()),2===n)t=a(e);else{var r=e.toArray();t=new Array(r.length);for(var o=0;o<r.length;o++)t[o]=i(r[o])}return t}function a(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)}0<i.length&&t.push(i)}}}catch(e){}return t}e.isOfficeReactNative=function(){try{return"undefined"!=typeof OfficePlatformGlobal&&void 0!==OfficePlatformGlobal.ReactNativeReka}catch(e){return!1}},(n=e.Utility||(e.Utility={})).xdmDebugLog=function(e){n._DebugXdm&&console.log(e)},n.enableDebugXdm=function(){n._DebugXdm=!0},n.createPromiseFromResult=function(e){return Promise.resolve(e)},n.createPromise=t,n.promisify=function(e,r){return t(function(t,n){e(function(e){(0===e?t:n)()}),setTimeout(function(){n()},r)})},n.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},n.getErrorCodeFromAsyncResult=function(e){return e.status===Office.AsyncResultStatus.Succeeded?0:e.error&&e.error.code?e.error.code:5001},n.externalNativeFunctionExists=function(e){return"unknown"===e||"undefined"!==e},n.stringEndsWith=function(e,t){if(n.isNullOrUndefined(e))throw n.createArgumentException("value");if(n.isNullOrUndefined(t))throw n.createArgumentException("subString");return!(t.length>e.length)&&e.substr(e.length-t.length)===t},n.fromSafeArray=function(e){var t=e;if(("object"==typeof e||"unknown"==typeof e)&&null!=e&&e.toArray){var n=e.toArray();t=new Array(n.length);for(var r=0;r<n.length;r++)t[r]=i(n[r])}return t},n.twoDVBArrayToJaggedArray=a,n.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}}},n._DebugXdm=!1}(OSF=OSF||{}),function(n){var r,e=(r=n.AsyncMethodExecutor,__extends(t,r),t.prototype.executeAsync=function(n,r,o,i){var a=this;this._clientHostController.execute(n,r.toWebHost(),function(e,t){return o&&a._asyncMethodExecutorHelper.handleWebHostResponse(t,e,o,r,n,i),!0})},t.prototype.registerEventAsync=function(n,e,t,r,o,i,a){var s=this;this._clientHostController.registerEvent(n,e,t,function(e){var t=e,n=o.fromWebHost(t);r(n)},function(e,t){return i&&s.invokeCallback(n,i,e,null,a),!0})},t.prototype.unregisterEventAsync=function(n,e,t,r,o){var i=this;this._clientHostController.unregisterEvent(n,e,t,function(e,t){return r&&i.invokeCallback(n,r,e,null,o),!0})},t);function t(e){var t=r.call(this)||this;return t._clientHostController=e,t._asyncMethodExecutorHelper=n.BootStrapExtension.createAsyncMethodExecutorHelper(t),t}n.WebAsyncMethodExecutor=e}(OSF=OSF||{}),function(u){var e;((e=u.DDA||(u.DDA={})).WebAuth||(e.WebAuth={})).getAuthContextAsync=function(e){u._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(99,{toSafeArrayHost:function(){return[]},fromSafeArrayHost:function(e){return null},toWebHost:function(){return{}},fromWebHost:function(e){return e.authContext}},e)},function(a){var s,e;(e=s=a.AuthFlow||(a.AuthFlow={})).AuthCode="authcode",e.Broker="broker",e.Implicit="implicit",a.loadAttempts=0;var o="webauth/",i="webauth.browserauth.debug.js",c="webauth.browserauth.js",l=!1;a.load=function(){return a.config&&a.config.authFlow===s.AuthCode?(a.loadAttempts++,(l=a.config&&(!0===a.config.useMsal3||!1!==a.config.useMsal3&&u.OUtil.checkFlight(u.FlightTreatmentNames.EnableMsal3SsoApi)))&&(i="webauth.browserauth.msal3.debug.js",c="webauth.browserauth.msal3.js"),new Promise(function(t,n){function e(i,a,s){return new Promise(function(r,o){i?u.OUtil.loadScript(i,function(e){if("boolean"!=typeof e||e)if(e instanceof Event&&e)o(new Event("loadScript: "+e.type+" '"+i+"'"));else if(s&&!a())var t=0,n=setInterval(function(){t+=500,!(a()||s<t)||(clearInterval(n),a())||o(new Event("Missing expected object after loaded."))},500);else r(null);else o(new Event("loadScript: failed to load '"+i+"'"))},u.LoadScriptHelper.getTrustedTypesPolicy(),s):r(null)})}var r=[e(a.config&&a.config.authVersion?u.LoadScriptHelper.getHostBundleJsBasePath()+o+a.config.authVersion+"/"+(a.config&&a.config.debugging?i:c):u.LoadScriptHelper.getHostBundleJsBasePath()+o+(a.config&&a.config.debugging?i:c),function(){return BrowserAuth},a.config.delayWebAuth)];l||r.push(e(a.config.msal,function(){return msal},a.config.delayMsal)),Promise.all(r).then(function(){a.config?BrowserAuth.Load(a.config,u._OfficeAppFactory.getHostInfo().osfControlAppCorrelationId).then(function(e){t(e)},function(e){n(e)}):n(new Event("config is empty."))},function(e){n(e)})})):new Promise(function(e,t){return t(new Event("'authcode' as authFlow is only supported"))})},a.getToken=function(e,t,n,r,o,i){return a.config&&a.config.authFlow===s.AuthCode?l?BrowserAuth.GetToken({resource:e,scopes:t,applicationId:n,correlationId:r,popup:!!o,claims:i}):BrowserAuth.GetToken(e,n,r,!!o,!!o,!1,i):Promise.reject(new Event("'authcode' as authFlow is only supported"))}}(u.WebAuth||(u.WebAuth={}))}(OSF=OSF||{}),function(s){var e=(t.prototype.execute=function(r,e,o){var i=this,t=this._webClientHostControllerHelper.getHostCallArgs(r,e),n=this._webClientHostControllerHelper.getTargetMethodName(r);this._webAppState.clientEndPoint.invoke(n,function(e,t){var n=0;if(0==e)i._delegateVersion=t.Version,n=i._webClientHostControllerHelper.parseErrorFromPayload(r,t);else switch(e){case-5:n=7e3;break;default:n=5001}o&&o(n,t)},t)},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(e){throw s.Utility.createNotImplementedException()},t.prototype.openDialog=function(e,t,n,r,o){throw s.Utility.createNotImplementedException()},t.prototype.closeDialog=function(e,t,n,r){throw s.Utility.createNotImplementedException()},t.prototype.sendMessage=function(e){throw s.Utility.createNotImplementedException()},t.prototype.closeSdxDialog=function(e){this._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[this._webAppState.id,s.AgaveHostAction.CloseSDXDialog,{InstanceId:this._webAppState.id,DialogCloseCallbackParam:e}])},t.prototype.resizeSdxDialog=function(e,t){this._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[this._webAppState.id,s.AgaveHostAction.ResizeSDXDialog,{InstanceId:this._webAppState.id,DialogWidth:e+"px",DialogHeight:t+"px"}])},t.prototype.getXdmEventName=function(e,t){return t==s.EventType.BindingSelectionChanged||t==s.EventType.BindingDataChanged||t==s.EventType.DataNodeDeleted||t==s.EventType.DataNodeInserted||t==s.EventType.DataNodeReplaced?e+"_"+t:t},t.prototype._getOnAfterRegisterEvent=function(r,o,i){var a=(new Date).getTime();return function(e,t){var n;if(0!=e)switch(e){case-5:n=7e3;break;default:n=5001}else n=t?t.Error?t.Error:0:5001;i&&i(n),s.AppTelemetry&&s.AppTelemetry.onRegisterDone(r,o,Math.abs((new Date).getTime()-a),n)}},t);function t(e){this._delegateVersion=1,this._webAppState=e,this._webClientHostControllerHelper=s.BootStrapExtension.createWebClientHostControllerHelper(this._webAppState,this._delegateVersion)}s.WebClientHostController=e}(OSF=OSF||{}),function(e){var t=(n.prototype.getHostCallArgs=function(e,t){var n=t;return(n=n||{}).DdaMethod={ControlId:this.getControlId(),DispatchId:e,Version:this._delegateVersion},n.__timeout__=-1,n},n.prototype.getTargetMethodName=function(e){return"executeMethod"},n.prototype.parseErrorFromPayload=function(e,t){return t.Error},n.prototype.getControlId=function(){return this._webAppState.id},n);function n(e,t){this._webAppState=e,this._delegateVersion=t}e.WebClientHostControllerHelper=t}(OSF=OSF||{}),function(s){var e=(t.prototype.read=function(i){s._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 t={},n=0;n<e.value.length;n++){var r=e.value[n];Array.isArray(r)?t[r[0]]=r[1]:t[r.Name]=r.Value}i(0,t)}else{var o=e.error.code;i(o,{})}})},t.prototype.write=function(e,n){var t=s._OfficeAppFactory.getAsyncMethodExecutor(),r=[];for(var o in e){var i=[];i.push(o),i.push(e[o]),r.push(i)}var a={toSafeArrayHost:function(){return null},fromSafeArrayHost:function(e){return null},toWebHost:function(){return{DdaSettingsMethod:{OverwriteIfStale:!0,Properties:r}}},fromWebHost:function(e){return null}};t.executeAsync(76,a,function(e){if(e.status===Office.AsyncResultStatus.Succeeded)n(0);else{var t=e.error.code;n(t)}})},t);function t(){}s.WebClientSettingsManager=e}(OSF=OSF||{}),function(v){var i,e=(i=v.InitializationHelper,__extends(t,i),Object.defineProperty(t.prototype,"isHostOriginTrusted",{get:function(){return this._isHostOriginTrustedFunc},set:function(e){this._isHostOriginTrustedFunc=e},enumerable:!0,configurable:!0}),t.prototype.saveAndSetDialogInfo=function(e){var t,n=v.OUtil.getSessionStorage();if(n){if((e=e||v.OUtil.parseHostInfoFromWindowName(!0,v._OfficeAppFactory.getWindowName()))&&-1<e.indexOf("isDialog")){var r=(t=v.OUtil.parseXdmInfo(!0))?t.split("|")[1]:null;return null!=r&&n.setItem(r+"IsDialog","true"),void(this._hostInfo.isDialog=!0)}this._hostInfo.isDialog=null!=n.getItem(v.OUtil.getXdmFieldValue("AppId",!1)+"IsDialog")}},t.prototype.checkReceiverOriginAndRun=function(p){return __awaiter(this,void 0,void 0,function(){var a,t,s,c,l,n,r,o,i,u;return __generator(this,function(e){switch(e.label){case 0:return 3===(a=this)._webAppState.clientEndPoint.hostTrustCheckStatus?(p(),[2]):(t=v.OUtil.parseUrl(a._webAppState.clientEndPoint.targetUrl,!1),s="https:"==t.protocol,c=t.hostname,l="NotHttps",0!==a._webAppState.clientEndPoint.hostTrustCheckStatus?[3,4]:(s||(a._webAppState.clientEndPoint.hostTrustCheckStatus=2),2==a._webAppState.clientEndPoint.hostTrustCheckStatus?[3,4]:(n=!1,(r=v.SovereignHelper.isSovereignVersion())&&!0!==v.OUtil.getCustomOfficeInitializationSettings().trustAllCloudEnvironments||(n=v.XdmCommunicationManager.isHostNameValidWacDomain(c),a.isHostOriginTrusted&&(n=n||a.isHostOriginTrusted(c))),n||!r?[3,3]:(a._sovereignHelper||(a._sovereignHelper=new v.SovereignHelper),[4,(o=a._sovereignHelper).isConfigAvailable()]))));case 1:return e.sent()?[4,o.isSovereignHostTrusted(c)]:[2];case 2:n=e.sent(),e.label=3;case 3:n&&(a._webAppState.clientEndPoint.hostTrustCheckStatus=3),e.label=4;case 4:if(a._webAppState.clientEndPoint.checkStatusLogged||null==a._hostInfo||void 0===a._hostInfo||(v.AppTelemetry.onCheckWACHost(a._webAppState.clientEndPoint.hostTrustCheckStatus,a._webAppState.id,a._hostInfo.hostType,a._hostInfo.hostPlatform,a._webAppState.clientEndPoint.targetUrl),a._webAppState.clientEndPoint.checkStatusLogged=!0),3===a._webAppState.clientEndPoint.hostTrustCheckStatus||v.LoadScriptHelper.disableHostCheck())p();else{if(v.LoadScriptHelper.isSdx())throw new Error("Not supported host");i=function(){var t=v.LoadScriptHelper.getHostBundleJsBasePath().match(/^https?:\/\/[^:/?#]*(?::([0-9]+))?/);if(t&&t[0]){var n=v.LoadScriptHelper.getHostBundleJsBasePath()+"AgaveErrorUX/index.html#",r={error:"NotTrustedWAC",locale:v.getSupportedLocale(a._hostInfo.hostLocale,v.ConstantNames.DefaultLocale),hostname:c,noHttps:!s,validate:!1},o=document.createElement("iframe");o.style.visibility="hidden",o.style.height="0",o.style.width="0";var i=function(e){if(e.source==o.contentWindow&&e.origin==t[0])try{!0===JSON.parse(e.data).hostUserTrusted?(a._webAppState.clientEndPoint.hostTrustCheckStatus=3,v.OUtil.removeEventListener(window,"message",i),document.body.removeChild(o)):(r.validate=!1,window.location.replace(n+encodeURIComponent(JSON.stringify(r)))),p()}catch(e){v.OUtil.ensureOfficeStringsJs().then(function(){document.body.textContent=Strings.OfficeOM.L_NotTrustedWAC})}};v.OUtil.addEventListener(window,"message",i),r.validate=!0,o.setAttribute("src",n+encodeURIComponent(JSON.stringify(r))),o.onload=function(){var e={hostname:c,noHttps:!s};o.contentWindow.postMessage(JSON.stringify(e),t[0])},document.body.appendChild(o)}else v.OUtil.ensureOfficeStringsJs().then(function(){document.body.textContent=Strings.OfficeOM.L_NotTrustedWAC});if(v.OUtil.checkFlight(2)&&!s)throw new Error(l)},document.body?i():(u=!1,document.addEventListener("DOMContentLoaded",function(){u||(u=!0,i())}))}return[2]}})})},t.prototype.setAgaveHostCommunication=function(){try{var o=this,e=v.OUtil.parseXdmInfoWithGivenFragment(!1,v._OfficeAppFactory.getWindowLocationHash());if(e=e||v.OUtil.parseXdmInfoFromWindowName(!1,v._OfficeAppFactory.getWindowName())){var t=v.OUtil.getInfoItems(e);null!=t&&3<=t.length&&(o._webAppState.conversationID=t[0],o._webAppState.id=t[1],o._webAppState.webAppUrl=0<=t[2].indexOf(":")?t[2]:decodeURIComponent(t[2]))}if(o._webAppState.wnd=null!=window.opener?window.opener:window.parent,this._hostInfo.isDialog&&null!=window.opener)return;o._webAppState.clientEndPoint=v.XdmCommunicationManager.connect(o._webAppState.conversationID,o._webAppState.wnd,o._webAppState.webAppUrl),o._webAppState.serviceEndPoint=v.XdmCommunicationManager.createServiceEndPoint(o._webAppState.id),o._webAppState.clientEndPoint.checkReceiverOriginAndRun=function(e){o.checkReceiverOriginAndRun(e)};var n=o._webAppState.conversationID+v.Constants.NotificationConversationIdSuffix;o._webAppState.serviceEndPoint.registerConversation(n,o._webAppState.webAppUrl),o._webAppState.serviceEndPoint.registerMethod("Office_notifyAgave",function(e){var t;switch(t="string"==typeof e?e:e[0]){case v.AgaveHostAction.Select:o._webAppState.focused=!0;break;case v.AgaveHostAction.UnSelect:o._webAppState.focused=!1;break;case v.AgaveHostAction.TabIn:case v.AgaveHostAction.CtrlF6In:window.focus();var n=document.querySelectorAll(o._tabbableElements);v.OUtil.focusToFirstTabbable(n,!1)||(window.blur(),o._webAppState.focused=!1,o._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[o._webAppState.id,v.AgaveHostAction.ExitNoFocusable]));break;case v.AgaveHostAction.TabInShift:window.focus(),n=document.querySelectorAll(o._tabbableElements),v.OUtil.focusToFirstTabbable(n,!0)||(window.blur(),o._webAppState.focused=!1,o._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[o._webAppState.id,v.AgaveHostAction.ExitNoFocusableShift]));break;case v.AgaveHostAction.SendMessage:if(Office.context.messaging.onMessage){var r=e[1];Office.context.messaging.onMessage(r)}break;case v.AgaveHostAction.TaskPaneHeaderButtonClicked:Office.context.ui.taskPaneAction.onHeaderButtonClick&&Office.context.ui.taskPaneAction.onHeaderButtonClick();break;default:v.Utility.trace("actionId "+t+" notifyAgave is wrong.")}},0,!1),o.addOrRemoveEventListenersForWindow(!0)}catch(e){throw v.AppTelemetry&&v.AppTelemetry.logAppException("Exception thrown in setAgaveHostCommunication. Exception:["+e+"]"),e}},t.prototype.getAppContext=function(e,m,y){function t(e,t){if(OSFPerformance.getAppContextXdmEnd=OSFPerformance.now(),t._appName===v.AppName.ExcelWebApp){for(var n=0,r=t._settings;n<r.length;n++){var o=r[n],i=o[0],a=o[1];_._serializedSettings[i]=a}for(var s=0,c=t._hostSettings;s<c.length;s++){var l=c[s];i=l[0],a=l[1],_._serializedHostSettings[i]=a}}else _._serializedSettings=t._settings||{},_._serializedHostSettings=t._hostSettings||{};if(!b._hostInfo.isDialog||null==window.opener){var u=window.location.href;b._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[b._webAppState.id,v.AgaveHostAction.UpdateTargetUrl,u])}if(0===e&&null!=t._id&&null!=t._appName&&null!=t._appVersion&&null!=t._appUILocale&&null!=t._dataLocale&&null!=t._docUrl&&null!=t._clientMode&&null!=t._reason){var p=(b._appContext=t)._appInstanceId?t._appInstanceId:t._id,f=0;null!=t._appMinorVersion&&(f=t._appMinorVersion);var d=void 0;null!=t._requirementMatrix&&(d=t._requirementMatrix),t.eToken=t.eToken?t.eToken:"";var h=new v.OfficeAppContext(t._id,t._appName,t._appVersion,t._appUILocale,t._dataLocale,t._docUrl,t._clientMode,function(){return _._serializedSettings},t._reason,t._osfControlType,t._eToken,t._correlationId,p,!1,!0,f,d,t._hostCustomMessage,t._hostFullVersion,t._clientWindowHeight,t._clientWindowWidth,t._addinName,t._appDomains,t._dialogRequirementMatrix,t._featureGates,t._officeTheme,t._initialDisplayMode,t._isFromWacAutomation,t._wopiHostOriginForSingleSignOn,function(){return _._serializedHostSettings},!0,t._nestedAppAuthBridgeType,t._partitionKey);h.set_taskpaneUrl(t._taskpaneUrl),m(h)}else{var g="Function ContextActivationManager_getAppContextAsync call failed. ErrorCode is "+e+", exception: "+t;v.AppTelemetry&&v.AppTelemetry.logAppException(g),y(g)}}var _=this,b=this;try{var n=!0;this._hostInfo.isDialog&&null!=window.opener&&(n=!1);var r=v.OUtil.parseAppContextFromWindowName(n,v._OfficeAppFactory.getWindowName());r?t(0,r):(OSFPerformance.getAppContextXdmStart=OSFPerformance.now(),this._webAppState.clientEndPoint.invoke("ContextActivationManager_getAppContextAsync",t,this._webAppState.id))}catch(e){v.AppTelemetry&&v.AppTelemetry.logAppException("Exception thrown when trying to invoke getAppContextAsync. Exception:["+e+"]"),y(e)}},t.prototype.createClientHostController=function(){return this._clientHostController||(this._clientHostController=new v.WebClientHostController(this._webAppState)),this._clientHostController},t.prototype.createAsyncMethodExecutor=function(){return new v.WebAsyncMethodExecutor(this._clientHostController)},t.prototype.createClientSettingsManager=function(){return new v.WebClientSettingsManager},t.prototype.addOrRemoveEventListenersForWindow=function(e){function t(){i._webAppState.focused||(i._webAppState.focused=!0),i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,v.AgaveHostAction.Select])}function n(){v&&(i._webAppState.focused&&(i._webAppState.focused=!1),i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,v.AgaveHostAction.UnSelect]))}function r(e){if(e.preventDefault=e.preventDefault||function(){e.returnValue=!1},117==e.keyCode&&(e.ctrlKey||e.metaKey)){e.preventDefault();var t=v.AgaveHostAction.CtrlF6Exit;e.shiftKey&&(t=v.AgaveHostAction.CtrlF6ExitShift),i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,t])}else if(9==e.keyCode){e.preventDefault();var n=document.querySelectorAll(i._tabbableElements);v.OUtil.focusToNextTabbable(n,e.target||e.srcElement,e.shiftKey)||(i._hostInfo.isDialog?v.OUtil.focusToFirstTabbable(n,e.shiftKey):e.shiftKey?i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,v.AgaveHostAction.TabExitShift]):i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,v.AgaveHostAction.TabExit]))}else if(27==e.keyCode)e.preventDefault(),i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,v.AgaveHostAction.EscExit]);else if(113==e.keyCode)e.preventDefault(),i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,v.AgaveHostAction.F2Exit]);else if((e.ctrlKey||e.metaKey||e.shiftKey||e.altKey)&&1<=e.keyCode&&e.keyCode<=255){var r={keyCode:e.keyCode,shiftKey:e.shiftKey,altKey:e.altKey,ctrlKey:e.ctrlKey,metaKey:e.metaKey};i._webAppState.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,v.AgaveHostAction.KeyboardShortcuts,r])}}function o(e){117==e.keyCode&&e.ctrlKey&&(e.preventDefault?e.preventDefault():e.returnValue=!1)}var i=this;v.Utility._DebugXdm||(e?(v.OUtil.addEventListener(window,"focus",t),v.OUtil.addEventListener(window,"blur",n),v.OUtil.addEventListener(window,"keydown",r),v.OUtil.addEventListener(window,"keypress",o)):(v.OUtil.removeEventListener(window,"focus",t),v.OUtil.removeEventListener(window,"blur",n),v.OUtil.removeEventListener(window,"keydown",r),v.OUtil.removeEventListener(window,"keypress",o)))},t.prototype.getTabbableElements=function(){return this._tabbableElements},t);function t(e,t,n,r){var o=i.call(this,e,t,n,r)||this;return o._serializedSettings={},o._serializedHostSettings={},o._appContext={},o._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'])",o}v.WebInitializationHelper=e}(OSF=OSF||{}),function(a){var e=(t.prototype.read=function(n){this._initializationHelper.getAppContext(null,function(e){if(n){var t=e.get_settingsFunc()();n(0,t)}},function(e){n&&n(5001,{})})},t.prototype.write=function(e,t){var n={},r=[],o=[];for(var i in e)r.push(i),o.push(e[i]);n.keys=r,n.values=o,this._scriptMessager.invokeMethod(a.Webkit.MessageHandlerName,a.Webkit.MethodId.WriteSettings,n,function(e){t&&t(e[0])})},t);function t(e,t){this._initializationHelper=e,this._scriptMessager=t}a.WebkitClientSettingsManager=e}(OSF=OSF||{}),function(d){!function(e){var t,n;e.MessageHandlerName="Agave",e.PopupMessageHandlerName="WefPopupHandler",(t=e.AppContextProperties||(e.AppContextProperties={}))[t.Settings=0]="Settings",t[t.SolutionReferenceId=1]="SolutionReferenceId",t[t.AppType=2]="AppType",t[t.MajorVersion=3]="MajorVersion",t[t.MinorVersion=4]="MinorVersion",t[t.RevisionVersion=5]="RevisionVersion",t[t.APIVersionSequence=6]="APIVersionSequence",t[t.AppCapabilities=7]="AppCapabilities",t[t.APPUILocale=8]="APPUILocale",t[t.AppDataLocale=9]="AppDataLocale",t[t.BindingCount=10]="BindingCount",t[t.DocumentUrl=11]="DocumentUrl",t[t.ActivationMode=12]="ActivationMode",t[t.ControlIntegrationLevel=13]="ControlIntegrationLevel",t[t.SolutionToken=14]="SolutionToken",t[t.APISetVersion=15]="APISetVersion",t[t.CorrelationId=16]="CorrelationId",t[t.InstanceId=17]="InstanceId",t[t.TouchEnabled=18]="TouchEnabled",t[t.CommerceAllowed=19]="CommerceAllowed",t[t.RequirementMatrix=20]="RequirementMatrix",t[t.HostCustomMessage=21]="HostCustomMessage",t[t.HostFullVersion=22]="HostFullVersion",t[t.InitialDisplayMode=23]="InitialDisplayMode",t[t.FeatureGates=24]="FeatureGates",t[t.HostSettings=25]="HostSettings",t[t.OfficeThemeInfo=26]="OfficeThemeInfo",(n=e.MethodId||(e.MethodId={}))[n.Execute=1]="Execute",n[n.RegisterEvent=2]="RegisterEvent",n[n.UnregisterEvent=3]="UnregisterEvent",n[n.WriteSettings=4]="WriteSettings",n[n.GetContext=5]="GetContext",n[n.SendMessage=6]="SendMessage",n[n.MessageParent=7]="MessageParent",n[n.SendMessage2=8]="SendMessage2",n[n.MessageParent2=9]="MessageParent2",n[n.CloseSdxDialog=10]="CloseSdxDialog",n[n.ResizeSdxDialog=11]="ResizeSdxDialog";var r=(f.prototype.execute=function(e,t,o){var n={id:e,apiArgs:t};this.hostScriptProxy.invokeMethod(d.Webkit.MessageHandlerName,d.Webkit.MethodId.Execute,n,function(e){if(o){var t=[];if(d.OUtil.isArray(e))for(var n=0;n<e.length;n++){var r=e[n];d.OUtil.isArray(r)&&(r=new d.WebkitSafeArray(r)),t.unshift(r)}return o.apply(null,t)}})},f.prototype.registerEvent=function(e,t,n,r,o){this.hostScriptProxy.registerEvent(d.Webkit.MessageHandlerName,d.Webkit.MethodId.RegisterEvent,e,n,function(e){var t=e,n=0;d.OUtil.isArray(e)&&2<=e.length&&(t=e[0],n=e[1]),r&&r(n,new d.WebkitSafeArray(t))},function(e){if(o)return o(new d.WebkitSafeArray(e))})},f.prototype.unregisterEvent=function(e,t,n,r){this.hostScriptProxy.unregisterEvent(d.Webkit.MessageHandlerName,d.Webkit.MethodId.UnregisterEvent,e,n,function(e){return r(new d.WebkitSafeArray(e))})},f.prototype.messageParent=function(e){var t,n;if(n=this.osfSupportsDialogOrigin&&e[d.ParameterNames.TargetOrigin]?(t=this.useFullDialogAPI?JSON.stringify(e):e[d.ParameterNames.MessageToParent],d.Webkit.MethodId.MessageParent2):(t=e[d.ParameterNames.MessageToParent],d.Webkit.MethodId.MessageParent),this.useFullDialogAPI)this.hostScriptProxy.invokeMethod(d.Webkit.MessageHandlerName,n,t,null);else{var r={dialogMessage:{messageType:0,messageContent:t}},o=n==d.Webkit.MethodId.MessageParent2?e[d.ParameterNames.TargetOrigin]:window.location.origin;window.opener.postMessage(JSON.stringify(r),o)}},f.prototype.openDialog=function(n,e,t,r,o){if(this.useFullDialogAPI)this.registerEvent(n,e,t,r,o);else if(!f.popup||f.popup.closed){f.OpenDialogCallback=void 0;var i=JSON.parse(t),a=i.url;if(a){var s=a.split("#"),c="?";-1<s[0].indexOf("?")&&(c="&");var l="width="+screen.width*i.width/100+", height="+screen.height*i.height/100;s[0]=s[0].concat(c).concat("action=displayDialog");var u=s.join("#");f.popup=window.open(u,"",l),f.DialogEventListener=function(t){if(t.origin==window.location.origin)try{var e=JSON.parse(t.data);e.dialogMessage&&r(n,[0,e.dialogMessage.messageContent,t.origin])}catch(e){d.Utility.trace("messages received cannot be handlered. Message:"+t.data)}},f.OpenDialogCallback=function(e){0==e&&(window.addEventListener("message",f.DialogEventListener),f.interval=window.setInterval(p,1e3),f.NotifyError=function(e){r(n,[e])}),o(e)}}else o(12003)}else o(12007);function p(){try{null!=f.popup&&!f.popup.closed||(window.clearInterval(f.interval),window.removeEventListener("message",f.DialogEventListener),f.NotifyError=null,f.popup=null,r(n,[12006]))}catch(e){d.Utility.trace("Error happened when popup window closed.")}}},f.prototype.closeDialog=function(e,t,n,r){this.useFullDialogAPI?this.unregisterEvent(e,t,n,r):f.popup?(f.interval&&window.clearInterval(f.interval),f.popup.close(),f.popup=null,window.removeEventListener("message",f.DialogEventListener),f.NotifyError=null,r(0)):r(5001)},f.prototype.sendMessage=function(e){var t,n;this.osfSupportsDialogOrigin&&e[d.ParameterNames.TargetOrigin]?(t=JSON.stringify(e),n=d.Webkit.MethodId.SendMessage2):(t=e[d.ParameterNames.MessageContent],n=d.Webkit.MethodId.SendMessage,!isNaN(parseFloat(t))&&isFinite(t)&&(t=t.toString())),this.hostScriptProxy.invokeMethod(d.Webkit.MessageHandlerName,n,t,null)},f.prototype.closeSdxDialog=function(e){var t=[e],n=d.Webkit.MethodId.CloseSdxDialog;this.hostScriptProxy.invokeMethod(d.Webkit.MessageHandlerName,n,t,null)},f.prototype.resizeSdxDialog=function(e,t){var n=[e,t],r=d.Webkit.MethodId.ResizeSdxDialog;this.hostScriptProxy.invokeMethod(d.Webkit.MessageHandlerName,r,n,null)},f);function f(e){this.hostScriptProxy=e,this.useFullDialogAPI=!!window._enableFullDialogAPI,this.osfSupportsDialogOrigin=!!window._osfEnableDialogOrigin}e.WebkitHostController=r}(d.Webkit||(d.Webkit={}))}(OSF=OSF||{}),function(M){var i,e=(i=M.InitializationHelper,__extends(t,i),t.prototype.initializeWebkitMessaging=function(){M.ScriptMessaging=OSFWebkit.ScriptMessaging},t.prototype.getAppContext=function(e,j,t){var n,k=this;n=this._hostInfo.isDialog&&window.webkit.messageHandlers[M.Webkit.PopupMessageHandlerName]?M.Webkit.PopupMessageHandlerName:M.Webkit.MessageHandlerName,M.ScriptMessaging.GetScriptMessenger().invokeMethod(n,M.Webkit.MethodId.GetContext,[],function(e){var t,n=M.Webkit.AppContextProperties,r=e[n.AppType],o=e[n.Settings];if(o&&2===o.length)for(var i=o[0],a=o[1],s=0;s<i.length;s++)k._serializedSettings[i[s]]=a[s];var c=e[n.HostSettings];if(c&&2===c.length)for(i=c[0],a=c[1],s=0;s<i.length;s++)k._serializedHostSettings[i[s]]=a[s];var l=e[n.SolutionReferenceId],u=e[n.MajorVersion],p=e[n.MinorVersion],f=e[n.AppCapabilities],d=e[n.APPUILocale],h=e[n.AppDataLocale],g=e[n.DocumentUrl],m=e[n.ActivationMode],y=e[n.ControlIntegrationLevel],_=e[n.SolutionToken];_=_?_.toString():"";var b,v=e[n.CorrelationId],O=e[n.InstanceId],C=e[n.TouchEnabled],P=e[n.CommerceAllowed],S=e[n.RequirementMatrix],A=e[n.HostCustomMessage],I=e[n.HostFullVersion],R=e[n.InitialDisplayMode],T=e[n.FeatureGates];if(T)try{b=JSON.parse(T)}catch(e){M.AppTelemetry&&M.AppTelemetry.logAppException("Exception trying to parse FeatureGates."+e)}var E=null;if(e[n.OfficeThemeInfo])try{E=JSON.parse(e[n.OfficeThemeInfo])}catch(e){M.AppTelemetry&&M.AppTelemetry.logAppException("Exception while parsing officeThemeInfo. Details: "+e)}var N={};if(E){var D={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 x in E){var w=!1,F=x;D[x]&&(F=D[x].name,w=D[x].convertToHex),N[F]=w?M.OUtil.convertIntToCssHexColor(E[x]):E[x]}}t=new M.OfficeAppContext(l,r,u,d,h,g,f,function(){return k._serializedSettings},m,y,_,v,O,C,P,p,S,A,I,void 0,void 0,void 0,void 0,void 0,b,N,R,void 0,void 0,function(){return k._serializedHostSettings},!1,void 0,void 0),j(t)})},t.prototype.createClientHostController=function(){return this._clientHostController||(this._clientHostController=new M.Webkit.WebkitHostController(M.ScriptMessaging.GetScriptMessenger())),this._clientHostController},t.prototype.createAsyncMethodExecutor=function(){return new M.SafeArrayAsyncMethodExecutor(this.createClientHostController())},t.prototype.createClientSettingsManager=function(){return new M.WebkitClientSettingsManager(this,M.ScriptMessaging.GetScriptMessenger())},t);function t(e,t,n,r){var o=i.call(this,e,t,n,r)||this;return o._serializedSettings={},o._serializedHostSettings={},o.initializeWebkitMessaging(),o}M.WebkitInitializationHelper=e}(OSF=OSF||{}),function(s){var e=(r.prototype.dimensions=function(){var e=0;return this.safeArrayFlag?e=this.data[0][0]:this.isArray()&&(e=2),e},r.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},r.prototype.lbound=function(e){return 0},r.prototype.ubound=function(e){var t=0;if(this.safeArrayFlag)t=this.data[0][e];else if(this.isArray()){if(1==e)return this.data.length;if(2==e){if(s.OUtil.isArray(this.data[0]))return this.data[0].length;if(null!=this.data[0])return 1}}return t},r.prototype.toArray=function(){if(0==this.isArray())return this.data;for(var e=[],t=this.safeArrayFlag?1:0;t<this.data.length;t++){var n=this.data[t];this.isSafeArray(n)?e.push(new r(n)):e.push(n)}return e},r.prototype.isArray=function(){return s.OUtil.isArray(this.data)},r.prototype.isSafeArray=function(e){var t=!1;if(s.OUtil.isArray(e)&&s.OUtil.isArray(e[0])){var n=e[0],r=n[0];if(n.length!=r+1)return!1;for(var o=1,i=1;i<n.length;i++){var a=n[i];if(0==isFinite(a))return!1;o*=a}t=++o==e.length}return t},r);function r(e){this.data=e,this.safeArrayFlag=this.isSafeArray(e)}s.WebkitSafeArray=e}(OSF=OSF||{}),function(e){!function(e){var n=null;e.agaveHostCallback=function(e,t){n.agaveHostCallback(e,t)},e.agaveHostEventCallback=function(e,t){n.agaveHostEventCallback(e,t)},e.GetScriptMessenger=function(){return null==n&&(n=t.IsSupportedByHost()?new t:new o("OSF.ScriptMessaging.agaveHostCallback","OSF.ScriptMessaging.agaveHostEventCallback")),n};var l=function(e,t,n){this.id=e,this.targetId=t,this.handler=n},t=(r.IsSupportedByHost=function(){return!!window._osfHostAPI},r.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})},r.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})},r.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;0<=a;a--){var s=this.eventHandlers[a];s.dispId===n&&s.targetId===r&&(this.eventHandlers.splice(a,1),window._osfHostUnregisterCallback(s.callbackId))}},r.prototype.agaveHostCallback=function(e,t){},r.prototype.agaveHostEventCallback=function(e,t){},r.prototype.constructMessagingArgs=function(e,t){return{params:t,methodId:e}},r);function r(){this.eventHandlers=[]}var o=(c.prototype.invokeMethod=function(e,t,n,r){this.postWebkitMessage({},e,t,n,r)},c.prototype.registerEvent=function(e,t,n,r,o,i){var a={eventCallbackFunction:this.eventCallbackFunctionName},s={id:n,targetId:r},c=this.postWebkitMessage(a,e,t,s,i);this.eventHandlerList[c]=new l(n,r,o)},c.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)},c.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]}},c.prototype.agaveHostEventCallback=function(e,t){var n=this.eventHandlerList[e];n&&n.handler(t)},c.prototype.postWebkitMessage=function(e,t,n,r,o){e.methodId=n,e.params=r;var i="";function a(){window.webkit.messageHandlers[t].postMessage(JSON.stringify(e))}o&&(i=this.generateCorrelationId(),this.callbackList[i]=o,e.callbackId=i,e.callbackFunction=this.asyncMethodCallbackFunctionName);var s=c.getCurrentTimeMS();return null==this.lastMessageTimestamp||s-this.lastMessageTimestamp>=c.MESSAGE_TIME_DELTA?(a(),this.lastMessageTimestamp=s):(this.lastMessageTimestamp+=c.MESSAGE_TIME_DELTA,setTimeout(function(){a()},this.lastMessageTimestamp-s)),i},c.prototype.generateCorrelationId=function(){return++this.callingIndex,this.conversationId+this.callingIndex},c.getCurrentTimeMS=function(){return(new Date).getTime()},c.MESSAGE_TIME_DELTA=10,c);function c(e,t){this.callingIndex=0,this.callbackList={},this.eventHandlerList={},this.asyncMethodCallbackFunctionName=e,this.eventCallbackFunctionName=t,this.conversationId=c.getCurrentTimeMS().toString()}}(e.ScriptMessaging||(e.ScriptMessaging={}))}(OSFWebkit=OSFWebkit||{}),function(a){var e=(t.prototype.read=function(n){this._initializationHelper.getAppContext(null,function(e){if(n){var t=e.get_settingsFunc()();n(0,t)}},function(e){n&&n(5001,{})})},t.prototype.write=function(e,t){var n={},r=[],o=[];for(var i in e)r.push(i),o.push(e[i]);n.keys=r,n.values=o,this._scriptMessager.invokeMethod(a.WebView.MessageHandlerName,a.WebView.MethodId.WriteSettings,n,function(e){t&&t(e[0])})},t);function t(e,t){this._initializationHelper=e,this._scriptMessager=t}a.WebViewClientSettingsManager=e}(OSF=OSF||{}),function(d){!function(e){var t,n;e.MessageHandlerName="Agave",e.PopupMessageHandlerName="WefPopupHandler",(t=e.AppContextProperties||(e.AppContextProperties={}))[t.Settings=0]="Settings",t[t.SolutionReferenceId=1]="SolutionReferenceId",t[t.AppType=2]="AppType",t[t.MajorVersion=3]="MajorVersion",t[t.MinorVersion=4]="MinorVersion",t[t.RevisionVersion=5]="RevisionVersion",t[t.APIVersionSequence=6]="APIVersionSequence",t[t.AppCapabilities=7]="AppCapabilities",t[t.APPUILocale=8]="APPUILocale",t[t.AppDataLocale=9]="AppDataLocale",t[t.BindingCount=10]="BindingCount",t[t.DocumentUrl=11]="DocumentUrl",t[t.ActivationMode=12]="ActivationMode",t[t.ControlIntegrationLevel=13]="ControlIntegrationLevel",t[t.SolutionToken=14]="SolutionToken",t[t.APISetVersion=15]="APISetVersion",t[t.CorrelationId=16]="CorrelationId",t[t.InstanceId=17]="InstanceId",t[t.TouchEnabled=18]="TouchEnabled",t[t.CommerceAllowed=19]="CommerceAllowed",t[t.RequirementMatrix=20]="RequirementMatrix",t[t.OfficeThemeInfo=21]="OfficeThemeInfo",(n=e.MethodId||(e.MethodId={}))[n.Execute=1]="Execute",n[n.RegisterEvent=2]="RegisterEvent",n[n.UnregisterEvent=3]="UnregisterEvent",n[n.WriteSettings=4]="WriteSettings",n[n.GetContext=5]="GetContext",n[n.OnKeydown=6]="OnKeydown",n[n.AddinInitialized=7]="AddinInitialized",n[n.OpenWindow=8]="OpenWindow",n[n.MessageParent=9]="MessageParent",n[n.SendMessage=10]="SendMessage";var r=(f.prototype.execute=function(e,t,n){var r=t;null==r&&(r=[]);var o={id:e,apiArgs:r};this.hostScriptProxy.invokeMethod(d.WebView.MessageHandlerName,d.WebView.MethodId.Execute,o,function(e){var t=e;if(d.OUtil.isArray(e)&&2<=e.length&&(e[0],t=e[1]),n)return n(new d.WebkitSafeArray(t))})},f.prototype.registerEvent=function(e,t,n,r,o){this.hostScriptProxy.registerEvent(d.WebView.MessageHandlerName,d.WebView.MethodId.RegisterEvent,e,n,function(e){var t=e,n=0;d.OUtil.isArray(e)&&2<=e.length&&(n=e[0],t=e[1]),r&&r(n,new d.WebkitSafeArray(t))},function(e){if(o)return o(new d.WebkitSafeArray(e))})},f.prototype.unregisterEvent=function(e,t,n,r){this.hostScriptProxy.unregisterEvent(d.WebView.MessageHandlerName,d.WebView.MethodId.UnregisterEvent,e,n,function(e){return r(new d.WebkitSafeArray(e))})},f.prototype.messageParent=function(e){var t={dialogMessage:{messageType:0,messageContent:e[d.ParameterNames.MessageToParent]}};window.opener.postMessage(JSON.stringify(t),window.location.origin)},f.prototype.openDialog=function(n,e,t,r,o){var i=JSON.parse(t),a=i.url;if(a){var s=a.split("#"),c="?";-1<a.indexOf("?")&&(c="&");var l="width="+screen.width*i.width/100+", height="+screen.height*i.height/100;s[0]=s[0].concat(c).concat("action=displayDialog");var u,p=s.join("#");f.popup=window.open(p,"",l),window.addEventListener("message",function(t){if(t.source==f.popup)try{var e=JSON.parse(t.data);e.dialogMessage&&r(n,[0,e.dialogMessage.messageContent])}catch(e){d.Utility.trace("messages received cannot be handled. Message:"+t.data)}}),u=window.setInterval(function(){try{null!=f.popup&&!f.popup.closed||(window.clearInterval(u),r(n,[12006]))}catch(e){d.Utility.trace("Error happened when popup window closed.")}},1e3),o(0)}},f.prototype.closeDialog=function(e,t,n,r){f.popup?(f.popup.close(),f.popup=null,r(0)):r(5001)},f.prototype.sendMessage=function(e){var t=e[d.ParameterNames.MessageContent];!isNaN(parseFloat(t))&&isFinite(t)&&(t=t.toString()),this.hostScriptProxy.invokeMethod(d.WebView.MessageHandlerName,d.WebView.MethodId.SendMessage,t,null)},f.prototype.closeSdxDialog=function(e){throw d.Utility.createNotImplementedException()},f.prototype.resizeSdxDialog=function(e,t){throw d.Utility.createNotImplementedException()},f);function f(e){this.hostScriptProxy=e}e.WebViewHostController=r}(d.WebView||(d.WebView={}))}(OSF=OSF||{}),function(T){var i,e=(i=T.InitializationHelper,__extends(t,i),t.prototype.initializeWebViewMessaging=function(){T.ScriptMessaging=T.WebView.ScriptMessaging},t.prototype.getAppContext=function(e,I,t){var n,R=this;n=this._hostInfo.isDialog?T.WebView.PopupMessageHandlerName:T.WebView.MessageHandlerName,T.ScriptMessaging.GetScriptMessenger().invokeMethod(n,T.WebView.MethodId.GetContext,[],function(e){var t,n=T.Webkit.AppContextProperties,r=e[n.AppType],o=e[n.Settings];if(o&&2===o.length)for(var i=o[0],a=o[1],s=0;s<i.length;s++)R._serializedSettings[i[s]]=a[s];var c=e[n.SolutionReferenceId],l=e[n.MajorVersion],u=e[n.MinorVersion],p=e[n.AppCapabilities],f=e[n.APPUILocale],d=e[n.AppDataLocale],h=e[n.DocumentUrl],g=e[n.ActivationMode],m=e[n.ControlIntegrationLevel],y=e[n.SolutionToken];y=y?y.toString():"";var _=e[n.CorrelationId],b=e[n.InstanceId],v=e[n.TouchEnabled],O=e[n.CommerceAllowed],C=e[n.RequirementMatrix],P=e[n.HostCustomMessage],S=e[n.HostFullVersion],A=e[n.InitialDisplayMode];t=new T.OfficeAppContext(c,r,l,f,d,h,p,function(){return R._serializedSettings},g,m,y,_,b,v,O,u,C,P,S,void 0,void 0,void 0,void 0,void 0,void 0,void 0,A,void 0,void 0,void 0,!1,void 0,void 0),I(t)})},t.prototype.createClientHostController=function(){return this._clientHostController||(this._clientHostController=new T.WebView.WebViewHostController(T.ScriptMessaging.GetScriptMessenger())),this._clientHostController},t.prototype.createAsyncMethodExecutor=function(){return new T.SafeArrayAsyncMethodExecutor(this.createClientHostController())},t.prototype.createClientSettingsManager=function(){return new T.WebViewClientSettingsManager(this,T.ScriptMessaging.GetScriptMessenger())},t);function t(e,t,n,r){var o=i.call(this,e,t,n,r)||this;return o._serializedSettings={},o.initializeWebViewMessaging(),o}T.WebViewInitializationHelper=e}(OSF=OSF||{}),function(n){var r,e,t,o,i;function a(){}function s(){window.addEventListener("message",this.OnReceiveMessage.bind(this))}!function(e){var t;(t=e.CallbackType||(e.CallbackType={}))[t.MethodCallback=0]="MethodCallback",t[t.EventCallback=1]="EventCallback";function n(e,t,n){this.callbackType=e,this.callbackId=t,this.params=n}e.CallbackData=n}(r=r||{}),e=n.Android||(n.Android={}),a.getInstance=function(){return null==a.uniqueInstance&&(a.uniqueInstance=new a),a.uniqueInstance},a.prototype.postMessage=function(e,t){agaveHost.postMessage(t)},a.prototype.ReceiveMessage=function(e){switch(e.callbackType){case r.CallbackType.MethodCallback:n.WebView.ScriptMessaging.agaveHostCallback(e.callbackId,e.params);break;case r.CallbackType.EventCallback:n.WebView.ScriptMessaging.agaveHostEventCallback(e.callbackId,e.params)}},t=a,e.Poster=t,o=n.WinRT||(n.WinRT={}),s.prototype.postMessage=function(e,t){window.parent.postMessage(t,"*")},s.prototype.OnReceiveMessage=function(e){if(e.source==window.parent&&window.parent==window.top&&e.origin.startsWith("ms-appx-web://")){var t;try{t=JSON.parse(e.data)}catch(e){return}switch(t.callbackType){case r.CallbackType.MethodCallback:n.WebView.ScriptMessaging.agaveHostCallback(t.callbackId,JSON.parse(t.params));break;case r.CallbackType.EventCallback:n.WebView.ScriptMessaging.agaveHostEventCallback(t.callbackId,JSON.parse(t.params))}}},i=s,o.Poster=i}(OSF=OSF||{}),function(o){var e;(function(e){var n=null;e.agaveHostCallback=function(e,t){n.agaveHostCallback(e,t)},e.agaveHostEventCallback=function(e,t){n.agaveHostEventCallback(e,t)},e.GetScriptMessenger=function(){if(null==n){var e=o._OfficeAppFactory.getHostInfo().hostPlatform;if(e===o.HostInfoPlatform.android)n=new t("OSF.ScriptMessaging.agaveHostCallback","OSF.ScriptMessaging.agaveHostEventCallback",o.Android.Poster.getInstance());else{if(e!==o.HostInfoPlatform.winrt)throw o.Utility.createNotImplementedException();n=new t("agaveHostCallback","agaveHostEventCallback",new o.WinRT.Poster)}}return n};var l=function(e,t,n){this.id=e,this.targetId=t,this.handler=n},t=(r.prototype.invokeMethod=function(e,t,n,r){this.postMessage({},e,t,n,r)},r.prototype.registerEvent=function(e,t,n,r,o,i){var a={eventCallbackFunction:this.eventCallbackFunctionName},s={id:n,targetId:r},c=this.postMessage(a,e,t,s,i);this.eventHandlerList[c]=new l(n,r,o)},r.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)},r.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]}},r.prototype.agaveHostEventCallback=function(e,t){var n=this.eventHandlerList[e];n&&n.handler(t)},r.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},r.prototype.generateCorrelationId=function(){return++this.callingIndex,this.conversationId+this.callingIndex},r.getCurrentTimeMS=function(){return(new Date).getTime()},r.MESSAGE_TIME_DELTA=10,r);function r(e,t,n){this.callingIndex=0,this.callbackList={},this.eventHandlerList={},this.asyncMethodCallbackFunctionName=e,this.eventCallbackFunctionName=t,this.poster=n,this.conversationId=r.getCurrentTimeMS().toString()}})((e=o.WebView||(o.WebView={})).ScriptMessaging||(e.ScriptMessaging={}))}(OSF=OSF||{}),function(n){var e,t=(e=n.RichClientHostController,__extends(r,e),r.prototype.messageParent=function(e){if(n.Utility.externalNativeFunctionExists(typeof window.external.MessageParent2))"undefined"!=typeof OsfOMToken&&OsfOMToken?window.external.MessageParent2(JSON.stringify(e),OsfOMToken):window.external.MessageParent2(JSON.stringify(e));else{var t=e[n.ParameterNames.MessageToParent];window.external.MessageParent(t)}},r.prototype.openDialog=function(e,t,n,r,o){this.registerEvent(e,t,n,r,o)},r.prototype.closeDialog=function(e,t,n,r){this.unregisterEvent(e,t,n,r)},r.prototype.sendMessage=function(e){if(n.Utility.externalNativeFunctionExists(typeof window.external.MessageChild2))"undefined"!=typeof OsfOMToken&&OsfOMToken?window.external.MessageChild2(JSON.stringify(e),OsfOMToken):window.external.MessageChild2(JSON.stringify(e));else{var t=e[n.ParameterNames.MessageContent];window.external.MessageChild(t)}},r.prototype.closeSdxDialog=function(e){n.Utility.externalNativeFunctionExists(typeof window.external.closeSdxDialog)&&window.external.closeSdxDialog(e)},r.prototype.resizeSdxDialog=function(e,t){n.Utility.externalNativeFunctionExists(typeof window.external.resizeSdxDialog)&&window.external.resizeSdxDialog(e,t)},r);function r(){return null!==e&&e.apply(this,arguments)||this}n.Win32RichClientHostController=t}(OSF=OSF||{}),function(f){var e,t=(e=f.Webkit.WebkitHostController,__extends(d,e),d.prototype.openDialog=function(n,e,t,r,o){if(!d.popup||d.popup.closed){window.dialogAPIErrorCode=void 0;var i=JSON.parse(t),a=i.url;if(a){var s=a.split("#"),c="?";-1<s[0].indexOf("?")&&(c="&");var l="width="+screen.width*i.width/100+", height="+screen.height*i.height/100;s[0]=s[0].concat(c).concat("action=displayDialog");var u=s.join("#");if(d.popup=window.open(u,"",l),d.DialogEventListener=function(t){if(t.source==d.popup)try{var e=JSON.parse(t.data);e.dialogMessage&&r(n,[0,e.dialogMessage.messageContent])}catch(e){f.Utility.trace("messages received cannot be handlered. Message:"+t.data)}},null!=d.popup&&null==window.dialogAPIErrorCode)window.addEventListener("message",d.DialogEventListener),d.interval=window.setInterval(function(){try{null!=d.popup&&!d.popup.closed||(window.clearInterval(d.interval),window.removeEventListener("message",d.DialogEventListener),d.NotifyError=null,r(n,[12006]))}catch(e){f.Utility.trace("Error happened when popup window closed.")}},500),d.NotifyError=function(e){r(n,[e])},o(0);else{var p=5001;window.dialogAPIErrorCode&&(p=window.dialogAPIErrorCode),o(p)}}else o(12003)}else o(12007)},d.prototype.messageParent=function(e){var t={dialogMessage:{messageType:0,messageContent:e[f.ParameterNames.MessageToParent]}};window.opener.postMessage(JSON.stringify(t),window.location.origin)},d.prototype.closeDialog=function(e,t,n,r){d.popup?(d.interval&&window.clearInterval(d.interval),d.popup.close(),d.popup=null,window.removeEventListener("message",d.DialogEventListener),d.NotifyError=null,r(0)):r(5001)},d);function d(){return null!==e&&e.apply(this,arguments)||this}f.MacRichClientHostController=t}(OSF=OSF||{}),function(e){var t,n,r;((n=e._Internal||(e._Internal={})).PromiseImpl||(n.PromiseImpl={})).Init=function(){return function(){"use strict";function l(e){return"function"==typeof e}var n,a=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},r=0,s=function(e,t){p[r]=e,p[r+1]=t,2===(r+=2)&&(n?n(f):o())};var e="undefined"!=typeof process&&"[object process]"==={}.toString.call(process),t="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;var o,i,c,u,p=new Array(1e3);function f(){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 d(){}o=e?(c=process.nextTick,u=process.versions.node.match(/^(?:(\d+)\.)?(?:(\d+)\.)?(\*|\d+)$/),Array.isArray(u)&&"0"===u[1]&&"10"===u[2]&&(c=setImmediate),function(){c(f)}):t?((i=new MessageChannel).port1.onmessage=f,function(){i.port2.postMessage(0)}):function(){setTimeout(f,1)};var h=void 0,g=1,m=2,y=new I;function _(e,r,o){s(function(t){var n=!1,e=function(e,t,n,r){try{e.call(t,n,r)}catch(e){return e}}(o,r,function(e){n||(n=!0,(r!==e?v:C)(t,e))},function(e){n||(n=!0,P(t,e))},t._label);!n&&e&&(n=!0,P(t,e))},e)}function b(e,t){if(t.constructor===e.constructor)r=e,(o=t)._state===g?C(r,o._result):o._state===m?P(r,o._result):S(o,void 0,function(e){v(r,e)},function(e){P(r,e)});else{var n=function(e){try{return e.then}catch(e){return y.error=e,y}}(t);n===y?P(e,y.error):void 0!==n&&l(n)?_(e,t,n):C(e,t)}var r,o}function v(e,t){var n;e===t?P(e,new TypeError("You cannot resolve a promise with itself")):("function"==typeof(n=t)||"object"==typeof n&&null!==n?b:C)(e,t)}function O(e){e._onerror&&e._onerror(e._result),A(e)}function C(e,t){e._state===h&&(e._result=t,e._state=g,0!==e._subscribers.length&&s(A,e))}function P(e,t){e._state===h&&(e._state=m,e._result=t,s(O,e))}function S(e,t,n,r){var o=e._subscribers,i=o.length;e._onerror=null,o[i]=t,o[i+g]=n,o[i+m]=r,0===i&&e._state&&s(A,e)}function A(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?T(n,r,o,i):o(i);e._subscribers.length=0}}function I(){this.error=null}var R=new I;function T(e,t,n,r){var o,i,a,s,c=l(n);if(c){if((o=function(e,t){try{return e(t)}catch(e){return R.error=e,R}}(n,r))===R?(s=!0,i=o.error,o=null):a=!0,t===o)return void P(t,new TypeError("A promises callback cannot return that same promise."))}else o=r,a=!0;t._state!==h||(c&&a?v(t,o):s?P(t,i):e===g?C(t,o):e===m&&P(t,o))}function E(e,t){var n=this;n._instanceConstructor=e,n.promise=new e(d),n._validateInput(t)?(n._input=t,n.length=t.length,n._remaining=t.length,n._init(),0===n.length?C(n.promise,n._result):(n.length=n.length||0,n._enumerate(),0===n._remaining&&C(n.promise,n._result))):P(n.promise,n._validationError())}E.prototype._validateInput=function(e){return a(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 N=E;E.prototype._enumerate=function(){for(var e=this.length,t=this.promise,n=this._input,r=0;t._state===h&&r<e;r++)this._eachEntry(n[r],r)},E.prototype._eachEntry=function(e,t){var n,r=this,o=r._instanceConstructor;"object"==typeof(n=e)&&null!==n?e.constructor===o&&e._state!==h?(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===h&&(r._remaining--,e===m?P(o,n):r._result[t]=n),0===r._remaining&&C(o,r._result)},E.prototype._willSettleAt=function(e,t){var n=this;S(e,void 0,function(e){n._settledAt(g,t,e)},function(e){n._settledAt(m,t,e)})};function D(e){var t=new this(d);if(!a(e))return P(t,new TypeError("You must pass an array to race.")),t;var n=e.length;function r(e){v(t,e)}function o(e){P(t,e)}for(var i=0;t._state===h&&i<n;i++)S(this.resolve(e[i]),void 0,r,o);return t}function x(e){if(e&&"object"==typeof e&&e.constructor===this)return e;var t=new this(d);return v(t,e),t}function w(e){var t=new this(d);return P(t,e),t}var F=0;var j=k;function k(e){this._id=F++,this._state=void 0,this._result=void 0,this._subscribers=[],d!==e&&(l(e)||function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof k||function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}(),function(t,e){try{e(function(e){v(t,e)},function(e){P(t,e)})}catch(e){P(t,e)}}(this,e))}return k.all=function(e){return new N(this,e).promise},k.race=D,k.resolve=x,k.reject=w,k._setScheduler=function(e){n=e},k._setAsap=function(e){s=e},k._asap=s,k.prototype={constructor:k,then:function(e,t){var n=this._state;if(n===g&&!e||n===m&&!t)return this;var r=new this.constructor(d),o=this._result;if(n){var i=arguments[n-1];s(function(){T(n,r,i,o)})}else S(this,r,e,t);return r},catch:function(e){return this.then(null,e)}},j}.call(this)},(r=t=e._Internal||(e._Internal={})).OfficePromise=function(){if("undefined"==typeof window&&"function"==typeof Promise)return Promise;if("undefined"!=typeof window){if(window.Promise)return window.Promise;var e=r.PromiseImpl.Init();return window.Promise=e}}(),e.OfficePromise=t.OfficePromise,e.Promise=e.OfficePromise}(Office=Office||{}),function(_){!function(i){var a,s=_.OUtil.Guid.generateNewGuid(),c=new RegExp("^https?://store\\.office(ppe|-int)?\\.com/","i"),l=!1,u="PRIVATE";i.enableTelemetry=!0;var p=function(){};i.AppInfo=p;var f=(e.prototype.getClientId=function(){var e=this.getValue(this.clientIDKey);return(!e||e.length<=0||40<e.length)&&(e=_.OUtil.Guid.generateNewGuid(),this.setValue(this.clientIDKey,e)),e},e.prototype.getValue=function(e){var t=_.OUtil.getLocalStorage(),n="";return t&&(n=t.getItem(e)),n},e.prototype.setValue=function(e,t){var n=_.OUtil.getLocalStorage();n&&n.setItem(e,t)},e);function e(){this.clientIDKey="Office API client",this.logIdSetKey="Office App Log Id Set"}function d(e){return(e=e&&e.replace(/[{}]/g,"").toLowerCase())||""}function h(t){try{return JSON.parse(t)}catch(e){return t}}function t(){a&&(l||OTel.OTelLogger.onTelemetryLoaded(function(){var e=[],t=a.isMos?1:0;e=e.concat([oteljs.makeStringDataField("Browser",a.browser),oteljs.makeInt64DataField("AppSizeWidth",window.innerWidth),oteljs.makeInt64DataField("AppSizeHeight",window.innerHeight),oteljs.makeInt64DataField("IsMOS",t)]),_.OUtil.isChangeGateEnabled("Microsoft.Office.SharedOnline.ChangeGate.OfficeVSO_10045620_CopilotAgentTelSettings")&&a.launchSource&&a.launchReason&&(e.push(oteljs.makeStringDataField("LaunchSource",a.launchSource)),e.push(oteljs.makeStringDataField("LaunchReason",a.launchReason))),Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.AppActivatedX",dataFields:e,eventFlags:{dataCategories:2,diagnosticLevel:110,samplingPolicy:191}})}))}function n(e,t){}function g(){var e=0!=(_._OfficeAppFactory.getHostInfo().flags&_.HostInfoFlags.PublicAddin);return e||!!a&&r(_._OfficeAppFactory.getHostInfo().hostPlatform,a.hostVersion)}function m(e,t){return g()||t!==e?t:u}function r(e,t){var n=!1,r=/^(\d+)\.(\d+)\.(\d+)\.(\d+)$/.exec(t);if(r){var o=parseInt(r[1]),i=parseInt(r[2]),a=parseInt(r[3]);e==_.HostInfoPlatform.win32?(o<16||16==o&&a<14225)&&(n=!0):e==_.HostInfoPlatform.mac&&(o<16||16==o&&(i<52||52==i&&a<808))&&(n=!0)}return n}function y(){return 0!=(_._OfficeAppFactory.getHostInfo().flags&_.HostInfoFlags.IsMos)}i.initialize=function(e){if(i.enableTelemetry&&!a){a=new p,e.get_hostFullVersion()?a.hostVersion=e.get_hostFullVersion():a.hostVersion=e.get_appVersion(),a.appId=g()?e.get_id():u,a.marketplaceType=e._marketplaceType,a.host=""+e.get_appName(),a.browser=window.navigator.userAgent,a.correlationId=d(e.get_correlationId()),a.clientId=(new f).getClientId(),a.appInstanceId=e.get_appInstanceId(),a.appInstanceId&&(a.appInstanceId=d(a.appInstanceId),a.appInstanceId=m(e.get_id(),a.appInstanceId)),a.message=e.get_hostCustomMessage(),a.officeJSVersion=_.ConstantNames.FileVersion,a.hostJSVersion="NA",e._wacHostEnvironment&&(a.wacHostEnvironment=e._wacHostEnvironment);var t=e.get_isFromWacAutomation();null!=t&&(a.isFromWacAutomation=t.toString().toLowerCase());var n=e.get_docUrl();a.docUrl=c.test(n)?n:"";var r=location.href;if(r&&(a.isPreload=-1!==r.indexOf("preload=1"),r=r.split("?")[0].split("#")[0]),a.isMos=y(),_.OUtil.isChangeGateEnabled("Microsoft.Office.SharedOnline.ChangeGate.OfficeVSO_10045620_CopilotAgentTelSettings")){var o=e.get_settingsFunc()();o&&o.LaunchSource&&o.LaunchReason&&(a.launchSource=h(o.LaunchSource),a.launchReason=h(o.LaunchReason))}!function(e,t){t.assetId="",t.userId="";try{if(!_.Utility.isNullOrEmpty(e)){var n=decodeURIComponent(e),r=new DOMParser,o=void 0;if(_.LoadScriptHelper.trustedTypesOptIn()&&window.trustedTypes&&window.trustedTypes.createPolicy)o=window.trustedTypes.createPolicy("officejs-domparser",{createHTML:function(e){return e}}).createHTML(n);else o=n;var i=r.parseFromString(o,"text/xml"),a=i.getElementsByTagName("t")[0].attributes.getNamedItem("cid"),s=i.getElementsByTagName("t")[0].attributes.getNamedItem("oid");a&&a.nodeValue?t.userId=a.nodeValue:s&&s.nodeValue&&(t.userId=s.nodeValue),t.assetId=i.getElementsByTagName("t")[0].attributes.getNamedItem("aid").nodeValue}}catch(e){}}(e.get_eToken(),a),a.sessionId=s,OTel.OTelLogger.initialize(a),a.isPreload?l=!0:i.onAppActivated()}},i.onAppActivated=t,i.onScriptDone=function(e,t,n,r){},i.onCallDone=function(e,t,n,r,o){},i.onMethodDone=function(e,t,n,r){},i.onPropertyDone=function(e,t){_.AppTelemetry.onCallDone("property",-1,e,t,0)},i.onCheckWACHost=function(e,t,n,r,o){},i.onEventDone=function(e,t){_.AppTelemetry.onCallDone("event",e,null,0,t)},i.onRegisterDone=function(e,t,n,r){_.AppTelemetry.onCallDone(e?"registerevent":"unregisterevent",t,null,n,r)},i.onAppClosed=function(e,t){},i.setOsfControlAppCorrelationId=function(e){d(e)},i.doAppInitializationLogging=n,i.logAppCommonMessage=function(e){},i.logAppException=function(e){},i.CallOnAppActivatedIfPending=function(){l&&(l=!1,t())},i.canSendAddinId=g,i.getCompliantAppInstanceId=m,i._isComplianceExceptedHost=r,i.isMos=y}(_.AppTelemetry||(_.AppTelemetry={}))}(OSF=OSF||{}),function(i){var e=(n.loaded=function(){return!(void 0===n.logger)},n.create=function(e){var t,n={id:e.appId,marketplaceType:e.marketplaceType,assetId:e.assetId,officeJsVersion:e.officeJSVersion,hostJsVersion:e.hostJSVersion,browserToken:e.clientId,instanceId:e.appInstanceId,sessionId:e.sessionId},r=oteljs.Contracts.Office.System.SDX.getFields("SDX",n);if("web"===OSF._OfficeAppFactory.getHostInfo().hostPlatform)t=new i.SdxWacSink;else{if(!Office.context.requirements.isSetSupported("Telemetry","1.2"))return console.error("Cannot create telemetry sink successfully"),null;t=new i.RichApiSink,this.richApiSink=t}var o=new oteljs.SimpleTelemetryLogger(void 0,r);return o.addSink(t),o.setTenantToken("Office.Extensibility.OfficeJs","db334b301e7b474db5e0f02f07c51a47-a1b5bc36-1bbe-482f-a64a-c2d9cb606706-7439",1755),oteljs.onNotification().addListener(function(e){OSF.Utility.debugLog(e.message())}),o},n.checkAndResolvePromises=function(){n.loaded()&&(n.promises.forEach(function(e){e()}),n.promises=[])},n.initialize=function(e){n.Enabled?Office.onReadyInternal().then(function(){n.loaded()||(OSF.Utility.debugLog("Creating OTelLogger"),n.logger=n.create(e),n.checkAndResolvePromises())}):n.promises=[]},n.sendTelemetryEvent=function(e){n.onTelemetryLoaded(function(){try{n.logger.sendTelemetryEvent(e)}catch(e){console.error("Cannot send telemetry event: "+JSON.stringify(e))}})},n.sendNonStandardEvent=function(e,t){n.onTelemetryLoaded(function(){try{n.logger.sendNonStandardEvent(e,t)}catch(e){console.error("Cannot send telemetry event: "+JSON.stringify(e))}})},n.flushTelemetryQueue=function(){var t=this;return new Office.Promise(function(e){n.onTelemetryLoaded(function(){t.richApiSink?t.richApiSink.flushTelemetryQueue().then(function(){e()}):e()})})},n.onTelemetryLoaded=function(e){n.Enabled&&(n.loaded()?e():n.promises.push(e))},n.promises=[],n.Enabled=!0,n);function n(){}i.OTelLogger=e}(OTel=OTel||{}),function(e){var t=(n.prototype.sendTelemetryEvent=function(e){this._telemetryQueue.push([e,1]),this._requestIsPending||this.processWorkBacklog()},n.prototype.sendNonStandardEvent=function(e,t){this._telemetryQueue.push([e,t]),this._requestIsPending||this.processWorkBacklog()},n.prototype.flushTelemetryQueue=function(){var n=this;return new Office.Promise(function(e){var t=n._telemetryQueue;n._telemetryQueue=[],n.processTelemetryEvents(t).then(function(){e()})})},n.prototype.processWorkBacklog=function(){var t=this;this._requestIsPending=!0;var e=this._telemetryQueue;this._telemetryQueue=[],this.processTelemetryEvents(e).then(this.waitAndProcessMore.bind(this)).catch(function(e){oteljs.logError(1,"RichApiSink Error",e),t.waitAndProcessMore.bind(t)()})},n.prototype.waitAndProcessMore=function(){var e=this;this.pause(1e3).then(function(){0<e._telemetryQueue.length&&setTimeout(function(){return e.processWorkBacklog()},0),e._requestIsPending=!1}).catch(function(){})},n.prototype.processTelemetryEvents=function(e){var i=this,a=new OfficeCore.RequestContext;return e.forEach(function(e){var t=e[0],n=e[1];if(t.telemetryProperties){var r=[];i.addDataFields(r,t.dataFields);var o=t.eventContract?t.eventContract.name:"";t.eventContract&&i.addDataFields(r,t.eventContract.dataFields),1===n?a.telemetry.sendTelemetryEvent(t.telemetryProperties,t.eventName,o,oteljs.getEffectiveEventFlags(t),r):a.telemetry.sendNonStandardEvent(t.telemetryProperties,t.eventName,o,oteljs.getEffectiveEventFlags(t),r,n)}}),a.sync().catch(function(){oteljs.logNotification(2,1,function(){return"RichApi telemetry call failed."})})},n.prototype.addDataFields=function(t,e){e&&e.forEach(function(e){t.push({name:e.name,value:e.value,classification:e.classification?e.classification:4,type:e.dataType})})},n.prototype.pause=function(t){return new Office.Promise(function(e){return setTimeout(e,t)})},n);function n(){var t=this;this._requestIsPending=!0,this._telemetryQueue=[],this.pause(1e3).then(function(){var e=t._telemetryQueue;t._telemetryQueue=[],t._requestIsPending=!1,t.processTelemetryEvents(e)})}e.RichApiSink=t}(OTel=OTel||{}),function(e){var t=(n.prototype.sendTelemetryEvent=function(e,t){try{if(e.dataFields&&0<e.dataFields.filter(function(e){var t=e.classification;return t&&4!==t&&1!==t}).length)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)}},n.prototype.sendNonStandardEvent=function(e,t){try{if(1===t)throw new Error("Please call sendTelemetryEvent for events of type "+t);if(e.dataFields&&0<e.dataFields.filter(function(e){var t=e.classification;return t&&4!==t&&1!==t&&32!==t&&2048!==t}).length)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)}},n);function n(){}e.SdxWacSink=t}(OTel=OTel||{}),function(){var t,e=[];function p(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 f(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{function n(o){var i=Navigator.prototype[o];i&&(Navigator.prototype[o]=function(e,t,n){if(3===arguments.length&&Function.prototype.isPrototypeOf(t)&&Function.prototype.isPrototypeOf(n)){var r=(d++).toString();return p(r,"Navigator.prototype."+o,JSON.stringify([{audio:!!e.audio,video:!!e.video}])),i.apply(this,[e,function(){return f(r,!0),t.apply(this,arguments)},function(){return f(r,!1,arguments[0]),n.apply(this,arguments)}])}return i.apply(this,arguments)},e.push("Navigator.prototype."+o))}for(var d=0,r=0,o=["getUserMedia","webkitGetUserMedia","mozGetUserMedia"];r<o.length;r++){n(o[r])}var i=MediaDevices.prototype.getUserMedia;i&&(MediaDevices.prototype.getUserMedia=function(e){var t=(d++).toString();return 1===arguments.length&&void 0!==e?(p(t,"MediaDevices.prototype.getUserMedia",JSON.stringify([{audio:!!e.audio,video:!!e.video}])),i.apply(this,arguments).then(function(){return f(t,!0),arguments[0]},function(){throw f(t,!1,arguments[0]),arguments[0]})):i.apply(this,arguments)},e.push("MediaDevices.prototype.getUserMedia"));function a(l){var u=Geolocation.prototype[l];u&&(Geolocation.prototype[l]=function(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];var i=(d++).toString(),a=!1;p(i,"Geolocation.prototype."+l,JSON.stringify([]));var s=Function.prototype.isPrototypeOf(e)?function(){return a||(f(i,!0),a=!0),e.apply(this,arguments)}:e,c=Function.prototype.isPrototypeOf(t)?function(){return a||(f(i,!1,arguments[0]),a=!0),t.apply(this,arguments)}:t;return u.apply(this,[s,c,n].concat(r))},e.push("Geolocation.prototype."+l))}for(var s=0,c=["getCurrentPosition","watchPosition"];s<c.length;s++){a(c[s])}}catch(e){t=e.toString()}OTel.OTelLogger.onTelemetryLoaded(function(){Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.AddinSpecialPermissionHookInstall",dataFields:[oteljs.makeStringDataField("hooksInstalled",JSON.stringify(e)),oteljs.makeStringDataField("error",t)],eventFlags:{dataCategories:2,diagnosticLevel:110}})})}(Office=Office||{}),function(e){var t,n;t=e.Office||(e.Office={}),(n=t.WebExtension||(t.WebExtension={})).FeatureGates={},n.EventType=OSF.EventType,n.sendTelemetryEvent=function(e){OTel.OTelLogger.sendTelemetryEvent(e)},n.sendNonStandardEvent=function(e,t){OTel.OTelLogger.sendNonStandardEvent(e,t)},n.flushTelemetryQueue=function(){return OTel.OTelLogger.flushTelemetryQueue()},n.telemetrySink=OTel.OTelLogger}(Microsoft=Microsoft||{}),function(o){o.sendTelemetryEvent=function(e){Microsoft.Office.WebExtension.sendTelemetryEvent(e)},o.sendNonStandardEvent=function(e,t){Microsoft.Office.WebExtension.sendNonStandardEvent(e,t)},o.flushTelemetryQueue=function(){return Microsoft.Office.WebExtension.flushTelemetryQueue()},o.telemetrySink=Microsoft.Office.WebExtension.telemetrySink,o.isTrustedHost=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return e.trys.push([0,6,,7]),OSF._OfficeAppFactory.getHostInfo().hostPlatform===OSF.HostInfoPlatform.web?[3,2]:[4,o.onReady()];case 1:return e.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 e.sent(),[2,!0];case 4:return[2,!1];case 5:return[3,7];case 6:return r=e.sent(),OSF.AppTelemetry&&OSF.AppTelemetry.logAppException("Exception happens at Office.isTrustedHost."+r),[2,!1];case 7:return[2]}})})},Microsoft.Office.WebExtension.onReadyInternal=o.onReadyInternal}(Office=Office||{});var OfficeExtension;__extends=this&&this.__extends||function(){var r=function(e,t){return(r=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])})(e,t)};return function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}}();!function(y){var a,e;(e=a=y.RemoteEndpointType||(y.RemoteEndpointType={})).graph="graph",e.wfe="wfe";var _=(t.prototype._resolveRequestUrlAndHeaderInfo=function(){return P._createPromiseFromResult(null)},t.prototype._createRequestExecutorOrNull=function(){return null},t.prototype.getEventRegistration=function(e){return null},t);function t(){}y.SessionBase=_;var s=(n.setCustomSendRequestFunc=function(e){n.s_customSendRequestFunc=e},n.xhrSendRequestFunc=function(o){return P.createPromise(function(t,e){var n=new XMLHttpRequest;if(n.open(o.method,o.url),n.onload=function(){var e={statusCode:n.status,headers:P._parseHttpResponseHeaders(n.getAllResponseHeaders()),body:n.responseText};t(e)},n.onerror=function(){e(new h.RuntimeError({code:g.connectionFailure,httpStatusCode:n.status,message:P._getResourceString(m.connectionFailureWithStatus,n.statusText)}))},o.headers)for(var r in o.headers)n.setRequestHeader(r,o.headers[r]);n.send(P._getRequestBodyText(o))})},n.fetchSendRequestFunc=function(e){var t=P._getRequestBodyText(e);return""===t&&(t=void 0),fetch(e.url,{method:e.method,headers:e.headers,body:t}).then(function(r){return r.text().then(function(e){var t=r.status,n={};return r.headers.forEach(function(e,t){n[t]=e}),{statusCode:t,headers:n,body:e}})})},n.sendRequest=function(e){n.validateAndNormalizeRequest(e);var t=n.s_customSendRequestFunc;return(t=t||("undefined"!=typeof fetch?n.fetchSendRequestFunc:n.xhrSendRequestFunc))(e)},n.setCustomSendLocalDocumentRequestFunc=function(e){n.s_customSendLocalDocumentRequestFunc=e},n.sendLocalDocumentRequest=function(e){return n.validateAndNormalizeRequest(e),(n.s_customSendLocalDocumentRequestFunc||n.officeJsSendLocalDocumentRequestFunc)(e)},n.officeJsSendLocalDocumentRequestFunc=function(e){e=P._validateLocalDocumentRequest(e);var t=P._buildRequestMessageSafeArray(e);return P.createPromise(function(n,e){OSF.DDA.RichApi.executeRichApiRequestAsync(t,function(e){var t;t="succeeded"==e.status?{statusCode:O.getResponseStatusCode(e),headers:O.getResponseHeaders(e),body:O.getResponseBody(e)}:O.buildHttpResponseFromOfficeJsError(e.error.code,e.error.message),P.log("Response:"),P.log(JSON.stringify(t)),n(t)})})},n.validateAndNormalizeRequest=function(e){if(P.isNullOrUndefined(e))throw h.RuntimeError._createInvalidArgError({argumentName:"request"});P.isNullOrEmptyString(e.method)&&(e.method="GET"),e.method=e.method.toUpperCase();var t=!1;if("object"==typeof e.headers&&e.headers[d.testRequestNameHeader]&&(t=!0),!t){var n=A._getCurrentTestNameWithSequenceId();n&&(e.headers||(e.headers={}),e.headers[d.testRequestNameHeader]=n)}},n.logRequest=function(e){if(P._logEnabled){if(P.log("---HTTP Request---"),P.log(e.method+" "+e.url),e.headers)for(var t in e.headers)P.log(t+": "+e.headers[t]);n._logBodyEnabled&&P.log(P._getRequestBodyText(e))}},n.logResponse=function(e){if(P._logEnabled){if(P.log("---HTTP Response---"),P.log(""+e.statusCode),e.headers)for(var t in e.headers)P.log(t+": "+e.headers[t]);n._logBodyEnabled&&P.log(e.body)}},n._logBodyEnabled=!1,n);function n(){}y.HttpUtility=s;var h,r,o,i,c=(l.init=function(e){if("object"==typeof e&&e){var a=new l(e);l.s_instance=a,s.setCustomSendLocalDocumentRequestFunc(function(e){e=P._validateLocalDocumentRequest(e);var t=0;P.isReadonlyRestRequest(e.method)||(t=1);var n=e.url.indexOf("?");if(0<=n){var r=e.url.substr(n+1),o=P._parseRequestFlagsAndCustomDataFromQueryStringIfAny(r);0<=o.flags&&(t=o.flags)}"string"==typeof e.body&&(e.body=JSON.parse(e.body));var i={id:l.nextId(),type:1,flags:t,message:e};return a.sendMessageToHostAndExpectResponse(i).then(function(e){return e.message})});for(var t=0;t<l.s_onInitedHandlers.length;t++)l.s_onInitedHandlers[t](a)}},Object.defineProperty(l,"instance",{get:function(){return l.s_instance},enumerable:!0,configurable:!0}),l.prototype.sendMessageToHost=function(e){this.m_bridge.sendMessageToHost(JSON.stringify(e))},l.prototype.sendMessageToHostAndExpectResponse=function(n){var r=this,e=P.createPromise(function(e,t){r.m_promiseResolver[n.id]=e});return this.m_bridge.sendMessageToHost(JSON.stringify(n)),e},l.prototype.addHostMessageHandler=function(e){this.m_handlers.push(e)},l.prototype.removeHostMessageHandler=function(e){var t=this.m_handlers.indexOf(e);0<=t&&this.m_handlers.splice(t,1)},l.onInited=function(e){l.s_onInitedHandlers.push(e),l.s_instance&&e(l.s_instance)},l.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)},l.nextId=function(){return l.s_nextId++},l.s_onInitedHandlers=[],l.s_nextId=1,l);function l(e){var a=this;this.m_bridge=e,this.m_promiseResolver={},this.m_handlers=[],this.m_bridge.onMessageFromHost=function(e){var t=JSON.parse(e);if(3==t.type){var n=t.message;if(n&&n.entries)for(var r=0;r<n.entries.length;r++){var o=n.entries[r];if(Array.isArray(o)){var i={messageCategory:o[0],messageType:o[1],targetId:o[2],message:o[3],id:o[4]};n.entries[r]=i}}}a.dispatchMessage(t)}}function u(e){var t=o.call(this,"string"==typeof e?e:e.message)||this;if(Object.setPrototypeOf(t,u.prototype),t.name="RichApi.Error","string"==typeof e?t.message=e:(t.code=e.code,t.message=e.message,t.traceMessages=e.traceMessages||[],t.innerError=e.innerError||null,t.debugInfo=t._createDebugInfo(e.debugInfo||{}),t.httpStatusCode=e.httpStatusCode,t.data=e.data),P.isNullOrUndefined(t.httpStatusCode)||200===t.httpStatusCode){var n={};n[g.accessDenied]=401,n[g.connectionFailure]=500,n[g.generalException]=500,n[g.invalidArgument]=400,n[g.invalidObjectPath]=400,n[g.invalidOrTimedOutSession]=408,n[g.invalidRequestContext]=400,n[g.timeout]=408,n[g.valueNotLoaded]=400,t.httpStatusCode=n[t.code]}return P.isNullOrUndefined(t.httpStatusCode)&&(t.httpStatusCode=500),t}y.HostBridge=c,"object"==typeof _richApiNativeBridge&&_richApiNativeBridge&&c.init(_richApiNativeBridge),r=h=y._Internal||(y._Internal={}),o=Error,__extends(u,o),u.prototype.toString=function(){return this.code+": "+this.message},u.prototype._createDebugInfo=function(e){var t={code:this.code,message:this.message,toString:function(){return JSON.stringify(this)}};for(var n in e)t[n]=e[n];return this.innerError&&(this.innerError instanceof r.RuntimeError?t.innerError=this.innerError.debugInfo:t.innerError=this.innerError),t},u._createInvalidArgError=function(e){return new r.RuntimeError({code:g.invalidArgument,httpStatusCode:400,message:P.isNullOrEmptyString(e.argumentName)?P._getResourceString(m.invalidArgumentGeneric):P._getResourceString(m.invalidArgument,e.argumentName),debugInfo:e.errorLocation?{errorLocation:e.errorLocation}:{},innerError:e.innerError})},i=u,r.RuntimeError=i,y.Error=h.RuntimeError;var g=(p.apiNotFound="ApiNotFound",p.accessDenied="AccessDenied",p.generalException="GeneralException",p.activityLimitReached="ActivityLimitReached",p.invalidArgument="InvalidArgument",p.connectionFailure="ConnectionFailure",p.timeout="Timeout",p.invalidOrTimedOutSession="InvalidOrTimedOutSession",p.invalidObjectPath="InvalidObjectPath",p.invalidRequestContext="InvalidRequestContext",p.valueNotLoaded="ValueNotLoaded",p.requestPayloadSizeLimitExceeded="RequestPayloadSizeLimitExceeded",p.responsePayloadSizeLimitExceeded="ResponsePayloadSizeLimitExceeded",p.writeNotSupportedWhenModalDialogOpen="WriteNotSupportedWhenModalDialogOpen",p.undoNotSupported="UndoNotSupported",p);function p(){}y.CoreErrorCodes=g;var m=(f.apiNotFoundDetails="ApiNotFoundDetails",f.connectionFailureWithStatus="ConnectionFailureWithStatus",f.connectionFailureWithDetails="ConnectionFailureWithDetails",f.invalidArgument="InvalidArgument",f.invalidArgumentGeneric="InvalidArgumentGeneric",f.timeout="Timeout",f.invalidOrTimedOutSessionMessage="InvalidOrTimedOutSessionMessage",f.invalidSheetName="InvalidSheetName",f.invalidObjectPath="InvalidObjectPath",f.invalidRequestContext="InvalidRequestContext",f.valueNotLoaded="ValueNotLoaded",f);function f(){}y.CoreResourceStrings=m;var d=(b.flags="flags",b.sourceLibHeader="SdkVersion",b.processQuery="ProcessQuery",b.localDocument="http://document.localhost/",b.localDocumentApiPrefix="http://document.localhost/_api/",b.customData="customdata",b.testRequestNameHeader="x-test-request-name",b);function b(){}y.CoreConstants=d;var v,O=(C.buildMessageArrayForIRequestExecutor=function(e,t,n,r){var o=JSON.stringify(n.Body);P.log("Request:"),P.log(o);var i={};return P._copyHeaders(n.Headers,i),i[d.sourceLibHeader]=r,C.buildRequestMessageSafeArray(e,t,"POST",d.processQuery,i,o)},C.buildResponseOnSuccess=function(e,t){var n={HttpStatusCode:200,ErrorCode:"",ErrorMessage:"",Headers:null,Body:null};return n.Body=JSON.parse(e),n.Headers=t,n},C.buildResponseOnError=function(e,t){var n={HttpStatusCode:500,ErrorCode:"",ErrorMessage:"",Headers:null,Body:null};return n.ErrorCode=g.generalException,n.ErrorMessage=t,e==C.OfficeJsErrorCode_ooeNoCapability?(n.ErrorCode=g.accessDenied,n.HttpStatusCode=401):e==C.OfficeJsErrorCode_ooeActivityLimitReached?(n.ErrorCode=g.activityLimitReached,n.HttpStatusCode=429):e==C.OfficeJsErrorCode_ooeInvalidOrTimedOutSession?(n.ErrorCode=g.invalidOrTimedOutSession,n.HttpStatusCode=408,n.ErrorMessage=P._getResourceString(m.invalidOrTimedOutSessionMessage)):e==C.OfficeJsErrorCode_ooeRequestPayloadSizeLimitExceeded?(n.ErrorCode=g.requestPayloadSizeLimitExceeded,n.HttpStatusCode=400):e==C.OfficeJsErrorCode_ooeResponsePayloadSizeLimitExceeded?(n.ErrorCode=g.responsePayloadSizeLimitExceeded,n.HttpStatusCode=400):e==C.OfficeJsErrorCode_ooeWriteNotSupportedWhenModalDialogOpen?(n.ErrorCode=g.writeNotSupportedWhenModalDialogOpen,n.HttpStatusCode=400):e==C.OfficeJsErrorCode_ooeInvalidSheetName?(n.ErrorCode=g.invalidRequestContext,n.HttpStatusCode=400,n.ErrorMessage=P._getResourceString(m.invalidSheetName)):e==C.OfficeJsErrorCode_ooeUndoNotSupported&&(n.ErrorCode=g.undoNotSupported,n.HttpStatusCode=400),n},C.buildHttpResponseFromOfficeJsError=function(e,t){var n=500,r={error:{}};return r.error.code=g.generalException,r.error.message=t,e===C.OfficeJsErrorCode_ooeNoCapability?(n=403,r.error.code=g.accessDenied):e===C.OfficeJsErrorCode_ooeActivityLimitReached&&(n=429,r.error.code=g.activityLimitReached),{statusCode:n,headers:{},body:JSON.stringify(r)}},C.buildRequestMessageSafeArray=function(e,t,n,r,o,i){var a=[];if(o)for(var s in o)a.push(s),a.push(o[s]);return[e,n,r,a,i,0,t,"","","","","",""]},C.getResponseBody=function(e){return C.getResponseBodyFromSafeArray(e.value.data)},C.getResponseHeaders=function(e){return C.getResponseHeadersFromSafeArray(e.value.data)},C.getResponseBodyFromSafeArray=function(e){var t=e[2];return"string"==typeof t?t:t.join("")},C.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},C.getResponseStatusCode=function(e){return C.getResponseStatusCodeFromSafeArray(e.value.data)},C.getResponseStatusCodeFromSafeArray=function(e){return e[0]},C.OfficeJsErrorCode_ooeInvalidOrTimedOutSession=5012,C.OfficeJsErrorCode_ooeActivityLimitReached=5102,C.OfficeJsErrorCode_ooeNoCapability=7e3,C.OfficeJsErrorCode_ooeRequestPayloadSizeLimitExceeded=5103,C.OfficeJsErrorCode_ooeResponsePayloadSizeLimitExceeded=5104,C.OfficeJsErrorCode_ooeWriteNotSupportedWhenModalDialogOpen=5016,C.OfficeJsErrorCode_ooeInvalidSheetName=1014,C.OfficeJsErrorCode_ooeUndoNotSupported=5017,C);function C(){}y.RichApiMessageUtility=O,(v=h=y._Internal||(y._Internal={})).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 v.Error("No Promise implementation found")};var P=(S.log=function(e){S._logEnabled&&"undefined"!=typeof console&&console.log&&console.log(e)},S.checkArgumentNull=function(e,t){if(S.isNullOrUndefined(e))throw h.RuntimeError._createInvalidArgError({argumentName:t})},S.isNullOrUndefined=function(e){return null==e},S.isUndefined=function(e){return void 0===e},S.isNullOrEmptyString=function(e){return null==e||0==e.length},S.isPlainJsonObject=function(e){if(S.isNullOrUndefined(e))return!1;if("object"!=typeof e)return!1;if("[object Object]"!==Object.prototype.toString.apply(e))return!1;if(e.constructor&&!Object.prototype.hasOwnProperty.call(e,"constructor")&&!Object.prototype.hasOwnProperty.call(e.constructor.prototype,"hasOwnProperty"))return!1;for(var t in e)if(!Object.prototype.hasOwnProperty.call(e,t))return!1;return!0},S.trim=function(e){return e.replace(new RegExp("^\\s+|\\s+$","g"),"")},S.caseInsensitiveCompareString=function(e,t){return S.isNullOrUndefined(e)?S.isNullOrUndefined(t):!S.isNullOrUndefined(t)&&e.toUpperCase()==t.toUpperCase()},S.isReadonlyRestRequest=function(e){return S.caseInsensitiveCompareString(e,"GET")},S._getResourceString=function(e,t){var n;if("undefined"!=typeof window&&window.Strings&&window.Strings.OfficeOM){var r="L_"+e,o=window.Strings.OfficeOM[r];o&&(n=o)}return n=(n=n||S.s_resourceStringValues[e])||e,S.isNullOrUndefined(t)||(n=Array.isArray(t)?S._formatString(n,t):n.replace("{0}",t)),n},S._formatString=function(e,n){return e.replace(/\{\d\}/g,function(e){var t=parseInt(e.substr(1,e.length-2));if(t<n.length)return n[t];throw h.RuntimeError._createInvalidArgError({argumentName:"format"})})},Object.defineProperty(S,"Promise",{get:function(){return h.getPromiseType()},enumerable:!0,configurable:!0}),S.createPromise=function(e){return new S.Promise(e)},S._createPromiseFromResult=function(n){return S.createPromise(function(e,t){e(n)})},S._createPromiseFromException=function(n){return S.createPromise(function(e,t){t(n)})},S._createTimeoutPromise=function(n){return S.createPromise(function(e,t){setTimeout(function(){e(null)},n)})},S._createInvalidArgError=function(e){return h.RuntimeError._createInvalidArgError(e)},S._isLocalDocumentUrl=function(e){return 0<S._getLocalDocumentUrlPrefixLength(e)},S._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},S._validateLocalDocumentRequest=function(e){var t=S._getLocalDocumentUrlPrefixLength(e.url);if(t<=0)throw h.RuntimeError._createInvalidArgError({argumentName:"request"});var n=e.url.substr(t),r=n.toLowerCase();return"_api"===r?n="":"_api/"===r.substr(0,"_api/".length)&&(n=n.substr("_api/".length)),{method:e.method,url:n,headers:e.headers,body:e.body}},S._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()===d.flags){var i=parseInt(o[1]);i&=65535,t.flags=i}else o[0].toLowerCase()===d.customData&&(t.customData=decodeURIComponent(o[1]))}return t},S._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},S._parseResponseBody=function(e){if("string"!=typeof e.body)return e.body;var t=S.trim(e.body);return JSON.parse(t)},S._buildRequestMessageSafeArray=function(e){var t=0;S.isReadonlyRestRequest(e.method)||(t=1);var n="";if(e.url.substr(0,d.processQuery.length).toLowerCase()===d.processQuery.toLowerCase()){var r=e.url.indexOf("?");if(0<r){var o=e.url.substr(r+1),i=S._parseRequestFlagsAndCustomDataFromQueryStringIfAny(o);0<=i.flags&&(t=i.flags),n=i.customData}}return O.buildRequestMessageSafeArray(n,t,e.method,e.url,e.headers,S._getRequestBodyText(e))},S._parseHttpResponseHeaders=function(e){var t={};if(!S.isNullOrEmptyString(e))for(var n=new RegExp("\r?\n"),r=e.split(n),o=0;o<r.length;o++){var i=r[o];if(null!=i){var a=i.indexOf(":");if(0<a){var s=i.substr(0,a),c=i.substr(a+1);s=S.trim(s),c=S.trim(c),t[s.toUpperCase()]=c}}}return t},S._parseErrorResponse=function(e){var t=S._parseErrorResponseBody(e),n=e.statusCode.toString();if(S.isNullOrUndefined(t)||"object"!=typeof t||!t.error)return S._createDefaultErrorResponse(n);var r=t.error,o=r.innerError;return o&&o.code?S._createErrorResponse(o.code,n,o.message):r.code?S._createErrorResponse(r.code,n,r.message):S._createDefaultErrorResponse(n)},S._parseErrorResponseBody=function(e){if(S.isPlainJsonObject(e.body))return e.body;if(!S.isNullOrEmptyString(e.body)){var t=S.trim(e.body);try{return JSON.parse(t)}catch(e){S.log("Error when parse "+t)}}},S._createDefaultErrorResponse=function(e){return{errorCode:g.connectionFailure,errorMessage:S._getResourceString(m.connectionFailureWithStatus,e)}},S._createErrorResponse=function(e,t,n){return{errorCode:e,errorMessage:S._getResourceString(m.connectionFailureWithDetails,[t,e,n])}},S._copyHeaders=function(e,t){if(e&&t)for(var n in e)t[n]=e[n]},S.addResourceStringValues=function(e){for(var t in e)S.s_resourceStringValues[t]=e[t]},S._logEnabled=!1,S.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.'},S);function S(){}y.CoreUtility=P;var A=(I.setMock=function(e){I.s_isMock=e},I.isMock=function(){return I.s_isMock},I._setCurrentTestName=function(e){I.s_currentTestName=e,I.s_currentTestSequenceId=0},I._getCurrentTestNameWithSequenceId=function(){return I.s_currentTestName?I.s_currentTestName+"."+ ++I.s_currentTestSequenceId:null},I);function I(){}y.TestUtility=A,y._internalConfig={showDisposeInfoInDebugInfo:!1,showInternalApiInDebugInfo:!1,enableEarlyDispose:!0,alwaysPolyfillClientObjectUpdateMethod:!1,alwaysPolyfillClientObjectRetrieveMethod:!1,enableConcurrentFlag:!0,enableUndoableFlag:!0,appendTypeNameToObjectPathInfo:!1,enablePreviewExecution:!1},y.config={extendedErrorLogging:!1};var R=(T.createSetPropertyAction=function(e,t,n,r,o){$.validateObjectPath(t);var i={Id:e._nextId(),ActionType:4,Name:n,ObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}},a=[r],s=$.setMethodArguments(e,i.ArgumentInfo,a);$.validateReferencedObjectPaths(s);var c=new D(i,0,o);if(c.referencedObjectPath=t._objectPath,c.referencedArgumentObjectPaths=s,y._internalConfig.enablePreviewExecution&&0!=(16&o)){var l={Id:e._nextId(),ActionType:4,Name:n,ObjectId:"",ObjectType:"",Arguments:[r]};t._addPreviewExecutionAction(l)}return t._addAction(c)},T.createQueryAction=function(e,t,n,r){$.validateObjectPath(t);var o={Id:e._nextId(),ActionType:2,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,QueryInfo:n},i=new D(o,1,4);return i.referencedObjectPath=t._objectPath,t._addAction(i,r)},T.createQueryAsJsonAction=function(e,t,n,r){$.validateObjectPath(t);var o={Id:e._nextId(),ActionType:7,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,QueryInfo:n},i=new D(o,1,4);return i.referencedObjectPath=t._objectPath,t._addAction(i,r)},T.createUpdateAction=function(e,t,n){$.validateObjectPath(t);var r={Id:e._nextId(),ActionType:9,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,ObjectState:n},o=new D(r,0,0);return o.referencedObjectPath=t._objectPath,t._addAction(o)},T);function T(){}y.CommonActionFactory=R;var E=(Object.defineProperty(N.prototype,"_objectPath",{get:function(){return this.m_objectPath},enumerable:!0,configurable:!0}),Object.defineProperty(N.prototype,"_context",{get:function(){return this.m_contextBase},enumerable:!0,configurable:!0}),N.prototype._addAction=function(n,r){var o=this;return void 0===r&&(r=null),P.createPromise(function(e,t){o._context._addServiceApiAction(n,r,e,t)})},N.prototype._addPreviewExecutionAction=function(e){},N.prototype._retrieve=function(e,t){var n=y._internalConfig.alwaysPolyfillClientObjectRetrieveMethod;n=n||!$.isSetSupported("RichApiRuntime","1.1");var r=j._parseQueryOption(e);return n?R.createQueryAction(this._context,this,r,t):R.createQueryAsJsonAction(this._context,this,r,t)},N.prototype._recursivelyUpdate=function(e){var t=y._internalConfig.alwaysPolyfillClientObjectUpdateMethod;t=t||!$.isSetSupported("RichApiRuntime","1.2");try{var n=this[K.scalarPropertyNames];n=n||[];var r=this[K.scalarPropertyUpdateable];if(!r){r=[];for(var o=0;o<n.length;o++)r.push(!1)}var i=this[K.navigationPropertyNames];i=i||[];var a={},s={},c=0;for(var l in e){var u=n.indexOf(l);if(0<=u){if(!r[u])throw new h.RuntimeError({code:g.invalidArgument,httpStatusCode:400,message:P._getResourceString(ee.attemptingToSetReadOnlyProperty,l),debugInfo:{errorLocation:l}});a[l]=e[l],++c}else{if(!(0<=i.indexOf(l)))throw new h.RuntimeError({code:g.invalidArgument,httpStatusCode:400,message:P._getResourceString(ee.propertyDoesNotExist,l),debugInfo:{errorLocation:l}});s[l]=e[l]}}if(0<c)if(t)for(o=0;o<n.length;o++){var p=a[l=n[o]];$.isUndefined(p)||R.createSetPropertyAction(this._context,this,l,p)}else R.createUpdateAction(this._context,this,a);for(var l in s){var f=this[l],d=s[l];f._recursivelyUpdate(d)}}catch(e){throw new h.RuntimeError({code:g.invalidArgument,httpStatusCode:400,message:P._getResourceString(m.invalidArgument,"properties"),debugInfo:{errorLocation:this._className+".update"},innerError:e})}},N);function N(e,t){this.m_contextBase=e,this.m_objectPath=t}y.ClientObjectBase=E;var D=(Object.defineProperty(x.prototype,"actionInfo",{get:function(){return this.m_actionInfo},enumerable:!0,configurable:!0}),Object.defineProperty(x.prototype,"operationType",{get:function(){return this.m_operationType},enumerable:!0,configurable:!0}),Object.defineProperty(x.prototype,"flags",{get:function(){return this.m_flags},enumerable:!0,configurable:!0}),x);function x(e,t,n){this.m_actionInfo=e,this.m_operationType=t,this.m_flags=n}y.Action=D;var w=(Object.defineProperty(F.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(F.prototype,"parent",{get:function(){var e=this.m_parentObjectPath;if(e)return e},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"parentId",{get:function(){return this.parent?this.parent.id:void 0},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"objectPathInfo",{get:function(){return this.m_objectPathInfo},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"operationType",{get:function(){return this.m_operationType},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"flags",{get:function(){return this.m_flags},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"isCollection",{get:function(){return this.m_isCollection},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"isInvalidAfterRequest",{get:function(){return this.m_isInvalidAfterRequest},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"parentObjectPath",{get:function(){return this.m_parentObjectPath},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"argumentObjectPaths",{get:function(){return this.m_argumentObjectPaths},set:function(e){this.m_argumentObjectPaths=e},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"isValid",{get:function(){return this.m_isValid},set:function(e){!(this.m_isValid=e)&&6===this.m_objectPathInfo.ObjectPathType&&this.m_savedObjectPathInfo&&(F.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(F.prototype,"originalObjectPathInfo",{get:function(){return this.m_originalObjectPathInfo},enumerable:!0,configurable:!0}),Object.defineProperty(F.prototype,"getByIdMethodName",{get:function(){return this.m_getByIdMethodName},set:function(e){this.m_getByIdMethodName=e},enumerable:!0,configurable:!0}),F.prototype._updateAsNullObject=function(){this.resetForUpdateUsingObjectData(),this.m_objectPathInfo.ObjectPathType=7,this.m_objectPathInfo.Name="",this.m_parentObjectPath=null},F.prototype.saveOriginalObjectPathInfo=function(){y.config.extendedErrorLogging&&!this.m_originalObjectPathInfo&&(this.m_originalObjectPathInfo={},F.copyObjectPathInfo(this.m_objectPathInfo,this.m_originalObjectPathInfo))},F.prototype.updateUsingObjectData=function(e,t){var n=e[K.referenceId];if(!P.isNullOrEmptyString(n)){if(!this.m_savedObjectPathInfo&&!this.isInvalidAfterRequest&&F.isRestorableObjectPath(this.m_objectPathInfo.ObjectPathType)){var r={};F.copyObjectPathInfo(this.m_objectPathInfo,r),this.m_savedObjectPathInfo={pathInfo:r,parent:this.m_parentObjectPath}}return this.saveOriginalObjectPathInfo(),this.resetForUpdateUsingObjectData(),this.m_objectPathInfo.ObjectPathType=6,this.m_objectPathInfo.Name=n,delete this.m_objectPathInfo.ParentObjectPathId,void(this.m_parentObjectPath=null)}if(t){var o=t[K.collectionPropertyPath];if(!P.isNullOrEmptyString(o)&&t.context){var i=$.tryGetObjectIdFromLoadOrRetrieveResult(e);if(!P.isNullOrUndefined(i)){for(var a=o.split("."),s=t.context[a[0]],c=1;c<a.length;c++)s=s[a[c]];return this.saveOriginalObjectPathInfo(),this.resetForUpdateUsingObjectData(),this.m_parentObjectPath=s._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=[i])}}}var l=this.parentObjectPath&&this.parentObjectPath.isCollection,u=this.getByIdMethodName;if((l||!P.isNullOrEmptyString(u))&&(i=$.tryGetObjectIdFromLoadOrRetrieveResult(e),!P.isNullOrUndefined(i)))return this.saveOriginalObjectPathInfo(),this.resetForUpdateUsingObjectData(),P.isNullOrEmptyString(u)?(this.m_objectPathInfo.ObjectPathType=5,this.m_objectPathInfo.Name=""):(this.m_objectPathInfo.ObjectPathType=3,this.m_objectPathInfo.Name=u),void(this.m_objectPathInfo.ArgumentInfo.Arguments=[i])},F.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},F.isRestorableObjectPath=function(e){return 1===e||5===e||3===e||4===e},F.copyObjectPathInfo=function(e,t){t.Id=e.Id,t.ArgumentInfo=e.ArgumentInfo,t.Name=e.Name,t.ObjectPathType=e.ObjectPathType,t.ParentObjectPathId=e.ParentObjectPathId},F);function F(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}y.ObjectPath=w;var j=(k.prototype._nextId=function(){return++this.m_nextId},k.prototype._addServiceApiAction=function(e,t,n,r){this.m_serviceApiQueue||(this.m_serviceApiQueue=new G(this)),this.m_serviceApiQueue.add(e,t,n,r)},k._parseQueryOption=function(e){var t={};if("string"==typeof e){var n=e;t.Select=$._parseSelectExpand(n)}else if(Array.isArray(e))t.Select=e;else if("object"==typeof e){var r=e;if(k.isLoadOption(r)){if("string"==typeof r.select)t.Select=$._parseSelectExpand(r.select);else if(Array.isArray(r.select))t.Select=r.select;else if(!$.isNullOrUndefined(r.select))throw h.RuntimeError._createInvalidArgError({argumentName:"option.select"});if("string"==typeof r.expand)t.Expand=$._parseSelectExpand(r.expand);else if(Array.isArray(r.expand))t.Expand=r.expand;else if(!$.isNullOrUndefined(r.expand))throw h.RuntimeError._createInvalidArgError({argumentName:"option.expand"});if("number"==typeof r.top)t.Top=r.top;else if(!$.isNullOrUndefined(r.top))throw h.RuntimeError._createInvalidArgError({argumentName:"option.top"});if("number"==typeof r.skip)t.Skip=r.skip;else if(!$.isNullOrUndefined(r.skip))throw h.RuntimeError._createInvalidArgError({argumentName:"option.skip"})}else t=k.parseStrictLoadOption(e)}else if(!$.isNullOrUndefined(e))throw h.RuntimeError._createInvalidArgError({argumentName:"option"});return t},k.isLoadOption=function(e){if(!$.isUndefined(e.select)&&("string"==typeof e.select||Array.isArray(e.select)))return!0;if(!$.isUndefined(e.expand)&&("string"==typeof e.expand||Array.isArray(e.expand)))return!0;if(!$.isUndefined(e.top)&&"number"==typeof e.top)return!0;if(!$.isUndefined(e.skip)&&"number"==typeof e.skip)return!0;for(var t in e)return!1;return!0},k.parseStrictLoadOption=function(e){var t={Select:[]};return k.parseStrictLoadOptionHelper(t,"","option",e),t},k.combineQueryPath=function(e,t,n){return 0===e.length?t:e+n+t},k.parseStrictLoadOptionHelper=function(e,t,n,r){for(var o in r){var i=r[o];if("$all"===o){if("boolean"!=typeof i)throw h.RuntimeError._createInvalidArgError({argumentName:k.combineQueryPath(n,o,".")});i&&e.Select.push(k.combineQueryPath(t,"*","/"))}else if("$top"===o){if("number"!=typeof i||0<t.length)throw h.RuntimeError._createInvalidArgError({argumentName:k.combineQueryPath(n,o,".")});e.Top=i}else if("$skip"===o){if("number"!=typeof i||0<t.length)throw h.RuntimeError._createInvalidArgError({argumentName:k.combineQueryPath(n,o,".")});e.Skip=i}else if("boolean"==typeof i)i&&e.Select.push(k.combineQueryPath(t,o,"/"));else{if("object"!=typeof i)throw h.RuntimeError._createInvalidArgError({argumentName:k.combineQueryPath(n,o,".")});k.parseStrictLoadOptionHelper(e,k.combineQueryPath(t,o,"/"),k.combineQueryPath(n,o,"."),i)}}},k);function k(){this.m_nextId=0}y.ClientRequestContextBase=j;var M=(H.prototype._handleResult=function(e){P.isNullOrUndefined(e)?this.m_objectPath._updateAsNullObject():this.m_objectPath.updateUsingObjectData(e,null)},H);function H(e){this.m_objectPath=e}var L=(U.prototype.addAction=function(e){this.m_actions.push(e),1==e.actionInfo.ActionType&&(this.m_instantiatedObjectPaths[e.actionInfo.ObjectPathId]=e)},U.prototype.addPreviewExecutionAction=function(e){this.m_previewExecutionActions.push(e)},Object.defineProperty(U.prototype,"hasActions",{get:function(){return 0<this.m_actions.length},enumerable:!0,configurable:!0}),U.prototype._getLastAction=function(){return this.m_actions[this.m_actions.length-1]},U.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 D(t,1,4);n.referencedObjectPath=e,this.addReferencedObjectPath(e),this.addAction(n);var r=new M(e);this.addActionResultHandler(n,r)}}},U.prototype.ensureInstantiateObjectPaths=function(e){if(e)for(var t=0;t<e.length;t++)this.ensureInstantiateObjectPath(e[t])},U.prototype.addReferencedObjectPath=function(e){if(e&&!this.m_referencedObjectPaths[e.objectPathInfo.Id]){if(!e.isValid)throw new h.RuntimeError({code:g.invalidObjectPath,httpStatusCode:400,message:P._getResourceString(m.invalidObjectPath,$.getObjectPathExpression(e)),debugInfo:{errorLocation:$.getObjectPathExpression(e)}});for(;e;)3==(this.m_referencedObjectPaths[e.objectPathInfo.Id]=e).objectPathInfo.ObjectPathType&&this.addReferencedObjectPaths(e.argumentObjectPaths),e=e.parentObjectPath}},U.prototype.addReferencedObjectPaths=function(e){if(e)for(var t=0;t<e.length;t++)this.addReferencedObjectPath(e[t])},U.prototype.addActionResultHandler=function(e,t){this.m_actionResultHandler[e.actionInfo.Id]=t},U.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},U.prototype.finallyNormalizeFlags=function(e){return 0==(1&e)&&(e&=-17,e&=-257),y._internalConfig.enableConcurrentFlag||(e&=-5),y._internalConfig.enableUndoableFlag||(e&=-17),$.isSetSupported("RichApiRuntimeFlag","1.1")||(e&=-5,e&=-17),$.isSetSupported("RichApiRuntimeFlag","1.2")||(e&=-257),"number"==typeof this.m_flagsForTesting&&(e=this.m_flagsForTesting),e},U.prototype.buildRequestMessageBodyAndRequestFlags=function(){y._internalConfig.enableEarlyDispose&&U._calculateLastUsedObjectPathIds(this.m_actions);var e=276,t={};for(var n in this.m_referencedObjectPaths)e=this.aggregrateRequestFlags(e,this.m_referencedObjectPaths[n].operationType,this.m_referencedObjectPaths[n].flags),t[n]=this.m_referencedObjectPaths[n].objectPathInfo;for(var r=[],o=!1,i=0;i<this.m_actions.length;i++){var a=this.m_actions[i];3===a.actionInfo.ActionType&&a.actionInfo.Name===K.keepReference&&(o=!0),e=this.aggregrateRequestFlags(e,a.operationType,a.flags),r.push(a.actionInfo)}e=this.finallyNormalizeFlags(e);var s={AutoKeepReference:this.m_contextBase._autoCleanup&&o,Actions:r,ObjectPaths:t};return 0<this.m_previewExecutionActions.length&&(s.PreviewExecutionActions=this.m_previewExecutionActions,e|=4096),{body:s,flags:e}},U.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)}},U.prototype.invalidatePendingInvalidObjectPaths=function(){for(var e in this.m_referencedObjectPaths)this.m_referencedObjectPaths[e].isInvalidAfterRequest&&(this.m_referencedObjectPaths[e].isValid=!1)},U.prototype._addPreSyncPromise=function(e){this.m_preSyncPromises.push(e)},Object.defineProperty(U.prototype,"_preSyncPromises",{get:function(){return this.m_preSyncPromises},enumerable:!0,configurable:!0}),Object.defineProperty(U.prototype,"_actions",{get:function(){return this.m_actions},enumerable:!0,configurable:!0}),Object.defineProperty(U.prototype,"_objectPaths",{get:function(){return this.m_referencedObjectPaths},enumerable:!0,configurable:!0}),U.prototype._removeKeepReferenceAction=function(e){for(var t=this.m_actions.length-1;0<=t;t--){var n=this.m_actions[t].actionInfo;if(n.ObjectPathId===e&&3===n.ActionType&&n.Name===K.keepReference){this.m_actions.splice(t,1);break}}},U._updateLastUsedActionIdOfObjectPathId=function(e,t,n){for(;t;){if(e[t.objectPathInfo.Id])return;e[t.objectPathInfo.Id]=n;var r=t.argumentObjectPaths;if(r)for(var o=r.length,i=0;i<o;i++)U._updateLastUsedActionIdOfObjectPathId(e,r[i],n);t=t.parentObjectPath}},U._calculateLastUsedObjectPathIds=function(e){for(var t={},n=e.length,r=n-1;0<=r;--r){var o=(p=e[r]).actionInfo.Id;p.referencedObjectPath&&U._updateLastUsedActionIdOfObjectPathId(t,p.referencedObjectPath,o);var i=p.referencedArgumentObjectPaths;if(i)for(var a=i.length,s=0;s<a;s++)U._updateLastUsedActionIdOfObjectPathId(t,i[s],o)}var c={};for(var l in t){var u=c[o=t[l]];u||(u=[],c[o]=u),u.push(parseInt(l))}for(r=0;r<n;r++){var p,f=c[(p=e[r]).actionInfo.Id];f&&0<f.length?p.actionInfo.L=f:p.actionInfo.L&&delete p.actionInfo.L}},U);function U(e){this.m_contextBase=e,this.m_actions=[],this.m_actionResultHandler={},this.m_referencedObjectPaths={},this.m_instantiatedObjectPaths={},this.m_preSyncPromises=[],this.m_previewExecutionActions=[]}y.ClientRequestBase=L;var B=(Object.defineProperty(W.prototype,"value",{get:function(){if(!this.m_isLoaded)throw new h.RuntimeError({code:g.valueNotLoaded,httpStatusCode:400,message:P._getResourceString(m.valueNotLoaded),debugInfo:{errorLocation:"clientResult.value"}});return this.m_value},enumerable:!0,configurable:!0}),W.prototype._handleResult=function(e){this.m_isLoaded=!0,"object"==typeof e&&e&&e._IsNull||(1===this.m_type?this.m_value=$.adjustToDateTime(e):this.m_value=e)},W);function W(e){this.m_type=e}y.ClientResult=B;var G=(q.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)},q.prototype.processActions=function(){var t=this;if(0!==this.m_actions.length){var n=this.m_actions;this.m_actions=[];for(var r=new L(this.m_context),e=0;e<n.length;e++){var o=n[e];r.ensureInstantiateObjectPath(o.action.referencedObjectPath),r.ensureInstantiateObjectPaths(o.action.referencedArgumentObjectPaths),r.addAction(o.action),r.addReferencedObjectPath(o.action.referencedObjectPath),r.addReferencedObjectPaths(o.action.referencedArgumentObjectPaths)}var i=r.buildRequestMessageBodyAndRequestFlags(),a=i.body,s=i.flags,c={Url:d.localDocumentApiPrefix,Headers:null,Body:a};P.log("Request:"),P.log(JSON.stringify(a)),(new V).executeAsync(this.m_context._customData,s,c).then(function(e){t.processResponse(r,n,e)}).catch(function(e){for(var t=0;t<n.length;t++)n[t].reject(e)})}},q.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)},q.prototype.getErrorFromResponse=function(e){return P.isNullOrEmptyString(e.ErrorCode)?e.Body&&e.Body.Error?new h.RuntimeError({code:e.Body.Error.Code,httpStatusCode:e.Body.Error.HttpStatusCode,message:e.Body.Error.Message}):null:new h.RuntimeError({code:e.ErrorCode,httpStatusCode:e.HttpStatusCode,message:e.ErrorMessage})},q.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 l=n[c].Value;i.resultHandler&&(i.resultHandler._handleResult(l),l=i.resultHandler.value),i.resolve&&i.resolve(l),s=!0;break}!s&&i.reject&&(r?i.reject(r):i.reject("No response for the action."))}},q);function q(e){this.m_context=e,this.m_actions=[]}var V=(z.prototype.getRequestUrl=function(e,t,n){void 0===n&&(n=a.graph.toString());var r=d.flags+"="+t.toString();switch(n){case a.graph.toString():"/"!=e.charAt(e.length-1)&&(e+="/"),e=(e+=d.processQuery)+"?"+r;break;case a.wfe.toString():e=(e=e+"&"+r)+"&wdRestPart=_api/"+d.processQuery}return e},z.prototype.executeAsync=function(e,t,n){var r=n.Headers?n.Headers[K.remoteEndpointTypeHeaderKey]:a.graph.toString(),o={method:"POST",url:this.getRequestUrl(n.Url,t,r),headers:{},body:n.Body};if(o.headers[d.sourceLibHeader]=z.SourceLibHeaderValue,o.headers["CONTENT-TYPE"]="application/json",n.Headers)for(var i in n.Headers)o.headers[i]=n.Headers[i];return(P._isLocalDocumentUrl(o.url)?s.sendLocalDocumentRequest:s.sendRequest)(o).then(function(e){var t;if(200===e.statusCode)t={HttpStatusCode:e.statusCode,ErrorCode:null,ErrorMessage:null,Headers:e.headers,Body:P._parseResponseBody(e)};else{P.log("Error Response:"+e.body);var n=P._parseErrorResponse(e);t={HttpStatusCode:e.statusCode,ErrorCode:n.errorCode,ErrorMessage:n.errorMessage,Headers:e.headers,Body:null,RawErrorResponseBody:P._parseErrorResponseBody(e)}}return t})},z.SourceLibHeaderValue="officejs-rest",z);function z(){}y.HttpRequestExecutor=V;var J,K=(__extends(X,J=d),X.collectionPropertyPath="_collectionPropertyPath",X.id="Id",X.idLowerCase="id",X.idPrivate="_Id",X.keepReference="_KeepReference",X.objectPathIdPrivate="_ObjectPathId",X.referenceId="_ReferenceId",X.items="_Items",X.itemsLowerCase="items",X.scalarPropertyNames="_scalarPropertyNames",X.scalarPropertyOriginalNames="_scalarPropertyOriginalNames",X.navigationPropertyNames="_navigationPropertyNames",X.scalarPropertyUpdateable="_scalarPropertyUpdateable",X.previewExecutionObjectId="_previewExecutionObjectId",X.remoteEndpointTypeHeaderKey="X-EndpointType",X);function X(){return null!==J&&J.apply(this,arguments)||this}y.CommonConstants=K;var Q,$=(__extends(Z,Q=P),Z.validateObjectPath=function(e){for(var t=e._objectPath;t;){if(!t.isValid)throw new h.RuntimeError({code:g.invalidObjectPath,httpStatusCode:400,message:P._getResourceString(m.invalidObjectPath,Z.getObjectPathExpression(t)),debugInfo:{errorLocation:Z.getObjectPathExpression(t)}});t=t.parentObjectPath}},Z.validateReferencedObjectPaths=function(e){if(e)for(var t=0;t<e.length;t++)for(var n=e[t];n;){if(!n.isValid)throw new h.RuntimeError({code:g.invalidObjectPath,httpStatusCode:400,message:P._getResourceString(m.invalidObjectPath,Z.getObjectPathExpression(n))});n=n.parentObjectPath}},Z._toCamelLowerCase=function(e){if(P.isNullOrEmptyString(e))return e;for(var t=0;t<e.length&&65<=e.charCodeAt(t)&&e.charCodeAt(t)<=90;)t++;return t<e.length?e.substr(0,t).toLowerCase()+e.substr(t):e.toLowerCase()},Z.adjustToDateTime=function(e){if(P.isNullOrUndefined(e))return null;if("string"==typeof e)return new Date(e);if(Array.isArray(e)){for(var t=e,n=0;n<t.length;n++)t[n]=Z.adjustToDateTime(t[n]);return t}throw P._createInvalidArgError({argumentName:"date"})},Z.tryGetObjectIdFromLoadOrRetrieveResult=function(e){var t=e[K.id];return P.isNullOrUndefined(t)&&(t=e[K.idLowerCase]),P.isNullOrUndefined(t)&&(t=e[K.idPrivate]),t},Z.getObjectPathExpression=function(e){for(var t="";e;){switch(e.objectPathInfo.ObjectPathType){case 1:t=t;break;case 2:t="new()"+(0<t.length?".":"")+t;break;case 3:t=Z.normalizeName(e.objectPathInfo.Name)+"()"+(0<t.length?".":"")+t;break;case 4:t=Z.normalizeName(e.objectPathInfo.Name)+(0<t.length?".":"")+t;break;case 5:t="getItem()"+(0<t.length?".":"")+t;break;case 6:t="_reference()"+(0<t.length?".":"")+t}e=e.parentObjectPath}return t},Z.setMethodArguments=function(e,t,n){if(P.isNullOrUndefined(n))return null;var r=new Array,o=new Array,i=Z.collectObjectPathInfos(e,n,r,o);return t.Arguments=n,i&&(t.ReferencedObjectPathIds=o),r},Z.validateContext=function(e,t){if(e&&t&&t._context!==e)throw new h.RuntimeError({code:g.invalidRequestContext,httpStatusCode:400,message:P._getResourceString(m.invalidRequestContext)})},Z.isSetSupported=function(e,t){return"function"==typeof Z.isSetSupportedOverride?Z.isSetSupportedOverride(e,t):!("undefined"!=typeof window&&window.Office&&window.Office.context&&window.Office.context.requirements)||window.Office.context.requirements.isSetSupported(e,t)},Z.throwIfApiNotSupported=function(e,t,n,r){if(Z._doApiNotSupportedCheck&&!Z.isSetSupported(t,n)){var o=P._getResourceString(m.apiNotFoundDetails,[e,t+" "+n,r]);throw new h.RuntimeError({code:g.apiNotFound,httpStatusCode:404,message:o,debugInfo:{errorLocation:e}})}},Z.calculateApiFlags=function(e,t,n){var r=window&&window.location&&window.location.href&&-1!==window.location.href.indexOf("eed0a086-3498-4f91-a377-1e0265ecc0cc");return("function"==typeof Z.isSetSupportedOverride?Z.isSetSupportedOverride(t,n):!r&&Z.isSetSupported(t,n))||(e&=-3),e},Z._parseSelectExpand=function(e){var t=[];if(!P.isNullOrEmptyString(e))for(var n=e.split(","),r=0;r<n.length;r++){var o=n[r];0<(o=i(o.trim())).length&&t.push(o)}return t;function i(e){var t=e.toLowerCase();return"items"===t||"items/"===t?"*":("items/"!==t.substr(0,6)&&"items."!==t.substr(0,6)||(e=e.substr(6)),e.replace(new RegExp("[/.]items[/.]","gi"),"/"))}},Z.changePropertyNameToCamelLowerCase=function(e){if(Array.isArray(e)){for(var t=[],n=0;n<e.length;n++)t.push(this.changePropertyNameToCamelLowerCase(e[n]));return t}if("object"!=typeof e||null===e)return e;for(var r in t={},e){var o=e[r];if(r===K.items){(t={})[K.itemsLowerCase]=this.changePropertyNameToCamelLowerCase(o);break}t[Z._toCamelLowerCase(r)]=this.changePropertyNameToCamelLowerCase(o)}return t},Z.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)return e;for(var r in t={},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},Z.collectObjectPathInfos=function(e,t,n,r){for(var o=!1,i=0;i<t.length;i++)if(t[i]instanceof E){var a=t[i];Z.validateContext(e,a),t[i]=a._objectPath.objectPathInfo.Id,r.push(a._objectPath.objectPathInfo.Id),n.push(a._objectPath),o=!0}else if(Array.isArray(t[i])){var s=new Array;Z.collectObjectPathInfos(e,t[i],n,s)?(r.push(s),o=!0):r.push(0)}else P.isPlainJsonObject(t[i])?(r.push(0),Z.replaceClientObjectPropertiesWithObjectPathIds(t[i],n)):r.push(0);return o},Z.replaceClientObjectPropertiesWithObjectPathIds=function(e,t){var n,r;for(var o in e){var i=e[o];if(i instanceof E)t.push(i._objectPath),e[o]=((n={})[K.objectPathIdPrivate]=i._objectPath.objectPathInfo.Id,n);else if(Array.isArray(i))for(var a=0;a<i.length;a++)if(i[a]instanceof E){var s=i[a];t.push(s._objectPath),i[a]=((r={})[K.objectPathIdPrivate]=s._objectPath.objectPathInfo.Id,r)}else P.isPlainJsonObject(i[a])&&Z.replaceClientObjectPropertiesWithObjectPathIds(i[a],t);else P.isPlainJsonObject(i)&&Z.replaceClientObjectPropertiesWithObjectPathIds(i,t)}},Z.normalizeName=function(e){return e.substr(0,1).toLowerCase()+e.substr(1)},Z._doApiNotSupportedCheck=!1,Z);function Z(){return null!==Q&&Q.apply(this,arguments)||this}y.CommonUtility=$;var Y,ee=(__extends(te,Y=m),te.propertyDoesNotExist="PropertyDoesNotExist",te.attemptingToSetReadOnlyProperty="AttemptingToSetReadOnlyProperty",te);function te(){return null!==Y&&Y.apply(this,arguments)||this}y.CommonResourceStrings=ee;var ne,re=(__extends(oe,ne=g),oe.propertyNotLoaded="PropertyNotLoaded",oe.runMustReturnPromise="RunMustReturnPromise",oe.cannotRegisterEvent="CannotRegisterEvent",oe.invalidOrTimedOutSession="InvalidOrTimedOutSession",oe.cannotUpdateReadOnlyProperty="CannotUpdateReadOnlyProperty",oe);function oe(){return null!==ne&&ne.apply(this,arguments)||this}y.ErrorCodes=re;var ie=(ae.prototype._handleResult=function(e){this.m_callback&&this.m_callback()},ae);function ae(e){this.m_callback=e}var se,ce=(__extends(le,se=R),le.createMethodAction=function(e,t,n,r,o,i){rt.validateObjectPath(t);var a={Id:e._nextId(),ActionType:3,Name:n,ObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}},s=rt.setMethodArguments(e,a.ArgumentInfo,o);rt.validateReferencedObjectPaths(s);var c=rt._fixupApiFlags(i),l=new D(a,r,c);if(l.referencedObjectPath=t._objectPath,l.referencedArgumentObjectPaths=s,t._addAction(l),y._internalConfig.enablePreviewExecution&&0!=(16&c)){var u={Id:e._nextId(),ActionType:3,Name:n,Arguments:o,ObjectId:"",ObjectType:""};t._addPreviewExecutionAction(u)}return l},le.createRecursiveQueryAction=function(e,t,n){rt.validateObjectPath(t);var r={Id:e._nextId(),ActionType:6,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,RecursiveQueryInfo:n},o=new D(r,1,4);return o.referencedObjectPath=t._objectPath,t._addAction(o),o},le.createEnsureUnchangedAction=function(e,t,n){rt.validateObjectPath(t);var r={Id:e._nextId(),ActionType:8,Name:"",ObjectPathId:t._objectPath.objectPathInfo.Id,ObjectState:n},o=new D(r,1,4);return o.referencedObjectPath=t._objectPath,t._addAction(o),o},le.createInstantiateAction=function(e,t){rt.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 D(n,1,4);return r.referencedObjectPath=t._objectPath,t._addAction(r,new Ge(t),!0),r},le.createTraceAction=function(e,t,n){var r={Id:e._nextId(),ActionType:5,Name:"Trace",ObjectPathId:0},o=new D(r,1,4);return e._pendingRequest.addAction(o),n&&e._pendingRequest.addTrace(r.Id,t),o},le.createTraceMarkerForCallback=function(e,t){var n=le.createTraceAction(e,null,!1);e._pendingRequest.addActionResultHandler(n,new ie(t))},le);function le(){return null!==se&&se.apply(this,arguments)||this}y.ActionFactory=ce;var ue,pe=(__extends(fe,ue=E),Object.defineProperty(fe.prototype,"context",{get:function(){return this.m_context},enumerable:!0,configurable:!0}),Object.defineProperty(fe.prototype,"isNull",{get:function(){return(void 0!==this.m_isNull||!A.isMock())&&(rt.throwIfNotLoaded("isNull",this._isNull,null,this._isNull),this._isNull)},enumerable:!0,configurable:!0}),Object.defineProperty(fe.prototype,"isNullObject",{get:function(){return(void 0!==this.m_isNull||!A.isMock())&&(rt.throwIfNotLoaded("isNullObject",this._isNull,null,this._isNull),this._isNull)},enumerable:!0,configurable:!0}),Object.defineProperty(fe.prototype,"_isNull",{get:function(){return this.m_isNull},set:function(e){(this.m_isNull=e)&&this._objectPath&&this._objectPath._updateAsNullObject()},enumerable:!0,configurable:!0}),fe.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),P._createPromiseFromResult(null)},fe.prototype._addPreviewExecutionAction=function(e){if(!rt.isUndefined(this._className)){e.ObjectType=this._className;var t=rt._getPropertyValueWithoutCheckLoaded(this,Se.idLowerCase);rt.isUndefined(t)&&(t=rt._getPropertyValueWithoutCheckLoaded(this,Se.idPrivate)),rt.isUndefined(t)&&(t=rt._getPropertyValueWithoutCheckLoaded(this,Se.previewExecutionObjectId)),e.ObjectId=t,this.context._pendingRequest.addPreviewExecutionAction(e)}},fe.prototype._handleResult=function(e){this._isNull=rt.isNullOrUndefined(e),this.context.trackedObjects._autoTrackIfNecessaryWhenHandleObjectResultValue(this,e)},fe.prototype._handleIdResult=function(e){this._isNull=rt.isNullOrUndefined(e),rt.fixObjectPathIfNecessary(this,e),this.context.trackedObjects._autoTrackIfNecessaryWhenHandleObjectResultValue(this,e)},fe.prototype._handleRetrieveResult=function(e,t){this._handleIdResult(e)},fe.prototype._recursivelySet=function(e,t,n,r,o){var i=e instanceof fe,a=e;if(i){if(Object.getPrototypeOf(this)!==Object.getPrototypeOf(e))throw h.RuntimeError._createInvalidArgError({argumentName:"properties",errorLocation:this._className+".set"});e=JSON.parse(JSON.stringify(e))}try{for(var s,c=0;c<n.length;c++)s=n[c],e.hasOwnProperty(s)&&void 0!==e[s]&&(this[s]=e[s]);for(c=0;c<r.length;c++)if(s=r[c],e.hasOwnProperty(s)&&void 0!==e[s]){var l=i?a[s]:e[s];this[s].set(l,t)}var u=!i;for(t&&!rt.isNullOrUndefined(u)&&(u=t.throwOnReadOnly),c=0;c<o.length;c++)if(s=o[c],e.hasOwnProperty(s)&&void 0!==e[s]&&u)throw new h.RuntimeError({code:g.invalidArgument,httpStatusCode:400,message:P._getResourceString(et.cannotApplyPropertyThroughSetMethod,s),debugInfo:{errorLocation:s}});for(s in e)if(n.indexOf(s)<0&&r.indexOf(s)<0){var p=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(this),s);if(!p)throw new h.RuntimeError({code:g.invalidArgument,httpStatusCode:400,message:P._getResourceString(ee.propertyDoesNotExist,s),debugInfo:{errorLocation:s}});if(u&&!p.set)throw new h.RuntimeError({code:g.invalidArgument,httpStatusCode:400,message:P._getResourceString(ee.attemptingToSetReadOnlyProperty,s),debugInfo:{errorLocation:s}})}}catch(e){throw new h.RuntimeError({code:g.invalidArgument,httpStatusCode:400,message:P._getResourceString(m.invalidArgument,"properties"),debugInfo:{errorLocation:this._className+".set"},innerError:e})}},fe);function fe(e,t){var n=ue.call(this,e,t)||this;return rt.checkArgumentNull(e,"context"),n.m_context=e,n._objectPath&&(!e._processingResult&&e._pendingRequest&&(ce.createInstantiateAction(e,n),e._autoCleanup&&n._KeepReference&&e.trackedObjects._autoAdd(n)),y._internalConfig.appendTypeNameToObjectPathInfo&&n._objectPath.objectPathInfo&&n._className&&(n._objectPath.objectPathInfo.T=n._className)),n}y.ClientObject=pe;var de=(he.prototype.executeAsync=function(e,t,n){var r={url:d.processQuery,method:"POST",headers:n.Headers,body:n.Body},o="";n.Headers&&(o=n.Headers[Se.officeControlId]);var i={id:c.nextId(),type:1,flags:t,controlId:o,message:r,customData:e};return P.log(JSON.stringify(i)),this.m_session.sendMessageToHost(i).then(function(e){P.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:P._parseResponseBody(n)};else{P.log("Error Response:"+n.body);var r=P._parseErrorResponse(n);t={HttpStatusCode:n.statusCode,ErrorCode:r.errorCode,ErrorMessage:r.errorMessage,Headers:n.headers,Body:null}}return t})},he);function he(e){this.m_session=e}var ge,me=(__extends(ye,ge=_),ye.getInstanceIfHostBridgeInited=function(){return c.instance?(!P.isNullOrUndefined(ye.s_instance)&&ye.s_instance.m_bridge===c.instance||(ye.s_instance=new ye(c.instance)),ye.s_instance):null},ye.prototype._resolveRequestUrlAndHeaderInfo=function(){return P._createPromiseFromResult(null)},ye.prototype._createRequestExecutorOrNull=function(){return P.log("NativeBridgeSession::CreateRequestExecutor"),new de(this)},ye.prototype.getEventRegistration=function(e){return He.getGenericEventRegistration(e)},ye.prototype.sendMessageToHost=function(e){return this.m_bridge.sendMessageToHostAndExpectResponse(e)},ye);function ye(e){var t=ge.call(this)||this;return t.m_bridge=e,t.m_bridge.addHostMessageHandler(function(e){if(3===e.type){var t=e.controlId;if(P.isNullOrEmptyString(t))He.getGenericEventRegistration(t)._handleRichApiMessage(e.message);else{var n=He.peekGenericEventRegistrationOrNull(t);n&&n._handleRichApiMessage(e.message),(n=He.peekGenericEventRegistrationOrNull(""))&&n._handleRichApiMessage(e.message)}}}),t}y.HostBridgeSession=me;var _e,be=(__extends(ve,_e=j),Object.defineProperty(ve.prototype,"session",{get:function(){return this.m_session},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"eventRegistration",{get:function(){return this.m_session?this.m_session.getEventRegistration(this._controlId):h.officeJsEventRegistration},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"_url",{get:function(){return this.m_requestUrlAndHeaderInfo?this.m_requestUrlAndHeaderInfo.url:null},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"_pendingRequest",{get:function(){return null==this.m_pendingRequest&&(this.m_pendingRequest=new Re(this)),this.m_pendingRequest},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"_controlId",{get:function(){var e=this.m_customRequestHeaders[Se.officeControlId];return P.isNullOrUndefined(e)&&(e=""),e},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"debugInfo",{get:function(){return{pendingStatements:new $e(this._rootObjectPropertyName,this._pendingRequest._objectPaths,this._pendingRequest._actions,y._internalConfig.showDisposeInfoInDebugInfo).process()}},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"trackedObjects",{get:function(){return this.m_trackedObjects||(this.m_trackedObjects=new Xe(this)),this.m_trackedObjects},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"requestHeaders",{get:function(){return this.m_customRequestHeaders},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"batchMode",{get:function(){return this.m_batchMode},enumerable:!0,configurable:!0}),Object.defineProperty(ve.prototype,"getAdditionalHeaders",{set:function(e){this.m_getAdditionalHeaders=e},enumerable:!0,configurable:!0}),ve.prototype.ensureInProgressBatchIfBatchMode=function(){if(1===this.m_batchMode&&!this.m_explicitBatchInProgress)throw rt.createRuntimeError(g.generalException,P._getResourceString(et.notInsideBatch),null)},ve.prototype.load=function(e,t){rt.validateContext(this,e);var n=ve._parseQueryOption(t);R.createQueryAction(this,e,n,e)},ve.prototype.loadRecursive=function(e,t,n){if(!rt.isPlainJsonObject(t))throw h.RuntimeError._createInvalidArgError({argumentName:"options"});var r={};for(var o in t)r[o]=ve._parseQueryOption(t[o]);var i=ce.createRecursiveQueryAction(this,e,{Queries:r,MaxDepth:n});this._pendingRequest.addActionResultHandler(i,e)},ve.prototype.trace=function(e){ce.createTraceAction(this,e,!0)},ve.prototype._processOfficeJsErrorResponse=function(e,t){},ve.prototype.ensureRequestUrlAndHeaderInfo=function(){var n=this;return rt._createPromiseFromResult(null).then(function(){if(!n.m_requestUrlAndHeaderInfo)return n.m_requestUrlAndHeaderInfoResolver._resolveRequestUrlAndHeaderInfo().then(function(e){if(n.m_requestUrlAndHeaderInfo=e,n.m_requestUrlAndHeaderInfo||(n.m_requestUrlAndHeaderInfo={url:d.localDocument,headers:{}}),rt.isNullOrEmptyString(n.m_requestUrlAndHeaderInfo.url)&&(n.m_requestUrlAndHeaderInfo.url=d.localDocument),n.m_requestUrlAndHeaderInfo.headers||(n.m_requestUrlAndHeaderInfo.headers={}),"function"==typeof n.m_requestUrlAndHeaderInfoResolver._createRequestExecutorOrNull){var t=n.m_requestUrlAndHeaderInfoResolver._createRequestExecutorOrNull();t&&(n._requestExecutor=t)}})})},ve.prototype.syncPrivateMain=function(){var t=this;return this.ensureRequestUrlAndHeaderInfo().then(function(){var e=t._pendingRequest;return t.m_pendingRequest=null,t.processPreSyncPromises(e).then(function(){return t.syncPrivate(e)})})},ve.prototype.syncPrivate=function(n){var t=this;if(A.isMock())return P._createPromiseFromResult(null);if(!n.hasActions)return this.processPendingEventHandlers(n);var e=n.buildRequestMessageBodyAndRequestFlags(),r=e.body,o=e.flags;this._requestFlagModifier&&(o|=this._requestFlagModifier),this._requestExecutor||(P._isLocalDocumentUrl(this.m_requestUrlAndHeaderInfo.url)?this._requestExecutor=new Je(this):this._requestExecutor=new V);var i=this._requestExecutor,a={};P._copyHeaders(this.m_requestUrlAndHeaderInfo.headers,a),P._copyHeaders(this.m_customRequestHeaders,a),delete this.m_customRequestHeaders[Se.officeScriptEventId],this.m_getAdditionalHeaders&&P._copyHeaders(this.m_getAdditionalHeaders(),a);var s=A._getCurrentTestNameWithSequenceId();s&&(a[d.testRequestNameHeader]=s);var c={Url:this.m_requestUrlAndHeaderInfo.url,Headers:a,Body:r};n.invalidatePendingInvalidObjectPaths();var l=null,u=null;return this._lastSyncStart="undefined"==typeof performance?Date.now():performance.now(),this._lastRequestFlags=o,i.executeAsync(this._customData,o,c).then(function(e){return t._lastSyncEnd="undefined"==typeof performance?Date.now():performance.now(),y.config.executePerfLogFunc&&y.config.executePerfLogFunc({syncStart:t._lastSyncStart,syncEnd:t._lastSyncEnd}),l=t.processRequestExecutorResponseMessage(n,e),t.processPendingEventHandlers(n).catch(function(e){P.log("Error in processPendingEventHandlers"),P.log(JSON.stringify(e)),u=e})}).then(function(){if(l)throw P.log("Throw error from response: "+JSON.stringify(l)),l;if(u){P.log("Throw error from ProcessEventHandler: "+JSON.stringify(u));var e=null;if(u instanceof h.RuntimeError)(e=u).traceMessages=n._responseTraceMessages;else{var t=null;t="string"==typeof u?u:u.message,rt.isNullOrEmptyString(t)&&(t=P._getResourceString(et.cannotRegisterEvent)),e=new h.RuntimeError({code:re.cannotRegisterEvent,httpStatusCode:400,message:t,traceMessages:n._responseTraceMessages})}throw e}})},ve.prototype.processRequestExecutorResponseMessage=function(e,t){t.Body&&t.Body.TraceIds&&e._setResponseTraceIds(t.Body.TraceIds);var n=e._responseTraceMessages,r=null;if(t.Body){if(t.Body.Error&&0<=t.Body.Error.ActionIndex){var o=new $e(this._rootObjectPropertyName,e._objectPaths,e._actions,!1,!0),i=o.processForDebugStatementInfo(t.Body.Error.ActionIndex);r={statement:i.statement,surroundingStatements:i.surroundingStatements,fullStatements:["Please enable config.extendedErrorLogging to see full statements."]},y.config.extendedErrorLogging&&(o=new $e(this._rootObjectPropertyName,e._objectPaths,e._actions,!1,!1),r.fullStatements=o.process())}var a=null;if(t.Body.Results?a=t.Body.Results:t.Body.ProcessedResults&&t.Body.ProcessedResults.Results&&(a=t.Body.ProcessedResults.Results),a){this._processingResult=!0;try{e.processResponse(a)}finally{this._processingResult=!1}}}if(!rt.isNullOrEmptyString(t.ErrorCode))return new h.RuntimeError({code:t.ErrorCode,httpStatusCode:t.HttpStatusCode,message:t.ErrorMessage,traceMessages:n,data:{responseBody:t.RawErrorResponseBody}});if(t.Body&&t.Body.Error){var s={errorLocation:t.Body.Error.Location};return r&&(s.statement=r.statement,s.surroundingStatements=r.surroundingStatements,s.fullStatements=r.fullStatements),new h.RuntimeError({code:t.Body.Error.Code,httpStatusCode:t.Body.Error.HttpStatusCode,message:t.Body.Error.Message,traceMessages:n,debugInfo:s})}return null},ve.prototype.processPendingEventHandlers=function(e){for(var t=rt._createPromiseFromResult(null),n=0;n<e._pendingProcessEventHandlers.length;n++){var r=e._pendingProcessEventHandlers[n];t=t.then(this.createProcessOneEventHandlersFunc(r,e))}return t},ve.prototype.createProcessOneEventHandlersFunc=function(e,t){return function(){return e._processRegistration(t)}},ve.prototype.processPreSyncPromises=function(e){for(var t=rt._createPromiseFromResult(null),n=0;n<e._preSyncPromises.length;n++){var r=e._preSyncPromises[n];t=t.then(this.createProcessOneProSyncFunc(r))}return t},ve.prototype.createProcessOneProSyncFunc=function(e){return function(){return e}},ve.prototype.sync=function(e){return A.isMock()?P._createPromiseFromResult(e):this.syncPrivateMain().then(function(){return e})},ve.prototype.batch=function(e){var t=this;if(1!==this.m_batchMode)return P._createPromiseFromException(rt.createRuntimeError(g.generalException,null,null));if(this.m_explicitBatchInProgress)return P._createPromiseFromException(rt.createRuntimeError(g.generalException,P._getResourceString(et.pendingBatchInProgress),null));if(rt.isNullOrUndefined(e))return rt._createPromiseFromResult(null);this.m_explicitBatchInProgress=!0;var n,r,o=this.m_pendingRequest;this.m_pendingRequest=new Re(this);try{n=e(this._rootObject,this)}catch(e){return this.m_explicitBatchInProgress=!1,this.m_pendingRequest=o,P._createPromiseFromException(e)}return("object"==typeof n&&n&&"function"==typeof n.then?rt._createPromiseFromResult(null).then(function(){return n}).then(function(e){return t.m_explicitBatchInProgress=!1,r=t.m_pendingRequest,t.m_pendingRequest=o,e}).catch(function(e){return t.m_explicitBatchInProgress=!1,r=t.m_pendingRequest,t.m_pendingRequest=o,P._createPromiseFromException(e)}):(this.m_explicitBatchInProgress=!1,r=this.m_pendingRequest,this.m_pendingRequest=o,rt._createPromiseFromResult(n))).then(function(e){return t.ensureRequestUrlAndHeaderInfo().then(function(){return t.syncPrivate(r)}).then(function(){return e})})},ve._run=function(e,t,n,r,o,i){return void 0===n&&(n=3),void 0===r&&(r=5e3),ve._runCommon("run",null,e,0,t,n,r,null,null,o,i)},ve.isValidRequestInfo=function(e){return"string"==typeof e||ve.isRequestUrlAndHeaderInfo(e)||ve.isRequestUrlAndHeaderInfoResolver(e)},ve.isRequestUrlAndHeaderInfo=function(e){return"object"==typeof e&&null!==e&&Object.getPrototypeOf(e)===Object.getPrototypeOf({})&&!rt.isNullOrUndefined(e.url)},ve.isRequestUrlAndHeaderInfoResolver=function(e){return"object"==typeof e&&null!==e&&"function"==typeof e._resolveRequestUrlAndHeaderInfo},ve._runBatch=function(e,t,n,r,o,i,a,s,c){return void 0===i&&(i=3),void 0===a&&(a=5e3),ve._runBatchCommon(0,e,t,n,i,a,r,o,s,c)},ve._runExplicitBatch=function(e,t,n,r,o,i,a,s,c){return void 0===i&&(i=3),void 0===a&&(a=5e3),ve._runBatchCommon(1,e,t,n,i,a,r,o,s,c)},ve._runBatchCommon=function(e,t,n,r,o,i,a,s,c,l){var u,p;void 0===o&&(o=3),void 0===i&&(i=5e3);var f=null,d=null,h=null,g=0,m=null;if(0<n.length)if(ve.isValidRequestInfo(n[0]))f=n[0],g=1;else if(rt.isPlainJsonObject(n[0])){if(null!=(f=(m=n[0]).session)&&!ve.isValidRequestInfo(f))return ve.createErrorPromise(t);d=m.getAdditionalHeaders,h=m.previousObjects,g=1}if(n.length==g+1)p=n[g+0];else{if(null!=m||n.length!=g+2)return ve.createErrorPromise(t);h=n[g+0],p=n[g+1]}if(null!=h)if(h instanceof pe)u=function(){return h.context};else if(h instanceof ve)u=function(){return h};else{if(!Array.isArray(h))return ve.createErrorPromise(t);var y=h;if(0==y.length)return ve.createErrorPromise(t);for(var _=0;_<y.length;_++){if(!(y[_]instanceof pe))return ve.createErrorPromise(t);if(y[_].context!=y[0].context)return ve.createErrorPromise(t,et.invalidRequestContext)}u=function(){return y[0].context}}else u=r;var b=null;a&&(b=function(e){return a(m||{},e)});var v=null;return s&&(v=function(e){return s(m||{},e)}),ve._runCommon(t,f,u,e,p,o,i,b,v,c,l,d)},ve.createErrorPromise=function(e,t){return void 0===t&&(t=m.invalidArgument),P._createPromiseFromException(rt.createRuntimeError(t,P._getResourceString(t),e))},ve._runCommon=function(t,n,e,r,o,s,c,i,l,u,p,a){_._overrideSession&&(n=_._overrideSession);var f,d,h,g=P.createPromise(function(e,t){e()}),m=!1;return g.then(function(){if((f=e(n)).getAdditionalHeaders=a,f._autoCleanup)return new y.Promise(function(e,t){f._onRunFinishedNotifiers.push(function(){f._autoCleanup=!0,e()})});f._autoCleanup=!0}).then(function(){return"function"!=typeof o?ve.createErrorPromise(t):(h=f.m_batchMode,f.m_batchMode=r,i&&i(f),e=o(1==r?f.batch.bind(f):f),!rt.isNullOrUndefined(e)&&"function"==typeof e.then||rt.throwError(et.runMustReturnPromise),e);var e}).then(function(e){return 1===r?e:f.sync(e)}).then(function(e){m=!0,d=e}).catch(function(e){d=e}).then(function(){var o=f.trackedObjects._retrieveAndClearAutoCleanupList();for(var e in f._autoCleanup=!1,f.m_batchMode=h,o)o[e]._objectPath.isValid=!1;var i=0;if(rt._synchronousCleanup||ve.isRequestUrlAndHeaderInfoResolver(n))return a();function a(){i++;var e=f.m_pendingRequest,t=f.m_batchMode,n=new Re(f);f.m_pendingRequest=n,f.m_batchMode=0;try{for(var r in o)f.trackedObjects.remove(o[r]);l&&l(f)}finally{f.m_batchMode=t,f.m_pendingRequest=e}return f.syncPrivate(n).then(function(){u&&u(i)}).catch(function(){p&&p(i),i<s&&setTimeout(function(){a()},c)})}a()}).then(function(){if(f._onRunFinishedNotifiers&&0<f._onRunFinishedNotifiers.length&&f._onRunFinishedNotifiers.shift()(),m)return d;throw d})},ve);function ve(e){var t=_e.call(this)||this;if(t.m_customRequestHeaders={},t.m_batchMode=0,t._onRunFinishedNotifiers=[],_._overrideSession)t.m_requestUrlAndHeaderInfoResolver=_._overrideSession;else if((rt.isNullOrUndefined(e)||"string"==typeof e&&0===e.length)&&(e=(e=ve.defaultRequestUrlAndHeaders)||{url:d.localDocument,headers:{}}),"string"==typeof e)t.m_requestUrlAndHeaderInfo={url:e,headers:{}};else if(ve.isRequestUrlAndHeaderInfoResolver(e))t.m_requestUrlAndHeaderInfoResolver=e;else{if(!ve.isRequestUrlAndHeaderInfo(e))throw h.RuntimeError._createInvalidArgError({argumentName:"url"});var n=e;t.m_requestUrlAndHeaderInfo={url:n.url,headers:{}},P._copyHeaders(n.headers,t.m_requestUrlAndHeaderInfo.headers)}return!t.m_requestUrlAndHeaderInfoResolver&&t.m_requestUrlAndHeaderInfo&&P._isLocalDocumentUrl(t.m_requestUrlAndHeaderInfo.url)&&me.getInstanceIfHostBridgeInited()&&(t.m_requestUrlAndHeaderInfo=null,t.m_requestUrlAndHeaderInfoResolver=me.getInstanceIfHostBridgeInited()),t.m_requestUrlAndHeaderInfoResolver instanceof _&&(t.m_session=t.m_requestUrlAndHeaderInfoResolver),t._processingResult=!1,t._customData=Se.iterativeExecutor,t.sync=t.sync.bind(t),t}y.ClientRequestContext=be;var Oe=(Object.defineProperty(Ce.prototype,"$proxy",{get:function(){return this.m_proxy},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"$isNullObject",{get:function(){if(!this.m_isLoaded)throw new h.RuntimeError({code:re.valueNotLoaded,httpStatusCode:400,message:P._getResourceString(et.valueNotLoaded),debugInfo:{errorLocation:"retrieveResult.$isNullObject"}});return this.m_isNullObject},enumerable:!0,configurable:!0}),Ce.prototype.toJSON=function(){if(this.m_isLoaded)return this.m_isNullObject?null:(rt.isUndefined(this.m_json)&&(this.m_json=rt.purifyJson(this.m_value)),this.m_json)},Ce.prototype.toString=function(){return JSON.stringify(this.toJSON())},Ce.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=rt.changePropertyNameToCamelLowerCase(e)),this.m_value=e,this.m_proxy._handleRetrieveResult(e,this)},Ce);function Ce(e,t){this.m_proxy=e,this.m_shouldPolyfill=t;var n=e[Se.scalarPropertyNames],r=e[Se.navigationPropertyNames],o=e[Se.className],i=e[Se.isCollection];if(n)for(var a=0;a<n.length;a++)rt.definePropertyThrowUnloadedException(this,o,n[a]);if(r)for(a=0;a<r.length;a++)rt.definePropertyThrowUnloadedException(this,o,r[a]);i&&rt.definePropertyThrowUnloadedException(this,o,Se.itemsLowerCase)}var Pe,Se=(__extends(Ae,Pe=K),Ae.getItemAt="GetItemAt",Ae.index="_Index",Ae.iterativeExecutor="IterativeExecutor",Ae.isTracked="_IsTracked",Ae.eventMessageCategory=65536,Ae.eventWorkbookId="Workbook",Ae.eventSourceRemote="Remote",Ae.proxy="$proxy",Ae.className="_className",Ae.isCollection="_isCollection",Ae.collectionPropertyPath="_collectionPropertyPath",Ae.objectPathInfoDoNotKeepReferenceFieldName="D",Ae.officeScriptEventId="X-OfficeScriptEventId",Ae.officeScriptFireRecordingEvent="X-OfficeScriptFireRecordingEvent",Ae.officeControlId="X-OfficeControlId",Ae);function Ae(){return null!==Pe&&Pe.apply(this,arguments)||this}y.Constants=Se;var Ie,Re=(__extends(Te,Ie=L),Object.defineProperty(Te.prototype,"traceInfos",{get:function(){return this.m_traceInfos},enumerable:!0,configurable:!0}),Object.defineProperty(Te.prototype,"_responseTraceMessages",{get:function(){return this.m_responseTraceMessages},enumerable:!0,configurable:!0}),Object.defineProperty(Te.prototype,"_responseTraceIds",{get:function(){return this.m_responseTraceIds},enumerable:!0,configurable:!0}),Te.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];P.isNullOrUndefined(r)||this.m_responseTraceMessages.push(r)}},Te.prototype.addTrace=function(e,t){this.m_traceInfos[e]=t},Te.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(Te.prototype,"_pendingProcessEventHandlers",{get:function(){return this.m_pendingProcessEventHandlers},enumerable:!0,configurable:!0}),Te.prototype._getPendingEventHandlerActions=function(e){return this.m_pendingEventHandlerActions[e._id]},Te);function Te(e){var t=Ie.call(this,e)||this;return t.m_context=e,t.m_pendingProcessEventHandlers=[],t.m_pendingEventHandlerActions={},t.m_traceInfos={},t.m_responseTraceIds={},t.m_responseTraceMessages=[],t}y.ClientRequest=Re;var Ee=(Object.defineProperty(Ne.prototype,"_registered",{get:function(){return this.m_registered},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"_id",{get:function(){return this.m_id},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"_handlers",{get:function(){return this.m_handlers},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"_context",{get:function(){return this.m_context},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"_callback",{get:function(){return this.m_callback},enumerable:!0,configurable:!0}),Ne.prototype.add=function(e){var t=ce.createTraceAction(this.m_context,null,!1);return this.m_context._pendingRequest._addPendingEventHandlerAction(this,{id:t.actionInfo.Id,handler:e,operation:0}),new we(this.m_context,this,e)},Ne.prototype.remove=function(e){var t=ce.createTraceAction(this.m_context,null,!1);this.m_context._pendingRequest._addPendingEventHandlerAction(this,{id:t.actionInfo.Id,handler:e,operation:1})},Ne.prototype.removeAll=function(){var e=ce.createTraceAction(this.m_context,null,!1);this.m_context._pendingRequest._addPendingEventHandlerAction(this,{id:e.actionInfo.Id,handler:null,operation:2})},Ne.prototype._processRegistration=function(e){var t=this,n=P._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;0<=s;s--)if(o[s]===r[i].handler){o.splice(s,1);break}break;case 2:o=[]}return a&&(!this.m_registered&&0<o.length?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){P.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},Ne.prototype.fireEvent=function(e){for(var t=[],n=0;n<this.m_handlers.length;n++){var r=this.m_handlers[n],o=P._createPromiseFromResult(null).then(this.createFireOneEventHandlerFunc(r,e)).catch(function(e){P.log("Error when invoke handler: "+JSON.stringify(e))});t.push(o)}P.Promise.all(t)},Ne.prototype.createFireOneEventHandlerFunc=function(e,t){return function(){return e(t)}},Ne);function Ne(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)})}}y.EventHandlers=Ee;var De,xe,we=(Object.defineProperty(Fe.prototype,"context",{get:function(){return this.m_context},enumerable:!0,configurable:!0}),Fe.prototype.remove=function(){this.m_allHandlers&&this.m_handler&&(this.m_allHandlers.remove(this.m_handler),this.m_allHandlers=null,this.m_handler=null)},Fe);function Fe(e,t,n){this.m_context=e,this.m_allHandlers=t,this.m_handler=n}function je(){}y.EventHandlerResult=we,De=h=y._Internal||(y._Internal={}),je.prototype.register=function(e,t,n){switch(e){case 4:return rt.promisify(function(e){return Office.context.document.bindings.getByIdAsync(t,e)}).then(function(t){return rt.promisify(function(e){return t.addHandlerAsync(Office.EventType.BindingDataChanged,n,e)})});case 3:return rt.promisify(function(e){return Office.context.document.bindings.getByIdAsync(t,e)}).then(function(t){return rt.promisify(function(e){return t.addHandlerAsync(Office.EventType.BindingSelectionChanged,n,e)})});case 2:return rt.promisify(function(e){return Office.context.document.addHandlerAsync(Office.EventType.DocumentSelectionChanged,n,e)});case 1:return rt.promisify(function(e){return Office.context.document.settings.addHandlerAsync(Office.EventType.SettingsChanged,n,e)});case 5:return OSF.DDA.RichApi.richApiMessageManager.register(n);case 13:return rt.promisify(function(e){return Office.context.document.addHandlerAsync(Office.EventType.ObjectDeleted,n,{id:t},e)});case 14:return rt.promisify(function(e){return Office.context.document.addHandlerAsync(Office.EventType.ObjectSelectionChanged,n,{id:t},e)});case 15:return rt.promisify(function(e){return Office.context.document.addHandlerAsync(Office.EventType.ObjectDataChanged,n,{id:t},e)});case 16:return rt.promisify(function(e){return Office.context.document.addHandlerAsync(Office.EventType.ContentControlAdded,n,{id:t},e)});default:throw De.RuntimeError._createInvalidArgError({argumentName:"eventId"})}},je.prototype.unregister=function(e,t,n){switch(e){case 4:return rt.promisify(function(e){return Office.context.document.bindings.getByIdAsync(t,e)}).then(function(t){return rt.promisify(function(e){return t.removeHandlerAsync(Office.EventType.BindingDataChanged,{handler:n},e)})});case 3:return rt.promisify(function(e){return Office.context.document.bindings.getByIdAsync(t,e)}).then(function(t){return rt.promisify(function(e){return t.removeHandlerAsync(Office.EventType.BindingSelectionChanged,{handler:n},e)})});case 2:return rt.promisify(function(e){return Office.context.document.removeHandlerAsync(Office.EventType.DocumentSelectionChanged,{handler:n},e)});case 1:return rt.promisify(function(e){return Office.context.document.settings.removeHandlerAsync(Office.EventType.SettingsChanged,{handler:n},e)});case 5:return rt.promisify(function(e){return OSF.DDA.RichApi.richApiMessageManager.removeHandlerAsync("richApiMessage",{handler:n},e)});case 13:return rt.promisify(function(e){return Office.context.document.removeHandlerAsync(Office.EventType.ObjectDeleted,{id:t,handler:n},e)});case 14:return rt.promisify(function(e){return Office.context.document.removeHandlerAsync(Office.EventType.ObjectSelectionChanged,{id:t,handler:n},e)});case 15:return rt.promisify(function(e){return Office.context.document.removeHandlerAsync(Office.EventType.ObjectDataChanged,{id:t,handler:n},e)});case 16:return rt.promisify(function(e){return Office.context.document.removeHandlerAsync(Office.EventType.ContentControlAdded,{id:t,handler:n},e)});default:throw De.RuntimeError._createInvalidArgError({argumentName:"eventId"})}},xe=je,De.officeJsEventRegistration=new xe;var ke=(Me.getTargetIdOrDefault=function(e){return rt.isNullOrUndefined(e)?"":e},Me.prototype.getHandlers=function(e,t){t=Me.getTargetIdOrDefault(t);var n=this.m_handlersByEventByTarget[e];n||(n={},this.m_handlersByEventByTarget[e]=n);var r=n[t];return r||(r=[],n[t]=r),r},Me.prototype.callHandlers=function(e,t,n){for(var r=this.getHandlers(e,t),o=0;o<r.length;o++)r[o](n)},Me.prototype.hasHandlers=function(e,t){return 0<this.getHandlers(e,t).length},Me.prototype.register=function(e,t,n){if(!n)throw h.RuntimeError._createInvalidArgError({argumentName:"handler"});var r=this.getHandlers(e,t);return r.push(n),1===r.length?this.m_registerEventImpl(e,t):rt._createPromiseFromResult(null)},Me.prototype.unregister=function(e,t,n){if(!n)throw h.RuntimeError._createInvalidArgError({argumentName:"handler"});for(var r=this.getHandlers(e,t),o=r.length-1;0<=o;o--)if(r[o]===n){r.splice(o,1);break}return 0===r.length?this.m_unregisterEventImpl(e,t):rt._createPromiseFromResult(null)},Me);function Me(e,t){this.m_handlersByEventByTarget={},this.m_registerEventImpl=e,this.m_unregisterEventImpl=t}y.EventRegistration=ke;var He=(Le.prototype.ready=function(){var e=this;return this.m_ready||(Le._testReadyImpl?this.m_ready=Le._testReadyImpl().then(function(){e.m_isReady=!0}):c.instance?this.m_ready=rt._createPromiseFromResult(null).then(function(){e.m_isReady=!0}):this.m_ready=h.officeJsEventRegistration.register(5,"",this.m_richApiMessageHandler).then(function(){e.m_isReady=!0})),this.m_ready},Object.defineProperty(Le.prototype,"isReady",{get:function(){return this.m_isReady},enumerable:!0,configurable:!0}),Le.prototype.register=function(e,t,n){var r=this;return this.ready().then(function(){return r.m_eventRegistration.register(e,t,n)})},Le.prototype.unregister=function(e,t,n){var r=this;return this.ready().then(function(){return r.m_eventRegistration.unregister(e,t,n)})},Le.prototype._registerEventImpl=function(e,t){return rt._createPromiseFromResult(null)},Le.prototype._unregisterEventImpl=function(e,t){return rt._createPromiseFromResult(null)},Le.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==Se.eventMessageCategory){P._logEnabled&&P.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=Se.eventSourceRemote),this.m_eventRegistration.callHandlers(r,o,i)}}}},Le.getGenericEventRegistration=function(e){P.isNullOrUndefined(e)&&(e="");var t=Le.s_genericEventRegistrations[e];return t||(t=new Le,Le.s_genericEventRegistrations[e]=t),t},Le.peekGenericEventRegistrationOrNull=function(e){return P.isNullOrUndefined(e)&&(e=""),Le.s_genericEventRegistrations[e]},Le.richApiMessageEventCategory=65536,Le.s_genericEventRegistrations={},Le);function Le(){this.m_eventRegistration=new ke(this._registerEventImpl.bind(this),this._unregisterEventImpl.bind(this)),this.m_richApiMessageHandler=this._handleRichApiMessage.bind(this)}y.GenericEventRegistration=He,y._testSetRichApiMessageReadyImpl=function(e){He._testReadyImpl=e},y._testTriggerRichApiMessageEvent=function(e){He.getGenericEventRegistration("")._handleRichApiMessage(e)};var Ue,Be=(__extends(We,Ue=Ee),We.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 He.getGenericEventRegistration(n).isReady||this._context._pendingRequest._addPreSyncPromise(He.getGenericEventRegistration(n).ready()),ce.createTraceMarkerForCallback(this._context,function(){t._handlers.push(e),1==t._handlers.length&&He.getGenericEventRegistration(n).register(t.m_genericEventInfo.eventType,t.m_genericEventInfo.getTargetIdFunc(),t._callback)}),new we(this._context,this,e)},We.prototype.remove=function(n){var r=this;1==this._handlers.length&&this.m_genericEventInfo.unregisterFunc&&this.m_genericEventInfo.unregisterFunc();var o=this._context._controlId;ce.createTraceMarkerForCallback(this._context,function(){for(var e=r._handlers,t=e.length-1;0<=t;t--)if(e[t]===n){e.splice(t,1);break}0==e.length&&He.getGenericEventRegistration(o).unregister(r.m_genericEventInfo.eventType,r.m_genericEventInfo.getTargetIdFunc(),r._callback)})},We.prototype.removeAll=function(){},We);function We(e,t,n,r){var o=Ue.call(this,e,t,n,r)||this;return o.m_genericEventInfo=r,o}y.GenericEventHandlers=Be;var Ge=(qe.prototype._handleResult=function(e){this.m_clientObject._handleIdResult(e)},qe);function qe(e){this.m_clientObject=e}var Ve=(ze.createGlobalObjectObjectPath=function(e){var t={Id:e._nextId(),ObjectPathType:1,Name:""};return new w(t,null,!1,!1,1,4)},ze.createNewObjectObjectPath=function(e,t,n,r){var o={Id:e._nextId(),ObjectPathType:2,Name:t};return new w(o,null,n,!1,1,rt._fixupApiFlags(r))},ze.createPropertyObjectPath=function(e,t,n,r,o,i){var a={Id:e._nextId(),ObjectPathType:4,Name:n,ParentObjectPathId:t._objectPath.objectPathInfo.Id};return new w(a,t._objectPath,r,o,1,rt._fixupApiFlags(i))},ze.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 w(r,t._objectPath,!1,!1,1,4)},ze.createIndexerObjectPathUsingParentPath=function(e,t,n){var r={Id:e._nextId(),ObjectPathType:5,Name:"",ParentObjectPathId:t.objectPathInfo.Id,ArgumentInfo:{}};return r.ArgumentInfo.Arguments=n,new w(r,t,!1,!1,1,4)},ze.createMethodObjectPath=function(e,t,n,r,o,i,a,s,c){var l={Id:e._nextId(),ObjectPathType:3,Name:n,ParentObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}},u=rt.setMethodArguments(e,l.ArgumentInfo,o),p=new w(l,t._objectPath,i,a,r,rt._fixupApiFlags(c));return p.argumentObjectPaths=u,p.getByIdMethodName=s,p},ze.createReferenceIdObjectPath=function(e,t){var n={Id:e._nextId(),ObjectPathType:6,Name:t,ArgumentInfo:{}};return new w(n,null,!1,!1,1,4)},ze.createChildItemObjectPathUsingIndexerOrGetItemAt=function(e,t,n,r,o){var i=rt.tryGetObjectIdFromLoadOrRetrieveResult(r);return e&&!rt.isNullOrUndefined(i)?ze.createChildItemObjectPathUsingIndexer(t,n,r):ze.createChildItemObjectPathUsingGetItemAt(t,n,r,o)},ze.createChildItemObjectPathUsingIndexer=function(e,t,n){var r=rt.tryGetObjectIdFromLoadOrRetrieveResult(n),o=o={Id:e._nextId(),ObjectPathType:5,Name:"",ParentObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}};return o.ArgumentInfo.Arguments=[r],new w(o,t._objectPath,!1,!1,1,4)},ze.createChildItemObjectPathUsingGetItemAt=function(e,t,n,r){var o=n[Se.index];o&&(r=o);var i={Id:e._nextId(),ObjectPathType:3,Name:Se.getItemAt,ParentObjectPathId:t._objectPath.objectPathInfo.Id,ArgumentInfo:{}};return i.ArgumentInfo.Arguments=[r],new w(i,t._objectPath,!1,!1,1,4)},ze);function ze(){}y.ObjectPathFactory=Ve;var Je=(Ke.prototype.executeAsync=function(e,t,n){var r=this,o=O.buildMessageArrayForIRequestExecutor(e,t,n,Ke.SourceLibHeaderValue);return new y.Promise(function(n,e){OSF.DDA.RichApi.executeRichApiRequestAsync(o,function(e){var t;P.log("Response:"),P.log(JSON.stringify(e)),"succeeded"==e.status?t=O.buildResponseOnSuccess(O.getResponseBody(e),O.getResponseHeaders(e)):(t=O.buildResponseOnError(e.error.code,e.error.message),r.m_context._processOfficeJsErrorResponse(e.error.code,t)),n(t)})})},Ke.SourceLibHeaderValue="officejs",Ke);function Ke(e){this.m_context=e}var Xe=(Qe.prototype.add=function(e){var t=this;Array.isArray(e)?e.forEach(function(e){return t._addCommon(e,!0)}):this._addCommon(e,!0)},Qe.prototype._autoAdd=function(e){this._addCommon(e,!1),this._autoCleanupList[e._objectPath.objectPathInfo.Id]=e},Qe.prototype._autoTrackIfNecessaryWhenHandleObjectResultValue=function(e,t){this.m_context._autoCleanup&&!e[Se.isTracked]&&e!==this.m_context._rootObject&&t&&!rt.isNullOrEmptyString(t[Se.referenceId])&&((this._autoCleanupList[e._objectPath.objectPathInfo.Id]=e)[Se.isTracked]=!0)},Qe.prototype._addCommon=function(e,t){if(e[Se.isTracked])t&&this.m_context._autoCleanup&&delete this._autoCleanupList[e._objectPath.objectPathInfo.Id];else{var n=e[Se.referenceId];if(e._objectPath.objectPathInfo[Se.objectPathInfoDoNotKeepReferenceFieldName])throw rt.createRuntimeError(g.generalException,P._getResourceString(et.objectIsUntracked),null);rt.isNullOrEmptyString(n)&&e._KeepReference&&(e._KeepReference(),ce.createInstantiateAction(this.m_context,e),t&&this.m_context._autoCleanup&&delete this._autoCleanupList[e._objectPath.objectPathInfo.Id],e[Se.isTracked]=!0)}},Qe.prototype.remove=function(e){var t=this;Array.isArray(e)?e.forEach(function(e){return t._removeCommon(e)}):this._removeCommon(e)},Qe.prototype._removeCommon=function(e){e._objectPath.objectPathInfo[Se.objectPathInfoDoNotKeepReferenceFieldName]=!0,e.context._pendingRequest._removeKeepReferenceAction(e._objectPath.objectPathInfo.Id);var t=e[Se.referenceId];if(!rt.isNullOrEmptyString(t)){var n=this.m_context._rootObject;n._RemoveReference&&n._RemoveReference(t)}delete e[Se.isTracked]},Qe.prototype._retrieveAndClearAutoCleanupList=function(){var e=this._autoCleanupList;return this._autoCleanupList={},e},Qe);function Qe(e){this._autoCleanupList={},this.m_context=e}y.TrackedObjects=Xe;var $e=(Ze.prototype.process=function(){this.m_showDispose&&Re._calculateLastUsedObjectPathIds(this.m_actions);for(var e=0;e<this.m_actions.length;e++)this.processOneAction(this.m_actions[e]);return this.m_statements},Ze.prototype.processForDebugStatementInfo=function(e){this.m_showDispose&&Re._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),!(0<=t&&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}},Ze.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)}},Ze.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}},Ze.prototype.processMethodAction=function(e){var t=e.actionInfo.Name;if("_KeepReference"===t){if(!y._internalConfig.showInternalApiInDebugInfo)return;t="track"}var n=this.getObjVarName(e.actionInfo.ObjectPathId)+"."+rt._toCamelLowerCase(t)+"("+this.buildArgumentsExpression(e.actionInfo.ArgumentInfo)+");";n=this.appendDisposeCommentIfRelevant(n,e),this.m_statements.push(n)},Ze.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)},Ze.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)},Ze.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)},Ze.prototype.processSetPropertyAction=function(e){var t=this.getObjVarName(e.actionInfo.ObjectPathId)+"."+rt._toCamelLowerCase(e.actionInfo.Name)+" = "+this.buildArgumentsExpression(e.actionInfo.ArgumentInfo)+";";t=this.appendDisposeCommentIfRelevant(t,e),this.m_statements.push(t)},Ze.prototype.processTraceAction=function(e){var t="context.trace();";t=this.appendDisposeCommentIfRelevant(t,e),this.m_statements.push(t)},Ze.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)},Ze.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)},Ze.prototype.appendDisposeCommentIfRelevant=function(e,t){var n=this;if(this.m_showDispose){var r=t.actionInfo.L;if(r&&0<r.length)return e+" // And then dispose {"+r.map(function(e){return n.getObjVarName(e)}).join(", ")+"}"}return e},Ze.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""},Ze.prototype.buildObjectPathExpressionWithParent=function(e){return 5!=e.objectPathInfo.ObjectPathType&&3!=e.objectPathInfo.ObjectPathType&&4!=e.objectPathInfo.ObjectPathType||!e.objectPathInfo.ParentObjectPathId?this.buildObjectPathExpression(e):this.getObjVarName(e.objectPathInfo.ParentObjectPathId)+"."+this.buildObjectPathExpression(e)},Ze.prototype.buildObjectPathExpression=function(e){var t=this.buildObjectPathInfoExpression(e.objectPathInfo),n=e.originalObjectPathInfo;return n&&(t=t+" /* originally "+this.buildObjectPathInfoExpression(n)+" */"),t},Ze.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 rt._toCamelLowerCase(e.Name)+"("+this.buildArgumentsExpression(e.ArgumentInfo)+")";case 2:return e.Name+".newObject()";case 7:return"null";case 4:return rt._toCamelLowerCase(e.Name);case 6:return"context."+this.m_globalObjName+"._getObjectByReferenceId("+JSON.stringify(e.Name)+")"}},Ze.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++)0<n&&(t+=", "),t+=this.buildArgumentLiteral(e.Arguments[n],e.ReferencedObjectPathIds?e.ReferencedObjectPathIds[n]:null);return"undefined"===t&&(t=""),t},Ze.prototype.buildArgumentLiteral=function(e,t){return"number"==typeof e&&e===t?this.getObjVarName(t):JSON.stringify(e)},Ze.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=rt._toCamelLowerCase(n.objectPathInfo.Name);break;case 3:var r=n.objectPathInfo.Name;3<r.length&&"Get"===r.substr(0,3)&&(r=r.substr(3)),t=rt._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},Ze.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},Ze);function Ze(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}var Ye,et=(__extends(tt,Ye=ee),tt.cannotRegisterEvent="CannotRegisterEvent",tt.connectionFailureWithStatus="ConnectionFailureWithStatus",tt.connectionFailureWithDetails="ConnectionFailureWithDetails",tt.propertyNotLoaded="PropertyNotLoaded",tt.runMustReturnPromise="RunMustReturnPromise",tt.moreInfoInnerError="MoreInfoInnerError",tt.cannotApplyPropertyThroughSetMethod="CannotApplyPropertyThroughSetMethod",tt.invalidOperationInCellEditMode="InvalidOperationInCellEditMode",tt.objectIsUntracked="ObjectIsUntracked",tt.customFunctionDefintionMissing="CustomFunctionDefintionMissing",tt.customFunctionImplementationMissing="CustomFunctionImplementationMissing",tt.customFunctionNameContainsBadChars="CustomFunctionNameContainsBadChars",tt.customFunctionNameCannotSplit="CustomFunctionNameCannotSplit",tt.customFunctionUnexpectedNumberOfEntriesInResultBatch="CustomFunctionUnexpectedNumberOfEntriesInResultBatch",tt.customFunctionCancellationHandlerMissing="CustomFunctionCancellationHandlerMissing",tt.customFunctionInvalidFunction="CustomFunctionInvalidFunction",tt.customFunctionInvalidFunctionMapping="CustomFunctionInvalidFunctionMapping",tt.customFunctionWindowMissing="CustomFunctionWindowMissing",tt.customFunctionDefintionMissingOnWindow="CustomFunctionDefintionMissingOnWindow",tt.pendingBatchInProgress="PendingBatchInProgress",tt.notInsideBatch="NotInsideBatch",tt.cannotUpdateReadOnlyProperty="CannotUpdateReadOnlyProperty",tt);function tt(){return null!==Ye&&Ye.apply(this,arguments)||this}y.ResourceStrings=et,P.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 nt,rt=(__extends(ot,nt=$),ot.fixObjectPathIfNecessary=function(e,t){e&&e._objectPath&&t&&e._objectPath.updateUsingObjectData(t,e)},ot.load=function(e,t){return e.context.load(e,t),e},ot.loadAndSync=function(e,t){return e.context.load(e,t),e.context.sync().then(function(){return e})},ot.retrieve=function(e,t){var n=y._internalConfig.alwaysPolyfillClientObjectRetrieveMethod;n=n||!ot.isSetSupported("RichApiRuntime","1.1");var r=new Oe(e,n);return e._retrieve(t,r),r},ot.retrieveAndSync=function(e,t){var n=ot.retrieve(e,t);return e.context.sync().then(function(){return n})},ot.toJson=function(e,t,n,r){var o={};for(var i in t)void 0!==(a=t[i])&&(o[i]=a);for(var i in n){var a;void 0!==(a=n[i])&&(a[ot.fieldName_isCollection]&&void 0!==a[ot.fieldName_m__items]?o[i]=a.toJSON().items:o[i]=a.toJSON())}return r&&(o.items=r.map(function(e){return e.toJSON()})),o},ot.throwError=function(e,t,n){throw new h.RuntimeError({code:e,httpStatusCode:400,message:P._getResourceString(e,t),debugInfo:n?{errorLocation:n}:void 0})},ot.createRuntimeError=function(e,t,n,r,o){return new h.RuntimeError({code:e,httpStatusCode:r,message:t,debugInfo:{errorLocation:n},data:o})},ot.throwIfNotLoaded=function(e,t,n,r){if(!r&&P.isUndefined(t)&&e.charCodeAt(0)!=ot.s_underscoreCharCode&&!ot.s_suppressPropertyNotLoadedException)throw ot.createPropertyNotLoadedException(n,e)},ot._getPropertyValueWithoutCheckLoaded=function(e,t){ot.s_suppressPropertyNotLoadedException=!0;try{return e[t]}finally{ot.s_suppressPropertyNotLoadedException=!1}},ot.createPropertyNotLoadedException=function(e,t){return new h.RuntimeError({code:re.propertyNotLoaded,httpStatusCode:400,message:P._getResourceString(et.propertyNotLoaded,t),debugInfo:e?{errorLocation:e+"."+t}:void 0})},ot.createCannotUpdateReadOnlyPropertyException=function(e,t){return new h.RuntimeError({code:re.cannotUpdateReadOnlyProperty,httpStatusCode:400,message:P._getResourceString(et.cannotUpdateReadOnlyProperty,t),debugInfo:e?{errorLocation:e+"."+t}:void 0})},ot.promisify=function(e){return new y.Promise(function(t,n){e(function(e){"failed"==e.status?n(e.error):t(e.value)})})},ot._addActionResultHandler=function(e,t,n){e.context._pendingRequest.addActionResultHandler(t,n)},ot._handleNavigationPropertyResults=function(e,t,n){for(var r=0;r<n.length-1;r+=2)P.isUndefined(t[n[r+1]])||e[n[r]]._handleResult(t[n[r+1]])},ot._fixupApiFlags=function(e){return"boolean"==typeof e&&(e=e?1:0),e},ot.definePropertyThrowUnloadedException=function(e,t,n){Object.defineProperty(e,n,{configurable:!0,enumerable:!0,get:function(){throw ot.createPropertyNotLoadedException(t,n)},set:function(){throw ot.createCannotUpdateReadOnlyPropertyException(t,n)}})},ot.defineReadOnlyPropertyWithValue=function(e,t,n){Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){return n},set:function(){throw ot.createCannotUpdateReadOnlyPropertyException(null,t)}})},ot.processRetrieveResult=function(e,t,n,r){if(!P.isNullOrUndefined(t))if(r){var o=t[Se.itemsLowerCase];if(Array.isArray(o)){for(var i=[],a=0;a<o.length;a++){var s=r(o[a],a),c={};(c[Se.proxy]=s)._handleRetrieveResult(o[a],c),i.push(c)}ot.defineReadOnlyPropertyWithValue(n,Se.itemsLowerCase,i)}}else{var l=e[Se.scalarPropertyNames],u=e[Se.navigationPropertyNames],p=e[Se.className];if(l)for(a=0;a<l.length;a++){var f=t[d=l[a]];P.isUndefined(f)?ot.definePropertyThrowUnloadedException(n,p,d):ot.defineReadOnlyPropertyWithValue(n,d,f)}if(u)for(a=0;a<u.length;a++){var d;if(f=t[d=u[a]],P.isUndefined(f))ot.definePropertyThrowUnloadedException(n,p,d);else{var h=e[d],g={};h._handleRetrieveResult(f,g),g[Se.proxy]=h,Array.isArray(g[Se.itemsLowerCase])&&(g=g[Se.itemsLowerCase]),ot.defineReadOnlyPropertyWithValue(n,d,g)}}}},ot.setMockData=function(e,t,n,r){if(P.isNullOrUndefined(t))e._handleResult(t);else{if(e[Se.scalarPropertyOriginalNames]){for(var o={},i=e[Se.scalarPropertyOriginalNames],a=e[Se.scalarPropertyNames],s=0;s<a.length;s++)void 0!==t[a[s]]&&(o[i[s]]=t[a[s]]);e._handleResult(o)}if(e[Se.navigationPropertyNames]){var c=e[Se.navigationPropertyNames];for(s=0;s<c.length;s++)if(void 0!==t[c[s]]){var l=e[c[s]];l.setMockData&&l.setMockData(t[c[s]])}}if(e[Se.isCollection]&&n){var u=Array.isArray(t)?t:t[Se.itemsLowerCase];if(Array.isArray(u)){var p=[];for(s=0;s<u.length;s++){var f=n(u,s);ot.setMockData(f,u[s]),p.push(f)}r(p)}}}},ot.applyMixin=function(t,n){Object.getOwnPropertyNames(n.prototype).forEach(function(e){"constructor"!==e&&Object.defineProperty(t.prototype,e,Object.getOwnPropertyDescriptor(n.prototype,e))})},ot.ensureTypeInitialized=function(e){var t=new be;new e(t,Ve.createNewObjectObjectPath(t,"Temp",!1,0))},ot.fieldName_m__items="m__items",ot.fieldName_isCollection="_isCollection",ot._synchronousCleanup=!1,ot.s_underscoreCharCode="_".charCodeAt(0),ot.s_suppressPropertyNotLoadedException=!1,ot);function ot(){return null!==nt&&nt.apply(this,arguments)||this}y.Utility=rt;var it=(at.invokeMethod=function(e,t,n,r,o,i){var a=ce.createMethodAction(e.context,e,t,n,r,o),s=new B(i);return rt._addActionResultHandler(e,a,s),s},at.invokeEnsureUnchanged=function(e,t){ce.createEnsureUnchangedAction(e.context,e,t)},at.invokeSetProperty=function(e,t,n,r){ce.createSetPropertyAction(e.context,e,t,n,r)},at.createRootServiceObject=function(e,t){return new e(t,Ve.createGlobalObjectObjectPath(t))},at.createObjectFromReferenceId=function(e,t,n){return new e(t,Ve.createReferenceIdObjectPath(t,n))},at.createTopLevelServiceObject=function(e,t,n,r,o){return new e(t,Ve.createNewObjectObjectPath(t,n,r,o))},at.createPropertyObject=function(e,t,n,r,o){var i=Ve.createPropertyObjectPath(t.context,t,n,r,!1,o);return new e(t.context,i)},at.createIndexerObject=function(e,t,n){var r=Ve.createIndexerObjectPath(t.context,t,n);return new e(t.context,r)},at.createMethodObject=function(e,t,n,r,o,i,a,s,c){var l=Ve.createMethodObjectPath(t.context,t,n,r,o,i,a,s,c);return new e(t.context,l)},at.createChildItemObject=function(e,t,n,r,o){var i=Ve.createChildItemObjectPathUsingIndexerOrGetItemAt(t,n.context,n,r,o);return new e(n.context,i)},at);function at(){}y.BatchApiHelper=it;var st=(ct.prototype.ensureArraySize=function(e,t){for(var n=t-e.length;0<n;)e.push(0),n--},ct.prototype.getString=function(e){return"number"==typeof e?0<e?this.m_strings[e-1]:null:e},ct.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},ct.prototype.buildClientObjectType=function(n,e){function t(e,t){pe.apply(this,arguments),r.m_targetNamespaceObject[n.name]._typeInited||(r.buildPrototype(r.m_targetNamespaceObject[n.name],n),r.m_targetNamespaceObject[n.name]._typeInited=!0),y._internalConfig.appendTypeNameToObjectPathInfo&&this._objectPath&&this._objectPath.objectPathInfo&&this._className&&(this._objectPath.objectPathInfo.T=this._className)}var r=this;this.m_targetNamespaceObject[n.name]=t,this.extendsType(t,pe),this.buildNewObject(t,n),0!=(2&n.behaviorFlags)&&(t.prototype._KeepReference=function(){it.invokeMethod(this,"_KeepReference",1,[],0,0)}),0!=(32&n.behaviorFlags)&&this.getFunction(ct.CustomizationCodeNamespace+"."+n.name+"_StaticCustomize").call(null,t),e&&(this.buildPrototype(t,n),t._typeInited=!0)},ct.prototype.extendsType=function(e,t){function n(){this.constructor=e}e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)},ct.prototype.findObjectUnderPath=function(e,t,n){for(var r=e,o=n;o<t.length;o++){if("object"!=typeof r)throw new y.Error("Cannot find "+t.join("."));r=r[t[o]]}return r},ct.prototype.getFunction=function(e){var t=this.resolveObjectByFullName(e);if("function"!=typeof t)throw new y.Error("Cannot find function or type: "+e);return t},ct.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)},ct.prototype.evaluateSimpleExpression=function(e,t){if(rt.isNullOrUndefined(e))return null;var n=e.split(".");if(3===n.length&&"OfficeExtension"===n[0]&&"Constants"===n[1])return Se[n[2]];if("this"!==n[0])throw new y.Error("Cannot evaluate: "+e);for(var r=t,o=1;o<n.length;o++)r="toString()"==n[o]?r.toString():"()"===n[o].substr(n[o].length-2)?r[n[o].substr(0,n[o].length-2)]():r[n[o]];return r},ct.prototype.evaluateEventTargetId=function(e,t){return rt.isNullOrEmptyString(e)?"":this.evaluateSimpleExpression(e,t)},ct.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},ct.prototype.evaluateEventType=function(e){if(rt.isNullOrEmptyString(e))return 0;if(this.isAllDigits(e))return parseInt(e);var t=this.resolveObjectByFullName(e);if("number"!=typeof t)throw new y.Error("Invalid event type: "+e);return t},ct.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)},ct.prototype.toSimpleCamelUpperCase=function(e){return e.substr(0,1).toUpperCase()+e.substr(1)},ct.prototype.ensureOriginalName=function(e){null===e.originalName&&(e.originalName=this.toSimpleCamelUpperCase(e.name))},ct.prototype.getFieldName=function(e){return"m_"+e.name},ct.prototype.throwIfApiNotSupported=function(e,t){if(this.m_apiSets&&0<t.apiSetInfoOrdinal){var n=this.m_apiSets[t.apiSetInfoOrdinal-1];n&&rt.throwIfApiNotSupported(e.name+"."+t.name,n.name,n.version,this.m_hostName)}},ct.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])}},ct.prototype.calculateApiFlags=function(e,t){if(0<t){var n=this.m_apiSets[t-1];n&&(e=$.calculateApiFlags(e,n.name,n.version))}return e},ct.prototype.buildScalarProperty=function(e,n,r){this.ensureOriginalName(r);var o=this,i=this.getFieldName(r),t={get:function(){return rt.throwIfNotLoaded(r.name,this[i],n.name,this._isNull),o.throwIfApiNotSupported(n,r),this[i]},enumerable:!0,configurable:!0};0==(2&r.behaviorFlags)&&(t.set=function(e){if(!(4&r.behaviorFlags&&o.getFunction(ct.CustomizationCodeNamespace+"."+n.name+"_"+r.originalName+"_Set").call(this,this,e).handled)){this[i]=e;var t=o.calculateApiFlags(r.setMethodApiFlags,r.undoableApiSetInfoOrdinal);it.invokeSetProperty(this,r.originalName,e,t)}}),Object.defineProperty(e.prototype,r.name,t)},ct.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])}},ct.prototype.buildNavigationProperty=function(e,n,r){this.ensureOriginalName(r);var o=this,i=this.getFieldName(r),t={get:function(){return this[o.getFieldName(r)]||(o.throwIfApiNotSupported(n,r),this[i]=it.createPropertyObject(o.getFunction(r.propertyTypeFullName),this,r.originalName,0!=(16&r.behaviorFlags),r.getMethodApiFlags)),64&r.behaviorFlags&&o.getFunction(ct.CustomizationCodeNamespace+"."+n.name+"_"+r.originalName+"_Get").call(this,this,this[i]),this[i]},enumerable:!0,configurable:!0};0==(2&r.behaviorFlags)&&(t.set=function(e){if(!(4&r.behaviorFlags&&o.getFunction(ct.CustomizationCodeNamespace+"."+n.name+"_"+r.originalName+"_Set").call(this,this,e).handled)){this[i]=e;var t=o.calculateApiFlags(r.setMethodApiFlags,r.undoableApiSetInfoOrdinal);it.invokeSetProperty(this,r.originalName,e,t)}}),Object.defineProperty(e.prototype,r.name,t)},ct.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])}},ct.prototype.buildScalarMethod=function(e,p,f){this.ensureOriginalName(f);var d=this;e.prototype[f.name]=function(){var e=[];if(64&f.behaviorFlags&&0<f.parameterCount){for(var t=0;t<f.parameterCount-1;t++)e.push(arguments[t]);var n=[];for(t=f.parameterCount-1;t<arguments.length;t++)n.push(arguments[t]);e.push(n)}else for(t=0;t<arguments.length;t++)e.push(arguments[t]);if(1&f.behaviorFlags){var r=d.getFunction(ct.CustomizationCodeNamespace+"."+p.name+"_"+f.originalName),o=[this];for(t=0;t<e.length;t++)o.push(e[t]);var i=r.apply(this,o),a=i.handled,s=i.result;if(a)return s}d.throwIfApiNotSupported(p,f);var c=0;32&f.behaviorFlags&&(c=1);var l=0;2&f.behaviorFlags&&(l=1);var u=d.calculateApiFlags(f.apiFlags,f.undoableApiSetInfoOrdinal);return it.invokeMethod(this,f.originalName,l,e,u,c)}},ct.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])}},ct.prototype.buildNavigationMethod=function(e,u,p){this.ensureOriginalName(p);var f=this;e.prototype[p.name]=function(){var e=[];if(64&p.behaviorFlags&&0<p.parameterCount){for(var t=0;t<p.parameterCount-1;t++)e.push(arguments[t]);var n=[];for(t=p.parameterCount-1;t<arguments.length;t++)n.push(arguments[t]);e.push(n)}else for(t=0;t<arguments.length;t++)e.push(arguments[t]);if(1&p.behaviorFlags){var r=f.getFunction(ct.CustomizationCodeNamespace+"."+u.name+"_"+p.originalName),o=[this];for(t=0;t<e.length;t++)o.push(e[t]);var i=r.apply(this,o),a=i.handled,s=i.result;if(a)return s}if(f.throwIfApiNotSupported(u,p),0!=(16&p.behaviorFlags))return it.createIndexerObject(f.getFunction(p.returnTypeFullName),this,e);var c=0;2&p.behaviorFlags&&(c=1);var l=f.calculateApiFlags(p.apiFlags,p.undoableApiSetInfoOrdinal);return it.createMethodObject(f.getFunction(p.returnTypeFullName),this,p.originalName,c,e,0!=(4&p.behaviorFlags),0!=(8&p.behaviorFlags),p.returnObjectGetByIdMethodName,l)}},ct.prototype.buildHandleResult=function(e,l){var u=this;e.prototype._handleResult=function(e){if(pe.prototype._handleResult.call(this,e),!rt.isNullOrUndefined(e)){if(rt.fixObjectPathIfNecessary(this,e),8&l.behaviorFlags&&u.getFunction(ct.CustomizationCodeNamespace+"."+l.name+"_HandleResult").call(this,this,e),l.scalarProperties)for(var t=0;t<l.scalarProperties.length;t++)rt.isUndefined(e[l.scalarProperties[t].originalName])||(0!=(8&l.scalarProperties[t].behaviorFlags)?this[u.getFieldName(l.scalarProperties[t])]=rt.adjustToDateTime(e[l.scalarProperties[t].originalName]):this[u.getFieldName(l.scalarProperties[t])]=e[l.scalarProperties[t].originalName]);if(l.navigationProperties){for(var n=[],r=0;r<l.navigationProperties.length;r++)n.push(l.navigationProperties[r].name),n.push(l.navigationProperties[r].originalName);rt._handleNavigationPropertyResults(this,e,n)}if(0!=(1&l.behaviorFlags)){var o=u.hasIndexMethod(l);if(!rt.isNullOrUndefined(e[Se.items])){this.m__items=[];for(var i=e[Se.items],a=u.getFunction(l.childItemTypeFullName),s=0;s<i.length;s++){var c=it.createChildItemObject(a,o,this,i[s],s);c._handleResult(i[s]),this.m__items.push(c)}}}}}},ct.prototype.buildHandleRetrieveResult=function(e,a){var s=this;e.prototype._handleRetrieveResult=function(e,t){if(pe.prototype._handleRetrieveResult.call(this,e,t),!rt.isNullOrUndefined(e)){if(a.scalarProperties)for(var n=0;n<a.scalarProperties.length;n++)8&a.scalarProperties[n].behaviorFlags&&(rt.isNullOrUndefined(e[a.scalarProperties[n].name])||(e[a.scalarProperties[n].name]=rt.adjustToDateTime(e[a.scalarProperties[n].name])));if(1&a.behaviorFlags){var r=s.hasIndexMethod(a),o=s.getFunction(a.childItemTypeFullName),i=this;rt.processRetrieveResult(i,e,t,function(e,t){return it.createChildItemObject(o,r,i,e,t)})}else rt.processRetrieveResult(this,e,t)}}},ct.prototype.buildHandleIdResult=function(e,r){var o=this;e.prototype._handleIdResult=function(e){if(pe.prototype._handleIdResult.call(this,e),!rt.isNullOrUndefined(e)&&(16&r.behaviorFlags&&o.getFunction(ct.CustomizationCodeNamespace+"."+r.name+"_HandleIdResult").call(this,this,e),r.scalarProperties))for(var t=0;t<r.scalarProperties.length;t++){var n=r.scalarProperties[t].originalName;"Id"!==n&&"_Id"!==n&&"_ReferenceId"!==n||rt.isNullOrUndefined(e[r.scalarProperties[t].originalName])||(this[o.getFieldName(r.scalarProperties[t])]=e[r.scalarProperties[t].originalName])}}},ct.prototype.buildLoad=function(e,t){e.prototype.load=function(e){return rt.load(this,e)}},ct.prototype.buildRetrieve=function(e,t){e.prototype.retrieve=function(e){return rt.retrieve(this,e)}},ct.prototype.buildNewObject=function(t,n){rt.isNullOrEmptyString(n.newObjectServerTypeFullName)||(t.newObject=function(e){return it.createTopLevelServiceObject(t,e,n.newObjectServerTypeFullName,0!=(1&n.behaviorFlags),n.newObjectApiFlags)})},ct.prototype.buildSetMockData=function(e,r){var o=this;if(1&r.behaviorFlags){var i=o.hasIndexMethod(r);e.prototype.setMockData=function(e){var n=this;rt.setMockData(n,e,function(e,t){return it.createChildItemObject(o.getFunction(r.childItemTypeFullName),i,n,e,t)},function(e){n.m__items=e})}}else e.prototype.setMockData=function(e){rt.setMockData(this,e)}},ct.prototype.buildEnsureUnchanged=function(e,t){e.prototype.ensureUnchanged=function(e){it.invokeEnsureUnchanged(this,e)}},ct.prototype.buildUpdate=function(e,t){e.prototype.update=function(e){this._recursivelyUpdate(e)}},ct.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)})}},ct.prototype.buildItems=function(e,t){0!=(1&t.behaviorFlags)&&Object.defineProperty(e.prototype,"items",{get:function(){return rt.throwIfNotLoaded("items",this.m__items,t.name,this._isNull),this.m__items},enumerable:!0,configurable:!0})},ct.prototype.buildToJSON=function(e,r){var o=this;0==(1&r.behaviorFlags)?e.prototype.toJSON=function(){var e={};if(r.scalarProperties)for(var t=0;t<r.scalarProperties.length;t++)0!=(1&r.scalarProperties[t].behaviorFlags)&&(e[r.scalarProperties[t].name]=this[o.getFieldName(r.scalarProperties[t])]);var n={};if(r.navigationProperties)for(t=0;t<r.navigationProperties.length;t++)0!=(1&r.navigationProperties[t].behaviorFlags)&&(n[r.navigationProperties[t].name]=this[o.getFieldName(r.navigationProperties[t])]);return rt.toJson(this,e,n)}:e.prototype.toJSON=function(){return rt.toJson(this,{},{},this.m__items)}},ct.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}),rt.isNullOrEmptyString(t.collectionPropertyPath)||Object.defineProperty(e.prototype,"_collectionPropertyPath",{get:function(){return t.collectionPropertyPath},enumerable:!0,configurable:!0}),t.scalarProperties&&0<t.scalarProperties.length&&(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&&0<t.navigationProperties.length&&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})},ct.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})},ct.prototype.buildMixin=function(e,t){if(4&t.behaviorFlags){var n=this.getFunction(t.name+"Custom");rt.applyMixin(e,n)}},ct.prototype.getOnEventName=function(e){return"_"===e[0]?"_on"+e.substr(1):"on"+e},ct.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])}},ct.prototype.buildEvent=function(e,t,n){1&n.behaviorFlags?this.buildV0Event(e,t,n):this.buildV2Event(e,t,n)},ct.prototype.buildV2Event=function(e,i,a){var s=this,t=this.getOnEventName(a.name),c=this.getFieldName(a);Object.defineProperty(e.prototype,t,{get:function(){if(!this[c]){s.throwIfApiNotSupported(i,a);var t=this,e=null;"null"!==a.register&&(e=this[a.register].bind(this));var n=null;"null"!==a.unregister&&(n=this[a.unregister].bind(this));var r=null;2&a.behaviorFlags&&(r=s.getFunction(ct.CustomizationCodeNamespace+"."+i.name+"_"+a.name+"_EventArgsTransform"));var o=s.evaluateEventType(a.typeExpression);this[c]=new Be(this.context,this,a.name,{eventType:o,getTargetIdFunc:function(){return s.evaluateEventTargetId(a.targetIdExpression,t)},registerFunc:e,unregisterFunc:n,eventArgsTransformFunc:function(e){return r&&(e=r.call(t,t,e)),rt._createPromiseFromResult(e)}})}return this[c]},enumerable:!0,configurable:!0})},ct.prototype.buildV0Event=function(e,c,l){var u=this,t=this.getOnEventName(l.name),p=this.getFieldName(l);Object.defineProperty(e.prototype,t,{get:function(){if(!this[p]){u.throwIfApiNotSupported(c,l);var n=this,e=null;if(rt.isNullOrEmptyString(l.register)){var r=u.evaluateEventType(l.typeExpression);e=function(e){var t=u.evaluateEventTargetId(l.targetIdExpression,n);return n.context.eventRegistration.register(r,t,e)}}else if("null"!==l.register){var t=u.getFunction(l.register);e=function(e){return t.call(n,n,e)}}var o=null;if(rt.isNullOrEmptyString(l.unregister)){var i=u.evaluateEventType(l.typeExpression);o=function(e){var t=u.evaluateEventTargetId(l.targetIdExpression,n);return n.context.eventRegistration.unregister(i,t,e)}}else if("null"!==l.unregister){var a=u.getFunction(l.unregister);o=function(e){return a.call(n,n,e)}}var s=null;2&l.behaviorFlags&&(s=u.getFunction(ct.CustomizationCodeNamespace+"."+c.name+"_"+l.name+"_EventArgsTransform")),this[p]=new Ee(this.context,this,l.name,{registerFunc:e,unregisterFunc:o,eventArgsTransformFunc:function(e){return s&&(e=s.call(n,n,e)),rt._createPromiseFromResult(e)}})}return this[p]},enumerable:!0,configurable:!0})},ct.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},ct.CustomizationCodeNamespace="_CC",ct);function ct(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)}}y.LibraryBuilder=st}(OfficeExtension=OfficeExtension||{}),function(e){var t;(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")},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 r(e,t,n,r){return{name:e,dataType:t,value:n,classification:r||4}}e.makeBooleanDataField=function(e,t,n){return r(e,1,t,n)},e.makeInt64DataField=function(e,t,n){return r(e,2,t,n)},e.makeDoubleDataField=function(e,t,n){return r(e,3,t,n)},e.makeStringDataField=function(e,t,n){return r(e,0,t,n)},e.makeGuidDataField=function(e,t,n){return r(e,4,t,n)}}(oteljs=oteljs||{}),function(e){var t,n,r,o,i,a,s,c,l,u,p,f,d;(t=e.DataClassification||(e.DataClassification={}))[t.EssentialServiceMetadata=1]="EssentialServiceMetadata",t[t.AccountData=2]="AccountData",t[t.SystemMetadata=4]="SystemMetadata",t[t.OrganizationIdentifiableInformation=8]="OrganizationIdentifiableInformation",t[t.EndUserIdentifiableInformation=16]="EndUserIdentifiableInformation",t[t.CustomerContent=32]="CustomerContent",t[t.AccessControl=64]="AccessControl",t[t.PublicNonPersonalData=128]="PublicNonPersonalData",t[t.EndUserPseudonymousInformation=256]="EndUserPseudonymousInformation",t[t.PublicPersonalData=512]="PublicPersonalData",t[t.SupportData=1024]="SupportData",t[t.DirectMeasurementData=2048]="DirectMeasurementData",t[t.Everything=65535]="Everything",(n=e.DataFieldType||(e.DataFieldType={}))[n.String=0]="String",n[n.Boolean=1]="Boolean",n[n.Int64=2]="Int64",n[n.Double=3]="Double",n[n.Guid=4]="Guid",(r=e.SamplingPolicy||(e.SamplingPolicy={}))[r.NotSet=0]="NotSet",r[r.Measure=1]="Measure",r[r.Diagnostics=2]="Diagnostics",r[r.CriticalBusinessImpact=191]="CriticalBusinessImpact",r[r.CriticalCensus=192]="CriticalCensus",r[r.CriticalExperimentation=193]="CriticalExperimentation",r[r.CriticalUsage=194]="CriticalUsage",(o=e.PersistencePriority||(e.PersistencePriority={}))[o.NotSet=0]="NotSet",o[o.Normal=1]="Normal",o[o.High=2]="High",(i=e.CostPriority||(e.CostPriority={}))[i.NotSet=0]="NotSet",i[i.Normal=1]="Normal",i[i.High=2]="High",(a=e.DataCategories||(e.DataCategories={}))[a.NotSet=0]="NotSet",a[a.SoftwareSetup=1]="SoftwareSetup",a[a.ProductServiceUsage=2]="ProductServiceUsage",a[a.ProductServicePerformance=4]="ProductServicePerformance",a[a.DeviceConfiguration=8]="DeviceConfiguration",a[a.InkingTypingSpeech=16]="InkingTypingSpeech",(s=e.DiagnosticLevel||(e.DiagnosticLevel={}))[s.ReservedDoNotUse=0]="ReservedDoNotUse",s[s.Required=10]="Required",s[s.BasicEvent=10]="BasicEvent",s[s.Optional=100]="Optional",s[s.FullEvent=100]="FullEvent",s[s.RequiredServiceData=110]="RequiredServiceData",s[s.NecessaryServiceDataEvent=110]="NecessaryServiceDataEvent",s[s.RequiredServiceDataForEssentialServices=120]="RequiredServiceDataForEssentialServices",s[s.AlwaysOnNecessaryServiceDataEvent=120]="AlwaysOnNecessaryServiceDataEvent",(c=e.CustomerContentType||(e.CustomerContentType={}))[c.None=0]="None",c[c.MocaAddIn=1]="MocaAddIn",(l=e.LogLevel||(e.LogLevel={}))[l.Error=0]="Error",l[l.Warning=1]="Warning",l[l.Info=2]="Info",l[l.Verbose=3]="Verbose",(u=e.Category||(e.Category={}))[u.Core=0]="Core",u[u.Sink=1]="Sink",u[u.Transport=2]="Transport",(p=e.DnmInterval||(e.DnmInterval={}))[p.Hourly=1]="Hourly",p[p.Daily=2]="Daily",(f=e.AllowedPartA||(e.AllowedPartA={}))[f.ReleaseAudienceGroup=1]="ReleaseAudienceGroup",f[f.WacRing=2]="WacRing",f[f.AppName=3]="AppName",f[f.AppPlatform=4]="AppPlatform",f[f.AppVersion=5]="AppVersion",(d=e.EventType||(e.EventType={}))[d.SendTelemetryEvent=1]="SendTelemetryEvent",d[d.CustomerContent=2]="CustomerContent",d[d.DirectNumericEvent=3]="DirectNumericEvent"}(oteljs=oteljs||{}),function(n){n.getEffectiveEventFlags=function(e){var t={costPriority:1,samplingPolicy:1,persistencePriority:1,dataCategories:0,diagnosticLevel:100};return e.eventFlags&&e.eventFlags.dataCategories||n.logNotification(0,0,function(){return"DataCategories"}),e.eventFlags&&(e.eventFlags.costPriority&&(t.costPriority=e.eventFlags.costPriority),e.eventFlags.samplingPolicy&&(t.samplingPolicy=e.eventFlags.samplingPolicy),e.eventFlags.persistencePriority&&(t.persistencePriority=e.eventFlags.persistencePriority),e.eventFlags.dataCategories&&(t.dataCategories=e.eventFlags.dataCategories),e.eventFlags.diagnosticLevel&&(t.diagnosticLevel=e.eventFlags.diagnosticLevel)),t}}(oteljs=oteljs||{}),function(e){var n,r=(n=[],{fireEvent:function(t){n.forEach(function(e){return e(t)})},addListener:function(e){e&&n.push(e)}});function o(e,t,n){r.fireEvent({level:e,category:t,message:n})}e.onNotification=function(){return r},e.logNotification=o,e.logError=function(e,t,n){o(0,e,function(){var e=n instanceof Error?n.message:"";return"".concat(t,": ").concat(e)})}}(oteljs=oteljs||{}),function(a){var e,t;function o(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}(t=e=e||{})[t.TelemetryData=0]="TelemetryData",t[t.AnonymousData=1]="AnonymousData",t[t.CustomerContent=2]="CustomerContent",a.SuppressNexus=-1,a.cloneEvent=o;var n=(r.prototype.addEventContentType=function(e,t){e.push(a.makeInt64DataField("EventContent.Type",t))},r.prototype.sendTelemetryEvent=function(e){var t=o(e),n=t.telemetryProperties;n.nexusTenantToken=a.SuppressNexus;var r=n.ariaTenantToken;r||a.fillTenantTokens(t.eventName,n)||r?this.sendTelemetryEventInternal(t,1):a.logNotification(0,0,function(){return"No tenant token: "+e.eventName})},r.prototype.sendNonStandardEvent=function(e,t){var n=o(e);this.sendTelemetryEventInternal(n,t)},r.prototype.sendCustomerContent=function(e){var t=o(e),n=t.telemetryProperties,r=n.customerContentVersion;return(!r||2<r)&&(n.customerContentVersion=2),n.ariaTenantToken=void 0,n.nexusTenantToken=void 0,n.dnmToken=void 0,this.addEventContentType(t.dataFields,2),this.sendTelemetryEventInternal(t,2)},r.prototype.sendDirectNumericEvent=function(e){var t=o(e),n=t.telemetryProperties;n.dnmToken||a.fillTenantTokens(t.eventName,n)||n.dnmToken?(this.addEventContentType(t.dataFields,1),this.sendTelemetryEventInternal(t,3)):a.logNotification(0,0,function(){return"No dnm token: "+t.eventName})},r.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]):a.logNotification(1,0,function(){return"No telemetry sinks are attached."}));this.processTelemetryEvent(t,n)}catch(e){return void a.logError(0,"SendTelemetryEvent",e)}this.telemetrySinks.forEach(function(e){try{3===n||2===n?e.sendNonStandardEvent&&e.sendNonStandardEvent(t,n):e.sendTelemetryEvent(t)}catch(e){}})}else a.logNotification(0,0,function(){return"Customer content"})},r.prototype.processTelemetryEvent=function(e,t){var n,r,o;if(e.dataFields&&(null!==(o=e.dataFields)&&void 0!==o&&o.unshift(a.makeStringDataField("OTelJS.Version",a.oteljsVersion)),3!==t&&this.persistentDataFields&&(n=e.dataFields).unshift.apply(n,this.persistentDataFields)),0<this.partAFields.length){var i=e.eventContract||{name:"",dataFields:[]};(r=i.dataFields).push.apply(r,this.partAFields),e.eventContract=i}this.config.disableValidation||a.validateTelemetryEvent(e)},r.prototype.addSink=function(e){this.telemetrySinks.push(e),this.flushQueue()},r.prototype.flushQueue=function(){var e=this.eventQueue;if(this.eventQueue=[],0<this.telemetrySinks.length)for(var t=0,n=e;t<n.length;t++){var r=n[t],o=r[0],i=r[1];this.sendTelemetryEventInternal(o,i)}},r.prototype.setTenantToken=function(e,t,n){a.setTenantTokens(e,{ariaTenantToken:t,nexusTenantToken:n})},r.prototype.setDNMToken=function(e,t){a.setTenantTokens(e,{dnmToken:t})},r.prototype.cloneEvent=function(e){return o(e)},r.prototype.getConfig=function(){return this.config},r);function r(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)}a.SimpleTelemetryLogger=n}(oteljs=oteljs||{}),function(e){var t=9007199254740991,n=-t,r=98,o=/^Office(\.[A-Z][a-zA-Z0-9]*){2,}$/,i=/^[a-zA-Z0-9_\.]{1,95}$/;function a(e){return i.test(e)}function s(e){e&&e.forEach(function(e){if("string"!=typeof e.name||!a(e.name))throw new Error("Invalid dataField name");2===e.dataType&&c(e.value)})}function c(e){if("number"!=typeof e||!isFinite(e)||Math.floor(e)!==e||e<n||t<e)throw new Error("Invalid integer ".concat(JSON.stringify(e)))}e.validateTelemetryEvent=function(e){if(!function(e){if(!e||e.length>r)return;return o.test(e)}(e.eventName))throw new Error("Invalid eventName");var t=e.eventContract;if(t){if(t.name&&!a(t.name))throw new Error("Invalid eventContract");s(t.dataFields)}s(e.dataFields)},e.validateInt=c}(oteljs=oteljs||{}),function(n){var i={};n.setTenantTokens=function(e,t){"Office."===e.substring(0,7)&&"."!==e[e.length-1]?i[e]?(t.ariaTenantToken&&(i[e].ariaTenantToken=t.ariaTenantToken),t.dnmToken&&(i[e].dnmToken=t.dnmToken)):i[e]=t:n.logNotification(0,0,function(){return"Namespace: ".concat(e)})},n.fillTenantTokens=function(e,t){for(var n=e.length;0<n;){var r=e.substr(0,n);if(i[r]){var o=i[r];return t.ariaTenantToken=o.ariaTenantToken,t.dnmToken=o.dnmToken,!0}n=e.lastIndexOf(".",n-1)}return!1},n.clear=function(){i={}}}(oteljs=oteljs||{}),(oteljs||(oteljs={})).oteljsVersion="4.18.0",function(a){var e=(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(e){a.logError(1,"RichApiSink Error",e),t.waitAndProcessMore()}))},t.prototype.waitAndProcessMore=function(){var e=this;this.pause(1e3).then(function(){e._requestIsPending=!1,0<e._telemetryQueue.length&&setTimeout(function(){return e.processWorkBacklog()},0)}).catch(function(){e._requestIsPending=!1})},t.prototype.processTelemetryEvents=function(){var o=this,e=this._telemetryQueue;this._telemetryQueue=[];var t=this._customerContentQueue;function n(e,t){if(e.telemetryProperties){var n=[];o.addDataFields(n,e.dataFields);var r=e.eventContract?e.eventContract.name:"";e.eventContract&&o.addDataFields(n,e.eventContract.dataFields),t(e.telemetryProperties,e.eventName,r,a.getEffectiveEventFlags(e),n)}}this._customerContentQueue=[];var i=new OfficeCore.RequestContext;return e.forEach(function(e){n(e,function(e,t,n,r,o){i.telemetry.sendTelemetryEvent(e,t,n,r,o)})}),t.forEach(function(e){n(e,function(e,t,n,r,o){i.telemetry.sendCustomerContent(e,t,n,r,o)})}),i.sync().catch(function(e){a.logError(1,"RichApi telemetry failed.",e)})},t.prototype.addDataFields=function(t,e){e&&e.forEach(function(e){t.push({name:e.name,value:e.value,classification:e.classification?e.classification:4,type:4===e.dataType?0:e.dataType})})},t.prototype.pause=function(t){return new Office.Promise(function(e){return setTimeout(e,t)})},t);function t(){var e=this;this._requestIsPending=!0,this._telemetryQueue=[],this._customerContentQueue=[],this.pause(1e3).then(function(){return e._requestIsPending=!1,e.processTelemetryEvents()}).catch()}a.RichApiSink=e}(oteljs=oteljs||{}),function(r){var e,t,n;e=r.Contracts||(r.Contracts={}),t=e.Office||(e.Office={}),((n=t.System||(t.System={})).SDX||(n.SDX={})).getFields=function(e,t){var n=[];return void 0!==t.id&&n.push(r.makeStringDataField("".concat(e,".Id"),t.id)),void 0!==t.version&&n.push(r.makeStringDataField("".concat(e,".Version"),t.version)),void 0!==t.instanceId&&n.push(r.makeStringDataField("".concat(e,".InstanceId"),t.instanceId)),void 0!==t.name&&n.push(r.makeStringDataField("".concat(e,".Name"),t.name)),void 0!==t.marketplaceType&&n.push(r.makeStringDataField("".concat(e,".MarketplaceType"),t.marketplaceType)),void 0!==t.sessionId&&n.push(r.makeStringDataField("".concat(e,".SessionId"),t.sessionId)),void 0!==t.browserToken&&n.push(r.makeStringDataField("".concat(e,".BrowserToken"),t.browserToken)),void 0!==t.osfRuntimeVersion&&n.push(r.makeStringDataField("".concat(e,".OsfRuntimeVersion"),t.osfRuntimeVersion)),void 0!==t.officeJsVersion&&n.push(r.makeStringDataField("".concat(e,".OfficeJsVersion"),t.officeJsVersion)),void 0!==t.hostJsVersion&&n.push(r.makeStringDataField("".concat(e,".HostJsVersion"),t.hostJsVersion)),void 0!==t.assetId&&n.push(r.makeStringDataField("".concat(e,".AssetId"),t.assetId)),void 0!==t.providerName&&n.push(r.makeStringDataField("".concat(e,".ProviderName"),t.providerName)),void 0!==t.type&&n.push(r.makeStringDataField("".concat(e,".Type"),t.type)),n}}(oteljs=oteljs||{}),function(o){var e=(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(e,t){try{if(e.dataFields&&0<e.dataFields.filter(function(e){var t=e.classification;return t&&4!==t&&1!==t}).length)return;var n=OSF._OfficeAppFactory.getId(),r=OSF.AgaveHostAction.SendTelemetryEvent;OSF.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n,r,e])}catch(e){o.logError(1,"AgaveWacSink",e)}},t.prototype.sendCustomerContent=function(e,t){try{if(e.dataFields&&0<e.dataFields.filter(function(e){var t=e.classification;return t&&4!==t&&1!==t&&32!==t}).length)return;var n=OSF._OfficeAppFactory.getId(),r=OSF.AgaveHostAction.SendCustomerContent;OSF.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[n,r,e])}catch(e){o.logError(1,"AgaveWacSink",e)}},t);function t(){}o.SdxWacSink=e}(oteljs=oteljs||{}),function(e){var t;function n(){try{if(void 0!==OSF&&void 0!==OSF.isOfficeReactNative&&OSF.isOfficeReactNative())return 1}catch(e){}}function r(){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}(t=e.ApiHelper||(e.ApiHelper={})).isNativeStorage=function(){var e=r();return!(function(){try{if(void 0!==OSF&&void 0!==OSF._OfficeAppFactory&&void 0!==OSF._OfficeAppFactory.getHostInfo)if(OSF._OfficeAppFactory.getHostInfo().flags&OSF.HostInfoFlags.SharedApp)return 1}catch(e){}}()||!(n()||"win32"===e||"mac"===e&&window._useSDXSandbox))},t.isNativeApiInfomation=function(){var e=r();return!!(n()||"win32"===e||"mac"===e&&window._useSDXSandbox)},t.isNativeDialog=function(){var e=r();return!(!n()&&"win32"!==e)}}(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,r=Object.keys(n).map(function(e){return e.toLowerCase()}).indexOf(e.toLowerCase());if(-1<r){var o=n[Object.keys(n)[r]];try{var i=s(t),a=void 0;if(0<(a=Array.isArray(o)?function(e,t){for(var n=0;n<e.length;n++){var r=s(e[n]);if(r.major==t)return r}return{major:0,minor:0,patch:0}}(o,i.major):s(o)).major){if(a.major>i.major)return!0;if(a.major==i.major&&a.minor>i.minor)return!0;if(a.major==i.major&&a.minor==i.minor&&a.patch>=i.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 s(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]),2<=t.length&&(r=Number(t[1])),3<=t.length&&(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 r=function(e,t){return(r=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])})(e,t)};return function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}}();!function(i){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject;function e(e){this._dialogService=e}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),a=OfficeExtension.Utility.fixObjectPathIfNecessary,s=(OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult);OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags;i.Dialog=e;var c,l=(__extends(u,c=e),u.prototype.close=function(){return this._dialogService.close(),OfficeExtension.CoreUtility.Promise.resolve()},u);function u(){return null!==c&&c.apply(this,arguments)||this}var p,f=(__extends(d,p=e),d.prototype.close=function(){return this._dialogService.close(),this._dialogService.context.sync()},d);function d(){return null!==p&&p.apply(this,arguments)||this}function h(e){return/^(\-|\+)?([0-9]+)%?$/.test(e)}function g(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}}i.displayWebDialog=function(r,o){return void 0===o&&(o={}),new OfficeExtension.CoreUtility.Promise(function(e,t){if(o.width&&o.height&&(!h(o.width)||!h(o.height)))throw new OfficeExtension.Error({code:"InvalidArgument",message:'Dimensions must be "number%" or number.'});var n={width:o.width?parseInt(o.width):50,height:o.height?parseInt(o.height):50,displayInIFrame:o.displayInIFrame};(i.ApiHelper.isNativeDialog()?function(e,t,n,r,o){void 0===o&&(o={});var i=new OfficeExtension.ClientRequestContext,a=b.newObject(i),s=new f(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)})}:function(e,t,n,r,o){void 0===o&&(o={});var i;function a(e){o.onMessage&&o.onMessage(e.message,i,e.origin)}function s(e){12006===e.error?o.onClose&&o.onClose():o.onRuntimeError&&o.onRuntimeError(new OfficeExtension.Error(g(e.error)),i)}Office.context.ui.displayDialogAsync(r,e,function(e){"failed"===e.status?n(new OfficeExtension.Error(g(e.error.code))):((i=e.value).addEventHandler(Office.EventType.DialogMessageReceived,a),i.addEventHandler(Office.EventType.DialogEventReceived,s),t(new l(i)))})})(n,e,t,r,o)})};var m,y,_,b=(m=OfficeExtension.ClientObject,__extends(v,m),Object.defineProperty(v.prototype,"_className",{get:function(){return"DialogService"},enumerable:!0,configurable:!0}),v.prototype.close=function(){n(this,"Close",1,[],4,0)},v.prototype.displayDialog=function(e,t){n(this,"DisplayDialog",1,[e,t],4,0)},v.prototype._handleResult=function(e){m.prototype._handleResult.call(this,e),r(e)||a(this,e)},v.prototype._handleRetrieveResult=function(e,t){m.prototype._handleRetrieveResult.call(this,e,t),s(this,e,t)},v.newObject=function(e){return t(i.DialogService,e,"Microsoft.Dialog.DialogService",!1,4)},Object.defineProperty(v.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(g(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}),v.prototype.toJSON=function(){return o(this,{},{})},v);function v(){return null!==m&&m.apply(this,arguments)||this}i.DialogService=b,(_=y=y||{})[_.dialogMessageReceived=0]="dialogMessageReceived",_[_.dialogEventReceived=1]="dialogEventReceived",(i.DialogErrorCodes||(i.DialogErrorCodes={})).generalException="GeneralException"}(OfficeRuntime=OfficeRuntime||{}),function(e){var t;function n(e,t){try{var n=Microsoft.Office.WebExtension.FeatureGates[e];return null==n?t:"true"===n.toString().toLowerCase()}catch(e){return t}}function r(e,t){try{var n=Microsoft.Office.WebExtension.FeatureGates,r=parseInt(n[e]);return isNaN(r)?t:r}catch(e){return t}}function o(e,t){try{var n=Microsoft.Office.WebExtension.FeatureGates[e];return null==n?t:n}catch(e){return t}}(t=e.experimentation||(e.experimentation={})).getBooleanFeatureGate=n,t.getIntFeatureGate=r,t.getStringFeatureGate=o,t.getBooleanFeatureGateAsync=function(e,t){return Promise.resolve(n(e,t))},t.getIntFeatureGateAsync=function(e,t){return Promise.resolve(r(e,t))},t.getStringFeatureGateAsync=function(e,t){return Promise.resolve(o(e,t))}}(OfficeRuntime=OfficeRuntime||{}),function(e){var t,o;t=e.message||(e.message={}),o={},t.on=function(e,t){return function(e,t){o.hasOwnProperty(e)||(o[e]=new n,function(){Office&&Office.context&&Office.context.messaging&&!Office.context.messaging.onMessage&&(Office.context.messaging.onMessage=function(e){var t=e.eventName,n=e.message;o.hasOwnProperty(t)&&o[t].call(n)}.bind(this))}());o[e].add(t)}(e,t),new Promise(function(e){e()})},t.off=function(e,t){var n,r;return n=e,r=t,o.hasOwnProperty(n)&&(r?o[n].remove(r):delete o[n]),new Promise(function(e){e()})},t.emit=function(e,t){var n;return n={eventName:e,message:t},Office&&Office.context&&Office.context.messaging&&Office.context.messaging.sendMessage&&Office.context.messaging.sendMessage(n),new Promise(function(e){e()})};var n=(r.prototype.add=function(e){this.listeners.push(e)},r.prototype.remove=function(e){var t=this.listeners.lastIndexOf(e);-1!==t&&this.listeners.splice(t,1)},r.prototype.call=function(t){this.listeners.forEach(function(e){return e(t)})},r);function r(){this.listeners=[]}e.ListenerManager=n}(OfficeRuntime=OfficeRuntime||{}),function(t){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject;var n=OfficeExtension.BatchApiHelper.createTopLevelServiceObject,r=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),o=(OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),e=(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_",l={getItem:function(n){return d(function(e,t){return e.multiGet(t,JSON.stringify([n]))},function(e){var t=JSON.parse(e);return t&&t[0]&&t[0][1]?t[0][1]:null})},setItem:function(n,r){return d(function(e,t){return e.multiSet(t,JSON.stringify([[n,r]]))},function(){return null})},removeItem:function(n){return d(function(e,t){return e.multiRemove(t,JSON.stringify([n]))},function(){return null})},getItems:function(n){return d(function(e,t){return e.multiGet(t,JSON.stringify(n))},function(e){var t=JSON.parse(e),r={};return t&&t.forEach(function(e){var t=e[0],n=e[1];return r[t]=n}),n&&n.forEach(function(e){r[e]&&r[e]}),r})},setItems:function(e){var n=[];for(var t in e)e.hasOwnProperty(t)&&n.push([t,e[t]]);return d(function(e,t){return e.multiSet(t,JSON.stringify(n))},function(){return null})},removeItems:function(n){return d(function(e,t){return e.multiRemove(t,JSON.stringify(n))},function(){return null})},getKeys:function(){return d(function(e,t){return e.getAllKeys(t)},function(e){return JSON.parse(e)})}},u={getItem:function(e){return m(function(){return p(e)})},setItem:function(e,t){return g(function(){return f(e,t)})},removeItem:function(e){return g(function(){return window.localStorage.removeItem(s+e)})},getItems:function(o){return new Promise(function(e,t){var n={},r=[];try{h()}catch(e){t(e)}o.forEach(function(e){try{var t=p(e);n[e]=t||null}catch(e){r.push(e)}}),0<r.length?t(new Error("Unknown error.")):e(n)})},setItems:function(t){return y(t,function(e){return f(e,t[e])})},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 p(e){return window.localStorage.getItem(s+e)}function f(e,t){window.localStorage.setItem(s+e,t)}function d(i,a){return new OfficeExtension.CoreUtility.Promise(function(r,o){var t=_.getInstance(),n=t.setCallBack(function(e,t){if(t)o(t);else{var n=a(e);r(n)}});t.ctx.sync().then(function(){var e=t.getPersistentKvStorageService();return i(e,n),t.ctx.sync()}).catch(function(e){o(e)})})}function h(){f(c,null),window.localStorage.removeItem(c)}function g(n,r){return void 0===r&&(r=function(){}),new Promise(function(e,t){try{h(),n(),r(null),e()}catch(e){r(e),t(e)}})}function m(r,o){return void 0===o&&(o=function(){}),new Promise(function(e,t){try{h();var n=r();o(null,n),e(n)}catch(e){o(e,null),t(e)}})}function y(o,i,a){return void 0===a&&(a=function(){}),new Promise(function(e,t){var n=[];try{h()}catch(e){n.push(e)}for(var r in o)if(o.hasOwnProperty(r)||Array.isArray(o))try{Array.isArray(o)?i(o[r]):i(r)}catch(e){n.push(e)}a(n),0<n.length?t(n):e()})}t.ApiHelper.isNativeStorage()?t.storage=l:t.storage=u;var _=(b.getInstance=function(){return void 0===b.instance?b.instance=new b:b.instance._perkvstorService=O.newObject(b.instance.ctx),b.instance},b.prototype.getPersistentKvStorageService=function(){return this._perkvstorService},b.prototype.getCallBack=function(e){return this._callDict[e]},b.prototype.setCallBack=function(e){var t=this._invokeId;return this._callDict[this._invokeId++]=e,t},b);function b(){var n=this;this._invokeId=0,this._callDict={},this.ctx=new OfficeExtension.ClientRequestContext,this._perkvstorService=O.newObject(this.ctx),this._eventResult=this._perkvstorService.onPersistentStorageMessage.add(function(e){OfficeExtension.Utility.log("persistentKvStoragegMessageHandler:"+JSON.stringify(e));var t=n._callDict[e.invokeId];t&&(t(e.message,e.error),delete n._callDict[e.invokeId])})}var v,O=(v=OfficeExtension.ClientObject,__extends(C,v),Object.defineProperty(C.prototype,"_className",{get:function(){return"PersistentKvStorageService"},enumerable:!0,configurable:!0}),C.prototype.clear=function(e){r(this,"Clear",1,[e],4,0)},C.prototype.getAllKeys=function(e){r(this,"GetAllKeys",1,[e],4,0)},C.prototype.multiGet=function(e,t){r(this,"MultiGet",1,[e,t],4,0)},C.prototype.multiRemove=function(e,t){r(this,"MultiRemove",1,[e,t],4,0)},C.prototype.multiSet=function(e,t){r(this,"MultiSet",1,[e,t],4,0)},C.prototype._handleResult=function(e){v.prototype._handleResult.call(this,e),o(e)||i(this,e)},C.prototype._handleRetrieveResult=function(e,t){v.prototype._handleRetrieveResult.call(this,e,t),a(this,e,t)},C.newObject=function(e){return n(t.PersistentKvStorageService,e,"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 e(this,{},{})},C);function C(){return null!==v&&v.apply(this,arguments)||this}t.PersistentKvStorageService=O,(t.ErrorCodes||(t.ErrorCodes={})).generalException="GeneralException"}(OfficeRuntime=OfficeRuntime||{});var OfficeFirstPartyDialog,OfficeFirstPartyAuth,OfficeCore,OfficeFirstParty;__extends=this&&this.__extends||function(){var r=function(e,t){return(r=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])})(e,t)};return function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}}(),__awaiter=this&&this.__awaiter||function(i,a,s,c){return new(s=s||Promise)(function(e,t){function n(e){try{o(c.next(e))}catch(e){t(e)}}function r(e){try{o(c.throw(e))}catch(e){t(e)}}function o(t){t.done?e(t.value):new s(function(e){e(t.value)}).then(n,r)}o((c=c.apply(i,a||[])).next())})},__generator=this&&this.__generator||function(n,r){var o,i,a,e,s={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return e={next:t(0),throw:t(1),return:t(2)},"function"==typeof Symbol&&(e[Symbol.iterator]=function(){return this}),e;function t(t){return function(e){return function(t){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,i&&(a=2&t[0]?i.return:t[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,t[1])).done)return a;switch(i=0,a&&(t=[2&t[0],a.value]),t[0]){case 0:case 1:a=t;break;case 4:return s.label++,{value:t[1],done:!1};case 5:s.label++,i=t[1],t=[0];continue;case 7:t=s.ops.pop(),s.trys.pop();continue;default:if(!(a=0<(a=s.trys).length&&a[a.length-1])&&(6===t[0]||2===t[0])){s=0;continue}if(3===t[0]&&(!a||t[1]>a[0]&&t[1]<a[3])){s.label=t[1];break}if(6===t[0]&&s.label<a[1]){s.label=a[1],a=t;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(t);break}a[2]&&s.ops.pop(),s.trys.pop();continue}t=r.call(n,s)}catch(e){t=[6,e],i=0}finally{o=a=0}if(5&t[0])throw t[1];return{value:t[0]?t[1]:void 0,done:!0}}([t,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(t){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject;var n,r=OfficeExtension.BatchApiHelper.createTopLevelServiceObject,o=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),i=(OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),e=(OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported,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),l=(n=OfficeExtension.ClientObject,__extends(u,n),Object.defineProperty(u.prototype,"_className",{get:function(){return"BiShim"},enumerable:!0,configurable:!0}),u.prototype.initialize=function(e){o(this,"Initialize",0,[e],c(2,"SharedApiUndo","1.5"),0)},u.prototype.getData=function(){return o(this,"getData",1,[],4,0)},u.prototype.setVisualObjects=function(e){o(this,"setVisualObjects",0,[e],2,0)},u.prototype.setVisualObjectsToPersist=function(e){o(this,"setVisualObjectsToPersist",0,[e],2,0)},u.prototype._handleResult=function(e){n.prototype._handleResult.call(this,e),i(e)||a(this,e)},u.prototype._handleRetrieveResult=function(e,t){n.prototype._handleRetrieveResult.call(this,e,t),s(this,e,t)},u.newObject=function(e){return r(t.BiShim,e,"Microsoft.AgaveVisual.BiShim",!1,4)},u.prototype.toJSON=function(){return e(this,{},{})},u);function u(){return null!==n&&n.apply(this,arguments)||this}t.BiShim=l,(t.AgaveVisualErrorCodes||(t.AgaveVisualErrorCodes={})).generalException="GeneralException"}(OfficeCore=OfficeCore||{}),function(o){OfficeExtension.BatchApiHelper.createPropertyObject;var n,i=OfficeExtension.BatchApiHelper.createMethodObject,t=(OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject,OfficeExtension.BatchApiHelper.createTopLevelServiceObject),r=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),a=OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,s=(OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),c=OfficeExtension.Utility.isUndefined,e=OfficeExtension.Utility.throwIfNotLoaded,l=(OfficeExtension.Utility.throwIfApiNotSupported,OfficeExtension.Utility.load),u=OfficeExtension.Utility.retrieve,p=OfficeExtension.Utility.toJson,f=OfficeExtension.Utility.fixObjectPathIfNecessary,d=(OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult),h=(n=OfficeExtension.ClientObject,__extends(g,n),Object.defineProperty(g.prototype,"_className",{get:function(){return"FlightingService"},enumerable:!0,configurable:!0}),g.prototype.getClientSessionId=function(){return r(this,"GetClientSessionId",1,[],4,0)},g.prototype.getDeferredFlights=function(){return r(this,"GetDeferredFlights",1,[],4,0)},g.prototype.getFeature=function(e,t,n,r){return i(o.ABType,this,"GetFeature",1,[e,t,n,r],!1,!1,null,4)},g.prototype.getFeatureGate=function(e,t){return i(o.ABType,this,"GetFeatureGate",1,[e,t],!1,!1,null,4)},g.prototype.resetOverride=function(e){r(this,"ResetOverride",0,[e],0,0)},g.prototype.setOverride=function(e,t,n){r(this,"SetOverride",0,[e,t,n],0,0)},g.prototype._handleResult=function(e){n.prototype._handleResult.call(this,e),s(e)||f(this,e)},g.prototype._handleRetrieveResult=function(e,t){n.prototype._handleRetrieveResult.call(this,e,t),d(this,e,t)},g.newObject=function(e){return t(o.FlightingService,e,"Microsoft.Experiment.FlightingService",!1,4)},g.prototype.toJSON=function(){return p(this,{},{})},g);function g(){return null!==n&&n.apply(this,arguments)||this}o.FlightingService=h;var m,y,_=(m=OfficeExtension.ClientObject,__extends(b,m),Object.defineProperty(b.prototype,"_className",{get:function(){return"ABType"},enumerable:!0,configurable:!0}),Object.defineProperty(b.prototype,"_scalarPropertyNames",{get:function(){return["value"]},enumerable:!0,configurable:!0}),Object.defineProperty(b.prototype,"value",{get:function(){return e("value",this._V,"ABType",this._isNull),this._V},enumerable:!0,configurable:!0}),b.prototype._handleResult=function(e){if(m.prototype._handleResult.call(this,e),!s(e)){var t=e;f(this,t),c(t.Value)||(this._V=t.Value)}},b.prototype.load=function(e){return l(this,e)},b.prototype.retrieve=function(e){return u(this,e)},b.prototype._handleRetrieveResult=function(e,t){m.prototype._handleRetrieveResult.call(this,e,t),d(this,e,t)},b.prototype.toJSON=function(){return p(this,{value:this._V},{})},b.prototype.ensureUnchanged=function(e){a(this,e)},b);function b(){return null!==m&&m.apply(this,arguments)||this}o.ABType=_,(y=o.FeatureType||(o.FeatureType={})).boolean="Boolean",y.integer="Integer",y.string="String",(o.ExperimentErrorCodes||(o.ExperimentErrorCodes={})).generalException="GeneralException"}(OfficeCore=OfficeCore||{}),function(r){var e,t,n=(o.prototype.close=function(){return this._dialogService.close(),this._dialogService.context.sync()},o.prototype.messageChild=function(e,t){DialogApiManager&&DialogApiManager.messageChildRichApiBridge&&DialogApiManager.messageChildRichApiBridge(e,t)},o);function o(e){this._dialogService=e}r.Dialog=n,r.displayWebDialog=function(n,h){return void 0===h&&(h={}),new OfficeExtension.CoreUtility.Promise(function(l,u){if(h.width&&h.height&&(!e(h.width)||!e(h.height)))throw new OfficeExtension.Error({code:"InvalidArgument",message:'Dimensions must be "number%" or number.'});var p=new OfficeExtension.ClientRequestContext,t=OfficeCore.FirstPartyDialogService.newObject(p),f=new r.Dialog(t),d=t.onDialogMessage.add(function(e){OfficeExtension.Utility.log("dialogMessageHandler:"+JSON.stringify(e));var t,n,r,o=JSON.parse(e.message),i=o.errorCode?new OfficeExtension.Error((t=o.errorCode,(n={})[12002]={code:"InvalidUrl",message:"Cannot load URL, no such page or bad URL syntax."},n[12003]={code:"InvalidUrl",message:"HTTPS is required."},n[12004]={code:"Untrusted",message:"Domain is not trusted."},n[12005]={code:"InvalidUrl",message:"HTTPS is required."},n[12007]={code:"FailedToOpen",message:"Another dialog is already opened."},(r=n)[t]?r[t]:{code:"Unknown",message:"An unknown error has occured with code: "+t})):null,a=o.type,s=o.origin,c=o.message;switch(a){case 17:i?u(i):l(f);break;case 12:h.onMessage&&h.onMessage(c,f,s);break;case 10:default:12006===o.errorCode?(d&&(d.remove(),p.sync()),h.onClose&&h.onClose()):h.onRuntimeError&&(h.onRuntimeError(i,f),u(i))}return OfficeExtension.CoreUtility.Promise.resolve()});return p.sync().then(function(){var e={width:h.width?parseInt(h.width):50,height:h.height?parseInt(h.height):50,displayInIFrame:h.displayInIFrame,dialogTitle:h.dialogTitle,escKeyCloseDialog:void 0===h.escKeyCloseDialog||h.escKeyCloseDialog};return t.displayDialog(n,e),p.sync()}).catch(function(e){u(e)})});function e(e){return/^(\-|\+)?([0-9]+)%?$/.test(e)}},(t=e=e||{})[t.dialogMessageReceived=0]="dialogMessageReceived",t[t.dialogEventReceived=1]="dialogEventReceived"}(OfficeFirstPartyDialog=OfficeFirstPartyDialog||{}),function(n){n.OfficeOnlineDomainList=["*.dod.online.office365.us","*.gov.online.office365.us","*.officeapps-df.live.com","*.officeapps.live.com","*.online.office.de","*.partner.officewebapps.cn"],n.isHostOriginTrusted=function(){if(void 0!==window.external&&void 0!==window.external.GetContext)return!0;var e=OSF.getClientEndPoint()._targetUrl,t=e.split("/")[2].split(":")[0].split("?")[0];return 0!=e.indexOf("https:")||n.OfficeOnlineDomainList.forEach(function(e){if(0==e.indexOf("*.")&&(e=e.substring(2)),t.indexOf(e)==t.length-e.length)return!0}),!1}}(OfficeCore=OfficeCore||{}),function(n){var e=(Object.defineProperty(t.prototype,"roamingSettings",{get:function(){return this.m_roamingSettings||(this.m_roamingSettings=n.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=n.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=n.Skill.newObject(this.context)),this.m_skill},enumerable:!0,configurable:!0}),t);function t(e){this.context=e}n.FirstPartyApis=e;var r,o=(r=OfficeExtension.ClientRequestContext,__extends(i,r),Object.defineProperty(i.prototype,"firstParty",{get:function(){return this.m_firstPartyApis||(this.m_firstPartyApis=new e(this)),this.m_firstPartyApis},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"flighting",{get:function(){return this.flightingService},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"telemetry",{get:function(){return this.m_telemetry||(this.m_telemetry=n.TelemetryService.newObject(this)),this.m_telemetry},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"ribbon",{get:function(){return this.m_ribbon||(this.m_ribbon=n.DynamicRibbon.newObject(this)),this.m_ribbon},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"bi",{get:function(){return this.m_biShim||(this.m_biShim=n.BiShim.newObject(this)),this.m_biShim},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"flightingService",{get:function(){return this.m_flightingService||(this.m_flightingService=n.FlightingService.newObject(this)),this.m_flightingService},enumerable:!0,configurable:!0}),i);function i(e){return r.call(this,e)||this}n.RequestContext=o,n.run=function(e,t){return OfficeExtension.ClientRequestContext._runBatch("OfficeCore.run",arguments,function(e){return new n.RequestContext(e)})}}(OfficeCore=OfficeCore||{}),function(e){var t;function s(){var e=new OfficeCore.RequestContext;return"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(e._customData="WacPartition"),e}(t=e.license||(e.license={})).isFeatureEnabled=function(o,i){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=s(),n=OfficeCore.License.newObject(t),r=n.isFeatureEnabled(o,i),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.getFeatureTier=function(o,i){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=s(),n=OfficeCore.License.newObject(t),r=n.getFeatureTier(o,i),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.isFreemiumUpsellEnabled=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=s(),n=OfficeCore.License.newObject(t),r=n.isFreemiumUpsellEnabled(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.launchUpsellExperience=function(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=s(),OfficeCore.License.newObject(t).launchUpsellExperience(n),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.onFeatureStateChanged=function(i,a){return __awaiter(this,void 0,void 0,function(){var t,n,r,o;return __generator(this,function(e){switch(e.label){case 0:return t=s(),n=OfficeCore.License.newObject(t),(r=n.getLicenseFeature(i)).onStateChanged.add(a),o=function(){return r.onStateChanged.remove(a),null},[4,t.sync()];case 1:return e.sent(),[2,o]}})})},t.getMsaDeviceTicket=function(o,i,a){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=s(),n=OfficeCore.License.newObject(t),r=n.getMsaDeviceTicket(o,i,a),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})}}(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;(e._CC||(e._CC={})).Skill_HostSkillEvent_EventArgsTransform=function(e,t){return{type:t.type,data:t.data}},(e.SkillErrorCodes||(e.SkillErrorCodes={})).generalException="GeneralException";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(t){OfficeExtension.BatchApiHelper.createPropertyObject,OfficeExtension.BatchApiHelper.createMethodObject,OfficeExtension.BatchApiHelper.createIndexerObject,OfficeExtension.BatchApiHelper.createRootServiceObject;var n,e,r,o=OfficeExtension.BatchApiHelper.createTopLevelServiceObject,a=(OfficeExtension.BatchApiHelper.createChildItemObject,OfficeExtension.BatchApiHelper.invokeMethod),i=(OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,OfficeExtension.BatchApiHelper.invokeSetProperty,OfficeExtension.Utility.isNullOrUndefined),s=(OfficeExtension.Utility.isUndefined,OfficeExtension.Utility.throwIfNotLoaded,OfficeExtension.Utility.throwIfApiNotSupported),c=(OfficeExtension.Utility.load,OfficeExtension.Utility.retrieve,OfficeExtension.Utility.toJson),l=OfficeExtension.Utility.fixObjectPathIfNecessary,u=(OfficeExtension.Utility._handleNavigationPropertyResults,OfficeExtension.Utility.adjustToDateTime,OfficeExtension.Utility.processRetrieveResult),p=(OfficeExtension.Utility.setMockData,OfficeExtension.CommonUtility.calculateApiFlags,n=OfficeExtension.ClientObject,__extends(f,n),Object.defineProperty(f.prototype,"_className",{get:function(){return"TelemetryService"},enumerable:!0,configurable:!0}),f.prototype.sendNonStandardEvent=function(e,t,n,r,o,i){s("TelemetryService.sendNonStandardEvent","Telemetry","1.4","OfficeCore"),a(this,"SendNonStandardEvent",1,[e,t,n,r,o,i],4,0)},f.prototype.sendTelemetryEvent=function(e,t,n,r,o){a(this,"SendTelemetryEvent",1,[e,t,n,r,o],4,0)},f.prototype._handleResult=function(e){n.prototype._handleResult.call(this,e),i(e)||l(this,e)},f.prototype._handleRetrieveResult=function(e,t){n.prototype._handleRetrieveResult.call(this,e,t),u(this,e,t)},f.newObject=function(e){return o(t.TelemetryService,e,"Microsoft.Telemetry.TelemetryService",!1,4)},f.prototype.toJSON=function(){return c(this,{},{})},f);function f(){return null!==n&&n.apply(this,arguments)||this}t.TelemetryService=p,(e=t.DataFieldType||(t.DataFieldType={})).unset="Unset",e.string="String",e.boolean="Boolean",e.int64="Int64",e.double="Double",(r=t.EventType||(t.EventType={})).sendTelemetryEvent="SendTelemetryEvent",r.customerContent="CustomerContent",r.directNumericEvent="DirectNumericEvent",(t.TelemetryErrorCodes||(t.TelemetryErrorCodes={})).generalException="GeneralException"}(OfficeCore=OfficeCore||{}),function(c){var l="officeWebAuthReplyUrls",g=!1,r=null;function e(n){function r(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return o=n.apply(void 0,e)}var o=null,i=null;return{immediateCall:r,delayCall:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];i=function(){return r.apply(void 0,e)}},waitForPromise:function(){return i&&(i(),i=null),o||Promise.resolve()}}}function m(r){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return(t=!1,r&&c.supportsTeamsTokenFlow)?(t=!0,[3,3]):[3,1];case 1:return[4,o()];case 2:(n=e.sent()).supportsAuthToken?t=!0:r&&(t=!n.hostPageSupportsAuth),e.label=3;case 3:return[2,t]}})})}function o(){return Office&&Office.context&&Office.context.webAuth?r?Promise.resolve(r):new Promise(function(t,n){Office.context.webAuth.getAuthContextAsync(function(e){if("succeeded"===e.status){if(!(r=e.value)||r.isAnonymous)return void n({code:"CannotGetAuthContext",message:r?r.Error:void 0,loggableErrorMessage:"Anonymous user"});if(!r.appId)return void n({code:"CannotGetAuthContext",message:"App ID is missing from getAuthContextAsync. Please verify the WebApplicationInfo node in app manifest."});t(r)}else n({code:"CannotGetAuthContext",message:e.status,loggableErrorMessage:String(e.error.code)})})}):Promise.reject({code:"GetAuthContextAsyncMissing",message:"Office:["+!Office+"],Office.context:["+!Office.context+"],Office.context.webAuth:["+!Office.context.webAuth+"]"})}c.authFlow="authcode",c.autoPopup=!1,c.upnCheck=!0,c.timeout=void 0,c.msal="https://alcdn.msauth.net/browser-1p/2.28.1/js/msal-browser-1p.min.js",c.debugging=!1,c.useMsal3=void 0,c.delay=0,c.delayMsal=0,c.supportsOauthManager=!1,c.supportsTeamsTokenFlow=!0,c.supportsBrowserAuth=!0;var y=e(function(a,s){return __awaiter(this,void 0,void 0,function(){var i;return __generator(this,function(e){switch(e.label){case 0:return c.supportsBrowserAuth?[4,o()]:[2,Promise.reject({code:"PackageNotLoaded"})];case 1:return i=e.sent(),[2,new Promise(function(t,n){try{var e="msa"===i.authorityType.toLowerCase();if(OSF.WebAuth.config={authFlow:c.authFlow,authVersion:c.authVersion?c.authVersion:null,msal:c.msal,delayWebAuth:c.delay,delayMsal:c.delayMsal,debugging:c.debugging,useMsal3:c.useMsal3,authority:c.authorityOverride?c.authorityOverride:i.authority,idp:i.authorityType.toLowerCase(),appIds:[e&&i.msaAppId?i.msaAppId:i.appId],redirectUri:a||null,upn:i.upn,puid:i.userId,prefetch:s,telemetryInstance:"otel",autoPopup:c.autoPopup,enableUpnCheck:c.upnCheck,enableConsoleLogging:c.debugging,tenantId:i.tenantId,timeout:c.timeout},OSF.WebAuth.load().then(function(e){u(e,g=!0),t()}).catch(function(e){n({code:"PackageNotLoaded",message:e instanceof Event?e.type:e,telemetryResult:e})}),"implicit"===c.authFlow){var r=a||window.location.href.split("?")[0],o=sessionStorage.getItem(l);o||""===o?o=r:o+=", "+r,o&&sessionStorage.setItem(l,o)}}catch(e){OSF.WebAuth.config=null,OSF.WebAuth.load().then(function(){t()}).catch(function(){n({code:"FailedToLoad",message:e})})}})]}})})});var n=e(function(r,o){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:if(!OSF.WebAuth||"web"!=OSF._OfficeAppFactory.getHostInfo().hostPlatform)return[3,6];e.label=1;case 1:return e.trys.push([1,5,,6]),y.delayCall(r,o),[4,m(c.supportsOauthManager)];case 2:return e.sent()?[3,4]:[4,y.waitForPromise()];case 3:e.sent(),e.label=4;case 4:return[3,6];case 5:throw t=e.sent(),u((n=t).result,!1,n),delete n.result,delete n.loggableErrorMessage,n;case 6:return[2]}})})});function t(e,t){return n.immediateCall(e,t)}function u(i,a,s){void 0!==OTel&&OTel.OTelLogger.onTelemetryLoaded(function(){var e=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)]:[],t=s&&s.loggableErrorMessage?s.loggableErrorMessage:"",n=a?[]:[oteljs.makeStringDataField("ApiErrorCode",s&&s.code?s.code:""),oteljs.makeStringDataField("Error",t||(i instanceof Event?i.type:""))],r=e.concat(n,[oteljs.makeBooleanDataField("Result",a)]);if(i&&!(i instanceof Event)&&i.Telemetry)for(var o in i.Telemetry)if(i.Telemetry[o])switch(o){case"succeeded":r.push(oteljs.makeBooleanDataField(o,i.Telemetry[o]));break;case"loadedApplicationCount":case"timeToLoad":r.push(oteljs.makeInt64DataField(o,i.Telemetry[o]));break;default:r.push(oteljs.makeStringDataField(o,i.Telemetry[o]))}OTel.OTelLogger.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.OfficeFirstPartyAuth.Load",dataFields:r,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage}})})}function _(n,r,o){void 0!==OTel&&OTel.OTelLogger.onTelemetryLoaded(function(){var e=[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("Popup","boolean"==typeof o&&o),oteljs.makeBooleanDataField("Result",r),oteljs.makeStringDataField("Error",n instanceof Event?n.type:n.ErrorCode)];if(n&&!(n instanceof Event)&&n.Telemetry)for(var t in n.Telemetry)if(n.Telemetry[t])switch(t){case"succeeded":e.push(oteljs.makeBooleanDataField(t,n.Telemetry[t]));break;case"timeToGetToken":e.push(oteljs.makeInt64DataField(t,n.Telemetry[t]));break;default:e.push(oteljs.makeStringDataField(t,n.Telemetry[t]))}OTel.OTelLogger.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.OfficeFirstPartyAuth.GetAccessToken",dataFields:e,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage}})})}c.load=t,c.getAccessToken=function(d,h){var e=this;return n.waitForPromise().then(function(){return new Promise(function(p,f){return __awaiter(e,void 0,void 0,function(){var r,o,i,a,s,c,l,u;return __generator(this,function(e){switch(e.label){case 0:return e.trys.push([0,10,,11]),"web"!=OSF._OfficeAppFactory.getHostInfo().hostPlatform?[3,6]:[4,m(!!d.appName)];case 1:return e.sent()?[3,3]:[4,y.waitForPromise()];case 2:return e.sent(),OSF.WebAuth&&g?OSF.WebAuth.config.appIds[0]&&OSF.WebAuth.getToken(d.resource,null,OSF.WebAuth.config.appIds[0],d.correlationId||OSF._OfficeAppFactory.getHostInfo().osfControlAppCorrelationId,h&&h.popup?h.popup:null,d&&d.authChallenge?d.authChallenge:null).then(function(e){_(e,!0,!(!h||!h.popup)&&h.popup),p({accessToken:e.Token,tokenIdenityType:"msa"==OSF.WebAuth.config.idp.toLowerCase()?OfficeCore.IdentityType.microsoftAccount:OfficeCore.IdentityType.organizationAccount})}).catch(function(e){_(e,!1,!(!h||!h.popup)&&h.popup),f({code:e.ErrorCode,message:e instanceof Event?e.type:e.ErrorMessage})}):(t=g,n=OSF.WebAuth.loadAttempts,void 0!==OTel&&OTel.OTelLogger.onTelemetryLoaded(function(){var e=[oteljs.makeBooleanDataField("Loaded",t),oteljs.makeInt64DataField("LoadAttempts","number"==typeof n?n:0)];OTel.OTelLogger.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.OfficeFirstPartyAuth.UnexpectedAcquire",dataFields:e,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage}})})),[3,5];case 3:return r=new OfficeCore.RequestContext,a=OfficeCore.AuthenticationService.newObject(r),r._customData="WacPartition",o=a.getAccessToken(d,null),[4,r.sync()];case 4:e.sent(),p(o.value),e.label=5;case 5:return[3,9];case 6:return i=new OfficeCore.RequestContext,a=OfficeCore.AuthenticationService.newObject(i),s=a.onTokenReceived.add(function(t){if(!OfficeExtension.CoreUtility.isNullOrUndefined(t))if(s.remove(),i.sync().catch(function(){}),0==t.code)p(t.tokenValue);else if(OfficeExtension.CoreUtility.isNullOrUndefined(t.errorInfo))f({code:t.code});else try{f(JSON.parse(t.errorInfo))}catch(e){f({code:t.code,message:t.errorInfo})}return null}),[4,i.sync()];case 7:return e.sent(),c=a.getAccessToken(d,a._targetId),[4,i.sync()];case 8:if(e.sent(),OfficeExtension.CoreUtility.isNullOrUndefined(c.value))return[2,null];l=c.value.accessToken,OfficeExtension.CoreUtility.isNullOrUndefined(l)||p(c.value),e.label=9;case 9:return[3,11];case 10:return u=e.sent(),f(u),[3,11];case 11:return[2]}var t,n})})})})},c.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})},c.getIdentities=function(){var e=new OfficeCore.RequestContext,t=OfficeCore.AuthenticationService.newObject(e).getIdentities();return e.sync().then(function(){return t.value})},c.onIdentityChanged=function(o){return __awaiter(this,void 0,void 0,function(){var t,n,r=this;return __generator(this,function(e){switch(e.label){case 0:return(e.trys.push([0,3,,4]),"web"===OSF._OfficeAppFactory.getHostInfo().hostPlatform)?[3,2]:(t=new OfficeCore.RequestContext,n=OfficeCore.AuthenticationService.newObject(t),n.onIdentityChanged.add(o),[4,t.sync()]);case 1:return e.sent(),[2,function(){return __awaiter(r,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return n.onIdentityChanged.remove(o),[4,t.sync()];case 1:return e.sent(),[2]}})})}];case 2:return[3,4];case 3:return e.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(l);null!==e&&-1!==e.indexOf(window.location.origin+window.location.pathname)&&t()}catch(e){console.error(e)}}()}(OfficeFirstPartyAuth=OfficeFirstPartyAuth||{}),function(e){!function(l){var r,e,p,t;(e=r=l.PopupOptions||(l.PopupOptions={}))[e.None=0]="None",e[e.Auto=1]="Auto",e[e.Force=2]="Force",(t=p=l.AuthErrorCode||(l.AuthErrorCode={}))[t.UnsupportedUserIdentity=13003]="UnsupportedUserIdentity",t[t.UserAborted=13004]="UserAborted",t[t.InteractionRequired=13005]="InteractionRequired",t[t.ClientError=13006]="ClientError",t[t.ServerError=13007]="ServerError",t[t.NotAvailable=13012]="NotAvailable",t[t.InternalError=5001]="InternalError",t[t.InvalidApiArguments=5013]="InvalidApiArguments";var f={ACCOUNT_UNAVAILABLE:p.UnsupportedUserIdentity,USER_CANCEL:p.UserAborted,USER_INTERACTION_REQUIRED:p.InteractionRequired,PERSISTENT_ERROR:p.ClientError,NO_NETWORK:p.ServerError,TRANSIENT_ERROR:p.ServerError,NESTED_APP_AUTH_UNAVAILABLE:p.NotAvailable},o={POPUP_WINDOW_ERROR:p.ClientError,USER_CANCELLED:p.UserAborted},u={ACCESS_TOKEN:"access_token",XMS_CC:"xms_cc"},d=0,h=!1,g=!1,n=void 0,s=null,m=void 0;l.clientCapabilities=[],l.upnCheck=!0,l.timeout=void 0,l.msal="https://alcdn.msauth.net/browser-1p/2.28.1/js/msal-browser-1p.min.js",l.debugging=!1,l.delay=0,l.delayMsal=0,l.useMsal3=void 0;var y={},_=function(e){try{var t="string"==typeof e?e:e.data,n=JSON.parse(t);if(n.requestId){var r=n.requestId;if(y.hasOwnProperty(r)){var o=p.InternalError,i=y[r],a=i[0],s=i[1];delete y[r];var c=n.token;if(c&&!0===n.success&&c.access_token&&"number"==typeof c.expires_in)return void a({accessToken:c.access_token,idToken:c.id_token,expiresOn:new Date(Date.now()+1e3*c.expires_in)});var l=n.error;if(l){var u=l.status;f[u]&&(o=f[u])}s({code:o})}}}catch(e){}},b={code:p.NotAvailable};function i(i,a){function e(e){function t(e,t){var n=Date.now()-r;!function(t,n,r,o,i){if(0<d&&!r)return;d++,void 0!==OTel&&OTel.OTelLogger.onTelemetryLoaded(function(){var e=[oteljs.makeStringDataField("NestedClientId",t),oteljs.makeStringDataField("CorrelationId",n),oteljs.makeBooleanDataField("Popup",r),oteljs.makeInt64DataField("Duration",o),oteljs.makeInt64DataField("ErrorCode",i?i.code:0),oteljs.makeBooleanDataField("BridgeAvailable",v())];OTel.OTelLogger.sendTelemetryEvent({eventName:"Office.Extensibility.OfficeJs.NestedAppAuth.GetAccessToken",dataFields:e,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage,diagnosticLevel:oteljs.DiagnosticLevel.NecessaryServiceDataEvent}})})}(s,c,a,n,t)}return e.then(function(e){t(0,null)}).catch(function(e){t(0,e)}),e}var s=i.clientId||m,c=i.correlationId||OSF.OUtil.Guid.generateNewGuid(),r=Date.now();return v()?e(new Promise(function(e,t){var n=OSF.OUtil.Guid.generateNewGuid(),r=i.scopes.join(" "),o={messageType:"NestedAppAuthRequest",method:a?"GetTokenPopup":"GetToken",requestId:n,clientLibrary:"officejs",sendTime:Date.now(),tokenParams:{clientId:s,scope:r,correlationId:c,claims:function(e){if(0===l.clientCapabilities.length)return e;var t={};if(e)try{t=JSON.parse(e)}catch(e){}return t.hasOwnProperty(u.ACCESS_TOKEN)||(t[u.ACCESS_TOKEN]={}),t[u.ACCESS_TOKEN][u.XMS_CC]={values:l.clientCapabilities},JSON.stringify(t)}(i.claims)}};h||(nestedAppAuthBridge.addEventListener("message",_),h=!0),y[n]=[e,t],nestedAppAuthBridge.postMessage(JSON.stringify(o))})):e(n?n.then(function(){if(!g)return Promise.reject(b);var e=i.scopes.join(" ");return e=e.replace(/(\/.default)$/,""),OSF.WebAuth.getToken(e,i.scopes,s,c,a,i.claims).then(function(e){return{accessToken:e.Token,expiresOn:e.MsalResult?e.MsalResult.expiresOn:void 0}}).catch(function(e){var t=p.InternalError,n=void 0;if(e)if(n=e.ErrorMessage,e.MsalResult&&"InteractionRequiredAuthError"===e.MsalResult.name)t=p.InteractionRequired;else if(e.ErrorCode){var r=e.ErrorCode.toUpperCase();o[r]&&(t=o[r])}return Promise.reject({code:t,description:n})})}):Promise.reject(b))}function v(){return"undefined"!=typeof nestedAppAuthBridge}l.isBridgeAvailable=v,l.load=function(r,o,i,a){return m=r,a&&(l.clientCapabilities=a),n||(n=new Promise(function(t,n){if(v())t();else if(Office&&Office.context&&Office.context.auth&&OSF.WebAuth)try{Office.context.auth.getAuthContextAsync(function(e){if("succeeded"===e.status){if(!(s=e.value))return void n(b);OSF.WebAuth.config={authFlow:"authcode",authVersion:l.authVersion?l.authVersion:null,msal:l.msal,delayWebAuth:l.delay,delayMsal:l.delayMsal,debugging:l.debugging,useMsal3:l.useMsal3,authority:l.authorityOverride?l.authorityOverride:s.authorityBaseUrl,idp:"msa"===s.authorityType.toLowerCase()?"msa":"aad",appIds:[r],redirectUri:o||null,upn:s.userPrincipalName,prefetch:i,telemetryInstance:"otel",enableUpnCheck:l.upnCheck,enableConsoleLogging:l.debugging,checkActiveAccount:!0,tenantId:s.tenantId,timeout:l.timeout,clientCapabilities:a},OSF.WebAuth.load().then(function(e){g=!0,t()}).catch(function(e){n(__assign({},b,{description:e instanceof Event?e.type:void 0}))})}else n(b)})}catch(e){n(b)}else n(b)}))},l.getAccessToken=function(t){var n=null==t.popup?r.None:t.popup;if(n===r.Auto&&!t.directUserActionCallback)throw{code:p.InvalidApiArguments};return i(t,n===r.Force).catch(function(e){if(e.code==p.InteractionRequired&&n===r.Auto&&t.directUserActionCallback)return t.directUserActionCallback().then(function(e){if(e)return i(t,!0);throw{code:p.UserAborted}}).catch(function(){throw{code:p.UserAborted}});throw e})}}(e.NestedAppAuth||(e.NestedAppAuth={}))}(OfficeFirstPartyAuth=OfficeFirstPartyAuth||{}),function(i){var n,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;(i._CC||(i._CC={})).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},(i._CC||(i._CC={})).ThemeService_OfficeThemeChanged_EventArgsTransform=function(e,t){return{bodyBackgroundColor:t.bodyBackgroundColor,bodyForegroundColor:t.bodyForegroundColor,controlBackgroundColor:t.controlBackgroundColor,controlForegroundColor:t.controlForegroundColor}},(e=n=i.PersonaPromiseType||(i.PersonaPromiseType={}))[e.immediate=0]="immediate",e[e.load=3]="load";var a=function(){};i.PersonaInfoAndSource=a;var t=(r.prototype.performAsyncOperation=function(e,l,u,p){var t=this;e!=n.immediate?p().then(function(e){if(e)u();else{var c=t;c.load("hostId"),c.context.sync().then(function(){var s=c.hostId;t.getPersonaLifetime().then(function(i){var a=function(o){return new OfficeExtension.CoreUtility.Promise(function(t,e){if(o.sendingPersonaHostId==s)for(var n=0;n<o.dataUpdated.length;++n){var r=o.dataUpdated[n];if(l==r)return void p().then(function(e){e&&(u(),i.onPersonaUpdated.remove(a),c.context.sync()),t(e)})}t(!1)})};i.onPersonaUpdated.add(a),c.context.sync()})})}}):u()},r.prototype.getOrganizationAsync=function(n){var o=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var r=o;o.performAsyncOperation(n,PersonaDataUpdated.organization,function(){var e=r.organization;e.load("*"),r.context.sync().then(function(){t(e)})},function(){return new OfficeExtension.CoreUtility.Promise(function(e,t){var n=r.organization;n.load("isWarmedUp"),r.context.sync().then(function(){e(n.isWarmedUp)})})})})},r.prototype.getIsPersonaInfoResolvedCheck=function(){var r=this;return new OfficeExtension.CoreUtility.Promise(function(e,t){var n=r.personaInfo;n.load("isPersonResolved"),r.context.sync().then(function(){e(n.isPersonResolved)})})},r.prototype.getPersonaInfoAsync=function(r){var o=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var n=o;o.performAsyncOperation(r,PersonaDataUpdated.personaInfo,function(){var e=n.personaInfo;e.load(),n.context.sync().then(function(){t(e)})},function(){return o.getIsPersonaInfoResolvedCheck()})})},r.prototype.getPersonaInfoWithSourceAsync=function(r){var o=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var n=o;o.performAsyncOperation(r,PersonaDataUpdated.personaInfo,function(){var e=new a;e.info=n.personaInfo,e.info.load(),e.source=n.personaInfo.sources,e.source.load(),n.context.sync().then(function(){t(e)})},function(){return o.getIsPersonaInfoResolvedCheck()})})},r.prototype.getUnifiedCommunicationInfo=function(r){var o=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var n=o;o.performAsyncOperation(r,PersonaDataUpdated.personaInfo,function(){var e=n.unifiedCommunicationInfo;e.load("*"),n.context.sync().then(function(){t(e)})},function(){return o.getIsPersonaInfoResolvedCheck()})})},r.prototype.getUnifiedGroupInfoAsync=function(r){var o=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var n=o;o.performAsyncOperation(r,PersonaDataUpdated.personaInfo,function(){var e=n.unifiedGroupInfo;e.load("*"),n.context.sync().then(function(){t(e)})},function(){return o.getIsPersonaInfoResolvedCheck()})})},r.prototype.getTypeAsync=function(r){var o=this;return new OfficeExtension.CoreUtility.Promise(function(e,t){var n=o;o.performAsyncOperation(r,PersonaDataUpdated.personaInfo,function(){n.load("type"),n.context.sync().then(function(){e(i.PersonaType[n.type.valueOf()])})},function(){return o.getIsPersonaInfoResolvedCheck()})})},r.prototype.getCustomizationsAsync=function(r){var o=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var n=o;o.performAsyncOperation(r,PersonaDataUpdated.personaInfo,function(){var e=n.getCustomizations();n.context.sync().then(function(){t(e.value)})},function(){return o.getIsPersonaInfoResolvedCheck()})})},r.prototype.getMembersAsync=function(n){var o=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var r=o;o.performAsyncOperation(n,PersonaDataUpdated.members,function(){var e=r.getMembers();e.load("isWarmedUp"),r.context.sync().then(function(){t(e)})},function(){return new OfficeExtension.CoreUtility.Promise(function(e,t){var n=r.getMembers();n.load("isWarmedUp"),r.context.sync().then(function(){e(n.isWarmedUp)})})})})},r.prototype.getMembershipAsync=function(r){var o=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var n=o;o.performAsyncOperation(r,PersonaDataUpdated.membership,function(){var e=n.getMembership();e.load("*"),n.context.sync().then(function(){t(e)})},function(){return new OfficeExtension.CoreUtility.Promise(function(e){var t=n.getMembership();t.load("isWarmedUp"),n.context.sync().then(function(){e(t.isWarmedUp)})})})})},r.prototype.getPersonaLifetime=function(){var r=this;return new OfficeExtension.CoreUtility.Promise(function(t,e){var n=r;n.load("instanceId"),n.context.sync().then(function(){new o(n.context,n.instanceId).getPersonaLifetime().then(function(e){t(e)})})})},r);function r(){}i.PersonaCustom=t;var o=(Object.defineProperty(s.prototype,"serviceContext",{get:function(){return this.m_serviceConext||(this.m_serviceConext=i.ServiceContext.newObject(this.context)),this.m_serviceConext},enumerable:!0,configurable:!0}),s.prototype.getPersonaLifetime=function(){var r=this;return new OfficeExtension.CoreUtility.Promise(function(e,t){var n=r.serviceContext.getPersonaLifetime(r.instanceId);r.context.sync().then(function(){n.load("instanceId"),r.context.sync().then(function(){e(n)})})})},s.prototype.getInitialPersona=function(){var r=this;return new OfficeExtension.CoreUtility.Promise(function(e,t){var n=r.serviceContext.getInitialPersona(r.instanceId);r.context.sync().then(function(){e(n)})})},s.prototype.getLokiTokenProvider=function(){var r=this;return new OfficeExtension.CoreUtility.Promise(function(e,t){var n=r.serviceContext.getLokiTokenProvider(r.instanceId);r.context.sync().then(function(){n.load("instanceId"),r.context.sync().then(function(){e(n)})})})},s);function s(e,t){this.context=e,this.instanceId=t}i.PeopleApiContext=o,(i._CC||(i._CC={})).FirstPartyDialogService_DialogMessage_EventArgsTransform=function(e,t){return{message:t.message}};var c,l,u=(Object.defineProperty(p.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}),p);function p(){}i.AuthenticationServiceCustom=u,(i._CC||(i._CC={})).AuthenticationService_TokenReceived_EventArgsTransform=function(e,t){return{tokenValue:t.tokenValue,code:t.code,errorInfo:t.errorInfo}},(c=i._CC||(i._CC={})).ExternalCodeService_ExternalCodeExecutionCompleted_EventArgsTransform=function(e,t){return{result:t.result}},c.ExternalCodeService_ExternalCodeServiceRequestCompleted_EventArgsTransform=function(e,t){return t},c.ExternalCodeService_ExternalCodeServiceResult_EventArgsTransform=function(e,t){return t},(i._CC||(i._CC={})).AddinSkillActionService_ReplyReceived_EventArgsTransform=function(e,t){return{actionCorrelationId:t.actionCorrelationId,replyMessage:t.replyMessage,resultCode:t.resultCode}},(l=i.ErrorCodes||(i.ErrorCodes={})).apiNotAvailable="ApiNotAvailable",l.clientError="ClientError",l.clpSessionError="ClpSessionError",l.controlIdNotFound="ControlIdNotFound",l.docCookieError="DocCookieError",l.entryIdRequired="EntryIdRequired",l.errorPointer="ErrorPointer",l.generalException="GeneralException",l.hostIntegrationManagerError="HostIntegrationManagerError",l.hostRestartNeeded="HostRestartNeeded",l.instanceNotFound="InstanceNotFound",l.interactiveFlowAborted="InteractiveFlowAborted",l.invalidArgument="InvalidArgument",l.invalidGrant="InvalidGrant",l.invalidResourceUrl="InvalidResourceUrl",l.invalidRibbonDefinition="InvalidRibbonDefinition",l.labelingDisabledAppguard="LabelingDisabledAppguard",l.labelingDisabledNoSignedInClpCompatibleUsers="LabelingDisabledNoSignedInClpCompatibleUsers",l.labelingDisabledPrivacySettings="LabelingDisabledPrivacySettings",l.labelingDisabledProtectedView="LabelingDisabledProtectedView",l.labelingDisabledUnsupportedLabelClient="LabelingDisabledUnsupportedLabelClient",l.msoOLDocumentError="MsoOLDocumentError",l.notImplement="NotImplement",l.objectNotFound="ObjectNotFound",l.officeJSItemLabelForIdentityError="OfficeJSItemLabelForIdentityError",l.officeJSRMSLicenseError="OfficeJSRMSLicenseError",l.officeJSSessionOrDocError="OfficeJSSessionOrDocError",l.officeSolutionFrameworkHostError="OfficeSolutionFrameworkHostError",l.omworkflowUserNotFound="OMWorkflowUserNotFound",l.osfControlContainerError="OsfControlContainerError",l.outOfMemory="OutOfMemory",l.resourceNotSupported="ResourceNotSupported",l.sensitivityDocumentReadOnly="SensitivityDocumentReadOnly",l.sensitivityInsufficientPermission="SensitivityInsufficientPermission",l.sensitivityLabelDisabled="SensitivityLabelDisabled",l.sensitivityLabelingDisabled="SensitivityLabelingDisabled",l.sensitivityLabelNotFound="SensitivityLabelNotFound",l.sensitivityNewLabelSensitivityOrder="SensitivityNewLabelSensitivityOrder",l.sensitivityUnsupportedContentType="SensitivityUnsupportedContentType",l.sensitivityUnsupportedCrossTenant="SensitivityUnsupportedCrossTenant",l.sensitivityUnsupportedDke="SensitivityUnsupportedDke",l.sensitivityUnsupportedUdp="SensitivityUnsupportedUdp",l.serverError="ServerError",l.serviceUrlNotFound="ServiceUrlNotFound",l.sharedRuntimeNotAvailable="SharedRuntimeNotAvailable",l.ticketInvalidParams="TicketInvalidParams",l.ticketNetworkError="TicketNetworkError",l.ticketUnauthorized="TicketUnauthorized",l.ticketUninitialized="TicketUninitialized",l.ticketUnknownError="TicketUnknownError",l.unexpectedError="UnexpectedError",l.unsupportedUserIdentity="UnsupportedUserIdentity",l.userNotSignedIn="UserNotSignedIn",i.Interfaces||(i.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"],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}]],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],[128,0,2,0,5],[129,0,2,0,5]],0,0,0,[["CopilotAgentEvent",0,0,"CopilotAgentEventType.onCopilotAgentEvent",65,128,129]],"Microsoft.Office.UnifiedStoreService",5]]},targetNamespaceObject:i})}(OfficeCore=OfficeCore||{}),function(e){var i,t,a,n,r,s,o;function c(e){var t=new OfficeCore.RequestContext;return t._requestFlagModifier|=64,e&&(t._customData="WacPartition"),t}function l(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=c(!0),OfficeCore.AppRuntimeService.newObject(t).setAppRuntimeState(n),[4,t.sync()];case 1:return e.sent(),[2]}})})}function u(e){var t=new OfficeCore.RequestContext;return t._requestFlagModifier|=64,e&&(t._customData="WacPartition"),t}(t=i=e.VisibilityMode||(e.VisibilityMode={})).hidden="Hidden",t.taskpane="Taskpane",(n=a=e.StartupBehavior||(e.StartupBehavior={})).none="None",n.load="Load",(r=e.addin||(e.addin={})).setStartupBehavior=function(r){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:if(r!==a.load&&r!==a.none)throw OfficeExtension.Utility.createRuntimeError(OfficeExtension.ErrorCodes.invalidArgument,null,null);return t=r==a.load?OfficeCore.AppRuntimeState.background:OfficeCore.AppRuntimeState.inactive,n=c(!1),OfficeCore.AppRuntimePersistenceService.newObject(n).setAppRuntimeStartState(t),[4,n.sync()];case 1:return e.sent(),[2]}})})},r.getStartupBehavior=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r,o;return __generator(this,function(e){switch(e.label){case 0:return t=c(!1),n=OfficeCore.AppRuntimePersistenceService.newObject(t),r=n.getAppRuntimeStartState(),[4,t.sync()];case 1:return e.sent(),o=r.value,[2,o==OfficeCore.AppRuntimeState.inactive?a.none:a.load]}})})},r.setSnapshotEnabled=function(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=c(!0),OfficeCore.AppRuntimeService.newObject(t).setSnapshotEnabled(n),[4,t.sync()];case 1:return e.sent(),[2,Promise.resolve()]}})})},r.getSnapshotEnabled=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=c(!0),n=OfficeCore.AppRuntimeService.newObject(t),r=n.getSnapshotEnabled(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},r.getContentSnapshotAsBase64=function(){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){return[2,new OfficeExtension.CoreUtility.Promise(function(t,n){var r=c(!0),e=OfficeCore.AppRuntimeService.newObject(r),o=setTimeout(function(){i.remove(),r.sync().catch(function(){}),n(OfficeExtension.Utility.createRuntimeError(OfficeExtension.ErrorCodes.generalException,"timeout","getContentSnapshotAsBase64"))},7e3),i=e.onSnapshotImageReady.add(function(e){return clearTimeout(o),i.remove(),OfficeExtension.CoreUtility.isNullOrUndefined(e)?(r.sync().catch(function(){}),n(OfficeExtension.Utility.createRuntimeError(OfficeExtension.ErrorCodes.generalException,"execution failed","getContentSnapshotAsBase64"))):(r.sync().catch(function(){}),t(e.imageBase64)),null});r.sync().then(function(){e.getContentSnapshotAsBase64();return r.sync().then(function(){return null})}).catch(function(e){n(e)})})]})})},r._getState=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=c(!0),n=OfficeCore.AppRuntimeService.newObject(t),r=n.getAppRuntimeState(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},r.showAsTaskpane=function(){return l(OfficeCore.AppRuntimeState.visible)},r.hide=function(){return l(OfficeCore.AppRuntimeState.background)},r.onVisibilityModeChanged=function(o){return __awaiter(this,void 0,void 0,function(){var t,n,r=this;return __generator(this,function(e){switch(e.label){case 0:return t=function(){if(!s){var e=c(!0);s=OfficeCore.AppRuntimeService.newObject(e)}return s}(),n=t.onVisibilityChanged.add(function(e){if(o){var t={visibilityMode:e.visibility===OfficeCore.Visibility.visible?i.taskpane:i.hidden};o(t)}return null}),[4,t.context.sync()];case 1:return e.sent(),[2,function(){return __awaiter(r,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return n.remove(),[4,t.context.sync()];case 1:return e.sent(),[2]}})})}]}})})},(o=r.beforeDocumentCloseNotification||(r.beforeDocumentCloseNotification={})).enable=function(){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return t=!1,"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(t=!0),n=u(t),OfficeCore.BeforeDocumentCloseNotification.newObject(n).enable(),[4,n.sync()];case 1:return e.sent(),[2]}})})},o.disable=function(){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return t=!1,"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(t=!0),n=u(t),OfficeCore.BeforeDocumentCloseNotification.newObject(n).disable(),[4,n.sync()];case 1:return e.sent(),[2]}})})},o.onCloseActionCancelled=function(a){return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i=this;return __generator(this,function(e){switch(e.label){case 0:return t=!1,"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(t=!0),n=u(t),r=OfficeCore.BeforeDocumentCloseNotification.newObject(n),o=r.onBeforeCloseNotificationCancelled.add(function(e){return a&&a(),null}),[4,n.sync()];case 1:return e.sent(),[2,function(){return __awaiter(i,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return o.remove(),[4,n.sync()];case 1:return e.sent(),[2]}})})}]}})})}}(Office=Office||{}),function(s){var c,e,t,n,r;function o(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}function l(){return new OfficeCore.RequestContext}(e=c=c||{}).taskpane="Taskpane",e.dialog="Dialog",n=t=s.ExtensionLifeCycle||(s.ExtensionLifeCycle={}),(r=n.taskpane||(n.taskpane={})).close=function(){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=o(),OfficeCore.TaskpaneService.newObject(t).close(),[4,t.sync()];case 1:return e.sent(),[2]}})})},r.move=function(){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=o(),OfficeCore.TaskpaneService.newObject(t).move(),[4,t.sync()];case 1:return e.sent(),[2]}})})},r.notifyHeaderLoaded=function(){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=o(),OfficeCore.TaskpaneService.newObject(t).notifyHeaderLoaded(),[4,t.sync()];case 1:return e.sent(),[2]}})})},r.setWidth=function(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=o(),OfficeCore.TaskpaneService.newObject(t).setWidth(n),[4,t.sync()];case 1:return e.sent(),[2]}})})},n.launchTaskpane=function(a){return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i;return __generator(this,function(e){switch(e.label){case 0:return s.context.platform&&"OfficeOnline"===s.context.platform?(t={SharedRuntimeId:a.sharedRuntimeId,SourceLocationOverrideResourceId:a.sourceLocationOverride,TaskPaneTitle:a.taskpaneTitle,TaskPaneWidth:a.taskpaneWidth},n={OptionalProperties:t,DevProperties:a.settings},s.context.extensionLifeCycle.launchExtensionComponent(null,"Taskpane",null,null,n),[3,3]):[3,1];case 1:return r=l(),o=OfficeCore.ExtensionLifeCycle.newObject(r),i=a.settings,a.settings=i&&OSF.OUtil.serializeSettings(i),o.launchExtensionComponent("",c.taskpane,a),[4,r.sync()];case 2:e.sent(),e.label=3;case 3:return[2]}})})},n.launchDialog=function(a){return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i;return __generator(this,function(e){switch(e.label){case 0:return s.context.platform&&"OfficeOnline"===s.context.platform?(t={SharedRuntimeId:a.sharedRuntimeId,SourceLocationOverrideResourceId:a.sourceLocationOverride},n={OptionalProperties:t,DevProperties:a.settings},s.context.extensionLifeCycle.launchExtensionComponent(null,"SDXDialog",null,null,n),[3,3]):[3,1];case 1:return r=l(),o=OfficeCore.ExtensionLifeCycle.newObject(r),i=a.settings,a.settings=i&&OSF.OUtil.serializeSettings(i),o.launchExtensionComponent("",c.dialog,a),[4,r.sync()];case 2:e.sent(),e.label=3;case 3:return[2]}})})},s.extensionLifeCycle=t}(Office=Office||{}),function(e){var t;function o(){var e=new OfficeCore.RequestContext;return"web"==OSF._OfficeAppFactory.getHostInfo().hostPlatform&&(e._customData="WacPartition"),e}(t=e.ribbon||(e.ribbon={})).requestUpdate=function(e){var t=o(),n=t.ribbon;function r(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=n.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=n.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){r(e)}):r(e)}),t.sync()},t.requestCreateControls=function(e){var n,t=o();return t.ribbon.executeRequestCreate(JSON.stringify(e)),n=250,new Promise(function(e,t){return setTimeout(function(){return e()},n)}).then(function(){return t.sync()})}}(Office=Office||{}),function(e){(e.contextMenu||(e.contextMenu={})).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()}}(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;(t||(t={})).generalException="GeneralException";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 r,t,h,g,m,y;function _(e,t){Microsoft.Office.WebExtension.sendTelemetryEvent({eventName:e,dataFields:t,eventFlags:{dataCategories:oteljs.DataCategories.ProductServiceUsage,diagnosticLevel:oteljs.DiagnosticLevel.Optional,samplingPolicy:oteljs.SamplingPolicy.CriticalBusinessImpact}})}function b(e){if(e){var t=e.toUpperCase(),n=r.mappings[t];if(!h(n)&&"function"==typeof n)return n}throw OfficeExtension.Utility.createRuntimeError("invalidOperation","sourceData","ActionProxy._getFunction")}function v(e,t,n,r){var o=OSF._OfficeAppFactory.getHostInfo();if(o&&"web"===o.hostPlatform.toLowerCase())OSF._OfficeAppFactory.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[OSF._OfficeAppFactory.getId(),OSF.AgaveHostAction.ReportAddinSkillResult,{actionCorrelationId:e,resultCode:t,replyMessage:r}]);else{if(h(window.external))throw new OfficeExtension.Error({code:"GenericException",message:"API currently unsupported."});var i=h(OSF.MethodDispId)?OSF.DDA.MethodDispId.dispidAddinSkillActionReply:OSF.MethodDispId.dispidAddinSkillActionReply;window.external.Execute(i,[e,r,t],null)}_("Office.Extensibility.AddinSkill.ExecuteAction",[oteljs.makeStringDataField("CorrelationId",e),oteljs.makeStringDataField("Message",n),oteljs.makeInt64DataField("ResultCode",t)])}function n(e){try{OfficeExtension.Utility.log("ActionProxy._handleMessage"),OfficeExtension.Utility.checkArgumentNull(e,"args");function t(e){if(d[e].messageCategory!==g)return"continue";if("string"==typeof d[e].message&&(d[e].message=JSON.parse(d[e].message)),d[e].messageType===m){var t=null,n=b(o=d[e].message[0]);if(2<=d[e].message.length){var r=d[e].message[1];r&&(t="string"==typeof(f=r)&&"{"===f[0]?JSON.parse(r):r)}void 0!==OSF&&OSF.AppTelemetry&&OSF.AppTelemetry.CallOnAppActivatedIfPending&&OSF.AppTelemetry.CallOnAppActivatedIfPending(),n.apply(null,[t])}else if(d[e].messageType===y){t=null;var o=d[e].message[0],i=d[e].message[1],a=JSON.parse(i);t=a.message;var s=a.correlationId,c=[oteljs.makeStringDataField("CorrelationId",s),oteljs.makeStringDataField("Message","ActionProxy._handleMessage is called")];_("Office.Extensibility.AddinSkill.ExecuteAction",c);var l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess;n=null;try{n=b(o)}catch(e){l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultNoActionFunctionMapping,c.push(oteljs.makeStringDataField("Message","ActionProxy._handleMessage failed to get function")),c.push(oteljs.makeInt64DataField("ResultCode",l)),_("Office.Extensibility.AddinSkill.ExecuteAction",c),O(e)}var u=null,p="";if(l==OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess)try{u=n.apply(null,[t])}catch(e){l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvocationFailed,c.push(oteljs.makeStringDataField("Message","ActionProxy._handleMessage failed to execute function")),c.push(oteljs.makeInt64DataField("ResultCode",l)),_("Office.Extensibility.AddinSkill.ExecuteAction",c),O(e)}if(l==OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess&&h(u)?(l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultNoResultGenerated,p="No result generated"):l!=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess||"object"==typeof u&&"function"==typeof u.then||(l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvalidResultGenerated,p="Invalid result generated"),l==OfficeFirstParty.AddinInvokeResult.AddinInvokeResultSuccess)try{u.then(function(e){p="Successfully executed function",h(e)?(e="",l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultNoResultGenerated,p="No result generated"):"string"!=typeof e&&(e="",l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvalidResultGenerated,p="Invalid result generated"),v(s,l,p,e)},function(e){var t="";l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvocationFailed,p="Failed to execute function","string"==typeof e?t=e:O(e),v(s,l,p,t)})}catch(e){l=OfficeFirstParty.AddinInvokeResult.AddinInvokeResultInvalidResultGenerated,p="Invalid result generated",O(e),v(s,l,p,"")}else try{v(s,l,p,"")}catch(e){O(e)}}else OfficeExtension.Utility.log("ActionProxy._handleMessage unknown message type "+d[e].messageType);var f}for(var d=e.entries,n=0;n<d.length;n++)t(n)}catch(e){throw O(e),e}return OfficeExtension.Utility._createPromiseFromResult(null)}function O(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 o(){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,"",n)}()}).then(function(){var e,t,n=OSF._OfficeAppFactory.getHostInfo();return!0===n.isDialog||"web"===n.hostPlatform&&"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){}}h=OfficeExtension.Utility.isNullOrUndefined,g=2,m=1e3,y=1001,OfficeExtension.Utility.log("ActionProxy.initOnce"),void 0!==e.actions&&(t=e.actions._association,r=t),"undefined"!=typeof document&&(document.readyState&&"loading"!==document.readyState?(OfficeExtension.Utility.log("ActionProxy.initOnce: document.readyState is not loading state"),o()):document.addEventListener&&document.addEventListener("DOMContentLoaded",function(){OfficeExtension.Utility.log("ActionProxy.initOnce: DOMContentLoaded event triggered"),o()})),OfficeExtension.HostBridge.onInited(function(e){e.addHostMessageHandler(function(e){3===e.type&&n(e.message)})})}(Office=Office||{}),function(e){var t;function c(e){var t=new OfficeCore.RequestContext;return e&&e.controlId&&(t.requestHeaders[OfficeExtension.Constants.officeControlId]=e.controlId),t._customData="WacPartition",t}(t=e.AugLoop||(e.AugLoop={})).SendMessage=function(r,o){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return t=void 0!==o?o:r,n=c(void 0!==o?r:void 0),OfficeCore.AugLoopEventService.newObject(n).sendMessage(t),[4,n.sync()];case 1:return e.sent(),[2]}})})},t.onHostMessageReceived=function(a,s){return __awaiter(this,void 0,void 0,function(){var n,t,r,o,i=this;return __generator(this,function(e){switch(e.label){case 0:return n=void 0!==s?s:a,t=c(void 0!==s?a:void 0),r=OfficeCore.AugLoopEventService.newObject(t),o=function(e){if(n){var t=e.data;n(t)}return null},r.onHostMessageReceived.add(o),[4,r.context.sync()];case 1:return e.sent(),[2,function(){return __awaiter(i,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return r.onHostMessageReceived.remove(o),[4,t.sync()];case 1:return e.sent(),[2]}})})}]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t,u,p;function f(e){return"object"==typeof e&&"string"==typeof e.controlId?e.controlId:void 0}function d(e){var t=new OfficeCore.RequestContext;return e&&(t.requestHeaders[OfficeExtension.Constants.officeControlId]=e),t._customData="SkipUndoRecording",t}t=e.Undo||(e.Undo={}),p={},t.undo=function(o){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=d(f(o)),n=OfficeCore.UndoService.newObject(t),r=n.undo(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.onUndoStackChanged=function(i,a){return __awaiter(this,void 0,void 0,function(){var t,n,r,o=this;return __generator(this,function(e){switch(e.label){case 0:return t=a||i,n=d(f(a?i:void 0)),(r=OfficeCore.UndoService.newObject(n)).onUndoStackChanged.add(t),[4,n.sync()];case 1:return e.sent(),[2,function(){return __awaiter(o,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return r.onUndoStackChanged.remove(t),[4,n.sync()];case 1:return e.sent(),[2]}})})}]}})})},t.startCopilotOperation=function(l){return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i,a,s,c;return __generator(this,function(e){switch(e.label){case 0:if(void 0===(t=f(l))){if(void 0!==u)throw new Error("startCopilotOperation is already inprogress")}else if(p[t])throw new Error("startCopilotOperation is already in progress");n=function(){},r=new Promise(function(e){void 0===t?u=e:p[t]=e}),e.label=1;case 1:return e.trys.push([1,4,,5]),o=d(t),i=OfficeCore.UndoService.newObject(o),a=function(){return function(t){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){return void 0===t?void 0!==u&&(u(),u=void 0):p[t]&&(p[t](),delete p[t]),[2]})})}(t)},n=function(){try{i.onCopilotOperationStarted.remove(a),o.sync()}catch(e){}},i.onCopilotOperationStarted.add(a),[4,o.sync()];case 2:return e.sent(),s=i.startCopilotOperation(""),[4,o.sync()];case 3:return(e.sent(),s.value)?(void 0!==t&&r.then(function(){n()}),[2,r]):(void 0===t?u=void 0:(n(),delete p[t]),[3,5]);case 4:throw c=e.sent(),void 0===t?u=void 0:(n(),delete p[t]),c;case 5:return[2]}})})},t.endCopilotOperation=function(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=d(f(n)),OfficeCore.UndoService.newObject(t).endCopilotOperation(""),[4,t.sync()];case 1:return e.sent(),[2]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t;(t=e.dialogPage||(e.dialogPage={})).close=function(){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=new OfficeCore.RequestContext,OfficeCore.DialogPage.newObject(t).close(),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.readyToShow=function(){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=new OfficeCore.RequestContext,OfficeCore.DialogPage.newObject(t).readyToShow(),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.onShow=function(o){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=new OfficeCore.RequestContext,(n=OfficeCore.DialogPage.newObject(t)).onOnShowEvent.add(o),r=function(){return n.onOnShowEvent.remove(o),null},[4,t.sync()];case 1:return e.sent(),[2,r]}})})},t.sendMessageToHost=function(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=new OfficeCore.RequestContext,OfficeCore.DialogPage.newObject(t).sendMessageToHost(n),[4,t.sync()];case 1:return e.sent(),[2]}})})}}(Office=Office||{}),function(e){var t;function a(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}(t=e.UserFeedback||(e.UserFeedback={})).CollectUserFeedback=function(n,r,o,i){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=a(),OfficeCore.UserFeedbackService.newObject(t).collectUserFeedback(n,r,o,i),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.onUserFeedbackUIDismissed=function(i){return __awaiter(this,void 0,void 0,function(){var t,n,r,o=this;return __generator(this,function(e){switch(e.label){case 0:return t=function(e){if(i){var t=e.isFeedbackSent;i(t)}return null},n=a(),(r=OfficeCore.UserFeedbackService.newObject(n)).onUserFeedbackUIDismissed.add(t),[4,r.context.sync()];case 1:return e.sent(),[2,function(){return __awaiter(o,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return r.onUserFeedbackUIDismissed.remove(t),[4,n.sync()];case 1:return e.sent(),[2]}})})}]}})})},t.CanCollectUserFeedback=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=a(),n=OfficeCore.UserFeedbackService.newObject(t),r=n.canCollectUserFeedback(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.onUserFeedbackResponse=function(i){return __awaiter(this,void 0,void 0,function(){var t,n,r,o=this;return __generator(this,function(e){switch(e.label){case 0:return t=function(e){if(i){var t=e.responseData;i(t)}return null},n=a(),(r=OfficeCore.UserFeedbackService.newObject(n)).onUserFeedbackResponse.add(t),[4,r.context.sync()];case 1:return e.sent(),[2,function(){return __awaiter(o,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return r.onUserFeedbackResponse.remove(t),[4,n.sync()];case 1:return e.sent(),[2]}})})}]}})})},t.InvokeDiagnosticsLogsUpload=function(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=a(),OfficeCore.UserFeedbackService.newObject(t).invokeDiagnosticsLogsUpload(n),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.GetInitializationData=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=a(),n=OfficeCore.UserFeedbackService.newObject(t),r=n.getInitializationData(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.GetHostScreenshot=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=a(),n=OfficeCore.UserFeedbackService.newObject(t),r=n.getHostScreenshot(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.CanCollectCopilotFeedback=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=a(),n=OfficeCore.UserFeedbackService.newObject(t),r=n.canCollectCopilotFeedback(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.CollectFeedbackEligibility=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=a(),n=OfficeCore.UserFeedbackService.newObject(t),r=n.collectFeedbackEligibility(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.CheckFeedbackEligibility=function(o){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=a(),n=OfficeCore.UserFeedbackService.newObject(t),r=n.checkFeedbackEligibility(o),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t,n;function s(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}function c(e){return JSON.stringify(e instanceof n?{type:"callout",params:e.params}:{type:"custom",props:e})}t=e.Notification||(e.Notification={}),n=function(){},t.callout=function(e){var t=new n;return t.params=e,t},t.addNotification=function(i,a){return __awaiter(this,void 0,void 0,function(){var n,r,o;return __generator(this,function(e){switch(e.label){case 0:return n=s(),r=OfficeCore.NotificationService.newObject(n),o=r.addNotification(c(i),(t=a,JSON.stringify(t))),[4,n.sync()];case 1:return e.sent(),[2,o.value]}var t})})},t.updateNotification=function(n,r){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=s(),OfficeCore.NotificationService.newObject(t).updateNotification(n,c(r)),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.removeNotification=function(n){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=s(),OfficeCore.NotificationService.newObject(t).removeNotification(n),[4,t.sync()];case 1:return e.sent(),[2]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t;function l(e){var t=new OfficeCore.RequestContext;return e&&e.controlId&&(t.requestHeaders[OfficeExtension.Constants.officeControlId]=e.controlId),t._customData="WacPartition",t}(t=e.Sensitivity||(e.Sensitivity={})).getLabel=function(o){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=l(o),n=OfficeCore.SensitivityService.newObject(t),r=n.getLabel(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})},t.tryUpgradeLabel=function(){for(var a=[],e=0;e<arguments.length;e++)a[e]=arguments[e];return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i;return __generator(this,function(e){switch(e.label){case 0:if(t=3===a.length,2!==a.length&&3!==a.length)throw new Error("tryUpgradeLabel: Invalid number of parameters ("+a.length+")");return n=t?a[0]:void 0,r=t?a[1]:a[0],o=t?a[2]:a[1],i=l(n),OfficeCore.SensitivityService.newObject(i).tryUpgradeLabel(r,o),[4,i.sync()];case 1:return e.sent(),[2]}})})},t.getHighestSensitivityLabel=function(){for(var s=[],e=0;e<arguments.length;e++)s[e]=arguments[e];return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i,a;return __generator(this,function(e){switch(e.label){case 0:if(t=2===s.length,1!==s.length&&2!==s.length)throw new Error("getHighestSensitivityLabel: Invalid number of parameters ("+s.length+")");return n=t?s[0]:void 0,r=t?s[1]:s[0],o=l(n),i=OfficeCore.SensitivityService.newObject(o),a=i.getHighestSensitivityLabel(r),[4,o.sync()];case 1:return e.sent(),[2,a.value]}})})},t.getSensitivityResultDetails=function(){for(var c=[],e=0;e<arguments.length;e++)c[e]=arguments[e];return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i,a,s;return __generator(this,function(e){switch(e.label){case 0:if(t=3===c.length,2!==c.length&&3!==c.length)throw new Error("getSensitivityResultDetails: Invalid number of parameters ("+c.length+")");return n=t?c[0]:void 0,r=t?c[1]:c[0],o=t?c[2]:c[1],i=l(n),a=OfficeCore.SensitivityService.newObject(i),s=a.getSensitivityResultDetails(r,o),[4,i.sync()];case 1:return e.sent(),[2,s.value]}})})},t.getSensitivityResultDetailsByStringErrorCode=function(){for(var c=[],e=0;e<arguments.length;e++)c[e]=arguments[e];return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i,a,s;return __generator(this,function(e){switch(e.label){case 0:if(t=3===c.length,2!==c.length&&3!==c.length)throw new Error("getSensitivityResultDetails: Invalid number of parameters ("+c.length+")");return n=t?c[0]:void 0,r=t?c[1]:c[0],o=t?c[2]:c[1],i=l(n),a=OfficeCore.SensitivityService.newObject(i),s=a.getSensitivityResultDetailsByStringErrorCode(r,o),[4,i.sync()];case 1:return e.sent(),[2,s.value]}})})},t.onLabelChangedEvent=function(){for(var c=[],e=0;e<arguments.length;e++)c[e]=arguments[e];return __awaiter(this,void 0,void 0,function(){var t,n,i,r,o,a,s=this;return __generator(this,function(e){switch(e.label){case 0:if(t=2===c.length,1!==c.length&&2!==c.length)throw new Error("onLabelChangedEvent: Invalid number of parameters ("+c.length+")");return n=t?c[0]:void 0,i=t?c[1]:c[0],r=function(e){if(i){var t=e.previousLabel,n=e.newLabel,r=e.context,o=e.error;i(t,n,r,o)}return null},o=l(n),(a=OfficeCore.SensitivityService.newObject(o)).onLabelChanged.add(r),[4,a.context.sync()];case 1:return e.sent(),[2,function(){return __awaiter(s,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return a.onLabelChanged.remove(r),[4,o.sync()];case 1:return e.sent(),[2]}})})}]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t;function o(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}(t=e.Copilot||(e.Copilot={})).launchHelpPaneByQuery=function(r){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return t=o(),n=OfficeCore.CopilotService.newObject(t),n.launchHelpPaneByQuery(r),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.launchHelpPaneByArticleId=function(r){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return t=o(),n=OfficeCore.CopilotService.newObject(t),n.launchHelpPaneByArticleId(r),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.launchHelpPaneByArticleIdString=function(r){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return t=o(),n=OfficeCore.CopilotService.newObject(t),n.launchHelpPaneByArticleIdString(r),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.launchTaskPaneByAgentId=function(r){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return t=o(),n=OfficeCore.CopilotService.newObject(t),n.launchTaskPaneByAgentId(r),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.getWindowClientWidth=function(){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:return t=o(),n=OfficeCore.CopilotService.newObject(t),r=n.getWindowClientWidth(),[4,t.sync()];case 1:return e.sent(),[2,r.value]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t;function l(e){var t=new OfficeCore.RequestContext;return e&&e.controlId&&(t.requestHeaders[OfficeExtension.Constants.officeControlId]=e.controlId),t._customData="WacPartition",t}(t=e.PrivateApi||(e.PrivateApi={})).execute=function(){for(var s=[],e=0;e<arguments.length;e++)s[e]=arguments[e];return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i,a;return __generator(this,function(e){switch(e.label){case 0:return t=2<=s.length,n=t?s[0]:void 0,r=t?s[1]:s[0],o=l(n),i=OfficeCore.PrivateApiService.newObject(o),a=i.execute(r),[4,o.sync()];case 1:return e.sent(),[2,a.value]}})})},t.onPrivateEvent=function(){for(var c=[],e=0;e<arguments.length;e++)c[e]=arguments[e];return __awaiter(this,void 0,void 0,function(){var t,n,r,o,i,a,s=this;return __generator(this,function(e){switch(e.label){case 0:return t=2<=c.length,n=t?c[0]:void 0,r=t?c[1]:c[0],o=function(e){if(r){var t=e.messageData;r(t)}return null},i=l(n),(a=OfficeCore.PrivateApiService.newObject(i)).onOnPrivateEvent.add(o),[4,a.context.sync()];case 1:return e.sent(),[2,function(){return __awaiter(s,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return a.onOnPrivateEvent.remove(o),[4,i.sync()];case 1:return e.sent(),[2]}})})}]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t,i,n;function a(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}t=e.UnifiedStore||(e.UnifiedStore={}),(i=t.DefaultPageType||(t.DefaultPageType={})).copilotAgentsPage="CopilotAgentsPage",(n=t.CopilotAgentActionType||(t.CopilotAgentActionType={})).activated="Activated",n.removed="Removed",t.launchStore=function(o){return __awaiter(this,void 0,void 0,function(){var t,n,r;return __generator(this,function(e){switch(e.label){case 0:if(o!==i.copilotAgentsPage)throw OfficeExtension.Utility.createRuntimeError(OfficeExtension.ErrorCodes.invalidArgument,null,null);return(t=a(),n=OfficeCore.UnifiedStoreService.newObject(t),o!=i.copilotAgentsPage)?[3,2]:(r=n.launchStoreDialogWithCopilotAgentPageShown(),[4,t.sync()]);case 1:return e.sent(),[2,r];case 2:return[2]}})})},t.onCopilotAgentEvent=function(i){return __awaiter(this,void 0,void 0,function(){var t,n,r,o=this;return __generator(this,function(e){switch(e.label){case 0:return t=function(e){if(i){var t=JSON.parse(e.messageData),n=t.actionType,r=t.titleId;i({actionType:n,titleId:r})}return null},n=a(),(r=OfficeCore.UnifiedStoreService.newObject(n)).onCopilotAgentEvent.add(t),[4,r.context.sync()];case 1:return e.sent(),[2,function(){return __awaiter(o,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return r.onCopilotAgentEvent.remove(t),[4,n.sync()];case 1:return e.sent(),[2]}})})}]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t;function o(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}(t=e.BusinessBar||(e.BusinessBar={})).hide=function(r){return __awaiter(this,void 0,void 0,function(){var t,n;return __generator(this,function(e){switch(e.label){case 0:return t=o(),n=OfficeCore.BusinessBarService.newObject(t),n.hide(r),[4,t.sync()];case 1:return e.sent(),[2]}})})},t.show=function(n,r){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(e){switch(e.label){case 0:return t=o(),OfficeCore.BusinessBarService.newObject(t).show(n,r),[4,t.sync()];case 1:return e.sent(),[2]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){(e.SimpleDialog||(e.SimpleDialog={})).launchSimpleDialog=function(i){return __awaiter(this,void 0,void 0,function(){var n,r,o;return __generator(this,function(e){switch(e.label){case 0:return(t=new OfficeCore.RequestContext)._customData="WacPartition",n=t,r=OfficeCore.ShowSimpleDialog.newObject(n),o=r.launchSimpleDialog(i.title,i.description,i.telemetryid,i.category,i.hasButton,i.buttonLabel,i.hasCheckbox,i.checkboxLabel),[4,n.sync()];case 1:return e.sent(),[2,o.value]}var t})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){(e.DispatchApi||(e.DispatchApi={})).execute=function(i,a){return __awaiter(this,void 0,void 0,function(){var n,r,o;return __generator(this,function(e){switch(e.label){case 0:return(t=new OfficeCore.RequestContext)._customData="WacPartition",n=t,r=OfficeCore.DispatchApiService.newObject(n),o=r.execute(i,a),[4,n.sync()];case 1:return e.sent(),[2,o.value]}var t})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){var t;(t=e.DevicePermissionType||(e.DevicePermissionType={})).camera="camera",t.microphone="microphone",t.geolocation="geolocation",(e.devicePermission||(e.devicePermission={})).requestPermissions=function(i){return __awaiter(this,void 0,void 0,function(){var n,r,o;return __generator(this,function(e){switch(e.label){case 0:return(t=new OfficeCore.RequestContext)._customData="WacPartition",n=t,r=OfficeCore.DevicePermissionService.newObject(n),o=r.requestPermissions(i),[4,n.sync()];case 1:return e.sent(),[2,o.value]}var t})})}}(Office=Office||{}),function(e){var c,t,n,l,r;function u(){var e=new OfficeCore.RequestContext;return e._customData="WacPartition",e}function p(e){!function(){if(null==r){r=function(e){var t=e.actionCorrelationId,n=(e.replyMessage,e.resultCode,l[t]);return null!=n&&(n.replyMessage=e.replyMessage,n.resultCode=e.resultCode,n.replyPromiseResolver()),null};var e=u();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}),l[e]=t}(t=c=e.AddinInvokeResult||(e.AddinInvokeResult={}))[t.AddinInvokeResultNotInstalled=-1]="AddinInvokeResultNotInstalled",t[t.AddinInvokeResultSkillNotFound=-2]="AddinInvokeResultSkillNotFound",t[t.AddinInvokeResultLaunchFailed=-3]="AddinInvokeResultLaunchFailed",t[t.AddinInvokeResultSuccess=0]="AddinInvokeResultSuccess",t[t.AddinInvokeResultInvocationFailed=1]="AddinInvokeResultInvocationFailed",t[t.AddinInvokeResultNoResultGenerated=2]="AddinInvokeResultNoResultGenerated",t[t.AddinInvokeResultInvalidResultGenerated=3]="AddinInvokeResultInvalidResultGenerated",t[t.AddinInvokeResultNoActionFunctionMapping=4]="AddinInvokeResultNoActionFunctionMapping",n=e.AddinSkillAction||(e.AddinSkillAction={}),l={},r=null,n.InvokeAction=function(i,a,s){return __awaiter(this,void 0,void 0,function(){var t,n,r,o;return __generator(this,function(e){switch(e.label){case 0:t=u(),n=OfficeCore.AddinSkillActionService.newObject(t),r=OSF.OUtil.Guid.generateNewGuid(),o=p(r),e.label=1;case 1:return e.trys.push([1,,4,5]),n.invokeAction(i,a,s,r),[4,t.sync()];case 2:return e.sent(),[4,o.replyPromise];case 3:return e.sent(),[3,5];case 4:return delete l[r],[7];case 5:if(o.resultCode==c.AddinInvokeResultSuccess){if("string"==typeof o.replyMessage)return[2,o.replyMessage];o.resultCode=c.AddinInvokeResultInvalidResultGenerated}switch(o.resultCode){case c.AddinInvokeResultNotInstalled:throw new OfficeExtension.Error({code:"AddinNotInstalled",message:"Add-in not installed."});case c.AddinInvokeResultSkillNotFound:throw new OfficeExtension.Error({code:"SkillNotFound",message:"Skill not found in the add-in manifest."});case c.AddinInvokeResultLaunchFailed:throw new OfficeExtension.Error({code:"LaunchFailed",message:"Add-in launch failed."});case c.AddinInvokeResultInvocationFailed:throw new OfficeExtension.Error({code:"InvocationFailed",message:"Skill invocation failed."});case c.AddinInvokeResultNoResultGenerated:throw new OfficeExtension.Error({code:"NoResultGenerated",message:"No result generated."});case c.AddinInvokeResultInvalidResultGenerated:throw new OfficeExtension.Error({code:"InvalidResultGenerated",message:"Invalid result generated."});case c.AddinInvokeResultNoActionFunctionMapping:throw new OfficeExtension.Error({code:"NoActionFunctionMapping",message:"No action function mapping."});default:throw new OfficeExtension.Error({code:"UnknownError",message:"Unknown error (code = "+o.resultCode+")."})}return[2]}})})}}(OfficeFirstParty=OfficeFirstParty||{}),function(e){(e.ThemeService||(e.ThemeService={})).getofficethemedataforvisualsurface=function(i){return __awaiter(this,void 0,void 0,function(){var n,r,o;return __generator(this,function(e){switch(e.label){case 0:return(t=new OfficeCore.RequestContext)._customData="WacPartition",n=t,r=OfficeCore.ThemeService.newObject(n),o=r.getOfficeThemeDataForVisualSurface(i),[4,n.sync()];case 1:return e.sent(),[2,JSON.parse(o.value)]}var t})})}}(OfficeFirstParty=OfficeFirstParty||{});var Word;__extends=this&&this.__extends||function(){var r=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(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}}();!function(i){function a(e,t){if(OfficeExtension.Utility.isNullOrUndefined(t))return null;if("object"!=typeof t&&OfficeExtension.Utility.throwError(OfficeExtension.ResourceStrings.invalidArgument,"searchOptions"),t instanceof i.SearchOptions)return t;var n=i.SearchOptions.newObject(e);for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);return n}function s(){return"undefined"!=typeof window&&window.Office&&window.Office.context&&window.Office.context.requirements&&window.Office.context.requirements.isSetSupported("WordApiSearchFlags","1.1")}function c(e){if(OfficeExtension.Utility.isNullOrUndefined(e))return 0;"object"!=typeof e&&OfficeExtension.Utility.throwError(OfficeExtension.ResourceStrings.invalidArgument,"searchOptions");var t=0;return e instanceof i.SearchOptions&&(e=e.toJSON()),e.ignorePunct&&(t|=32),e.ignoreSpace&&(t|=64),e.matchCase&&(t|=1),e.matchPrefix&&(t|=8),e.matchSuffix&&(t|=16),e.matchWildcards&&(t|=4),e.matchWholeWord&&(t|=2),t}var n,e,l="Word",u="WordApi",t=OfficeExtension.BatchApiHelper.createPropertyObject,p=OfficeExtension.BatchApiHelper.createMethodObject,r=OfficeExtension.BatchApiHelper.createIndexerObject,o=(OfficeExtension.BatchApiHelper.createRootServiceObject,OfficeExtension.BatchApiHelper.createTopLevelServiceObject),f=OfficeExtension.BatchApiHelper.createChildItemObject,d=OfficeExtension.BatchApiHelper.invokeMethod,h=OfficeExtension.BatchApiHelper.invokeEnsureUnchanged,g=OfficeExtension.BatchApiHelper.invokeSetProperty,m=OfficeExtension.Utility.isNullOrUndefined,y=OfficeExtension.Utility.isUndefined,_=OfficeExtension.Utility.throwIfNotLoaded,b=OfficeExtension.Utility.throwIfApiNotSupported,v=OfficeExtension.Utility.load,O=OfficeExtension.Utility.retrieve,C=OfficeExtension.Utility.toJson,P=OfficeExtension.Utility.fixObjectPathIfNecessary,S=OfficeExtension.Utility._handleNavigationPropertyResults,A=OfficeExtension.Utility.adjustToDateTime,I=OfficeExtension.Utility.processRetrieveResult,R=OfficeExtension.Utility.setMockData,T=(OfficeExtension.CommonUtility.calculateApiFlags,"AugloopAnnotation"),E=(n=OfficeExtension.ClientObject,__extends(N,n),Object.defineProperty(N.prototype,"_className",{get:function(){return"AugloopAnnotation"},enumerable:!0,configurable:!0}),Object.defineProperty(N.prototype,"_scalarPropertyNames",{get:function(){return["content","id","_ReferenceId","_State"]},enumerable:!0,configurable:!0}),Object.defineProperty(N.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Content","Id","_ReferenceId","_State"]},enumerable:!0,configurable:!0}),Object.defineProperty(N.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(N.prototype,"content",{get:function(){return _("content",this._C,T,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(N.prototype,"id",{get:function(){return _("id",this._I,T,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(N.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,T,this._isNull),this.__R},enumerable:!0,configurable:!0}),Object.defineProperty(N.prototype,"_State",{get:function(){return _("_State",this.__S,T,this._isNull),this.__S},set:function(e){this.__S=e,g(this,"_State",e,0)},enumerable:!0,configurable:!0}),N.prototype.delete=function(){d(this,"Delete",0,[],0,0)},N.prototype.getParentAsAnnotation=function(){return p(i.AugloopAnnotation,this,"GetParentAsAnnotation",1,[],!1,!1,null,4)},N.prototype.getParentAsParagraph=function(){return p(i.Paragraph,this,"GetParentAsParagraph",1,[],!1,!1,null,4)},N.prototype.getParentType=function(){return d(this,"GetParentType",1,[],4,0)},N.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},N.prototype._handleResult=function(e){if(n.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Content)||(this._C=t.Content),y(t.Id)||(this._I=t.Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),y(t._State)||(this.__S=t._State)}},N.prototype.load=function(e){return v(this,e)},N.prototype.retrieve=function(e){return O(this,e)},N.prototype._handleIdResult=function(e){n.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},N.prototype._handleRetrieveResult=function(e,t){n.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},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 C(this,{content:this._C,id:this._I},{})},N.prototype.setMockData=function(e){R(this,e)},N.prototype.ensureUnchanged=function(e){h(this,e)},N);function N(){return null!==n&&n.apply(this,arguments)||this}i.AugloopAnnotation=E,(e=i.CritiqueColorScheme||(i.CritiqueColorScheme={})).red="Red",e.green="Green",e.blue="Blue",e.lavender="Lavender",e.berry="Berry";var D,x,w="CritiqueAnnotation",F=(D=OfficeExtension.ClientObject,__extends(j,D),Object.defineProperty(j.prototype,"_className",{get:function(){return"CritiqueAnnotation"},enumerable:!0,configurable:!0}),Object.defineProperty(j.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","critique"]},enumerable:!0,configurable:!0}),Object.defineProperty(j.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Critique"]},enumerable:!0,configurable:!0}),Object.defineProperty(j.prototype,"_navigationPropertyNames",{get:function(){return["range"]},enumerable:!0,configurable:!0}),Object.defineProperty(j.prototype,"range",{get:function(){return this._R||(this._R=t(i.Range,this,"Range",!1,4)),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(j.prototype,"critique",{get:function(){return _("critique",this._C,w,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(j.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,w,this._isNull),this.__R},enumerable:!0,configurable:!0}),j.prototype.accept=function(){d(this,"Accept",0,[],0,0)},j.prototype.reject=function(){d(this,"Reject",0,[],0,0)},j.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},j.prototype._handleResult=function(e){if(D.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Critique)||(this._C=t.Critique),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["range","Range"])}},j.prototype.load=function(e){return v(this,e)},j.prototype.retrieve=function(e){return O(this,e)},j.prototype._handleIdResult=function(e){D.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},j.prototype._handleRetrieveResult=function(e,t){D.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},j.prototype.track=function(){return this.context.trackedObjects.add(this),this},j.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},j.prototype.toJSON=function(){return C(this,{critique:this._C},{})},j.prototype.setMockData=function(e){R(this,e)},j.prototype.ensureUnchanged=function(e){h(this,e)},j);function j(){return null!==D&&D.apply(this,arguments)||this}i.CritiqueAnnotation=F,(x=i.AnnotationState||(i.AnnotationState={})).created="Created",x.accepted="Accepted",x.rejected="Rejected";var k,M="Annotation",H=(k=OfficeExtension.ClientObject,__extends(L,k),Object.defineProperty(L.prototype,"_className",{get:function(){return"Annotation"},enumerable:!0,configurable:!0}),Object.defineProperty(L.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","state"]},enumerable:!0,configurable:!0}),Object.defineProperty(L.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","State"]},enumerable:!0,configurable:!0}),Object.defineProperty(L.prototype,"_navigationPropertyNames",{get:function(){return["critiqueAnnotation"]},enumerable:!0,configurable:!0}),Object.defineProperty(L.prototype,"critiqueAnnotation",{get:function(){return this._C||(this._C=t(i.CritiqueAnnotation,this,"CritiqueAnnotation",!1,4)),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(L.prototype,"id",{get:function(){return _("id",this._I,M,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(L.prototype,"state",{get:function(){return _("state",this._S,M,this._isNull),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(L.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,M,this._isNull),this.__R},enumerable:!0,configurable:!0}),L.prototype.delete=function(){d(this,"Delete",0,[],0,0)},L.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},L.prototype._handleResult=function(e){if(k.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Id)||(this._I=t.Id),y(t.State)||(this._S=t.State),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["critiqueAnnotation","CritiqueAnnotation"])}},L.prototype.load=function(e){return v(this,e)},L.prototype.retrieve=function(e){return O(this,e)},L.prototype._handleIdResult=function(e){k.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},L.prototype._handleRetrieveResult=function(e,t){k.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},L.prototype.track=function(){return this.context.trackedObjects.add(this),this},L.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},L.prototype.toJSON=function(){return C(this,{id:this._I,state:this._S},{})},L.prototype.setMockData=function(e){R(this,e)},L.prototype.ensureUnchanged=function(e){h(this,e)},L);function L(){return null!==k&&k.apply(this,arguments)||this}i.Annotation=H;var U,B="AnnotationCollection",W=(U=OfficeExtension.ClientObject,__extends(G,U),Object.defineProperty(G.prototype,"_className",{get:function(){return"AnnotationCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(G.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(G.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(G.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(G.prototype,"items",{get:function(){return _("items",this.m__items,B,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(G.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,B,this._isNull),this.__R},enumerable:!0,configurable:!0}),G.prototype.getFirst=function(){return p(i.Annotation,this,"GetFirst",0,[],!1,!1,null,0)},G.prototype.getFirstOrNullObject=function(){return p(i.Annotation,this,"GetFirstOrNullObject",0,[],!1,!1,null,0)},G.prototype._GetItem=function(e){return r(i.Annotation,this,[e])},G.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},G.prototype._handleResult=function(e){if(U.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Annotation,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},G.prototype.load=function(e){return v(this,e)},G.prototype.retrieve=function(e){return O(this,e)},G.prototype._handleIdResult=function(e){U.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},G.prototype._handleRetrieveResult=function(e,t){var n=this;U.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Annotation,!0,n,e,t)})},G.prototype.track=function(){return this.context.trackedObjects.add(this),this},G.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},G.prototype.toJSON=function(){return C(this,{},{},this.m__items)},G.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Annotation,!0,n,e,t)},function(e){return n.m__items=e})},G);function G(){return null!==U&&U.apply(this,arguments)||this}i.AnnotationCollection=W;var q,V="AugloopAnnotationCollection",z=(q=OfficeExtension.ClientObject,__extends(J,q),Object.defineProperty(J.prototype,"_className",{get:function(){return"AugloopAnnotationCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(J.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(J.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(J.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(J.prototype,"items",{get:function(){return _("items",this.m__items,V,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(J.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,V,this._isNull),this.__R},enumerable:!0,configurable:!0}),J.prototype.getFirst=function(){return p(i.AugloopAnnotation,this,"GetFirst",1,[],!1,!1,null,4)},J.prototype.getFirstOrNullObject=function(){return p(i.AugloopAnnotation,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},J.prototype.getItem=function(e){return r(i.AugloopAnnotation,this,[e])},J.prototype.refresh=function(){d(this,"Refresh",1,[],4,0)},J.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},J.prototype._handleResult=function(e){if(q.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.AugloopAnnotation,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},J.prototype.load=function(e){return v(this,e)},J.prototype.retrieve=function(e){return O(this,e)},J.prototype._handleIdResult=function(e){q.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},J.prototype._handleRetrieveResult=function(e,t){var n=this;q.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.AugloopAnnotation,!0,n,e,t)})},Object.defineProperty(J.prototype,"onAnnotationAdded",{get:function(){var n=this;return this.m_annotationAdded||(this.m_annotationAdded=new OfficeExtension.GenericEventHandlers(this.context,this,"AnnotationAdded",{eventType:4,registerFunc:function(){return n._RegisterAddedEvent()},unregisterFunc:function(){return n._UnregisterAddedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.AugloopAnnotationCollection_AnnotationAdded_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_annotationAdded},enumerable:!0,configurable:!0}),Object.defineProperty(J.prototype,"onAnnotationChanged",{get:function(){var n=this;return this.m_annotationChanged||(this.m_annotationChanged=new OfficeExtension.GenericEventHandlers(this.context,this,"AnnotationChanged",{eventType:5,registerFunc:function(){return n._RegisterChangedEvent()},unregisterFunc:function(){return n._UnregisterChangedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.AugloopAnnotationCollection_AnnotationChanged_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_annotationChanged},enumerable:!0,configurable:!0}),Object.defineProperty(J.prototype,"onAnnotationDeleted",{get:function(){var n=this;return this.m_annotationDeleted||(this.m_annotationDeleted=new OfficeExtension.GenericEventHandlers(this.context,this,"AnnotationDeleted",{eventType:6,registerFunc:function(){return n._RegisterDeletedEvent()},unregisterFunc:function(){return n._UnregisterDeletedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.AugloopAnnotationCollection_AnnotationDeleted_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_annotationDeleted},enumerable:!0,configurable:!0}),J.prototype.track=function(){return this.context.trackedObjects.add(this),this},J.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},J.prototype.toJSON=function(){return C(this,{},{},this.m__items)},J.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.AugloopAnnotation,!0,n,e,t)},function(e){return n.m__items=e})},J);function J(){return null!==q&&q.apply(this,arguments)||this}i.AugloopAnnotationCollection=z;var K,X,Q=($.prototype.getDocument=function(){return m(this._document)&&(this._document=this.context.document),this._document},$.prototype.getReferenceId=function(){return m(this._refId)&&(this._refId=this._ReferenceId),this._refId},$.prototype._RegisterAddedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"AnnotationAdded")},$.prototype._UnregisterAddedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"AnnotationAdded")},$.prototype._RegisterChangedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"AnnotationChanged")},$.prototype._UnregisterChangedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"AnnotationChanged")},$.prototype._RegisterDeletedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"AnnotationDeleted")},$.prototype._UnregisterDeletedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"AnnotationDeleted")},$);function $(){}i.AugloopAnnotationCollectionCustom=Q,OfficeExtension.Utility.applyMixin(z,Q),(X=K=i._CC||(i._CC={})).AugloopAnnotationCollection_AnnotationAdded_EventArgsTransform=function(e,t){var n={eventType:i.EventType.annotationAdded,annotation:OfficeExtension.BatchApiHelper.createObjectFromReferenceId(i.AugloopAnnotation,e.context,t)};return n.annotation.load(),n},X.AugloopAnnotationCollection_AnnotationChanged_EventArgsTransform=function(e,t){var n={eventType:i.EventType.annotationChanged,annotation:OfficeExtension.BatchApiHelper.createObjectFromReferenceId(i.AugloopAnnotation,e.context,t)};return n.annotation.load(),n},X.AugloopAnnotationCollection_AnnotationDeleted_EventArgsTransform=function(e,t){var n={eventType:i.EventType.annotationDeleted,annotation:OfficeExtension.BatchApiHelper.createObjectFromReferenceId(i.AugloopAnnotation,e.context,t)};return n.annotation.load(),n};var Z,Y=(Z=OfficeExtension.ClientObject,__extends(ee,Z),Object.defineProperty(ee.prototype,"_className",{get:function(){return"Application"},enumerable:!0,configurable:!0}),ee.prototype.createDocument=function(e){return p(i.DocumentCreated,this,"CreateDocument",1,[e],!1,!1,null,4)},ee.prototype.getEnterpriseUserInfo=function(){return d(this,"GetEnterpriseUserInfo",1,[],5,0)},ee.prototype.getMruFriendlyPath=function(e){return d(this,"GetMruFriendlyPath",1,[e],5,0)},ee.prototype.getSharePointTenantRoot=function(){return d(this,"GetSharePointTenantRoot",1,[],5,0)},ee.prototype.isTapEnabled=function(){return d(this,"IsTapEnabled",1,[],5,0)},ee.prototype.launchFileUrlInOfficeApp=function(e,t){return d(this,"LaunchFileUrlInOfficeApp",1,[e,t],5,0)},ee.prototype.openDocument=function(e){b("Application.openDocument",u,"1.6",l),d(this,"OpenDocument",1,[e],4,0)},ee.prototype.retrieveStylesFromBase64=function(e){return b("Application.retrieveStylesFromBase64",u,"1.5",l),d(this,"RetrieveStylesFromBase64",1,[e],4,0)},ee.prototype._handleResult=function(e){Z.prototype._handleResult.call(this,e),m(e)||P(this,e)},ee.prototype._handleRetrieveResult=function(e,t){Z.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},ee.newObject=function(e){return o(i.Application,e,"Microsoft.WordServices.Application",!1,4)},ee.prototype.toJSON=function(){return C(this,{},{})},ee);function ee(){return null!==Z&&Z.apply(this,arguments)||this}i.Application=Y;var te,ne="Body",re=(te=OfficeExtension.ClientObject,__extends(oe,te),Object.defineProperty(oe.prototype,"_className",{get:function(){return"Body"},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","style","text","type","styleBuiltIn"]},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Style","Text","Type","StyleBuiltIn"]},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!1,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"_navigationPropertyNames",{get:function(){return["paragraphs","contentControls","parentContentControl","font","inlinePictures","parentBody","lists","tables","parentSection","parentContentControlOrNullObject","parentBodyOrNullObject","parentSectionOrNullObject","footnotes","endnotes","fields","shapes"]},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"contentControls",{get:function(){return this._C||(this._C=t(i.ContentControlCollection,this,"ContentControls",!0,4)),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"endnotes",{get:function(){return b("Body.endnotes",u,"1.5",l),this._E||(this._E=t(i.NoteItemCollection,this,"Endnotes",!0,4)),this._E},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"fields",{get:function(){return b("Body.fields",u,"1.4",l),this._F||(this._F=t(i.FieldCollection,this,"Fields",!0,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"font",{get:function(){return this._Fo||(this._Fo=t(i.Font,this,"Font",!1,4)),this._Fo},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"footnotes",{get:function(){return b("Body.footnotes",u,"1.5",l),this._Foo||(this._Foo=t(i.NoteItemCollection,this,"Footnotes",!0,4)),this._Foo},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"inlinePictures",{get:function(){return this._I||(this._I=t(i.InlinePictureCollection,this,"InlinePictures",!0,4)),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"lists",{get:function(){return b("Body.lists",u,"1.3",l),this._L||(this._L=t(i.ListCollection,this,"Lists",!0,4)),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"paragraphs",{get:function(){return this._P||(this._P=t(i.ParagraphCollection,this,"Paragraphs",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"parentBody",{get:function(){return b("Body.parentBody",u,"1.3",l),this._Pa||(this._Pa=t(i.Body,this,"ParentBody",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"parentBodyOrNullObject",{get:function(){return b("Body.parentBodyOrNullObject",u,"1.3",l),this._Par||(this._Par=t(i.Body,this,"ParentBodyOrNullObject",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"parentContentControl",{get:function(){return this._Pare||(this._Pare=t(i.ContentControl,this,"ParentContentControl",!1,4)),this._Pare},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"parentContentControlOrNullObject",{get:function(){return b("Body.parentContentControlOrNullObject",u,"1.3",l),this._Paren||(this._Paren=t(i.ContentControl,this,"ParentContentControlOrNullObject",!1,4)),this._Paren},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"parentSection",{get:function(){return b("Body.parentSection",u,"1.3",l),this._Parent||(this._Parent=t(i.Section,this,"ParentSection",!1,4)),this._Parent},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"parentSectionOrNullObject",{get:function(){return b("Body.parentSectionOrNullObject",u,"1.3",l),this._ParentS||(this._ParentS=t(i.Section,this,"ParentSectionOrNullObject",!1,4)),this._ParentS},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"shapes",{get:function(){return b("Body.shapes","WordApiDesktop","1.2",l),this._S||(this._S=t(i.ShapeCollection,this,"Shapes",!0,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"tables",{get:function(){return b("Body.tables",u,"1.3",l),this._T||(this._T=t(i.TableCollection,this,"Tables",!0,4)),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"style",{get:function(){return _("style",this._St,ne,this._isNull),this._St},set:function(e){this._St=e,g(this,"Style",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"styleBuiltIn",{get:function(){return _("styleBuiltIn",this._Sty,ne,this._isNull),b("Body.styleBuiltIn",u,"1.3",l),this._Sty},set:function(e){this._Sty=e,g(this,"StyleBuiltIn",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"text",{get:function(){return _("text",this._Te,ne,this._isNull),this._Te},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"type",{get:function(){return _("type",this._Ty,ne,this._isNull),b("Body.type",u,"1.3",l),this._Ty},enumerable:!0,configurable:!0}),Object.defineProperty(oe.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ne,this._isNull),this.__R},enumerable:!0,configurable:!0}),oe.prototype.set=function(e,t){this._recursivelySet(e,t,["style","styleBuiltIn"],["font"],["contentControls","endnotes","fields","footnotes","inlinePictures","lists","paragraphs","parentBody","parentBodyOrNullObject","parentContentControl","parentContentControlOrNullObject","parentSection","parentSectionOrNullObject","shapes","tables"])},oe.prototype.update=function(e){this._recursivelyUpdate(e)},oe.prototype.clear=function(){d(this,"Clear",0,[],0,0)},oe.prototype.getComments=function(){return b("Body.getComments",u,"1.4",l),p(i.CommentCollection,this,"GetComments",1,[],!0,!1,null,4)},oe.prototype.getContentControls=function(e){return b("Body.getContentControls",u,"1.5",l),p(i.ContentControlCollection,this,"GetContentControls",1,[e],!0,!1,null,4)},oe.prototype.getHtml=function(){return d(this,"GetHtml",1,[],4,0)},oe.prototype.getOoxml=function(){return d(this,"GetOoxml",1,[],4,0)},oe.prototype.getRange=function(e){return b("Body.getRange",u,"1.3",l),p(i.Range,this,"GetRange",1,[e],!1,!1,null,4)},oe.prototype.getReviewedText=function(e){return b("Body.getReviewedText",u,"1.4",l),d(this,"GetReviewedText",1,[e],4,0)},oe.prototype.getTrackedChanges=function(){return b("Body.getTrackedChanges",u,"1.6",l),p(i.TrackedChangeCollection,this,"GetTrackedChanges",1,[],!0,!1,null,4)},oe.prototype.insertBreak=function(e,t){d(this,"InsertBreak",0,[e,t],0,0)},oe.prototype.insertContentControl=function(e){return p(i.ContentControl,this,"InsertContentControl",0,[e],!1,!0,null,0)},oe.prototype.insertFileFromBase64=function(e,t){return p(i.Range,this,"InsertFileFromBase64",0,[e,t],!1,!0,null,0)},oe.prototype.insertHtml=function(e,t){return p(i.Range,this,"InsertHtml",0,[e,t],!1,!0,null,0)},oe.prototype.insertInlinePictureFromBase64=function(e,t){return b("Body.insertInlinePictureFromBase64",u,"1.2",l),p(i.InlinePicture,this,"InsertInlinePictureFromBase64",0,[e,t],!1,!0,null,0)},oe.prototype.insertOoxml=function(e,t){return p(i.Range,this,"InsertOoxml",0,[e,t],!1,!0,null,0)},oe.prototype.insertParagraph=function(e,t){return p(i.Paragraph,this,"InsertParagraph",0,[e,t],!1,!0,null,0)},oe.prototype.insertTable=function(e,t,n,r){return b("Body.insertTable",u,"1.3",l),p(i.Table,this,"InsertTable",0,[e,t,n,r],!1,!0,null,0)},oe.prototype.insertText=function(e,t){return p(i.Range,this,"InsertText",0,[e,t],!1,!0,null,0)},oe.prototype.search=function(e,t){var n=K.Body_Search(this,e,t),r=n.handled,o=n.result;return r?o:p(i.RangeCollection,this,"Search",1,[e,t],!0,!1,null,4)},oe.prototype.select=function(e){d(this,"Select",1,[e],4,0)},oe.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},oe.prototype._Search2=function(e,t){return p(i.RangeCollection,this,"_Search2",1,[e,t],!0,!1,null,4)},oe.prototype._handleResult=function(e){if(te.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Style)||(this._St=t.Style),y(t.StyleBuiltIn)||(this._Sty=t.StyleBuiltIn),y(t.Text)||(this._Te=t.Text),y(t.Type)||(this._Ty=t.Type),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["contentControls","ContentControls","endnotes","Endnotes","fields","Fields","font","Font","footnotes","Footnotes","inlinePictures","InlinePictures","lists","Lists","paragraphs","Paragraphs","parentBody","ParentBody","parentBodyOrNullObject","ParentBodyOrNullObject","parentContentControl","ParentContentControl","parentContentControlOrNullObject","ParentContentControlOrNullObject","parentSection","ParentSection","parentSectionOrNullObject","ParentSectionOrNullObject","shapes","Shapes","tables","Tables"])}},oe.prototype.load=function(e){return v(this,e)},oe.prototype.retrieve=function(e){return O(this,e)},oe.prototype._handleIdResult=function(e){te.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},oe.prototype._handleRetrieveResult=function(e,t){te.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},oe.prototype.track=function(){return this.context.trackedObjects.add(this),this},oe.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},oe.prototype.toJSON=function(){return C(this,{style:this._St,styleBuiltIn:this._Sty,text:this._Te,type:this._Ty},{contentControls:this._C,fields:this._F,font:this._Fo,inlinePictures:this._I,lists:this._L,paragraphs:this._P,shapes:this._S,tables:this._T})},oe.prototype.setMockData=function(e){R(this,e)},oe.prototype.ensureUnchanged=function(e){h(this,e)},oe);function oe(){return null!==te&&te.apply(this,arguments)||this}i.Body=re;var ie=(ae.prototype.getDocument=function(){return m(this._document)&&(this._document=this.context.document),this._document},ae.prototype.getReferenceId=function(){return m(this._refId)&&(this._refId=this._ReferenceId),this._refId},ae.prototype._RegisterCommentAddedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentAdded")},ae.prototype._UnregisterCommentAddedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentAdded")},ae.prototype._RegisterCommentDeletedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentDeleted")},ae.prototype._UnregisterCommentDeletedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentDeleted")},ae.prototype._RegisterCommentChangedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentChanged")},ae.prototype._UnregisterCommentChangedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentChanged")},ae.prototype._RegisterCommentSelectedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentSelected")},ae.prototype._UnregisterCommentSelectedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentSelected")},ae.prototype._RegisterCommentDeselectedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentDeselected")},ae.prototype._UnregisterCommentDeselectedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentDeselected")},ae);function ae(){}i.BodyCustom=ie,OfficeExtension.Utility.applyMixin(re,ie),(K=i._CC||(i._CC={})).Body_Search=function(e,t,n){var r;if(s()){var o=c(n);r=e._Search2(t,o)}else n=a(e.context,n),r=p(i.RangeCollection,e,"Search",1,[t,n],!0,!1,null,4);return{handled:!0,result:r}};var se,ce="Border",le=(se=OfficeExtension.ClientObject,__extends(ue,se),Object.defineProperty(ue.prototype,"_className",{get:function(){return"Border"},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","color","type","width","visible","location"]},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Color","Type","Width","Visible","Location"]},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0,!0,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"color",{get:function(){return _("color",this._C,ce,this._isNull),this._C},set:function(e){this._C=e,g(this,"Color",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"location",{get:function(){return _("location",this._L,ce,this._isNull),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"type",{get:function(){return _("type",this._T,ce,this._isNull),this._T},set:function(e){this._T=e,g(this,"Type",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"visible",{get:function(){return _("visible",this._V,ce,this._isNull),this._V},set:function(e){this._V=e,g(this,"Visible",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"width",{get:function(){return _("width",this._W,ce,this._isNull),this._W},set:function(e){this._W=e,g(this,"Width",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ue.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ce,this._isNull),this.__R},enumerable:!0,configurable:!0}),ue.prototype.set=function(e,t){this._recursivelySet(e,t,["color","type","width","visible"],[],[])},ue.prototype.update=function(e){this._recursivelyUpdate(e)},ue.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},ue.prototype._handleResult=function(e){if(se.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Color)||(this._C=t.Color),y(t.Location)||(this._L=t.Location),y(t.Type)||(this._T=t.Type),y(t.Visible)||(this._V=t.Visible),y(t.Width)||(this._W=t.Width),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},ue.prototype.load=function(e){return v(this,e)},ue.prototype.retrieve=function(e){return O(this,e)},ue.prototype._handleIdResult=function(e){se.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},ue.prototype._handleRetrieveResult=function(e,t){se.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},ue.prototype.track=function(){return this.context.trackedObjects.add(this),this},ue.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},ue.prototype.toJSON=function(){return C(this,{color:this._C,location:this._L,type:this._T,visible:this._V,width:this._W},{})},ue.prototype.setMockData=function(e){R(this,e)},ue.prototype.ensureUnchanged=function(e){h(this,e)},ue);function ue(){return null!==se&&se.apply(this,arguments)||this}i.Border=le;var pe,fe="BorderCollection",de=(pe=OfficeExtension.ClientObject,__extends(he,pe),Object.defineProperty(he.prototype,"_className",{get:function(){return"BorderCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"_scalarPropertyNames",{get:function(){return["insideBorderColor","insideBorderType","insideBorderWidth","outsideBorderColor","outsideBorderType","outsideBorderWidth","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"_scalarPropertyOriginalNames",{get:function(){return["InsideBorderColor","InsideBorderType","InsideBorderWidth","OutsideBorderColor","OutsideBorderType","OutsideBorderWidth","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"_scalarPropertyUpdateable",{get:function(){return[!0,!0,!0,!0,!0,!0,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"items",{get:function(){return _("items",this.m__items,fe,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"insideBorderColor",{get:function(){return _("insideBorderColor",this._I,fe,this._isNull),this._I},set:function(e){this._I=e,g(this,"InsideBorderColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"insideBorderType",{get:function(){return _("insideBorderType",this._In,fe,this._isNull),this._In},set:function(e){this._In=e,g(this,"InsideBorderType",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"insideBorderWidth",{get:function(){return _("insideBorderWidth",this._Ins,fe,this._isNull),this._Ins},set:function(e){this._Ins=e,g(this,"InsideBorderWidth",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"outsideBorderColor",{get:function(){return _("outsideBorderColor",this._O,fe,this._isNull),this._O},set:function(e){this._O=e,g(this,"OutsideBorderColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"outsideBorderType",{get:function(){return _("outsideBorderType",this._Ou,fe,this._isNull),this._Ou},set:function(e){this._Ou=e,g(this,"OutsideBorderType",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"outsideBorderWidth",{get:function(){return _("outsideBorderWidth",this._Out,fe,this._isNull),this._Out},set:function(e){this._Out=e,g(this,"OutsideBorderWidth",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(he.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,fe,this._isNull),this.__R},enumerable:!0,configurable:!0}),he.prototype.getByLocation=function(e){return p(i.Border,this,"GetByLocation",1,[e],!1,!1,null,4)},he.prototype.getFirst=function(){return p(i.Border,this,"GetFirst",1,[],!1,!1,null,4)},he.prototype.getFirstOrNullObject=function(){return p(i.Border,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},he.prototype.getItem=function(e){return r(i.Border,this,[e])},he.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},he.prototype._handleResult=function(e){if(pe.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t.InsideBorderColor)||(this._I=t.InsideBorderColor),y(t.InsideBorderType)||(this._In=t.InsideBorderType),y(t.InsideBorderWidth)||(this._Ins=t.InsideBorderWidth),y(t.OutsideBorderColor)||(this._O=t.OutsideBorderColor),y(t.OutsideBorderType)||(this._Ou=t.OutsideBorderType),y(t.OutsideBorderWidth)||(this._Out=t.OutsideBorderWidth),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Border,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},he.prototype.load=function(e){return v(this,e)},he.prototype.retrieve=function(e){return O(this,e)},he.prototype._handleIdResult=function(e){pe.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},he.prototype._handleRetrieveResult=function(e,t){var n=this;pe.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Border,!0,n,e,t)})},he.prototype.track=function(){return this.context.trackedObjects.add(this),this},he.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},he.prototype.toJSON=function(){return C(this,{insideBorderColor:this._I,insideBorderType:this._In,insideBorderWidth:this._Ins,outsideBorderColor:this._O,outsideBorderType:this._Ou,outsideBorderWidth:this._Out},{},this.m__items)},he.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Border,!0,n,e,t)},function(e){return n.m__items=e})},he);function he(){return null!==pe&&pe.apply(this,arguments)||this}i.BorderCollection=de;var ge,me="CheckboxContentControl",ye=(ge=OfficeExtension.ClientObject,__extends(_e,ge),Object.defineProperty(_e.prototype,"_className",{get:function(){return"CheckboxContentControl"},enumerable:!0,configurable:!0}),Object.defineProperty(_e.prototype,"_scalarPropertyNames",{get:function(){return["isChecked","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(_e.prototype,"_scalarPropertyOriginalNames",{get:function(){return["IsChecked","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(_e.prototype,"_scalarPropertyUpdateable",{get:function(){return[!0,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(_e.prototype,"isChecked",{get:function(){return _("isChecked",this._I,me,this._isNull),this._I},set:function(e){this._I=e,g(this,"IsChecked",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(_e.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,me,this._isNull),this.__R},enumerable:!0,configurable:!0}),_e.prototype.set=function(e,t){this._recursivelySet(e,t,["isChecked"],[],[])},_e.prototype.update=function(e){this._recursivelyUpdate(e)},_e.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},_e.prototype._handleResult=function(e){if(ge.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.IsChecked)||(this._I=t.IsChecked),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},_e.prototype.load=function(e){return v(this,e)},_e.prototype.retrieve=function(e){return O(this,e)},_e.prototype._handleIdResult=function(e){ge.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},_e.prototype._handleRetrieveResult=function(e,t){ge.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},_e.prototype.track=function(){return this.context.trackedObjects.add(this),this},_e.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},_e.prototype.toJSON=function(){return C(this,{isChecked:this._I},{})},_e.prototype.setMockData=function(e){R(this,e)},_e.prototype.ensureUnchanged=function(e){h(this,e)},_e);function _e(){return null!==ge&&ge.apply(this,arguments)||this}i.CheckboxContentControl=ye;var be,ve="Comment",Oe=(be=OfficeExtension.ClientObject,__extends(Ce,be),Object.defineProperty(Ce.prototype,"_className",{get:function(){return"Comment"},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"_scalarPropertyNames",{get:function(){return["authorEmail","authorName","content","creationDate","id","_ReferenceId","resolved"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"_scalarPropertyOriginalNames",{get:function(){return["AuthorEmail","AuthorName","Content","CreationDate","Id","_ReferenceId","Resolved"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!1,!1,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"_navigationPropertyNames",{get:function(){return["replies","contentRange"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"contentRange",{get:function(){return this._Co||(this._Co=t(i.CommentContentRange,this,"ContentRange",!1,4)),this._Co},set:function(e){this._Co=e,g(this,"ContentRange",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"replies",{get:function(){return this._R||(this._R=t(i.CommentReplyCollection,this,"Replies",!0,4)),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"authorEmail",{get:function(){return _("authorEmail",this._A,ve,this._isNull),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"authorName",{get:function(){return _("authorName",this._Au,ve,this._isNull),this._Au},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"content",{get:function(){return _("content",this._C,ve,this._isNull),this._C},set:function(e){this._C=e,g(this,"Content",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"creationDate",{get:function(){return _("creationDate",this._Cr,ve,this._isNull),this._Cr},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"id",{get:function(){return _("id",this._I,ve,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"resolved",{get:function(){return _("resolved",this._Re,ve,this._isNull),this._Re},set:function(e){this._Re=e,g(this,"Resolved",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ce.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ve,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ce.prototype.set=function(e,t){this._recursivelySet(e,t,["content","resolved"],["contentRange"],["replies"])},Ce.prototype.update=function(e){this._recursivelyUpdate(e)},Ce.prototype.delete=function(){d(this,"Delete",0,[],0,0)},Ce.prototype.getRange=function(){return p(i.Range,this,"GetRange",0,[],!1,!1,null,0)},Ce.prototype.reply=function(e){return p(i.CommentReply,this,"Reply",0,[e],!1,!1,null,0)},Ce.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ce.prototype._handleResult=function(e){if(be.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.AuthorEmail)||(this._A=t.AuthorEmail),y(t.AuthorName)||(this._Au=t.AuthorName),y(t.Content)||(this._C=t.Content),y(t.CreationDate)||(this._Cr=A(t.CreationDate)),y(t.Id)||(this._I=t.Id),y(t.Resolved)||(this._Re=t.Resolved),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["contentRange","ContentRange","replies","Replies"])}},Ce.prototype.load=function(e){return v(this,e)},Ce.prototype.retrieve=function(e){return O(this,e)},Ce.prototype._handleIdResult=function(e){be.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},Ce.prototype._handleRetrieveResult=function(e,t){if(be.prototype._handleRetrieveResult.call(this,e,t),!m(e)){var n=e;y(n.CreationDate)||(n.creationDate=A(n.creationDate)),I(this,e,t)}},Ce.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ce.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ce.prototype.toJSON=function(){return C(this,{authorEmail:this._A,authorName:this._Au,content:this._C,creationDate:this._Cr,id:this._I,resolved:this._Re},{contentRange:this._Co,replies:this._R})},Ce.prototype.setMockData=function(e){R(this,e)},Ce.prototype.ensureUnchanged=function(e){h(this,e)},Ce);function Ce(){return null!==be&&be.apply(this,arguments)||this}i.Comment=Oe;var Pe,Se="CommentCollection",Ae=(Pe=OfficeExtension.ClientObject,__extends(Ie,Pe),Object.defineProperty(Ie.prototype,"_className",{get:function(){return"CommentCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Ie.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Ie.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ie.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ie.prototype,"items",{get:function(){return _("items",this.m__items,Se,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Ie.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Se,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ie.prototype.getFirst=function(){return p(i.Comment,this,"GetFirst",1,[],!1,!1,null,4)},Ie.prototype.getFirstOrNullObject=function(){return p(i.Comment,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Ie.prototype._GetItem=function(e){return r(i.Comment,this,[e])},Ie.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ie.prototype._handleResult=function(e){if(Pe.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Comment,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Ie.prototype.load=function(e){return v(this,e)},Ie.prototype.retrieve=function(e){return O(this,e)},Ie.prototype._handleIdResult=function(e){Pe.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Ie.prototype._handleRetrieveResult=function(e,t){var n=this;Pe.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Comment,!0,n,e,t)})},Ie.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ie.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ie.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Ie.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Comment,!0,n,e,t)},function(e){return n.m__items=e})},Ie);function Ie(){return null!==Pe&&Pe.apply(this,arguments)||this}i.CommentCollection=Ae;var Re,Te="CommentContentRange",Ee=(Re=OfficeExtension.ClientObject,__extends(Ne,Re),Object.defineProperty(Ne.prototype,"_className",{get:function(){return"CommentContentRange"},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","text","isEmpty","hyperlink","bold","italic","strikeThrough","underline"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Text","IsEmpty","Hyperlink","Bold","Italic","StrikeThrough","Underline"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"bold",{get:function(){return _("bold",this._B,Te,this._isNull),this._B},set:function(e){this._B=e,g(this,"Bold",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"hyperlink",{get:function(){return _("hyperlink",this._H,Te,this._isNull),this._H},set:function(e){this._H=e,g(this,"Hyperlink",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"isEmpty",{get:function(){return _("isEmpty",this._I,Te,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"italic",{get:function(){return _("italic",this._It,Te,this._isNull),this._It},set:function(e){this._It=e,g(this,"Italic",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"strikeThrough",{get:function(){return _("strikeThrough",this._S,Te,this._isNull),this._S},set:function(e){this._S=e,g(this,"StrikeThrough",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"text",{get:function(){return _("text",this._T,Te,this._isNull),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"underline",{get:function(){return _("underline",this._U,Te,this._isNull),this._U},set:function(e){this._U=e,g(this,"Underline",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ne.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Te,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ne.prototype.set=function(e,t){this._recursivelySet(e,t,["hyperlink","bold","italic","strikeThrough","underline"],[],[])},Ne.prototype.update=function(e){this._recursivelyUpdate(e)},Ne.prototype.insertText=function(e,t){return p(i.CommentContentRange,this,"InsertText",0,[e,t],!1,!1,null,0)},Ne.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ne.prototype._handleResult=function(e){if(Re.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Bold)||(this._B=t.Bold),y(t.Hyperlink)||(this._H=t.Hyperlink),y(t.IsEmpty)||(this._I=t.IsEmpty),y(t.Italic)||(this._It=t.Italic),y(t.StrikeThrough)||(this._S=t.StrikeThrough),y(t.Text)||(this._T=t.Text),y(t.Underline)||(this._U=t.Underline),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Ne.prototype.load=function(e){return v(this,e)},Ne.prototype.retrieve=function(e){return O(this,e)},Ne.prototype._handleIdResult=function(e){Re.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Ne.prototype._handleRetrieveResult=function(e,t){Re.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Ne.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ne.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ne.prototype.toJSON=function(){return C(this,{bold:this._B,hyperlink:this._H,isEmpty:this._I,italic:this._It,strikeThrough:this._S,text:this._T,underline:this._U},{})},Ne.prototype.setMockData=function(e){R(this,e)},Ne.prototype.ensureUnchanged=function(e){h(this,e)},Ne);function Ne(){return null!==Re&&Re.apply(this,arguments)||this}i.CommentContentRange=Ee;var De,xe="CommentReply",we=(De=OfficeExtension.ClientObject,__extends(Fe,De),Object.defineProperty(Fe.prototype,"_className",{get:function(){return"CommentReply"},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"_scalarPropertyNames",{get:function(){return["authorEmail","authorName","content","creationDate","id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"_scalarPropertyOriginalNames",{get:function(){return["AuthorEmail","AuthorName","Content","CreationDate","Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!1,!1,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"_navigationPropertyNames",{get:function(){return["parentComment","contentRange"]},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"contentRange",{get:function(){return this._Co||(this._Co=t(i.CommentContentRange,this,"ContentRange",!1,4)),this._Co},set:function(e){this._Co=e,g(this,"ContentRange",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"parentComment",{get:function(){return this._P||(this._P=t(i.Comment,this,"ParentComment",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"authorEmail",{get:function(){return _("authorEmail",this._A,xe,this._isNull),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"authorName",{get:function(){return _("authorName",this._Au,xe,this._isNull),this._Au},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"content",{get:function(){return _("content",this._C,xe,this._isNull),this._C},set:function(e){this._C=e,g(this,"Content",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"creationDate",{get:function(){return _("creationDate",this._Cr,xe,this._isNull),this._Cr},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"id",{get:function(){return _("id",this._I,xe,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(Fe.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,xe,this._isNull),this.__R},enumerable:!0,configurable:!0}),Fe.prototype.set=function(e,t){this._recursivelySet(e,t,["content"],["parentComment","contentRange"],[])},Fe.prototype.update=function(e){this._recursivelyUpdate(e)},Fe.prototype.delete=function(){d(this,"Delete",0,[],0,0)},Fe.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Fe.prototype._handleResult=function(e){if(De.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.AuthorEmail)||(this._A=t.AuthorEmail),y(t.AuthorName)||(this._Au=t.AuthorName),y(t.Content)||(this._C=t.Content),y(t.CreationDate)||(this._Cr=A(t.CreationDate)),y(t.Id)||(this._I=t.Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["contentRange","ContentRange","parentComment","ParentComment"])}},Fe.prototype.load=function(e){return v(this,e)},Fe.prototype.retrieve=function(e){return O(this,e)},Fe.prototype._handleIdResult=function(e){De.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},Fe.prototype._handleRetrieveResult=function(e,t){if(De.prototype._handleRetrieveResult.call(this,e,t),!m(e)){var n=e;y(n.CreationDate)||(n.creationDate=A(n.creationDate)),I(this,e,t)}},Fe.prototype.track=function(){return this.context.trackedObjects.add(this),this},Fe.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Fe.prototype.toJSON=function(){return C(this,{authorEmail:this._A,authorName:this._Au,content:this._C,creationDate:this._Cr,id:this._I},{contentRange:this._Co,parentComment:this._P})},Fe.prototype.setMockData=function(e){R(this,e)},Fe.prototype.ensureUnchanged=function(e){h(this,e)},Fe);function Fe(){return null!==De&&De.apply(this,arguments)||this}i.CommentReply=we;var je,ke="CommentReplyCollection",Me=(je=OfficeExtension.ClientObject,__extends(He,je),Object.defineProperty(He.prototype,"_className",{get:function(){return"CommentReplyCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(He.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(He.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(He.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(He.prototype,"items",{get:function(){return _("items",this.m__items,ke,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(He.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ke,this._isNull),this.__R},enumerable:!0,configurable:!0}),He.prototype.getFirst=function(){return p(i.CommentReply,this,"GetFirst",1,[],!1,!1,null,4)},He.prototype.getFirstOrNullObject=function(){return p(i.CommentReply,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},He.prototype._GetItem=function(e){return r(i.CommentReply,this,[e])},He.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},He.prototype._handleResult=function(e){if(je.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.CommentReply,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},He.prototype.load=function(e){return v(this,e)},He.prototype.retrieve=function(e){return O(this,e)},He.prototype._handleIdResult=function(e){je.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},He.prototype._handleRetrieveResult=function(e,t){var n=this;je.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.CommentReply,!0,n,e,t)})},He.prototype.track=function(){return this.context.trackedObjects.add(this),this},He.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},He.prototype.toJSON=function(){return C(this,{},{},this.m__items)},He.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.CommentReply,!0,n,e,t)},function(e){return n.m__items=e})},He);function He(){return null!==je&&je.apply(this,arguments)||this}i.CommentReplyCollection=Me;var Le,Ue="ContentControl",Be=(Le=OfficeExtension.ClientObject,__extends(We,Le),Object.defineProperty(We.prototype,"_className",{get:function(){return"ContentControl"},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","title","tag","placeholderText","type","appearance","color","removeWhenEdited","cannotDelete","cannotEdit","style","text","subtype","styleBuiltIn"]},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","Title","Tag","PlaceholderText","Type","Appearance","Color","RemoveWhenEdited","CannotDelete","CannotEdit","Style","Text","Subtype","StyleBuiltIn"]},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!0,!0,!1,!0,!0,!0,!0,!0,!0,!1,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"_navigationPropertyNames",{get:function(){return["font","paragraphs","contentControls","parentContentControl","inlinePictures","lists","tables","parentTableCell","parentTable","parentBody","parentContentControlOrNullObject","parentTableCellOrNullObject","parentTableOrNullObject","footnotes","endnotes","fields","checkboxContentControl","dropDownListContentControl","comboBoxContentControl"]},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"checkboxContentControl",{get:function(){return b("ContentControl.checkboxContentControl",u,"1.7",l),this._Ch||(this._Ch=t(i.CheckboxContentControl,this,"CheckboxContentControl",!1,4)),this._Ch},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"comboBoxContentControl",{get:function(){return b("ContentControl.comboBoxContentControl",u,"1.9",l),this._Com||(this._Com=t(i.ComboBoxContentControl,this,"ComboBoxContentControl",!1,4)),this._Com},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"contentControls",{get:function(){return this._Con||(this._Con=t(i.ContentControlCollection,this,"ContentControls",!0,4)),this._Con},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"dropDownListContentControl",{get:function(){return b("ContentControl.dropDownListContentControl",u,"1.9",l),this._D||(this._D=t(i.DropDownListContentControl,this,"DropDownListContentControl",!1,4)),this._D},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"endnotes",{get:function(){return b("ContentControl.endnotes",u,"1.5",l),this._E||(this._E=t(i.NoteItemCollection,this,"Endnotes",!0,4)),this._E},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"fields",{get:function(){return b("ContentControl.fields",u,"1.4",l),this._F||(this._F=t(i.FieldCollection,this,"Fields",!0,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"font",{get:function(){return this._Fo||(this._Fo=t(i.Font,this,"Font",!1,4)),this._Fo},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"footnotes",{get:function(){return b("ContentControl.footnotes",u,"1.5",l),this._Foo||(this._Foo=t(i.NoteItemCollection,this,"Footnotes",!0,4)),this._Foo},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"inlinePictures",{get:function(){return this._In||(this._In=t(i.InlinePictureCollection,this,"InlinePictures",!0,4)),this._In},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"lists",{get:function(){return b("ContentControl.lists",u,"1.3",l),this._L||(this._L=t(i.ListCollection,this,"Lists",!0,4)),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"paragraphs",{get:function(){return this._P||(this._P=t(i.ParagraphCollection,this,"Paragraphs",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"parentBody",{get:function(){return b("ContentControl.parentBody",u,"1.3",l),this._Pa||(this._Pa=t(i.Body,this,"ParentBody",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"parentContentControl",{get:function(){return this._Par||(this._Par=t(i.ContentControl,this,"ParentContentControl",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"parentContentControlOrNullObject",{get:function(){return b("ContentControl.parentContentControlOrNullObject",u,"1.3",l),this._Pare||(this._Pare=t(i.ContentControl,this,"ParentContentControlOrNullObject",!1,4)),this._Pare},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"parentTable",{get:function(){return b("ContentControl.parentTable",u,"1.3",l),this._Paren||(this._Paren=t(i.Table,this,"ParentTable",!1,4)),this._Paren},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"parentTableCell",{get:function(){return b("ContentControl.parentTableCell",u,"1.3",l),this._Parent||(this._Parent=t(i.TableCell,this,"ParentTableCell",!1,4)),this._Parent},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"parentTableCellOrNullObject",{get:function(){return b("ContentControl.parentTableCellOrNullObject",u,"1.3",l),this._ParentT||(this._ParentT=t(i.TableCell,this,"ParentTableCellOrNullObject",!1,4)),this._ParentT},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"parentTableOrNullObject",{get:function(){return b("ContentControl.parentTableOrNullObject",u,"1.3",l),this._ParentTa||(this._ParentTa=t(i.Table,this,"ParentTableOrNullObject",!1,4)),this._ParentTa},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"tables",{get:function(){return b("ContentControl.tables",u,"1.3",l),this._T||(this._T=t(i.TableCollection,this,"Tables",!0,4)),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"appearance",{get:function(){return _("appearance",this._A,Ue,this._isNull),this._A},set:function(e){this._A=e,g(this,"Appearance",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"cannotDelete",{get:function(){return _("cannotDelete",this._C,Ue,this._isNull),this._C},set:function(e){this._C=e,g(this,"CannotDelete",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"cannotEdit",{get:function(){return _("cannotEdit",this._Ca,Ue,this._isNull),this._Ca},set:function(e){this._Ca=e,g(this,"CannotEdit",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"color",{get:function(){return _("color",this._Co,Ue,this._isNull),this._Co},set:function(e){this._Co=e,g(this,"Color",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"id",{get:function(){return _("id",this._I,Ue,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"placeholderText",{get:function(){return _("placeholderText",this._Pl,Ue,this._isNull),this._Pl},set:function(e){this._Pl=e,g(this,"PlaceholderText",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"removeWhenEdited",{get:function(){return _("removeWhenEdited",this._R,Ue,this._isNull),this._R},set:function(e){this._R=e,g(this,"RemoveWhenEdited",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"style",{get:function(){return _("style",this._S,Ue,this._isNull),this._S},set:function(e){this._S=e,g(this,"Style",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"styleBuiltIn",{get:function(){return _("styleBuiltIn",this._St,Ue,this._isNull),b("ContentControl.styleBuiltIn",u,"1.3",l),this._St},set:function(e){this._St=e,g(this,"StyleBuiltIn",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"subtype",{get:function(){return _("subtype",this._Su,Ue,this._isNull),b("ContentControl.subtype",u,"1.3",l),this._Su},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"tag",{get:function(){return _("tag",this._Ta,Ue,this._isNull),this._Ta},set:function(e){this._Ta=e,g(this,"Tag",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"text",{get:function(){return _("text",this._Te,Ue,this._isNull),this._Te},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"title",{get:function(){return _("title",this._Ti,Ue,this._isNull),this._Ti},set:function(e){this._Ti=e,g(this,"Title",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"type",{get:function(){return _("type",this._Ty,Ue,this._isNull),this._Ty},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Ue,this._isNull),this.__R},enumerable:!0,configurable:!0}),We.prototype.set=function(e,t){this._recursivelySet(e,t,["title","tag","placeholderText","appearance","color","removeWhenEdited","cannotDelete","cannotEdit","style","styleBuiltIn"],["font","checkboxContentControl"],["comboBoxContentControl","contentControls","dropDownListContentControl","endnotes","fields","footnotes","inlinePictures","lists","paragraphs","parentBody","parentContentControl","parentContentControlOrNullObject","parentTable","parentTableCell","parentTableCellOrNullObject","parentTableOrNullObject","tables"])},We.prototype.update=function(e){this._recursivelyUpdate(e)},We.prototype.clear=function(){d(this,"Clear",0,[],0,0)},We.prototype.delete=function(e){d(this,"Delete",0,[e],0,0)},We.prototype.getComments=function(){return b("ContentControl.getComments",u,"1.4",l),p(i.CommentCollection,this,"GetComments",1,[],!0,!1,null,4)},We.prototype.getContentControls=function(e){return b("ContentControl.getContentControls",u,"1.5",l),p(i.ContentControlCollection,this,"GetContentControls",1,[e],!0,!1,null,4)},We.prototype.getHtml=function(){return d(this,"GetHtml",1,[],4,0)},We.prototype.getOoxml=function(){return d(this,"GetOoxml",1,[],4,0)},We.prototype.getRange=function(e){return b("ContentControl.getRange",u,"1.3",l),p(i.Range,this,"GetRange",1,[e],!1,!1,null,4)},We.prototype.getReviewedText=function(e){return b("ContentControl.getReviewedText",u,"1.4",l),d(this,"GetReviewedText",1,[e],4,0)},We.prototype.getTextRanges=function(e,t){return b("ContentControl.getTextRanges",u,"1.3",l),p(i.RangeCollection,this,"GetTextRanges",1,[e,t],!0,!1,null,4)},We.prototype.getTrackedChanges=function(){return b("ContentControl.getTrackedChanges",u,"1.6",l),p(i.TrackedChangeCollection,this,"GetTrackedChanges",1,[],!0,!1,null,4)},We.prototype.insertBreak=function(e,t){d(this,"InsertBreak",0,[e,t],0,0)},We.prototype.insertFileFromBase64=function(e,t){return p(i.Range,this,"InsertFileFromBase64",0,[e,t],!1,!0,null,0)},We.prototype.insertHtml=function(e,t){return p(i.Range,this,"InsertHtml",0,[e,t],!1,!0,null,0)},We.prototype.insertInlinePictureFromBase64=function(e,t){return b("ContentControl.insertInlinePictureFromBase64",u,"1.2",l),p(i.InlinePicture,this,"InsertInlinePictureFromBase64",0,[e,t],!1,!0,null,0)},We.prototype.insertOoxml=function(e,t){return p(i.Range,this,"InsertOoxml",0,[e,t],!1,!0,null,0)},We.prototype.insertParagraph=function(e,t){return p(i.Paragraph,this,"InsertParagraph",0,[e,t],!1,!0,null,0)},We.prototype.insertTable=function(e,t,n,r){return b("ContentControl.insertTable",u,"1.3",l),p(i.Table,this,"InsertTable",0,[e,t,n,r],!1,!0,null,0)},We.prototype.insertText=function(e,t){return p(i.Range,this,"InsertText",0,[e,t],!1,!0,null,0)},We.prototype.search=function(e,t){var n=K.ContentControl_Search(this,e,t),r=n.handled,o=n.result;return r?o:p(i.RangeCollection,this,"Search",1,[e,t],!0,!1,null,4)},We.prototype.select=function(e){d(this,"Select",1,[e],4,0)},We.prototype.split=function(e,t,n,r){return b("ContentControl.split",u,"1.3",l),p(i.RangeCollection,this,"Split",1,[e,t,n,r],!0,!1,null,4)},We.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},We.prototype._Search2=function(e,t){return p(i.RangeCollection,this,"_Search2",1,[e,t],!0,!1,null,4)},We.prototype._handleResult=function(e){if(Le.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Appearance)||(this._A=t.Appearance),y(t.CannotDelete)||(this._C=t.CannotDelete),y(t.CannotEdit)||(this._Ca=t.CannotEdit),y(t.Color)||(this._Co=t.Color),y(t.Id)||(this._I=t.Id),y(t.PlaceholderText)||(this._Pl=t.PlaceholderText),y(t.RemoveWhenEdited)||(this._R=t.RemoveWhenEdited),y(t.Style)||(this._S=t.Style),y(t.StyleBuiltIn)||(this._St=t.StyleBuiltIn),y(t.Subtype)||(this._Su=t.Subtype),y(t.Tag)||(this._Ta=t.Tag),y(t.Text)||(this._Te=t.Text),y(t.Title)||(this._Ti=t.Title),y(t.Type)||(this._Ty=t.Type),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["checkboxContentControl","CheckboxContentControl","comboBoxContentControl","ComboBoxContentControl","contentControls","ContentControls","dropDownListContentControl","DropDownListContentControl","endnotes","Endnotes","fields","Fields","font","Font","footnotes","Footnotes","inlinePictures","InlinePictures","lists","Lists","paragraphs","Paragraphs","parentBody","ParentBody","parentContentControl","ParentContentControl","parentContentControlOrNullObject","ParentContentControlOrNullObject","parentTable","ParentTable","parentTableCell","ParentTableCell","parentTableCellOrNullObject","ParentTableCellOrNullObject","parentTableOrNullObject","ParentTableOrNullObject","tables","Tables"])}},We.prototype.load=function(e){return v(this,e)},We.prototype.retrieve=function(e){return O(this,e)},We.prototype._handleIdResult=function(e){Le.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},We.prototype._handleRetrieveResult=function(e,t){Le.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Object.defineProperty(We.prototype,"onDataChanged",{get:function(){var n=this;return b("ContentControl.onDataChanged",u,"1.5",l),this.m_dataChanged||(this.m_dataChanged=new OfficeExtension.GenericEventHandlers(this.context,this,"DataChanged",{eventType:2,registerFunc:function(){return n._RegisterDataChangedEvent()},unregisterFunc:function(){return n._UnregisterDataChangedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.ContentControl_DataChanged_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_dataChanged},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"onDeleted",{get:function(){var n=this;return b("ContentControl.onDeleted",u,"1.5",l),this.m_deleted||(this.m_deleted=new OfficeExtension.GenericEventHandlers(this.context,this,"Deleted",{eventType:0,registerFunc:function(){return n._RegisterDeletedEvent()},unregisterFunc:function(){return n._UnregisterDeletedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.ContentControl_Deleted_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_deleted},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"onEntered",{get:function(){var n=this;return b("ContentControl.onEntered",u,"1.5",l),this.m_entered||(this.m_entered=new OfficeExtension.GenericEventHandlers(this.context,this,"Entered",{eventType:12,registerFunc:function(){return n._RegisterEnteredEvent()},unregisterFunc:function(){return n._UnregisterEnteredEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.ContentControl_Entered_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_entered},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"onExited",{get:function(){var n=this;return b("ContentControl.onExited",u,"1.5",l),this.m_exited||(this.m_exited=new OfficeExtension.GenericEventHandlers(this.context,this,"Exited",{eventType:13,registerFunc:function(){return n._RegisterExitedEvent()},unregisterFunc:function(){return n._UnregisterExitedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.ContentControl_Exited_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_exited},enumerable:!0,configurable:!0}),Object.defineProperty(We.prototype,"onSelectionChanged",{get:function(){var n=this;return b("ContentControl.onSelectionChanged",u,"1.5",l),this.m_selectionChanged||(this.m_selectionChanged=new OfficeExtension.GenericEventHandlers(this.context,this,"SelectionChanged",{eventType:1,registerFunc:function(){return n._RegisterSelectionChangedEvent()},unregisterFunc:function(){return n._UnregisterSelectionChangedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.ContentControl_SelectionChanged_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_selectionChanged},enumerable:!0,configurable:!0}),We.prototype.track=function(){return this.context.trackedObjects.add(this),this},We.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},We.prototype.toJSON=function(){return C(this,{appearance:this._A,cannotDelete:this._C,cannotEdit:this._Ca,color:this._Co,id:this._I,placeholderText:this._Pl,removeWhenEdited:this._R,style:this._S,styleBuiltIn:this._St,subtype:this._Su,tag:this._Ta,text:this._Te,title:this._Ti,type:this._Ty},{checkboxContentControl:this._Ch,comboBoxContentControl:this._Com,contentControls:this._Con,dropDownListContentControl:this._D,fields:this._F,font:this._Fo,inlinePictures:this._In,lists:this._L,paragraphs:this._P,tables:this._T})},We.prototype.setMockData=function(e){R(this,e)},We.prototype.ensureUnchanged=function(e){h(this,e)},We);function We(){return null!==Le&&Le.apply(this,arguments)||this}i.ContentControl=Be;var Ge,qe=(Ve.prototype.getDocument=function(){return m(this._document)&&(this._document=this.context.document),this._document},Ve.prototype.getReferenceId=function(){return m(this._refId)&&(this._refId=this._ReferenceId),this._refId},Ve.prototype._RegisterDataChangedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"ContentControlDataChanged")},Ve.prototype._UnregisterDataChangedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"ContentControlDataChanged")},Ve.prototype._RegisterDeletedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"ContentControlDeleted")},Ve.prototype._UnregisterDeletedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"ContentControlDeleted")},Ve.prototype._RegisterSelectionChangedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"ContentControlSelectionChanged")},Ve.prototype._UnregisterSelectionChangedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"ContentControlSelectionChanged")},Ve.prototype._RegisterCommentAddedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentAdded")},Ve.prototype._UnregisterCommentAddedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentAdded")},Ve.prototype._RegisterCommentChangedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentChanged")},Ve.prototype._UnregisterCommentChangedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentChanged")},Ve.prototype._RegisterCommentSelectedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentSelected")},Ve.prototype._UnregisterCommentSelectedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentSelected")},Ve.prototype._RegisterCommentDeselectedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentDeselected")},Ve.prototype._UnregisterCommentDeselectedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentDeselected")},Ve.prototype._RegisterEnteredEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"ContentControlEntered")},Ve.prototype._UnregisterEnteredEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"ContentControlEntered")},Ve.prototype._RegisterExitedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"ContentControlExited")},Ve.prototype._UnregisterExitedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"ContentControlExited")},Ve);function Ve(){}i.ContentControlCustom=qe,OfficeExtension.Utility.applyMixin(Be,qe),(Ge=K=i._CC||(i._CC={})).ContentControl_Search=function(e,t,n){var r;if(s()){var o=c(n);r=e._Search2(t,o)}else n=a(e.context,n),r=p(i.RangeCollection,e,"Search",1,[t,n],!0,!1,null,4);return{handled:!0,result:r}},Ge.ContentControl_DataChanged_EventArgsTransform=function(e,t){return{eventType:i.EventType.contentControlDataChanged,source:t.source,ids:[e.id]}},Ge.ContentControl_Deleted_EventArgsTransform=function(e,t){return{eventType:i.EventType.contentControlDeleted,source:t.source,ids:[e.id]}},Ge.ContentControl_Entered_EventArgsTransform=function(e,t){return{eventType:i.EventType.contentControlEntered,source:i.EventSource.local,ids:[e.id]}},Ge.ContentControl_Exited_EventArgsTransform=function(e,t){return{eventType:i.EventType.contentControlExited,source:i.EventSource.local,ids:[e.id]}},Ge.ContentControl_SelectionChanged_EventArgsTransform=function(e,t){return{eventType:i.EventType.contentControlSelectionChanged,source:i.EventSource.local,ids:[e.id]}};var ze,Je="ContentControlCollection",Ke=(ze=OfficeExtension.ClientObject,__extends(Xe,ze),Object.defineProperty(Xe.prototype,"_className",{get:function(){return"ContentControlCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Xe.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Xe.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Xe.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Xe.prototype,"items",{get:function(){return _("items",this.m__items,Je,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Xe.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Je,this._isNull),this.__R},enumerable:!0,configurable:!0}),Xe.prototype.getByChangeTrackingStates=function(e){return b("ContentControlCollection.getByChangeTrackingStates",u,"1.5",l),p(i.ContentControlCollection,this,"GetByChangeTrackingStates",1,[e],!0,!1,null,4)},Xe.prototype.getById=function(e){return p(i.ContentControl,this,"GetById",1,[e],!1,!1,null,4)},Xe.prototype.getByIdOrNullObject=function(e){return b("ContentControlCollection.getByIdOrNullObject",u,"1.3",l),p(i.ContentControl,this,"GetByIdOrNullObject",1,[e],!1,!1,null,4)},Xe.prototype.getByTag=function(e){return p(i.ContentControlCollection,this,"GetByTag",1,[e],!0,!1,null,4)},Xe.prototype.getByTitle=function(e){return p(i.ContentControlCollection,this,"GetByTitle",1,[e],!0,!1,null,4)},Xe.prototype.getByTypes=function(e){return b("ContentControlCollection.getByTypes",u,"1.3",l),p(i.ContentControlCollection,this,"GetByTypes",1,[e],!0,!1,null,4)},Xe.prototype.getFirst=function(){return b("ContentControlCollection.getFirst",u,"1.3",l),p(i.ContentControl,this,"GetFirst",1,[],!1,!1,null,4)},Xe.prototype.getFirstOrNullObject=function(){return b("ContentControlCollection.getFirstOrNullObject",u,"1.3",l),p(i.ContentControl,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Xe.prototype.getItem=function(e){return r(i.ContentControl,this,[e])},Xe.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Xe.prototype._handleResult=function(e){if(ze.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.ContentControl,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Xe.prototype.load=function(e){return v(this,e)},Xe.prototype.retrieve=function(e){return O(this,e)},Xe.prototype._handleIdResult=function(e){ze.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Xe.prototype._handleRetrieveResult=function(e,t){var n=this;ze.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.ContentControl,!0,n,e,t)})},Xe.prototype.track=function(){return this.context.trackedObjects.add(this),this},Xe.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Xe.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Xe.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.ContentControl,!0,n,e,t)},function(e){return n.m__items=e})},Xe);function Xe(){return null!==ze&&ze.apply(this,arguments)||this}i.ContentControlCollection=Ke;var Qe,$e="ContentControlListItem",Ze=(Qe=OfficeExtension.ClientObject,__extends(Ye,Qe),Object.defineProperty(Ye.prototype,"_className",{get:function(){return"ContentControlListItem"},enumerable:!0,configurable:!0}),Object.defineProperty(Ye.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","displayText","value","index"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ye.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","DisplayText","Value","Index"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ye.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Ye.prototype,"displayText",{get:function(){return _("displayText",this._D,$e,this._isNull),this._D},set:function(e){this._D=e,g(this,"DisplayText",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ye.prototype,"index",{get:function(){return _("index",this._I,$e,this._isNull),this._I},set:function(e){this._I=e,g(this,"Index",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ye.prototype,"value",{get:function(){return _("value",this._V,$e,this._isNull),this._V},set:function(e){this._V=e,g(this,"Value",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ye.prototype,"_Id",{get:function(){return _("_Id",this.__I,$e,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Ye.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,$e,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ye.prototype.set=function(e,t){this._recursivelySet(e,t,["displayText","value","index"],[],[])},Ye.prototype.update=function(e){this._recursivelyUpdate(e)},Ye.prototype.delete=function(){d(this,"Delete",0,[],0,0)},Ye.prototype.select=function(){d(this,"Select",0,[],0,0)},Ye.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ye.prototype._handleResult=function(e){if(Qe.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.DisplayText)||(this._D=t.DisplayText),y(t.Index)||(this._I=t.Index),y(t.Value)||(this._V=t.Value),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Ye.prototype.load=function(e){return v(this,e)},Ye.prototype.retrieve=function(e){return O(this,e)},Ye.prototype._handleIdResult=function(e){Qe.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Ye.prototype._handleRetrieveResult=function(e,t){Qe.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Ye.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ye.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ye.prototype.toJSON=function(){return C(this,{displayText:this._D,index:this._I,value:this._V},{})},Ye.prototype.setMockData=function(e){R(this,e)},Ye.prototype.ensureUnchanged=function(e){h(this,e)},Ye);function Ye(){return null!==Qe&&Qe.apply(this,arguments)||this}i.ContentControlListItem=Ze;var et,tt="ContentControlListItemCollection",nt=(et=OfficeExtension.ClientObject,__extends(rt,et),Object.defineProperty(rt.prototype,"_className",{get:function(){return"ContentControlListItemCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(rt.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(rt.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(rt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(rt.prototype,"items",{get:function(){return _("items",this.m__items,tt,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(rt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,tt,this._isNull),this.__R},enumerable:!0,configurable:!0}),rt.prototype.getFirst=function(){return p(i.ContentControlListItem,this,"GetFirst",0,[],!1,!1,null,0)},rt.prototype.getFirstOrNullObject=function(){return p(i.ContentControlListItem,this,"GetFirstOrNullObject",0,[],!1,!1,null,0)},rt.prototype._GetItem=function(e){return r(i.ContentControlListItem,this,[e])},rt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},rt.prototype._handleResult=function(e){if(et.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.ContentControlListItem,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},rt.prototype.load=function(e){return v(this,e)},rt.prototype.retrieve=function(e){return O(this,e)},rt.prototype._handleIdResult=function(e){et.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},rt.prototype._handleRetrieveResult=function(e,t){var n=this;et.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.ContentControlListItem,!0,n,e,t)})},rt.prototype.track=function(){return this.context.trackedObjects.add(this),this},rt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},rt.prototype.toJSON=function(){return C(this,{},{},this.m__items)},rt.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.ContentControlListItem,!0,n,e,t)},function(e){return n.m__items=e})},rt);function rt(){return null!==et&&et.apply(this,arguments)||this}i.ContentControlListItemCollection=nt;var ot,it="CustomProperty",at=(ot=OfficeExtension.ClientObject,__extends(st,ot),Object.defineProperty(st.prototype,"_className",{get:function(){return"CustomProperty"},enumerable:!0,configurable:!0}),Object.defineProperty(st.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","key","value","type","_Id"]},enumerable:!0,configurable:!0}),Object.defineProperty(st.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Key","Value","Type","_Id"]},enumerable:!0,configurable:!0}),Object.defineProperty(st.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!1,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(st.prototype,"key",{get:function(){return _("key",this._K,it,this._isNull),this._K},enumerable:!0,configurable:!0}),Object.defineProperty(st.prototype,"type",{get:function(){return _("type",this.m_type,it,this._isNull),this.m_type},enumerable:!0,configurable:!0}),Object.defineProperty(st.prototype,"value",{get:function(){return _("value",this.m_value,it,this._isNull),this.m_value},set:function(e){this.m_value=e,g(this,"Value",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(st.prototype,"_Id",{get:function(){return _("_Id",this.__I,it,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(st.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,it,this._isNull),this.__R},enumerable:!0,configurable:!0}),st.prototype.set=function(e,t){this._recursivelySet(e,t,["value"],[],[])},st.prototype.update=function(e){this._recursivelyUpdate(e)},st.prototype.delete=function(){d(this,"Delete",0,[],0,0)},st.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},st.prototype._handleResult=function(e){if(ot.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),K.CustomProperty_HandleResult(this,t),y(t.Key)||(this._K=t.Key),y(t.Type)||(this.m_type=t.Type),y(t.Value)||(this.m_value=t.Value),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},st.prototype.load=function(e){return v(this,e)},st.prototype.retrieve=function(e){return O(this,e)},st.prototype._handleIdResult=function(e){ot.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},st.prototype._handleRetrieveResult=function(e,t){ot.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},st.prototype.track=function(){return this.context.trackedObjects.add(this),this},st.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},st.prototype.toJSON=function(){return C(this,{key:this._K,type:this.m_type,value:this.m_value},{})},st.prototype.setMockData=function(e){R(this,e)},st.prototype.ensureUnchanged=function(e){h(this,e)},st);function st(){return null!==ot&&ot.apply(this,arguments)||this}i.CustomProperty=at,(K=i._CC||(i._CC={})).CustomProperty_HandleResult=function(e,t){y(t.Value)||y(t.Type)||"Date"!=t.Type||(t.Value=new Date(t.Value))};var ct,lt="CustomPropertyCollection",ut=(ct=OfficeExtension.ClientObject,__extends(pt,ct),Object.defineProperty(pt.prototype,"_className",{get:function(){return"CustomPropertyCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(pt.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(pt.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(pt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(pt.prototype,"items",{get:function(){return _("items",this.m__items,lt,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(pt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,lt,this._isNull),this.__R},enumerable:!0,configurable:!0}),pt.prototype.add=function(e,t){return p(i.CustomProperty,this,"Add",0,[e,t],!1,!0,null,0)},pt.prototype.deleteAll=function(){d(this,"DeleteAll",0,[],0,0)},pt.prototype.getCount=function(){return d(this,"GetCount",1,[],4,0)},pt.prototype.getItem=function(e){return r(i.CustomProperty,this,[e])},pt.prototype.getItemOrNullObject=function(e){return p(i.CustomProperty,this,"GetItemOrNullObject",1,[e],!1,!1,null,4)},pt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},pt.prototype._handleResult=function(e){if(ct.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.CustomProperty,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},pt.prototype.load=function(e){return v(this,e)},pt.prototype.retrieve=function(e){return O(this,e)},pt.prototype._handleIdResult=function(e){ct.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},pt.prototype._handleRetrieveResult=function(e,t){var n=this;ct.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.CustomProperty,!0,n,e,t)})},pt.prototype.track=function(){return this.context.trackedObjects.add(this),this},pt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},pt.prototype.toJSON=function(){return C(this,{},{},this.m__items)},pt.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.CustomProperty,!0,n,e,t)},function(e){return n.m__items=e})},pt);function pt(){return null!==ct&&ct.apply(this,arguments)||this}i.CustomPropertyCollection=ut;var ft,dt="CustomXmlPart",ht=(ft=OfficeExtension.ClientObject,__extends(gt,ft),Object.defineProperty(gt.prototype,"_className",{get:function(){return"CustomXmlPart"},enumerable:!0,configurable:!0}),Object.defineProperty(gt.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","id","namespaceUri"]},enumerable:!0,configurable:!0}),Object.defineProperty(gt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Id","NamespaceUri"]},enumerable:!0,configurable:!0}),Object.defineProperty(gt.prototype,"id",{get:function(){return _("id",this._I,dt,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(gt.prototype,"namespaceUri",{get:function(){return _("namespaceUri",this._N,dt,this._isNull),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(gt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,dt,this._isNull),this.__R},enumerable:!0,configurable:!0}),gt.prototype.delete=function(){d(this,"Delete",0,[],0,0)},gt.prototype.deleteAttribute=function(e,t,n){d(this,"DeleteAttribute",0,[e,t,n],0,0)},gt.prototype.deleteElement=function(e,t){d(this,"DeleteElement",0,[e,t],0,0)},gt.prototype.getXml=function(){return d(this,"GetXml",1,[],4,0)},gt.prototype.insertAttribute=function(e,t,n,r){d(this,"InsertAttribute",0,[e,t,n,r],0,0)},gt.prototype.insertElement=function(e,t,n,r){d(this,"InsertElement",0,[e,t,n,r],0,0)},gt.prototype.query=function(e,t){return d(this,"Query",0,[e,t],0,0)},gt.prototype.setXml=function(e){d(this,"SetXml",0,[e],0,0)},gt.prototype.updateAttribute=function(e,t,n,r){d(this,"UpdateAttribute",0,[e,t,n,r],0,0)},gt.prototype.updateElement=function(e,t,n){d(this,"UpdateElement",0,[e,t,n],0,0)},gt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},gt.prototype._handleResult=function(e){if(ft.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Id)||(this._I=t.Id),y(t.NamespaceUri)||(this._N=t.NamespaceUri),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},gt.prototype.load=function(e){return v(this,e)},gt.prototype.retrieve=function(e){return O(this,e)},gt.prototype._handleIdResult=function(e){ft.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},gt.prototype._handleRetrieveResult=function(e,t){ft.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},gt.prototype.track=function(){return this.context.trackedObjects.add(this),this},gt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},gt.prototype.toJSON=function(){return C(this,{id:this._I,namespaceUri:this._N},{})},gt.prototype.setMockData=function(e){R(this,e)},gt.prototype.ensureUnchanged=function(e){h(this,e)},gt);function gt(){return null!==ft&&ft.apply(this,arguments)||this}i.CustomXmlPart=ht;var mt,yt="CustomXmlPartCollection",_t=(mt=OfficeExtension.ClientObject,__extends(bt,mt),Object.defineProperty(bt.prototype,"_className",{get:function(){return"CustomXmlPartCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(bt.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(bt.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(bt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(bt.prototype,"items",{get:function(){return _("items",this.m__items,yt,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(bt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,yt,this._isNull),this.__R},enumerable:!0,configurable:!0}),bt.prototype.add=function(e){return p(i.CustomXmlPart,this,"Add",0,[e],!1,!0,null,0)},bt.prototype.getByNamespace=function(e){return p(i.CustomXmlPartScopedCollection,this,"GetByNamespace",1,[e],!0,!1,null,4)},bt.prototype.getCount=function(){return d(this,"GetCount",1,[],4,0)},bt.prototype.getItem=function(e){return r(i.CustomXmlPart,this,[e])},bt.prototype.getItemOrNullObject=function(e){return p(i.CustomXmlPart,this,"GetItemOrNullObject",1,[e],!1,!1,null,4)},bt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},bt.prototype._handleResult=function(e){if(mt.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.CustomXmlPart,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},bt.prototype.load=function(e){return v(this,e)},bt.prototype.retrieve=function(e){return O(this,e)},bt.prototype._handleIdResult=function(e){mt.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},bt.prototype._handleRetrieveResult=function(e,t){var n=this;mt.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.CustomXmlPart,!0,n,e,t)})},bt.prototype.track=function(){return this.context.trackedObjects.add(this),this},bt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},bt.prototype.toJSON=function(){return C(this,{},{},this.m__items)},bt.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.CustomXmlPart,!0,n,e,t)},function(e){return n.m__items=e})},bt);function bt(){return null!==mt&&mt.apply(this,arguments)||this}i.CustomXmlPartCollection=_t;var vt,Ot="CustomXmlPartScopedCollection",Ct=(vt=OfficeExtension.ClientObject,__extends(Pt,vt),Object.defineProperty(Pt.prototype,"_className",{get:function(){return"CustomXmlPartScopedCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Pt.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Pt.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Pt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Pt.prototype,"items",{get:function(){return _("items",this.m__items,Ot,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Pt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Ot,this._isNull),this.__R},enumerable:!0,configurable:!0}),Pt.prototype.getCount=function(){return d(this,"GetCount",1,[],4,0)},Pt.prototype.getItem=function(e){return r(i.CustomXmlPart,this,[e])},Pt.prototype.getItemOrNullObject=function(e){return p(i.CustomXmlPart,this,"GetItemOrNullObject",1,[e],!1,!1,null,4)},Pt.prototype.getOnlyItem=function(){return p(i.CustomXmlPart,this,"GetOnlyItem",1,[],!1,!1,null,4)},Pt.prototype.getOnlyItemOrNullObject=function(){return p(i.CustomXmlPart,this,"GetOnlyItemOrNullObject",1,[],!1,!1,null,4)},Pt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Pt.prototype._handleResult=function(e){if(vt.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.CustomXmlPart,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Pt.prototype.load=function(e){return v(this,e)},Pt.prototype.retrieve=function(e){return O(this,e)},Pt.prototype._handleIdResult=function(e){vt.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Pt.prototype._handleRetrieveResult=function(e,t){var n=this;vt.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.CustomXmlPart,!0,n,e,t)})},Pt.prototype.track=function(){return this.context.trackedObjects.add(this),this},Pt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Pt.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Pt.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.CustomXmlPart,!0,n,e,t)},function(e){return n.m__items=e})},Pt);function Pt(){return null!==vt&&vt.apply(this,arguments)||this}i.CustomXmlPartScopedCollection=Ct;var St,At="Document",It=(St=OfficeExtension.ClientObject,__extends(Rt,St),Object.defineProperty(Rt.prototype,"_className",{get:function(){return"Document"},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"_scalarPropertyNames",{get:function(){return["saved","_ReferenceId","allowCloseOnUntitled","changeTrackingMode"]},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Saved","_ReferenceId","AllowCloseOnUntitled","ChangeTrackingMode"]},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"_navigationPropertyNames",{get:function(){return["sections","body","contentControls","properties","settings","customXmlParts","windows","activeWindow"]},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"activeWindow",{get:function(){return b("Document.activeWindow","WordApiDesktop","1.2",l),this._A||(this._A=t(i.Window,this,"ActiveWindow",!1,4)),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"body",{get:function(){return this._B||(this._B=t(i.Body,this,"Body",!1,4)),this._B},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"contentControls",{get:function(){return this._Co||(this._Co=t(i.ContentControlCollection,this,"ContentControls",!0,4)),this._Co},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"customXmlParts",{get:function(){return b("Document.customXmlParts",u,"1.4",l),this._Cu||(this._Cu=t(i.CustomXmlPartCollection,this,"CustomXmlParts",!0,4)),this._Cu},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"properties",{get:function(){return b("Document.properties",u,"1.3",l),this._P||(this._P=t(i.DocumentProperties,this,"Properties",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"sections",{get:function(){return this._Se||(this._Se=t(i.SectionCollection,this,"Sections",!0,4)),this._Se},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"settings",{get:function(){return b("Document.settings",u,"1.4",l),this._Set||(this._Set=t(i.SettingCollection,this,"Settings",!0,4)),this._Set},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"windows",{get:function(){return b("Document.windows","WordApiDesktop","1.2",l),this._W||(this._W=t(i.WindowCollection,this,"Windows",!0,4)),this._W},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"allowCloseOnUntitled",{get:function(){return _("allowCloseOnUntitled",this._Al,At,this._isNull),this._Al},set:function(e){this._Al=e,g(this,"AllowCloseOnUntitled",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"changeTrackingMode",{get:function(){return _("changeTrackingMode",this._C,At,this._isNull),b("Document.changeTrackingMode",u,"1.4",l),this._C},set:function(e){this._C=e,g(this,"ChangeTrackingMode",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"saved",{get:function(){return _("saved",this._S,At,this._isNull),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.m__ReferenceId,At,this._isNull),this.m__ReferenceId},enumerable:!0,configurable:!0}),Rt.prototype.set=function(e,t){this._recursivelySet(e,t,["allowCloseOnUntitled","changeTrackingMode"],["body","properties"],["activeWindow","contentControls","customXmlParts","sections","settings","windows"])},Rt.prototype.update=function(e){this._recursivelyUpdate(e)},Rt.prototype.addStyle=function(e,t){return b("Document.addStyle",u,"1.5",l),p(i.Style,this,"AddStyle",0,[e,t],!1,!1,null,0)},Rt.prototype.close=function(e){b("Document.close",u,"1.5",l),d(this,"Close",0,[e],0,0)},Rt.prototype.compare=function(e,t){b("Document.compare","WordApiDesktop","1.1",l),d(this,"Compare",0,[e,t],0,0)},Rt.prototype.compareFromBase64=function(e,t){b("Document.compareFromBase64","WordApiDesktop","1.2",l),d(this,"CompareFromBase64",0,[e,t],0,0)},Rt.prototype.deleteBookmark=function(e){b("Document.deleteBookmark",u,"1.4",l),d(this,"DeleteBookmark",0,[e],0,0)},Rt.prototype.getAnnotationById=function(e){return b("Document.getAnnotationById",u,"1.7",l),p(i.Annotation,this,"GetAnnotationById",0,[e],!1,!1,null,0)},Rt.prototype.getAnnotationsByType=function(e){return b("Document.getAnnotationsByType","WordApiOnline","1.1",l),p(i.AugloopAnnotationCollection,this,"GetAnnotationsByType",1,[e],!0,!1,null,4)},Rt.prototype.getBookmarkRange=function(e){return b("Document.getBookmarkRange",u,"1.4",l),p(i.Range,this,"GetBookmarkRange",1,[e],!1,!1,null,4)},Rt.prototype.getBookmarkRangeOrNullObject=function(e){return b("Document.getBookmarkRangeOrNullObject",u,"1.4",l),p(i.Range,this,"GetBookmarkRangeOrNullObject",1,[e],!1,!1,null,4)},Rt.prototype.getContentControls=function(e){return b("Document.getContentControls",u,"1.5",l),p(i.ContentControlCollection,this,"GetContentControls",1,[e],!0,!1,null,4)},Rt.prototype.getEndnoteBody=function(){return b("Document.getEndnoteBody",u,"1.5",l),p(i.Body,this,"GetEndnoteBody",1,[],!1,!1,null,4)},Rt.prototype.getFootnoteBody=function(){return b("Document.getFootnoteBody",u,"1.5",l),p(i.Body,this,"GetFootnoteBody",1,[],!1,!1,null,4)},Rt.prototype.getMetadata=function(e){return d(this,"GetMetadata",1,[e],4,0)},Rt.prototype.getNeighborhoodTextAroundSelection=function(e){return d(this,"GetNeighborhoodTextAroundSelection",1,[e],5,0)},Rt.prototype.getParagraphByUniqueLocalId=function(e){return b("Document.getParagraphByUniqueLocalId",u,"1.6",l),p(i.Paragraph,this,"GetParagraphByUniqueLocalId",1,[e],!1,!1,null,4)},Rt.prototype.getSelection=function(){return p(i.Range,this,"GetSelection",1,[],!1,!0,null,4)},Rt.prototype.getStyles=function(){return b("Document.getStyles",u,"1.5",l),p(i.StyleCollection,this,"GetStyles",1,[],!0,!1,null,4)},Rt.prototype.importStylesFromJson=function(e,t){return b("Document.importStylesFromJson",u,"1.6",l),d(this,"ImportStylesFromJson",0,[e,t],0,0)},Rt.prototype.insertFileFromBase64=function(e,t,n){return b("Document.insertFileFromBase64",u,"1.5",l),p(i.SectionCollection,this,"InsertFileFromBase64",0,[e,t,n],!0,!0,null,0)},Rt.prototype.launchTapPane=function(e){d(this,"LaunchTapPane",1,[e],5,0)},Rt.prototype.save=function(e,t){d(this,"Save",0,[e,t],0,0)},Rt.prototype.search=function(e,t){var n=K.Document_Search(this,e,t),r=n.handled,o=n.result;return r?o:(b("Document.search",u,"1.7",l),p(i.RangeCollection,this,"Search",1,[e,t],!0,!1,null,4))},Rt.prototype.setMetadata=function(e,t){d(this,"SetMetadata",0,[e,t],0,0)},Rt.prototype.setMetadataOnTile=function(e,t,n){d(this,"SetMetadataOnTile",0,[e,t,n],0,0)},Rt.prototype.setNavigationPaneVisibility=function(e){b("Document.setNavigationPaneVisibility","WordApiOnline","1.1",l),d(this,"SetNavigationPaneVisibility",0,[e],1,0)},Rt.prototype._GetObjectByReferenceId=function(e){return d(this,"_GetObjectByReferenceId",1,[e],4,0)},Rt.prototype._GetObjectTypeNameByReferenceId=function(e){return d(this,"_GetObjectTypeNameByReferenceId",1,[e],4,0)},Rt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Rt.prototype._RegisterEvent=function(e,t){d(this,"_RegisterEvent",1,[e,t],4,0)},Rt.prototype._RemoveAllReferences=function(){d(this,"_RemoveAllReferences",1,[],4,0)},Rt.prototype._RemoveReference=function(e){d(this,"_RemoveReference",1,[e],4,0)},Rt.prototype._Search2=function(e,t){return b("Document._Search2",u,"1.7",l),p(i.RangeCollection,this,"_Search2",1,[e,t],!0,!1,null,4)},Rt.prototype._UnregisterEvent=function(e,t){d(this,"_UnregisterEvent",1,[e,t],4,0)},Rt.prototype._handleResult=function(e){if(St.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.AllowCloseOnUntitled)||(this._Al=t.AllowCloseOnUntitled),y(t.ChangeTrackingMode)||(this._C=t.ChangeTrackingMode),y(t.Saved)||(this._S=t.Saved),y(t._ReferenceId)||(this.m__ReferenceId=t._ReferenceId),S(this,t,["activeWindow","ActiveWindow","body","Body","contentControls","ContentControls","customXmlParts","CustomXmlParts","properties","Properties","sections","Sections","settings","Settings","windows","Windows"])}},Rt.prototype.load=function(e){return v(this,e)},Rt.prototype.retrieve=function(e){return O(this,e)},Rt.prototype._handleIdResult=function(e){St.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.m__ReferenceId=e._ReferenceId)},Rt.prototype._handleRetrieveResult=function(e,t){St.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Object.defineProperty(Rt.prototype,"onAnnotationClicked",{get:function(){var n=this;return b("Document.onAnnotationClicked",u,"1.7",l),this.m_annotationClicked||(this.m_annotationClicked=new OfficeExtension.GenericEventHandlers(this.context,this,"AnnotationClicked",{eventType:18,registerFunc:function(){return n._RegisterAnnotationClickedEvent()},unregisterFunc:function(){return n._UnregisterAnnotationClickedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_AnnotationClicked_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_annotationClicked},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onAnnotationHovered",{get:function(){var n=this;return b("Document.onAnnotationHovered",u,"1.7",l),this.m_annotationHovered||(this.m_annotationHovered=new OfficeExtension.GenericEventHandlers(this.context,this,"AnnotationHovered",{eventType:19,registerFunc:function(){return n._RegisterAnnotationHoveredEvent()},unregisterFunc:function(){return n._UnregisterAnnotationHoveredEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_AnnotationHovered_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_annotationHovered},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onAnnotationInserted",{get:function(){var n=this;return b("Document.onAnnotationInserted",u,"1.7",l),this.m_annotationInserted||(this.m_annotationInserted=new OfficeExtension.GenericEventHandlers(this.context,this,"AnnotationInserted",{eventType:20,registerFunc:function(){return n._RegisterAnnotationInsertedEvent()},unregisterFunc:function(){return n._UnregisterAnnotationInsertedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_AnnotationInserted_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_annotationInserted},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onAnnotationPopupAction",{get:function(){var e=this;return b("Document.onAnnotationPopupAction",u,"1.8",l),this.m_annotationPopupAction||(this.m_annotationPopupAction=new OfficeExtension.GenericEventHandlers(this.context,this,"AnnotationPopupAction",{eventType:22,registerFunc:function(){return e._RegisterAnnotationPopupActionEvent()},unregisterFunc:function(){return e._UnregisterAnnotationPopupActionEvent()},getTargetIdFunc:function(){return e._ReferenceId},eventArgsTransformFunc:function(e){var t={action:e.action,critiqueSuggestion:e.critiqueSuggestion,id:e.id};return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_annotationPopupAction},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onAnnotationRemoved",{get:function(){var n=this;return b("Document.onAnnotationRemoved",u,"1.7",l),this.m_annotationRemoved||(this.m_annotationRemoved=new OfficeExtension.GenericEventHandlers(this.context,this,"AnnotationRemoved",{eventType:21,registerFunc:function(){return n._RegisterAnnotationRemovedEvent()},unregisterFunc:function(){return n._UnregisterAnnotationRemovedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_AnnotationRemoved_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_annotationRemoved},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onContentControlAdded",{get:function(){var n=this;return b("Document.onContentControlAdded",u,"1.5",l),this.m_contentControlAdded||(this.m_contentControlAdded=new OfficeExtension.GenericEventHandlers(this.context,this,"ContentControlAdded",{eventType:3,registerFunc:function(){return n._RegisterContentControlAddedEvent()},unregisterFunc:function(){return n._UnregisterContentControlAddedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_ContentControlAdded_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_contentControlAdded},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onParagraphAdded",{get:function(){var n=this;return b("Document.onParagraphAdded",u,"1.6",l),this.m_paragraphAdded||(this.m_paragraphAdded=new OfficeExtension.GenericEventHandlers(this.context,this,"ParagraphAdded",{eventType:15,registerFunc:function(){return n._RegisterParagraphAddedEvent()},unregisterFunc:function(){return n._UnregisterParagraphAddedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_ParagraphAdded_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_paragraphAdded},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onParagraphChanged",{get:function(){var n=this;return b("Document.onParagraphChanged",u,"1.6",l),this.m_paragraphChanged||(this.m_paragraphChanged=new OfficeExtension.GenericEventHandlers(this.context,this,"ParagraphChanged",{eventType:16,registerFunc:function(){return n._RegisterParagraphChangedEvent()},unregisterFunc:function(){return n._UnregisterParagraphChangedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_ParagraphChanged_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_paragraphChanged},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onParagraphDeleted",{get:function(){var n=this;return b("Document.onParagraphDeleted",u,"1.6",l),this.m_paragraphDeleted||(this.m_paragraphDeleted=new OfficeExtension.GenericEventHandlers(this.context,this,"ParagraphDeleted",{eventType:17,registerFunc:function(){return n._RegisterParagraphDeletedEvent()},unregisterFunc:function(){return n._UnregisterParagraphDeletedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_ParagraphDeleted_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_paragraphDeleted},enumerable:!0,configurable:!0}),Object.defineProperty(Rt.prototype,"onWordCountChanged",{get:function(){var n=this;return this.m_wordCountChanged||(this.m_wordCountChanged=new OfficeExtension.GenericEventHandlers(this.context,this,"WordCountChanged",{eventType:14,registerFunc:function(){return n._RegisterWordCountChangedEvent()},unregisterFunc:function(){return n._UnregisterWordCountChangedEvent()},getTargetIdFunc:function(){return n._ReferenceId},eventArgsTransformFunc:function(e){var t=K.Document_WordCountChanged_EventArgsTransform(n,e);return OfficeExtension.Utility._createPromiseFromResult(t)}})),this.m_wordCountChanged},enumerable:!0,configurable:!0}),Rt.prototype.track=function(){return this.context.trackedObjects.add(this),this},Rt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Rt.prototype.toJSON=function(){return C(this,{allowCloseOnUntitled:this._Al,changeTrackingMode:this._C,saved:this._S},{activeWindow:this._A,body:this._B,contentControls:this._Co,customXmlParts:this._Cu,properties:this._P,sections:this._Se,settings:this._Set,windows:this._W})},Rt.prototype.setMockData=function(e){R(this,e)},Rt.prototype.ensureUnchanged=function(e){h(this,e)},Rt);function Rt(){return null!==St&&St.apply(this,arguments)||this}i.Document=It;var Tt,Et=(Nt.prototype._RegisterContentControlAddedEvent=function(){this._RegisterEvent(this._ReferenceId,"ContentControlAdded")},Nt.prototype._UnregisterContentControlAddedEvent=function(){this._UnregisterEvent(this._ReferenceId,"ContentControlAdded")},Nt.prototype._RegisterWordCountChangedEvent=function(){this._RegisterEvent(this._ReferenceId,"DocumentWordCountChanged")},Nt.prototype._UnregisterWordCountChangedEvent=function(){this._UnregisterEvent(this._ReferenceId,"DocumentWordCountChanged")},Nt.prototype._RegisterParagraphAddedEvent=function(){this._RegisterEvent(this._ReferenceId,"ParagraphAdded")},Nt.prototype._UnregisterParagraphAddedEvent=function(){this._UnregisterEvent(this._ReferenceId,"ParagraphAdded")},Nt.prototype._RegisterParagraphChangedEvent=function(){this._RegisterEvent(this._ReferenceId,"ParagraphChanged")},Nt.prototype._UnregisterParagraphChangedEvent=function(){this._UnregisterEvent(this._ReferenceId,"ParagraphChanged")},Nt.prototype._RegisterParagraphDeletedEvent=function(){this._RegisterEvent(this._ReferenceId,"ParagraphDeleted")},Nt.prototype._UnregisterParagraphDeletedEvent=function(){this._UnregisterEvent(this._ReferenceId,"ParagraphDeleted")},Nt.prototype._RegisterAnnotationClickedEvent=function(){this._RegisterEvent(this._ReferenceId,"AnnotationClicked")},Nt.prototype._UnregisterAnnotationClickedEvent=function(){this._UnregisterEvent(this._ReferenceId,"AnnotationClicked")},Nt.prototype._RegisterAnnotationHoveredEvent=function(){this._RegisterEvent(this._ReferenceId,"AnnotationHovered")},Nt.prototype._UnregisterAnnotationHoveredEvent=function(){this._UnregisterEvent(this._ReferenceId,"AnnotationHovered")},Nt.prototype._RegisterAnnotationInsertedEvent=function(){this._RegisterEvent(this._ReferenceId,"AnnotationInserted")},Nt.prototype._UnregisterAnnotationInsertedEvent=function(){this._UnregisterEvent(this._ReferenceId,"AnnotationInserted")},Nt.prototype._RegisterAnnotationRemovedEvent=function(){this._RegisterEvent(this._ReferenceId,"AnnotationRemoved")},Nt.prototype._UnregisterAnnotationRemovedEvent=function(){this._UnregisterEvent(this._ReferenceId,"AnnotationRemoved")},Nt.prototype._RegisterAnnotationPopupActionEvent=function(){this._RegisterEvent(this._ReferenceId,"AnnotationPopupAction")},Nt.prototype._UnregisterAnnotationPopupActionEvent=function(){this._UnregisterEvent(this._ReferenceId,"AnnotationPopupAction")},Nt);function Nt(){}i.DocumentCustom=Et,OfficeExtension.Utility.applyMixin(It,Et),(Tt=K=i._CC||(i._CC={})).Document_Search=function(e,t,n){var r;if(s())n=a(e.context,n),r=p(i.RangeCollection,e,"Search",1,[t,n],!0,!1,null,4);else{var o=c(n);r=e._Search2(t,o)}return{handled:!0,result:r}},Tt.Document_AnnotationClicked_EventArgsTransform=function(e,t){return{id:t}},Tt.Document_AnnotationHovered_EventArgsTransform=function(e,t){return{id:t}},Tt.Document_AnnotationInserted_EventArgsTransform=function(e,t){return{ids:t}},Tt.Document_AnnotationRemoved_EventArgsTransform=function(e,t){return{ids:t}},Tt.Document_ContentControlAdded_EventArgsTransform=function(e,t){return{eventType:i.EventType.contentControlAdded,source:t.source,ids:t.ids}},Tt.Document_ParagraphAdded_EventArgsTransform=function(e,t){return{type:i.EventType.paragraphAdded,source:t.source,uniqueLocalIds:t.uniqueLocalIds}},Tt.Document_ParagraphChanged_EventArgsTransform=function(e,t){return{type:i.EventType.paragraphChanged,source:t.source,uniqueLocalIds:t.uniqueLocalIds}},Tt.Document_ParagraphDeleted_EventArgsTransform=function(e,t){return{type:i.EventType.paragraphDeleted,source:t.source,uniqueLocalIds:t.uniqueLocalIds}},Tt.Document_WordCountChanged_EventArgsTransform=function(e,t){return{eventType:i.EventType.documentWordCountChanged,source:t.source,wordCount:t.wordCount}};var Dt,xt="DocumentCreated",wt=(Dt=OfficeExtension.ClientObject,__extends(Ft,Dt),Object.defineProperty(Ft.prototype,"_className",{get:function(){return"DocumentCreated"},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"_scalarPropertyNames",{get:function(){return["saved","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Saved","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"_navigationPropertyNames",{get:function(){return["sections","body","contentControls","properties","settings","customXmlParts"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"body",{get:function(){return b("DocumentCreated.body","WordApiHiddenDocument","1.3",l),this._B||(this._B=t(i.Body,this,"Body",!1,4)),this._B},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"contentControls",{get:function(){return b("DocumentCreated.contentControls","WordApiHiddenDocument","1.3",l),this._C||(this._C=t(i.ContentControlCollection,this,"ContentControls",!0,4)),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"customXmlParts",{get:function(){return b("DocumentCreated.customXmlParts","WordApiHiddenDocument","1.4",l),this._Cu||(this._Cu=t(i.CustomXmlPartCollection,this,"CustomXmlParts",!0,4)),this._Cu},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"properties",{get:function(){return b("DocumentCreated.properties","WordApiHiddenDocument","1.3",l),this._P||(this._P=t(i.DocumentProperties,this,"Properties",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"sections",{get:function(){return b("DocumentCreated.sections","WordApiHiddenDocument","1.3",l),this._Se||(this._Se=t(i.SectionCollection,this,"Sections",!0,4)),this._Se},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"settings",{get:function(){return b("DocumentCreated.settings","WordApiHiddenDocument","1.4",l),this._Set||(this._Set=t(i.SettingCollection,this,"Settings",!0,4)),this._Set},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"saved",{get:function(){return _("saved",this._S,xt,this._isNull),b("DocumentCreated.saved","WordApiHiddenDocument","1.3",l),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(Ft.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.m__ReferenceId,xt,this._isNull),this.m__ReferenceId},enumerable:!0,configurable:!0}),Ft.prototype.set=function(e,t){this._recursivelySet(e,t,[],["body","properties"],["contentControls","customXmlParts","sections","settings"])},Ft.prototype.update=function(e){this._recursivelyUpdate(e)},Ft.prototype.addStyle=function(e,t){return b("DocumentCreated.addStyle","WordApiHiddenDocument","1.5",l),p(i.Style,this,"AddStyle",0,[e,t],!1,!1,null,0)},Ft.prototype.deleteBookmark=function(e){b("DocumentCreated.deleteBookmark","WordApiHiddenDocument","1.4",l),d(this,"DeleteBookmark",0,[e],0,0)},Ft.prototype.getBookmarkRange=function(e){return b("DocumentCreated.getBookmarkRange","WordApiHiddenDocument","1.4",l),p(i.Range,this,"GetBookmarkRange",1,[e],!1,!1,null,4)},Ft.prototype.getBookmarkRangeOrNullObject=function(e){return b("DocumentCreated.getBookmarkRangeOrNullObject","WordApiHiddenDocument","1.4",l),p(i.Range,this,"GetBookmarkRangeOrNullObject",1,[e],!1,!1,null,4)},Ft.prototype.getContentControls=function(e){return b("DocumentCreated.getContentControls","WordApiHiddenDocument","1.5",l),p(i.ContentControlCollection,this,"GetContentControls",1,[e],!0,!1,null,4)},Ft.prototype.getStyles=function(){return b("DocumentCreated.getStyles","WordApiHiddenDocument","1.5",l),p(i.StyleCollection,this,"GetStyles",1,[],!0,!1,null,4)},Ft.prototype.insertFileFromBase64=function(e,t,n){return b("DocumentCreated.insertFileFromBase64","WordApiHiddenDocument","1.5",l),p(i.SectionCollection,this,"InsertFileFromBase64",0,[e,t,n],!0,!0,null,0)},Ft.prototype.open=function(){d(this,"Open",1,[],4,0)},Ft.prototype.save=function(e,t){b("DocumentCreated.save","WordApiHiddenDocument","1.3",l),d(this,"Save",0,[e,t],0,0)},Ft.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ft.prototype._handleResult=function(e){if(Dt.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Saved)||(this._S=t.Saved),y(t._ReferenceId)||(this.m__ReferenceId=t._ReferenceId),S(this,t,["body","Body","contentControls","ContentControls","customXmlParts","CustomXmlParts","properties","Properties","sections","Sections","settings","Settings"])}},Ft.prototype.load=function(e){return v(this,e)},Ft.prototype.retrieve=function(e){return O(this,e)},Ft.prototype._handleIdResult=function(e){Dt.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.m__ReferenceId=e._ReferenceId)},Ft.prototype._handleRetrieveResult=function(e,t){Dt.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Ft.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ft.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ft.prototype.toJSON=function(){return C(this,{saved:this._S},{body:this._B,contentControls:this._C,customXmlParts:this._Cu,properties:this._P,sections:this._Se,settings:this._Set})},Ft.prototype.setMockData=function(e){R(this,e)},Ft.prototype.ensureUnchanged=function(e){h(this,e)},Ft);function Ft(){return null!==Dt&&Dt.apply(this,arguments)||this}i.DocumentCreated=wt;var jt,kt="DocumentProperties",Mt=(jt=OfficeExtension.ClientObject,__extends(Ht,jt),Object.defineProperty(Ht.prototype,"_className",{get:function(){return"DocumentProperties"},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","title","subject","author","keywords","comments","template","lastAuthor","revisionNumber","applicationName","lastPrintDate","creationDate","lastSaveTime","security","category","format","manager","company"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Title","Subject","Author","Keywords","Comments","Template","LastAuthor","RevisionNumber","ApplicationName","LastPrintDate","CreationDate","LastSaveTime","Security","Category","Format","Manager","Company"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0,!0,!0,!1,!1,!1,!1,!1,!1,!1,!1,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"_navigationPropertyNames",{get:function(){return["customProperties"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"customProperties",{get:function(){return this._Cu||(this._Cu=t(i.CustomPropertyCollection,this,"CustomProperties",!0,4)),this._Cu},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"applicationName",{get:function(){return _("applicationName",this._A,kt,this._isNull),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"author",{get:function(){return _("author",this._Au,kt,this._isNull),this._Au},set:function(e){this._Au=e,g(this,"Author",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"category",{get:function(){return _("category",this._C,kt,this._isNull),this._C},set:function(e){this._C=e,g(this,"Category",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"comments",{get:function(){return _("comments",this._Co,kt,this._isNull),this._Co},set:function(e){this._Co=e,g(this,"Comments",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"company",{get:function(){return _("company",this._Com,kt,this._isNull),this._Com},set:function(e){this._Com=e,g(this,"Company",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"creationDate",{get:function(){return _("creationDate",this._Cr,kt,this._isNull),this._Cr},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"format",{get:function(){return _("format",this._F,kt,this._isNull),this._F},set:function(e){this._F=e,g(this,"Format",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"keywords",{get:function(){return _("keywords",this._K,kt,this._isNull),this._K},set:function(e){this._K=e,g(this,"Keywords",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"lastAuthor",{get:function(){return _("lastAuthor",this._L,kt,this._isNull),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"lastPrintDate",{get:function(){return _("lastPrintDate",this._La,kt,this._isNull),this._La},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"lastSaveTime",{get:function(){return _("lastSaveTime",this._Las,kt,this._isNull),this._Las},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"manager",{get:function(){return _("manager",this._M,kt,this._isNull),this._M},set:function(e){this._M=e,g(this,"Manager",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"revisionNumber",{get:function(){return _("revisionNumber",this._R,kt,this._isNull),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"security",{get:function(){return _("security",this._S,kt,this._isNull),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"subject",{get:function(){return _("subject",this._Su,kt,this._isNull),this._Su},set:function(e){this._Su=e,g(this,"Subject",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"template",{get:function(){return _("template",this._T,kt,this._isNull),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"title",{get:function(){return _("title",this._Ti,kt,this._isNull),this._Ti},set:function(e){this._Ti=e,g(this,"Title",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ht.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,kt,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ht.prototype.set=function(e,t){this._recursivelySet(e,t,["title","subject","author","keywords","comments","category","format","manager","company"],[],["customProperties"])},Ht.prototype.update=function(e){this._recursivelyUpdate(e)},Ht.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ht.prototype._handleResult=function(e){if(jt.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.ApplicationName)||(this._A=t.ApplicationName),y(t.Author)||(this._Au=t.Author),y(t.Category)||(this._C=t.Category),y(t.Comments)||(this._Co=t.Comments),y(t.Company)||(this._Com=t.Company),y(t.CreationDate)||(this._Cr=A(t.CreationDate)),y(t.Format)||(this._F=t.Format),y(t.Keywords)||(this._K=t.Keywords),y(t.LastAuthor)||(this._L=t.LastAuthor),y(t.LastPrintDate)||(this._La=A(t.LastPrintDate)),y(t.LastSaveTime)||(this._Las=A(t.LastSaveTime)),y(t.Manager)||(this._M=t.Manager),y(t.RevisionNumber)||(this._R=t.RevisionNumber),y(t.Security)||(this._S=t.Security),y(t.Subject)||(this._Su=t.Subject),y(t.Template)||(this._T=t.Template),y(t.Title)||(this._Ti=t.Title),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["customProperties","CustomProperties"])}},Ht.prototype.load=function(e){return v(this,e)},Ht.prototype.retrieve=function(e){return O(this,e)},Ht.prototype._handleIdResult=function(e){jt.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Ht.prototype._handleRetrieveResult=function(e,t){if(jt.prototype._handleRetrieveResult.call(this,e,t),!m(e)){var n=e;y(n.CreationDate)||(n.creationDate=A(n.creationDate)),y(n.LastPrintDate)||(n.lastPrintDate=A(n.lastPrintDate)),y(n.LastSaveTime)||(n.lastSaveTime=A(n.lastSaveTime)),I(this,e,t)}},Ht.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ht.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ht.prototype.toJSON=function(){return C(this,{applicationName:this._A,author:this._Au,category:this._C,comments:this._Co,company:this._Com,creationDate:this._Cr,format:this._F,keywords:this._K,lastAuthor:this._L,lastPrintDate:this._La,lastSaveTime:this._Las,manager:this._M,revisionNumber:this._R,security:this._S,subject:this._Su,template:this._T,title:this._Ti},{customProperties:this._Cu})},Ht.prototype.setMockData=function(e){R(this,e)},Ht.prototype.ensureUnchanged=function(e){h(this,e)},Ht);function Ht(){return null!==jt&&jt.apply(this,arguments)||this}i.DocumentProperties=Mt;var Lt,Ut=(Lt=OfficeExtension.ClientObject,__extends(Bt,Lt),Object.defineProperty(Bt.prototype,"_className",{get:function(){return"DropDownListContentControl"},enumerable:!0,configurable:!0}),Object.defineProperty(Bt.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Bt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Bt.prototype,"_navigationPropertyNames",{get:function(){return["listItems"]},enumerable:!0,configurable:!0}),Object.defineProperty(Bt.prototype,"listItems",{get:function(){return this._L||(this._L=t(i.ContentControlListItemCollection,this,"ListItems",!0,4)),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(Bt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,"DropDownListContentControl",this._isNull),this.__R},enumerable:!0,configurable:!0}),Bt.prototype.addListItem=function(e,t,n){return p(i.ContentControlListItem,this,"AddListItem",0,[e,t,n],!1,!0,null,0)},Bt.prototype.deleteAllListItems=function(){d(this,"DeleteAllListItems",0,[],0,0)},Bt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Bt.prototype._handleResult=function(e){if(Lt.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["listItems","ListItems"])}},Bt.prototype.load=function(e){return v(this,e)},Bt.prototype.retrieve=function(e){return O(this,e)},Bt.prototype._handleIdResult=function(e){Lt.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Bt.prototype._handleRetrieveResult=function(e,t){Lt.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Bt.prototype.track=function(){return this.context.trackedObjects.add(this),this},Bt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Bt.prototype.toJSON=function(){return C(this,{},{})},Bt);function Bt(){return null!==Lt&&Lt.apply(this,arguments)||this}i.DropDownListContentControl=Ut;var Wt,Gt=(Wt=OfficeExtension.ClientObject,__extends(qt,Wt),Object.defineProperty(qt.prototype,"_className",{get:function(){return"ComboBoxContentControl"},enumerable:!0,configurable:!0}),Object.defineProperty(qt.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(qt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(qt.prototype,"_navigationPropertyNames",{get:function(){return["listItems"]},enumerable:!0,configurable:!0}),Object.defineProperty(qt.prototype,"listItems",{get:function(){return this._L||(this._L=t(i.ContentControlListItemCollection,this,"ListItems",!0,4)),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(qt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,"ComboBoxContentControl",this._isNull),this.__R},enumerable:!0,configurable:!0}),qt.prototype.addListItem=function(e,t,n){return p(i.ContentControlListItem,this,"AddListItem",0,[e,t,n],!1,!0,null,0)},qt.prototype.deleteAllListItems=function(){d(this,"DeleteAllListItems",0,[],0,0)},qt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},qt.prototype._handleResult=function(e){if(Wt.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["listItems","ListItems"])}},qt.prototype.load=function(e){return v(this,e)},qt.prototype.retrieve=function(e){return O(this,e)},qt.prototype._handleIdResult=function(e){Wt.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},qt.prototype._handleRetrieveResult=function(e,t){Wt.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},qt.prototype.track=function(){return this.context.trackedObjects.add(this),this},qt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},qt.prototype.toJSON=function(){return C(this,{},{})},qt);function qt(){return null!==Wt&&Wt.apply(this,arguments)||this}i.ComboBoxContentControl=Gt;var Vt,zt="Field",Jt=(Vt=OfficeExtension.ClientObject,__extends(Kt,Vt),Object.defineProperty(Kt.prototype,"_className",{get:function(){return"Field"},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","code","type","kind","showCodes","locked","data"]},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","Code","Type","Kind","ShowCodes","Locked","Data"]},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!1,!1,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"_navigationPropertyNames",{get:function(){return["result","parentBody","parentContentControl","parentContentControlOrNullObject","parentTable","parentTableOrNullObject","parentTableCell","parentTableCellOrNullObject"]},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"parentBody",{get:function(){return this._P||(this._P=t(i.Body,this,"ParentBody",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"parentContentControl",{get:function(){return this._Pa||(this._Pa=t(i.ContentControl,this,"ParentContentControl",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"parentContentControlOrNullObject",{get:function(){return this._Par||(this._Par=t(i.ContentControl,this,"ParentContentControlOrNullObject",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"parentTable",{get:function(){return this._Pare||(this._Pare=t(i.Table,this,"ParentTable",!1,4)),this._Pare},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"parentTableCell",{get:function(){return this._Paren||(this._Paren=t(i.TableCell,this,"ParentTableCell",!1,4)),this._Paren},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"parentTableCellOrNullObject",{get:function(){return this._Parent||(this._Parent=t(i.TableCell,this,"ParentTableCellOrNullObject",!1,4)),this._Parent},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"parentTableOrNullObject",{get:function(){return this._ParentT||(this._ParentT=t(i.Table,this,"ParentTableOrNullObject",!1,4)),this._ParentT},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"result",{get:function(){return this._R||(this._R=t(i.Range,this,"Result",!1,4)),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"code",{get:function(){return _("code",this._C,zt,this._isNull),this._C},set:function(e){this._C=e,g(this,"Code",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"data",{get:function(){return _("data",this._D,zt,this._isNull),b("Field.data",u,"1.5",l),this._D},set:function(e){this._D=e,g(this,"Data",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"kind",{get:function(){return _("kind",this._K,zt,this._isNull),b("Field.kind",u,"1.5",l),this._K},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"locked",{get:function(){return _("locked",this._L,zt,this._isNull),b("Field.locked",u,"1.5",l),this._L},set:function(e){this._L=e,g(this,"Locked",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"showCodes",{get:function(){return _("showCodes",this._S,zt,this._isNull),b("Field.showCodes","WordApiDesktop","1.1",l),this._S},set:function(e){this._S=e,g(this,"ShowCodes",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"type",{get:function(){return _("type",this._T,zt,this._isNull),b("Field.type",u,"1.5",l),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"_Id",{get:function(){return _("_Id",this.__I,zt,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Kt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,zt,this._isNull),this.__R},enumerable:!0,configurable:!0}),Kt.prototype.set=function(e,t){this._recursivelySet(e,t,["code","showCodes","locked","data"],["result"],["parentBody","parentContentControl","parentContentControlOrNullObject","parentTable","parentTableCell","parentTableCellOrNullObject","parentTableOrNullObject"])},Kt.prototype.update=function(e){this._recursivelyUpdate(e)},Kt.prototype.delete=function(){b("Field.delete",u,"1.5",l),d(this,"Delete",0,[],0,0)},Kt.prototype.getNext=function(){return p(i.Field,this,"GetNext",1,[],!1,!1,null,4)},Kt.prototype.getNextOrNullObject=function(){return p(i.Field,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},Kt.prototype.select=function(e){b("Field.select",u,"1.5",l),d(this,"Select",1,[e],4,0)},Kt.prototype.updateResult=function(){b("Field.updateResult",u,"1.5",l),d(this,"UpdateResult",0,[],0,0)},Kt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Kt.prototype._handleResult=function(e){if(Vt.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Code)||(this._C=t.Code),y(t.Data)||(this._D=t.Data),y(t.Kind)||(this._K=t.Kind),y(t.Locked)||(this._L=t.Locked),y(t.ShowCodes)||(this._S=t.ShowCodes),y(t.Type)||(this._T=t.Type),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["parentBody","ParentBody","parentContentControl","ParentContentControl","parentContentControlOrNullObject","ParentContentControlOrNullObject","parentTable","ParentTable","parentTableCell","ParentTableCell","parentTableCellOrNullObject","ParentTableCellOrNullObject","parentTableOrNullObject","ParentTableOrNullObject","result","Result"])}},Kt.prototype.load=function(e){return v(this,e)},Kt.prototype.retrieve=function(e){return O(this,e)},Kt.prototype._handleIdResult=function(e){Vt.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Kt.prototype._handleRetrieveResult=function(e,t){Vt.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Kt.prototype.track=function(){return this.context.trackedObjects.add(this),this},Kt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Kt.prototype.toJSON=function(){return C(this,{code:this._C,data:this._D,kind:this._K,locked:this._L,showCodes:this._S,type:this._T},{result:this._R})},Kt.prototype.setMockData=function(e){R(this,e)},Kt.prototype.ensureUnchanged=function(e){h(this,e)},Kt);function Kt(){return null!==Vt&&Vt.apply(this,arguments)||this}i.Field=Jt;var Xt,Qt="FieldCollection",$t=(Xt=OfficeExtension.ClientObject,__extends(Zt,Xt),Object.defineProperty(Zt.prototype,"_className",{get:function(){return"FieldCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Zt.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Zt.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Zt.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Zt.prototype,"items",{get:function(){return _("items",this.m__items,Qt,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Zt.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Qt,this._isNull),this.__R},enumerable:!0,configurable:!0}),Zt.prototype.getFirst=function(){return p(i.Field,this,"GetFirst",1,[],!1,!1,null,4)},Zt.prototype.getFirstOrNullObject=function(){return p(i.Field,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Zt.prototype._GetItem=function(e){return r(i.Field,this,[e])},Zt.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Zt.prototype.getByTypes=function(e){return b("FieldCollection.getByTypes",u,"1.5",l),p(i.FieldCollection,this,"getByTypes",1,[e],!0,!1,null,4)},Zt.prototype._handleResult=function(e){if(Xt.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Field,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Zt.prototype.load=function(e){return v(this,e)},Zt.prototype.retrieve=function(e){return O(this,e)},Zt.prototype._handleIdResult=function(e){Xt.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Zt.prototype._handleRetrieveResult=function(e,t){var n=this;Xt.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Field,!0,n,e,t)})},Zt.prototype.track=function(){return this.context.trackedObjects.add(this),this},Zt.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Zt.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Zt.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Field,!0,n,e,t)},function(e){return n.m__items=e})},Zt);function Zt(){return null!==Xt&&Xt.apply(this,arguments)||this}i.FieldCollection=$t;var Yt,en="Font",tn=(Yt=OfficeExtension.ClientObject,__extends(nn,Yt),Object.defineProperty(nn.prototype,"_className",{get:function(){return"Font"},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","name","size","bold","italic","color","underline","subscript","superscript","strikeThrough","doubleStrikeThrough","highlightColor","hidden"]},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Name","Size","Bold","Italic","Color","Underline","Subscript","Superscript","StrikeThrough","DoubleStrikeThrough","HighlightColor","Hidden"]},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"bold",{get:function(){return _("bold",this._B,en,this._isNull),this._B},set:function(e){this._B=e,g(this,"Bold",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"color",{get:function(){return _("color",this._C,en,this._isNull),this._C},set:function(e){this._C=e,g(this,"Color",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"doubleStrikeThrough",{get:function(){return _("doubleStrikeThrough",this._D,en,this._isNull),this._D},set:function(e){this._D=e,g(this,"DoubleStrikeThrough",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"hidden",{get:function(){return _("hidden",this._H,en,this._isNull),b("Font.hidden","WordApiDesktop","1.2",l),this._H},set:function(e){this._H=e,g(this,"Hidden",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"highlightColor",{get:function(){return _("highlightColor",this._Hi,en,this._isNull),this._Hi},set:function(e){this._Hi=e,g(this,"HighlightColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"italic",{get:function(){return _("italic",this._I,en,this._isNull),this._I},set:function(e){this._I=e,g(this,"Italic",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"name",{get:function(){return _("name",this._N,en,this._isNull),this._N},set:function(e){this._N=e,g(this,"Name",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"size",{get:function(){return _("size",this._S,en,this._isNull),this._S},set:function(e){this._S=e,g(this,"Size",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"strikeThrough",{get:function(){return _("strikeThrough",this._St,en,this._isNull),this._St},set:function(e){this._St=e,g(this,"StrikeThrough",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"subscript",{get:function(){return _("subscript",this._Su,en,this._isNull),this._Su},set:function(e){this._Su=e,g(this,"Subscript",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"superscript",{get:function(){return _("superscript",this._Sup,en,this._isNull),this._Sup},set:function(e){this._Sup=e,g(this,"Superscript",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"underline",{get:function(){return _("underline",this._U,en,this._isNull),this._U},set:function(e){this._U=e,g(this,"Underline",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(nn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,en,this._isNull),this.__R},enumerable:!0,configurable:!0}),nn.prototype.set=function(e,t){this._recursivelySet(e,t,["name","size","bold","italic","color","underline","subscript","superscript","strikeThrough","doubleStrikeThrough","highlightColor","hidden"],[],[])},nn.prototype.update=function(e){this._recursivelyUpdate(e)},nn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},nn.prototype._handleResult=function(e){if(Yt.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Bold)||(this._B=t.Bold),y(t.Color)||(this._C=t.Color),y(t.DoubleStrikeThrough)||(this._D=t.DoubleStrikeThrough),y(t.Hidden)||(this._H=t.Hidden),y(t.HighlightColor)||(this._Hi=t.HighlightColor),y(t.Italic)||(this._I=t.Italic),y(t.Name)||(this._N=t.Name),y(t.Size)||(this._S=t.Size),y(t.StrikeThrough)||(this._St=t.StrikeThrough),y(t.Subscript)||(this._Su=t.Subscript),y(t.Superscript)||(this._Sup=t.Superscript),y(t.Underline)||(this._U=t.Underline),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},nn.prototype.load=function(e){return v(this,e)},nn.prototype.retrieve=function(e){return O(this,e)},nn.prototype._handleIdResult=function(e){Yt.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},nn.prototype._handleRetrieveResult=function(e,t){Yt.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},nn.prototype.track=function(){return this.context.trackedObjects.add(this),this},nn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},nn.prototype.toJSON=function(){return C(this,{bold:this._B,color:this._C,doubleStrikeThrough:this._D,hidden:this._H,highlightColor:this._Hi,italic:this._I,name:this._N,size:this._S,strikeThrough:this._St,subscript:this._Su,superscript:this._Sup,underline:this._U},{})},nn.prototype.setMockData=function(e){R(this,e)},nn.prototype.ensureUnchanged=function(e){h(this,e)},nn);function nn(){return null!==Yt&&Yt.apply(this,arguments)||this}i.Font=tn;var rn,on="InlinePicture",an=(rn=OfficeExtension.ClientObject,__extends(sn,rn),Object.defineProperty(sn.prototype,"_className",{get:function(){return"InlinePicture"},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","altTextDescription","altTextTitle","height","hyperlink","lockAspectRatio","width","imageFormat"]},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","AltTextDescription","AltTextTitle","Height","Hyperlink","LockAspectRatio","Width","ImageFormat"]},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!0,!0,!0,!0,!0,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"_navigationPropertyNames",{get:function(){return["parentContentControl","paragraph","parentTableCell","parentTable","parentContentControlOrNullObject","parentTableCellOrNullObject","parentTableOrNullObject"]},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"paragraph",{get:function(){return b("InlinePicture.paragraph",u,"1.2",l),this._P||(this._P=t(i.Paragraph,this,"Paragraph",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"parentContentControl",{get:function(){return this._Pa||(this._Pa=t(i.ContentControl,this,"ParentContentControl",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"parentContentControlOrNullObject",{get:function(){return b("InlinePicture.parentContentControlOrNullObject",u,"1.3",l),this._Par||(this._Par=t(i.ContentControl,this,"ParentContentControlOrNullObject",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"parentTable",{get:function(){return b("InlinePicture.parentTable",u,"1.3",l),this._Pare||(this._Pare=t(i.Table,this,"ParentTable",!1,4)),this._Pare},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"parentTableCell",{get:function(){return b("InlinePicture.parentTableCell",u,"1.3",l),this._Paren||(this._Paren=t(i.TableCell,this,"ParentTableCell",!1,4)),this._Paren},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"parentTableCellOrNullObject",{get:function(){return b("InlinePicture.parentTableCellOrNullObject",u,"1.3",l),this._Parent||(this._Parent=t(i.TableCell,this,"ParentTableCellOrNullObject",!1,4)),this._Parent},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"parentTableOrNullObject",{get:function(){return b("InlinePicture.parentTableOrNullObject",u,"1.3",l),this._ParentT||(this._ParentT=t(i.Table,this,"ParentTableOrNullObject",!1,4)),this._ParentT},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"altTextDescription",{get:function(){return _("altTextDescription",this._A,on,this._isNull),this._A},set:function(e){this._A=e,g(this,"AltTextDescription",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"altTextTitle",{get:function(){return _("altTextTitle",this._Al,on,this._isNull),this._Al},set:function(e){this._Al=e,g(this,"AltTextTitle",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"height",{get:function(){return _("height",this._H,on,this._isNull),this._H},set:function(e){this._H=e,g(this,"Height",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"hyperlink",{get:function(){return _("hyperlink",this._Hy,on,this._isNull),this._Hy},set:function(e){this._Hy=e,g(this,"Hyperlink",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"imageFormat",{get:function(){return _("imageFormat",this._I,on,this._isNull),b("InlinePicture.imageFormat","WordApiDesktop","1.1",l),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"lockAspectRatio",{get:function(){return _("lockAspectRatio",this._L,on,this._isNull),this._L},set:function(e){this._L=e,g(this,"LockAspectRatio",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"width",{get:function(){return _("width",this._W,on,this._isNull),this._W},set:function(e){this._W=e,g(this,"Width",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"_Id",{get:function(){return _("_Id",this.__I,on,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(sn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,on,this._isNull),this.__R},enumerable:!0,configurable:!0}),sn.prototype.set=function(e,t){this._recursivelySet(e,t,["altTextDescription","altTextTitle","height","hyperlink","lockAspectRatio","width"],[],["paragraph","parentContentControl","parentContentControlOrNullObject","parentTable","parentTableCell","parentTableCellOrNullObject","parentTableOrNullObject"])},sn.prototype.update=function(e){this._recursivelyUpdate(e)},sn.prototype.delete=function(){b("InlinePicture.delete",u,"1.2",l),d(this,"Delete",0,[],0,0)},sn.prototype.getBase64ImageSrc=function(){return d(this,"GetBase64ImageSrc",1,[],4,0)},sn.prototype.getNext=function(){return b("InlinePicture.getNext",u,"1.3",l),p(i.InlinePicture,this,"GetNext",1,[],!1,!1,null,4)},sn.prototype.getNextOrNullObject=function(){return b("InlinePicture.getNextOrNullObject",u,"1.3",l),p(i.InlinePicture,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},sn.prototype.getRange=function(e){return b("InlinePicture.getRange",u,"1.3",l),p(i.Range,this,"GetRange",1,[e],!1,!1,null,4)},sn.prototype.insertBreak=function(e,t){b("InlinePicture.insertBreak",u,"1.2",l),d(this,"InsertBreak",0,[e,t],0,0)},sn.prototype.insertContentControl=function(){return p(i.ContentControl,this,"InsertContentControl",0,[],!1,!0,null,0)},sn.prototype.insertFileFromBase64=function(e,t){return b("InlinePicture.insertFileFromBase64",u,"1.2",l),p(i.Range,this,"InsertFileFromBase64",0,[e,t],!1,!0,null,0)},sn.prototype.insertHtml=function(e,t){return b("InlinePicture.insertHtml",u,"1.2",l),p(i.Range,this,"InsertHtml",0,[e,t],!1,!0,null,0)},sn.prototype.insertInlinePictureFromBase64=function(e,t){return b("InlinePicture.insertInlinePictureFromBase64",u,"1.2",l),p(i.InlinePicture,this,"InsertInlinePictureFromBase64",0,[e,t],!1,!0,null,0)},sn.prototype.insertOoxml=function(e,t){return b("InlinePicture.insertOoxml",u,"1.2",l),p(i.Range,this,"InsertOoxml",0,[e,t],!1,!0,null,0)},sn.prototype.insertParagraph=function(e,t){return b("InlinePicture.insertParagraph",u,"1.2",l),p(i.Paragraph,this,"InsertParagraph",0,[e,t],!1,!0,null,0)},sn.prototype.insertText=function(e,t){return b("InlinePicture.insertText",u,"1.2",l),p(i.Range,this,"InsertText",0,[e,t],!1,!0,null,0)},sn.prototype.select=function(e){b("InlinePicture.select",u,"1.2",l),d(this,"Select",1,[e],4,0)},sn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},sn.prototype._handleResult=function(e){if(rn.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.AltTextDescription)||(this._A=t.AltTextDescription),y(t.AltTextTitle)||(this._Al=t.AltTextTitle),y(t.Height)||(this._H=t.Height),y(t.Hyperlink)||(this._Hy=t.Hyperlink),y(t.ImageFormat)||(this._I=t.ImageFormat),y(t.LockAspectRatio)||(this._L=t.LockAspectRatio),y(t.Width)||(this._W=t.Width),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["paragraph","Paragraph","parentContentControl","ParentContentControl","parentContentControlOrNullObject","ParentContentControlOrNullObject","parentTable","ParentTable","parentTableCell","ParentTableCell","parentTableCellOrNullObject","ParentTableCellOrNullObject","parentTableOrNullObject","ParentTableOrNullObject"])}},sn.prototype.load=function(e){return v(this,e)},sn.prototype.retrieve=function(e){return O(this,e)},sn.prototype._handleIdResult=function(e){rn.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},sn.prototype._handleRetrieveResult=function(e,t){rn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},sn.prototype.track=function(){return this.context.trackedObjects.add(this),this},sn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},sn.prototype.toJSON=function(){return C(this,{altTextDescription:this._A,altTextTitle:this._Al,height:this._H,hyperlink:this._Hy,imageFormat:this._I,lockAspectRatio:this._L,width:this._W},{})},sn.prototype.setMockData=function(e){R(this,e)},sn.prototype.ensureUnchanged=function(e){h(this,e)},sn);function sn(){return null!==rn&&rn.apply(this,arguments)||this}i.InlinePicture=an;var cn,ln="InlinePictureCollection",un=(cn=OfficeExtension.ClientObject,__extends(pn,cn),Object.defineProperty(pn.prototype,"_className",{get:function(){return"InlinePictureCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(pn.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(pn.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(pn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(pn.prototype,"items",{get:function(){return _("items",this.m__items,ln,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(pn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ln,this._isNull),this.__R},enumerable:!0,configurable:!0}),pn.prototype.getFirst=function(){return b("InlinePictureCollection.getFirst",u,"1.3",l),p(i.InlinePicture,this,"GetFirst",1,[],!1,!1,null,4)},pn.prototype.getFirstOrNullObject=function(){return b("InlinePictureCollection.getFirstOrNullObject",u,"1.3",l),p(i.InlinePicture,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},pn.prototype._GetItem=function(e){return r(i.InlinePicture,this,[e])},pn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},pn.prototype._handleResult=function(e){if(cn.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.InlinePicture,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},pn.prototype.load=function(e){return v(this,e)},pn.prototype.retrieve=function(e){return O(this,e)},pn.prototype._handleIdResult=function(e){cn.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},pn.prototype._handleRetrieveResult=function(e,t){var n=this;cn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.InlinePicture,!0,n,e,t)})},pn.prototype.track=function(){return this.context.trackedObjects.add(this),this},pn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},pn.prototype.toJSON=function(){return C(this,{},{},this.m__items)},pn.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.InlinePicture,!0,n,e,t)},function(e){return n.m__items=e})},pn);function pn(){return null!==cn&&cn.apply(this,arguments)||this}i.InlinePictureCollection=un;var fn,dn="List",hn=(fn=OfficeExtension.ClientObject,__extends(gn,fn),Object.defineProperty(gn.prototype,"_className",{get:function(){return"List"},enumerable:!0,configurable:!0}),Object.defineProperty(gn.prototype,"_scalarPropertyNames",{get:function(){return["id","_ReferenceId","levelTypes","levelExistences"]},enumerable:!0,configurable:!0}),Object.defineProperty(gn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["Id","_ReferenceId","LevelTypes","LevelExistences"]},enumerable:!0,configurable:!0}),Object.defineProperty(gn.prototype,"_navigationPropertyNames",{get:function(){return["paragraphs"]},enumerable:!0,configurable:!0}),Object.defineProperty(gn.prototype,"paragraphs",{get:function(){return this._P||(this._P=t(i.ParagraphCollection,this,"Paragraphs",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(gn.prototype,"id",{get:function(){return _("id",this._I,dn,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(gn.prototype,"levelExistences",{get:function(){return _("levelExistences",this._L,dn,this._isNull),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(gn.prototype,"levelTypes",{get:function(){return _("levelTypes",this._Le,dn,this._isNull),this._Le},enumerable:!0,configurable:!0}),Object.defineProperty(gn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,dn,this._isNull),this.__R},enumerable:!0,configurable:!0}),gn.prototype.getLevelFont=function(e){return b("List.getLevelFont","WordApiDesktop","1.1",l),p(i.Font,this,"GetLevelFont",1,[e],!1,!1,null,4)},gn.prototype.getLevelParagraphs=function(e){return p(i.ParagraphCollection,this,"GetLevelParagraphs",1,[e],!0,!1,null,4)},gn.prototype.getLevelPicture=function(e){return b("List.getLevelPicture","WordApiDesktop","1.1",l),d(this,"GetLevelPicture",1,[e],4,0)},gn.prototype.getLevelString=function(e){return d(this,"GetLevelString",1,[e],4,0)},gn.prototype.insertParagraph=function(e,t){return p(i.Paragraph,this,"InsertParagraph",0,[e,t],!1,!0,null,0)},gn.prototype.resetLevelFont=function(e,t){b("List.resetLevelFont","WordApiDesktop","1.1",l),d(this,"ResetLevelFont",0,[e,t],0,0)},gn.prototype.setLevelAlignment=function(e,t){d(this,"SetLevelAlignment",0,[e,t],0,0)},gn.prototype.setLevelBullet=function(e,t,n,r){d(this,"SetLevelBullet",0,[e,t,n,r],0,0)},gn.prototype.setLevelIndents=function(e,t,n){d(this,"SetLevelIndents",0,[e,t,n],0,0)},gn.prototype.setLevelNumbering=function(e,t,n){d(this,"SetLevelNumbering",0,[e,t,n],0,0)},gn.prototype.setLevelPicture=function(e,t){b("List.setLevelPicture","WordApiDesktop","1.1",l),d(this,"SetLevelPicture",0,[e,t],0,0)},gn.prototype.setLevelStartingNumber=function(e,t){d(this,"SetLevelStartingNumber",0,[e,t],0,0)},gn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},gn.prototype._handleResult=function(e){if(fn.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Id)||(this._I=t.Id),y(t.LevelExistences)||(this._L=t.LevelExistences),y(t.LevelTypes)||(this._Le=t.LevelTypes),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["paragraphs","Paragraphs"])}},gn.prototype.load=function(e){return v(this,e)},gn.prototype.retrieve=function(e){return O(this,e)},gn.prototype._handleIdResult=function(e){fn.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},gn.prototype._handleRetrieveResult=function(e,t){fn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},gn.prototype.track=function(){return this.context.trackedObjects.add(this),this},gn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},gn.prototype.toJSON=function(){return C(this,{id:this._I,levelExistences:this._L,levelTypes:this._Le},{paragraphs:this._P})},gn.prototype.setMockData=function(e){R(this,e)},gn.prototype.ensureUnchanged=function(e){h(this,e)},gn);function gn(){return null!==fn&&fn.apply(this,arguments)||this}i.List=hn;var mn,yn="ListCollection",_n=(mn=OfficeExtension.ClientObject,__extends(bn,mn),Object.defineProperty(bn.prototype,"_className",{get:function(){return"ListCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(bn.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(bn.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(bn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(bn.prototype,"items",{get:function(){return _("items",this.m__items,yn,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(bn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,yn,this._isNull),this.__R},enumerable:!0,configurable:!0}),bn.prototype.getById=function(e){return p(i.List,this,"GetById",1,[e],!1,!1,null,4)},bn.prototype.getByIdOrNullObject=function(e){return p(i.List,this,"GetByIdOrNullObject",1,[e],!1,!1,null,4)},bn.prototype.getFirst=function(){return p(i.List,this,"GetFirst",1,[],!1,!1,null,4)},bn.prototype.getFirstOrNullObject=function(){return p(i.List,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},bn.prototype.getItem=function(e){return r(i.List,this,[e])},bn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},bn.prototype._handleResult=function(e){if(mn.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.List,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},bn.prototype.load=function(e){return v(this,e)},bn.prototype.retrieve=function(e){return O(this,e)},bn.prototype._handleIdResult=function(e){mn.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},bn.prototype._handleRetrieveResult=function(e,t){var n=this;mn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.List,!0,n,e,t)})},bn.prototype.track=function(){return this.context.trackedObjects.add(this),this},bn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},bn.prototype.toJSON=function(){return C(this,{},{},this.m__items)},bn.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.List,!0,n,e,t)},function(e){return n.m__items=e})},bn);function bn(){return null!==mn&&mn.apply(this,arguments)||this}i.ListCollection=_n;var vn,On="ListItem",Cn=(vn=OfficeExtension.ClientObject,__extends(Pn,vn),Object.defineProperty(Pn.prototype,"_className",{get:function(){return"ListItem"},enumerable:!0,configurable:!0}),Object.defineProperty(Pn.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","siblingIndex","listString","level"]},enumerable:!0,configurable:!0}),Object.defineProperty(Pn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","SiblingIndex","ListString","Level"]},enumerable:!0,configurable:!0}),Object.defineProperty(Pn.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Pn.prototype,"level",{get:function(){return _("level",this._L,On,this._isNull),this._L},set:function(e){this._L=e,g(this,"Level",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Pn.prototype,"listString",{get:function(){return _("listString",this._Li,On,this._isNull),this._Li},enumerable:!0,configurable:!0}),Object.defineProperty(Pn.prototype,"siblingIndex",{get:function(){return _("siblingIndex",this._S,On,this._isNull),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(Pn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,On,this._isNull),this.__R},enumerable:!0,configurable:!0}),Pn.prototype.set=function(e,t){this._recursivelySet(e,t,["level"],[],[])},Pn.prototype.update=function(e){this._recursivelyUpdate(e)},Pn.prototype.getAncestor=function(e){return p(i.Paragraph,this,"GetAncestor",1,[e],!1,!1,null,4)},Pn.prototype.getAncestorOrNullObject=function(e){return p(i.Paragraph,this,"GetAncestorOrNullObject",1,[e],!1,!1,null,4)},Pn.prototype.getDescendants=function(e){return p(i.ParagraphCollection,this,"GetDescendants",1,[e],!0,!1,null,4)},Pn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Pn.prototype._handleResult=function(e){if(vn.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Level)||(this._L=t.Level),y(t.ListString)||(this._Li=t.ListString),y(t.SiblingIndex)||(this._S=t.SiblingIndex),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Pn.prototype.load=function(e){return v(this,e)},Pn.prototype.retrieve=function(e){return O(this,e)},Pn.prototype._handleIdResult=function(e){vn.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Pn.prototype._handleRetrieveResult=function(e,t){vn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Pn.prototype.track=function(){return this.context.trackedObjects.add(this),this},Pn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Pn.prototype.toJSON=function(){return C(this,{level:this._L,listString:this._Li,siblingIndex:this._S},{})},Pn.prototype.setMockData=function(e){R(this,e)},Pn.prototype.ensureUnchanged=function(e){h(this,e)},Pn);function Pn(){return null!==vn&&vn.apply(this,arguments)||this}i.ListItem=Cn;var Sn,An="ListLevel",In=(Sn=OfficeExtension.ClientObject,__extends(Rn,Sn),Object.defineProperty(Rn.prototype,"_className",{get:function(){return"ListLevel"},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","alignment","linkedStyle","numberFormat","numberPosition","numberStyle","resetOnHigher","startAt","tabPosition","textPosition","trailingCharacter"]},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","Alignment","LinkedStyle","NumberFormat","NumberPosition","NumberStyle","ResetOnHigher","StartAt","TabPosition","TextPosition","TrailingCharacter"]},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"_navigationPropertyNames",{get:function(){return["font"]},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"font",{get:function(){return this._F||(this._F=t(i.Font,this,"Font",!1,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"alignment",{get:function(){return _("alignment",this._A,An,this._isNull),this._A},set:function(e){this._A=e,g(this,"Alignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"linkedStyle",{get:function(){return _("linkedStyle",this._L,An,this._isNull),this._L},set:function(e){this._L=e,g(this,"LinkedStyle",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"numberFormat",{get:function(){return _("numberFormat",this._N,An,this._isNull),this._N},set:function(e){this._N=e,g(this,"NumberFormat",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"numberPosition",{get:function(){return _("numberPosition",this._Nu,An,this._isNull),this._Nu},set:function(e){this._Nu=e,g(this,"NumberPosition",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"numberStyle",{get:function(){return _("numberStyle",this._Num,An,this._isNull),this._Num},set:function(e){this._Num=e,g(this,"NumberStyle",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"resetOnHigher",{get:function(){return _("resetOnHigher",this._R,An,this._isNull),this._R},set:function(e){this._R=e,g(this,"ResetOnHigher",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"startAt",{get:function(){return _("startAt",this._S,An,this._isNull),this._S},set:function(e){this._S=e,g(this,"StartAt",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"tabPosition",{get:function(){return _("tabPosition",this._T,An,this._isNull),this._T},set:function(e){this._T=e,g(this,"TabPosition",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"textPosition",{get:function(){return _("textPosition",this._Te,An,this._isNull),this._Te},set:function(e){this._Te=e,g(this,"TextPosition",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"trailingCharacter",{get:function(){return _("trailingCharacter",this._Tr,An,this._isNull),this._Tr},set:function(e){this._Tr=e,g(this,"TrailingCharacter",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"_Id",{get:function(){return _("_Id",this.__I,An,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Rn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,An,this._isNull),this.__R},enumerable:!0,configurable:!0}),Rn.prototype.set=function(e,t){this._recursivelySet(e,t,["alignment","linkedStyle","numberFormat","numberPosition","numberStyle","resetOnHigher","startAt","tabPosition","textPosition","trailingCharacter"],["font"],[])},Rn.prototype.update=function(e){this._recursivelyUpdate(e)},Rn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Rn.prototype._handleResult=function(e){if(Sn.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Alignment)||(this._A=t.Alignment),y(t.LinkedStyle)||(this._L=t.LinkedStyle),y(t.NumberFormat)||(this._N=t.NumberFormat),y(t.NumberPosition)||(this._Nu=t.NumberPosition),y(t.NumberStyle)||(this._Num=t.NumberStyle),y(t.ResetOnHigher)||(this._R=t.ResetOnHigher),y(t.StartAt)||(this._S=t.StartAt),y(t.TabPosition)||(this._T=t.TabPosition),y(t.TextPosition)||(this._Te=t.TextPosition),y(t.TrailingCharacter)||(this._Tr=t.TrailingCharacter),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["font","Font"])}},Rn.prototype.load=function(e){return v(this,e)},Rn.prototype.retrieve=function(e){return O(this,e)},Rn.prototype._handleIdResult=function(e){Sn.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Rn.prototype._handleRetrieveResult=function(e,t){Sn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Rn.prototype.track=function(){return this.context.trackedObjects.add(this),this},Rn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Rn.prototype.toJSON=function(){return C(this,{alignment:this._A,linkedStyle:this._L,numberFormat:this._N,numberPosition:this._Nu,numberStyle:this._Num,resetOnHigher:this._R,startAt:this._S,tabPosition:this._T,textPosition:this._Te,trailingCharacter:this._Tr},{font:this._F})},Rn.prototype.setMockData=function(e){R(this,e)},Rn.prototype.ensureUnchanged=function(e){h(this,e)},Rn);function Rn(){return null!==Sn&&Sn.apply(this,arguments)||this}i.ListLevel=In;var Tn,En="ListLevelCollection",Nn=(Tn=OfficeExtension.ClientObject,__extends(Dn,Tn),Object.defineProperty(Dn.prototype,"_className",{get:function(){return"ListLevelCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Dn.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Dn.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Dn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Dn.prototype,"items",{get:function(){return _("items",this.m__items,En,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Dn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,En,this._isNull),this.__R},enumerable:!0,configurable:!0}),Dn.prototype.getFirst=function(){return p(i.ListLevel,this,"GetFirst",1,[],!1,!1,null,4)},Dn.prototype.getFirstOrNullObject=function(){return p(i.ListLevel,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Dn.prototype._GetItem=function(e){return r(i.ListLevel,this,[e])},Dn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Dn.prototype._handleResult=function(e){if(Tn.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.ListLevel,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Dn.prototype.load=function(e){return v(this,e)},Dn.prototype.retrieve=function(e){return O(this,e)},Dn.prototype._handleIdResult=function(e){Tn.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Dn.prototype._handleRetrieveResult=function(e,t){var n=this;Tn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.ListLevel,!0,n,e,t)})},Dn.prototype.track=function(){return this.context.trackedObjects.add(this),this},Dn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Dn.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Dn.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.ListLevel,!0,n,e,t)},function(e){return n.m__items=e})},Dn);function Dn(){return null!==Tn&&Tn.apply(this,arguments)||this}i.ListLevelCollection=Nn;var xn,wn="ListTemplate",Fn=(xn=OfficeExtension.ClientObject,__extends(jn,xn),Object.defineProperty(jn.prototype,"_className",{get:function(){return"ListTemplate"},enumerable:!0,configurable:!0}),Object.defineProperty(jn.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","outlineNumbered"]},enumerable:!0,configurable:!0}),Object.defineProperty(jn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","OutlineNumbered"]},enumerable:!0,configurable:!0}),Object.defineProperty(jn.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(jn.prototype,"_navigationPropertyNames",{get:function(){return["listLevels"]},enumerable:!0,configurable:!0}),Object.defineProperty(jn.prototype,"listLevels",{get:function(){return this._L||(this._L=t(i.ListLevelCollection,this,"ListLevels",!0,4)),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(jn.prototype,"outlineNumbered",{get:function(){return _("outlineNumbered",this._O,wn,this._isNull),this._O},set:function(e){this._O=e,g(this,"OutlineNumbered",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(jn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,wn,this._isNull),this.__R},enumerable:!0,configurable:!0}),jn.prototype.set=function(e,t){this._recursivelySet(e,t,["outlineNumbered"],[],["listLevels"])},jn.prototype.update=function(e){this._recursivelyUpdate(e)},jn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},jn.prototype._handleResult=function(e){if(xn.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.OutlineNumbered)||(this._O=t.OutlineNumbered),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["listLevels","ListLevels"])}},jn.prototype.load=function(e){return v(this,e)},jn.prototype.retrieve=function(e){return O(this,e)},jn.prototype._handleIdResult=function(e){xn.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},jn.prototype._handleRetrieveResult=function(e,t){xn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},jn.prototype.track=function(){return this.context.trackedObjects.add(this),this},jn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},jn.prototype.toJSON=function(){return C(this,{outlineNumbered:this._O},{listLevels:this._L})},jn.prototype.setMockData=function(e){R(this,e)},jn.prototype.ensureUnchanged=function(e){h(this,e)},jn);function jn(){return null!==xn&&xn.apply(this,arguments)||this}i.ListTemplate=Fn;var kn,Mn="NoteItem",Hn=(kn=OfficeExtension.ClientObject,__extends(Ln,kn),Object.defineProperty(Ln.prototype,"_className",{get:function(){return"NoteItem"},enumerable:!0,configurable:!0}),Object.defineProperty(Ln.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","type"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ln.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","Type"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ln.prototype,"_navigationPropertyNames",{get:function(){return["body","reference"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ln.prototype,"body",{get:function(){return this._B||(this._B=t(i.Body,this,"Body",!1,4)),this._B},enumerable:!0,configurable:!0}),Object.defineProperty(Ln.prototype,"reference",{get:function(){return this._R||(this._R=t(i.Range,this,"Reference",!1,4)),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(Ln.prototype,"type",{get:function(){return _("type",this._T,Mn,this._isNull),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(Ln.prototype,"_Id",{get:function(){return _("_Id",this.__I,Mn,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Ln.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Mn,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ln.prototype.set=function(e,t){this._recursivelySet(e,t,[],["body","reference"],[])},Ln.prototype.update=function(e){this._recursivelyUpdate(e)},Ln.prototype.delete=function(){d(this,"Delete",0,[],0,0)},Ln.prototype.getNext=function(){return p(i.NoteItem,this,"GetNext",1,[],!1,!1,null,4)},Ln.prototype.getNextOrNullObject=function(){return p(i.NoteItem,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},Ln.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ln.prototype._handleResult=function(e){if(kn.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Type)||(this._T=t.Type),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["body","Body","reference","Reference"])}},Ln.prototype.load=function(e){return v(this,e)},Ln.prototype.retrieve=function(e){return O(this,e)},Ln.prototype._handleIdResult=function(e){kn.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Ln.prototype._handleRetrieveResult=function(e,t){kn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Ln.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ln.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ln.prototype.toJSON=function(){return C(this,{type:this._T},{body:this._B,reference:this._R})},Ln.prototype.setMockData=function(e){R(this,e)},Ln.prototype.ensureUnchanged=function(e){h(this,e)},Ln);function Ln(){return null!==kn&&kn.apply(this,arguments)||this}i.NoteItem=Hn;var Un,Bn="NoteItemCollection",Wn=(Un=OfficeExtension.ClientObject,__extends(Gn,Un),Object.defineProperty(Gn.prototype,"_className",{get:function(){return"NoteItemCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Gn.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Gn.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Gn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Gn.prototype,"items",{get:function(){return _("items",this.m__items,Bn,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Gn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Bn,this._isNull),this.__R},enumerable:!0,configurable:!0}),Gn.prototype.getFirst=function(){return p(i.NoteItem,this,"GetFirst",1,[],!1,!1,null,4)},Gn.prototype.getFirstOrNullObject=function(){return p(i.NoteItem,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Gn.prototype._GetItem=function(e){return r(i.NoteItem,this,[e])},Gn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Gn.prototype._handleResult=function(e){if(Un.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.NoteItem,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Gn.prototype.load=function(e){return v(this,e)},Gn.prototype.retrieve=function(e){return O(this,e)},Gn.prototype._handleIdResult=function(e){Un.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Gn.prototype._handleRetrieveResult=function(e,t){var n=this;Un.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.NoteItem,!0,n,e,t)})},Gn.prototype.track=function(){return this.context.trackedObjects.add(this),this},Gn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Gn.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Gn.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.NoteItem,!0,n,e,t)},function(e){return n.m__items=e})},Gn);function Gn(){return null!==Un&&Un.apply(this,arguments)||this}i.NoteItemCollection=Wn;var qn,Vn="Page",zn=(qn=OfficeExtension.ClientObject,__extends(Jn,qn),Object.defineProperty(Jn.prototype,"_className",{get:function(){return"Page"},enumerable:!0,configurable:!0}),Object.defineProperty(Jn.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","height","width","index"]},enumerable:!0,configurable:!0}),Object.defineProperty(Jn.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","Height","Width","Index"]},enumerable:!0,configurable:!0}),Object.defineProperty(Jn.prototype,"height",{get:function(){return _("height",this._H,Vn,this._isNull),this._H},enumerable:!0,configurable:!0}),Object.defineProperty(Jn.prototype,"index",{get:function(){return _("index",this._I,Vn,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(Jn.prototype,"width",{get:function(){return _("width",this._W,Vn,this._isNull),this._W},enumerable:!0,configurable:!0}),Object.defineProperty(Jn.prototype,"_Id",{get:function(){return _("_Id",this.__I,Vn,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Jn.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Vn,this._isNull),this.__R},enumerable:!0,configurable:!0}),Jn.prototype.getNext=function(){return p(i.Page,this,"GetNext",1,[],!1,!1,null,4)},Jn.prototype.getNextOrNullObject=function(){return p(i.Page,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},Jn.prototype.getRange=function(e){return p(i.Range,this,"GetRange",1,[e],!1,!1,null,4)},Jn.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Jn.prototype._handleResult=function(e){if(qn.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Height)||(this._H=t.Height),y(t.Index)||(this._I=t.Index),y(t.Width)||(this._W=t.Width),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Jn.prototype.load=function(e){return v(this,e)},Jn.prototype.retrieve=function(e){return O(this,e)},Jn.prototype._handleIdResult=function(e){qn.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Jn.prototype._handleRetrieveResult=function(e,t){qn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Jn.prototype.track=function(){return this.context.trackedObjects.add(this),this},Jn.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Jn.prototype.toJSON=function(){return C(this,{height:this._H,index:this._I,width:this._W},{})},Jn.prototype.setMockData=function(e){R(this,e)},Jn.prototype.ensureUnchanged=function(e){h(this,e)},Jn);function Jn(){return null!==qn&&qn.apply(this,arguments)||this}i.Page=zn;var Kn,Xn="PageCollection",Qn=(Kn=OfficeExtension.ClientObject,__extends($n,Kn),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"]},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 _("items",this.m__items,Xn,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty($n.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Xn,this._isNull),this.__R},enumerable:!0,configurable:!0}),$n.prototype.getFirst=function(){return p(i.Page,this,"GetFirst",1,[],!1,!1,null,4)},$n.prototype.getFirstOrNullObject=function(){return p(i.Page,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},$n.prototype._GetItem=function(e){return r(i.Page,this,[e])},$n.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},$n.prototype._handleResult=function(e){if(Kn.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Page,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},$n.prototype.load=function(e){return v(this,e)},$n.prototype.retrieve=function(e){return O(this,e)},$n.prototype._handleIdResult=function(e){Kn.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},$n.prototype._handleRetrieveResult=function(e,t){var n=this;Kn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Page,!0,n,e,t)})},$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 C(this,{},{},this.m__items)},$n.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Page,!0,n,e,t)},function(e){return n.m__items=e})},$n);function $n(){return null!==Kn&&Kn.apply(this,arguments)||this}i.PageCollection=Qn;var Zn,Yn=(Zn=OfficeExtension.ClientObject,__extends(er,Zn),Object.defineProperty(er.prototype,"_className",{get:function(){return"Pane"},enumerable:!0,configurable:!0}),Object.defineProperty(er.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(er.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(er.prototype,"_navigationPropertyNames",{get:function(){return["pages","pagesEnclosingViewport"]},enumerable:!0,configurable:!0}),Object.defineProperty(er.prototype,"pages",{get:function(){return this._P||(this._P=t(i.PageCollection,this,"Pages",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(er.prototype,"pagesEnclosingViewport",{get:function(){return this._Pa||(this._Pa=t(i.PageCollection,this,"PagesEnclosingViewport",!0,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(er.prototype,"_Id",{get:function(){return _("_Id",this.__I,"Pane",this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(er.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,"Pane",this._isNull),this.__R},enumerable:!0,configurable:!0}),er.prototype.getNext=function(){return p(i.Pane,this,"GetNext",1,[],!1,!1,null,4)},er.prototype.getNextOrNullObject=function(){return p(i.Pane,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},er.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},er.prototype._handleResult=function(e){if(Zn.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["pages","Pages","pagesEnclosingViewport","PagesEnclosingViewport"])}},er.prototype.load=function(e){return v(this,e)},er.prototype.retrieve=function(e){return O(this,e)},er.prototype._handleIdResult=function(e){Zn.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},er.prototype._handleRetrieveResult=function(e,t){Zn.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},er.prototype.track=function(){return this.context.trackedObjects.add(this),this},er.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},er.prototype.toJSON=function(){return C(this,{},{pages:this._P,pagesEnclosingViewport:this._Pa})},er);function er(){return null!==Zn&&Zn.apply(this,arguments)||this}i.Pane=Yn;var tr,nr="PaneCollection",rr=(tr=OfficeExtension.ClientObject,__extends(or,tr),Object.defineProperty(or.prototype,"_className",{get:function(){return"PaneCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(or.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(or.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(or.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(or.prototype,"items",{get:function(){return _("items",this.m__items,nr,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(or.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,nr,this._isNull),this.__R},enumerable:!0,configurable:!0}),or.prototype.getFirst=function(){return p(i.Pane,this,"GetFirst",1,[],!1,!1,null,4)},or.prototype.getFirstOrNullObject=function(){return p(i.Pane,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},or.prototype._GetItem=function(e){return r(i.Pane,this,[e])},or.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},or.prototype._handleResult=function(e){if(tr.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Pane,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},or.prototype.load=function(e){return v(this,e)},or.prototype.retrieve=function(e){return O(this,e)},or.prototype._handleIdResult=function(e){tr.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},or.prototype._handleRetrieveResult=function(e,t){var n=this;tr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Pane,!0,n,e,t)})},or.prototype.track=function(){return this.context.trackedObjects.add(this),this},or.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},or.prototype.toJSON=function(){return C(this,{},{},this.m__items)},or);function or(){return null!==tr&&tr.apply(this,arguments)||this}i.PaneCollection=rr;var ir,ar=(ir=OfficeExtension.ClientObject,__extends(sr,ir),Object.defineProperty(sr.prototype,"_className",{get:function(){return"Window"},enumerable:!0,configurable:!0}),Object.defineProperty(sr.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(sr.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(sr.prototype,"_navigationPropertyNames",{get:function(){return["panes","activePane"]},enumerable:!0,configurable:!0}),Object.defineProperty(sr.prototype,"activePane",{get:function(){return this._A||(this._A=t(i.Pane,this,"ActivePane",!1,4)),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(sr.prototype,"panes",{get:function(){return this._P||(this._P=t(i.PaneCollection,this,"Panes",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(sr.prototype,"_Id",{get:function(){return _("_Id",this.__I,"Window",this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(sr.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,"Window",this._isNull),this.__R},enumerable:!0,configurable:!0}),sr.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},sr.prototype._handleResult=function(e){if(ir.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["activePane","ActivePane","panes","Panes"])}},sr.prototype.load=function(e){return v(this,e)},sr.prototype.retrieve=function(e){return O(this,e)},sr.prototype._handleIdResult=function(e){ir.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},sr.prototype._handleRetrieveResult=function(e,t){ir.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},sr.prototype.track=function(){return this.context.trackedObjects.add(this),this},sr.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},sr.prototype.toJSON=function(){return C(this,{},{})},sr);function sr(){return null!==ir&&ir.apply(this,arguments)||this}i.Window=ar;var cr,lr="WindowCollection",ur=(cr=OfficeExtension.ClientObject,__extends(pr,cr),Object.defineProperty(pr.prototype,"_className",{get:function(){return"WindowCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(pr.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(pr.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(pr.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(pr.prototype,"items",{get:function(){return _("items",this.m__items,lr,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(pr.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,lr,this._isNull),this.__R},enumerable:!0,configurable:!0}),pr.prototype.getFirst=function(){return p(i.Window,this,"GetFirst",1,[],!1,!1,null,4)},pr.prototype.getFirstOrNullObject=function(){return p(i.Window,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},pr.prototype._GetItem=function(e){return r(i.Window,this,[e])},pr.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},pr.prototype._handleResult=function(e){if(cr.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Window,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},pr.prototype.load=function(e){return v(this,e)},pr.prototype.retrieve=function(e){return O(this,e)},pr.prototype._handleIdResult=function(e){cr.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},pr.prototype._handleRetrieveResult=function(e,t){var n=this;cr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Window,!0,n,e,t)})},pr.prototype.track=function(){return this.context.trackedObjects.add(this),this},pr.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},pr.prototype.toJSON=function(){return C(this,{},{},this.m__items)},pr);function pr(){return null!==cr&&cr.apply(this,arguments)||this}i.WindowCollection=ur;var fr,dr="Paragraph",hr=(fr=OfficeExtension.ClientObject,__extends(gr,fr),Object.defineProperty(gr.prototype,"_className",{get:function(){return"Paragraph"},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","style","alignment","firstLineIndent","leftIndent","rightIndent","lineSpacing","outlineLevel","spaceBefore","spaceAfter","lineUnitBefore","lineUnitAfter","text","isListItem","tableNestingLevel","isLastParagraph","styleBuiltIn","uniqueLocalId"]},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","Style","Alignment","FirstLineIndent","LeftIndent","RightIndent","LineSpacing","OutlineLevel","SpaceBefore","SpaceAfter","LineUnitBefore","LineUnitAfter","Text","IsListItem","TableNestingLevel","IsLastParagraph","StyleBuiltIn","UniqueLocalId"]},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!1,!1,!1,!1,!0,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"_navigationPropertyNames",{get:function(){return["font","contentControls","parentContentControl","inlinePictures","parentBody","list","parentTableCell","parentTable","listItem","parentContentControlOrNullObject","parentTableCellOrNullObject","parentTableOrNullObject","listOrNullObject","listItemOrNullObject","footnotes","endnotes","fields","shapes"]},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"contentControls",{get:function(){return this._C||(this._C=t(i.ContentControlCollection,this,"ContentControls",!0,4)),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"endnotes",{get:function(){return b("Paragraph.endnotes",u,"1.5",l),this._E||(this._E=t(i.NoteItemCollection,this,"Endnotes",!0,4)),this._E},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"fields",{get:function(){return b("Paragraph.fields",u,"1.4",l),this._F||(this._F=t(i.FieldCollection,this,"Fields",!0,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"font",{get:function(){return this._Fo||(this._Fo=t(i.Font,this,"Font",!1,4)),this._Fo},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"footnotes",{get:function(){return b("Paragraph.footnotes",u,"1.5",l),this._Foo||(this._Foo=t(i.NoteItemCollection,this,"Footnotes",!0,4)),this._Foo},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"inlinePictures",{get:function(){return this._I||(this._I=t(i.InlinePictureCollection,this,"InlinePictures",!0,4)),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"list",{get:function(){return b("Paragraph.list",u,"1.3",l),this._Lis||(this._Lis=t(i.List,this,"List",!1,4)),this._Lis},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"listItem",{get:function(){return b("Paragraph.listItem",u,"1.3",l),this._List||(this._List=t(i.ListItem,this,"ListItem",!1,4)),this._List},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"listItemOrNullObject",{get:function(){return b("Paragraph.listItemOrNullObject",u,"1.3",l),this._ListI||(this._ListI=t(i.ListItem,this,"ListItemOrNullObject",!1,4)),this._ListI},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"listOrNullObject",{get:function(){return b("Paragraph.listOrNullObject",u,"1.3",l),this._ListO||(this._ListO=t(i.List,this,"ListOrNullObject",!1,4)),this._ListO},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"parentBody",{get:function(){return b("Paragraph.parentBody",u,"1.3",l),this._P||(this._P=t(i.Body,this,"ParentBody",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"parentContentControl",{get:function(){return this._Pa||(this._Pa=t(i.ContentControl,this,"ParentContentControl",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"parentContentControlOrNullObject",{get:function(){return b("Paragraph.parentContentControlOrNullObject",u,"1.3",l),this._Par||(this._Par=t(i.ContentControl,this,"ParentContentControlOrNullObject",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"parentTable",{get:function(){return b("Paragraph.parentTable",u,"1.3",l),this._Pare||(this._Pare=t(i.Table,this,"ParentTable",!1,4)),this._Pare},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"parentTableCell",{get:function(){return b("Paragraph.parentTableCell",u,"1.3",l),this._Paren||(this._Paren=t(i.TableCell,this,"ParentTableCell",!1,4)),this._Paren},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"parentTableCellOrNullObject",{get:function(){return b("Paragraph.parentTableCellOrNullObject",u,"1.3",l),this._Parent||(this._Parent=t(i.TableCell,this,"ParentTableCellOrNullObject",!1,4)),this._Parent},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"parentTableOrNullObject",{get:function(){return b("Paragraph.parentTableOrNullObject",u,"1.3",l),this._ParentT||(this._ParentT=t(i.Table,this,"ParentTableOrNullObject",!1,4)),this._ParentT},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"shapes",{get:function(){return b("Paragraph.shapes","WordApiDesktop","1.2",l),this._S||(this._S=t(i.ShapeCollection,this,"Shapes",!0,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"alignment",{get:function(){return _("alignment",this._A,dr,this._isNull),this._A},set:function(e){this._A=e,g(this,"Alignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"firstLineIndent",{get:function(){return _("firstLineIndent",this._Fi,dr,this._isNull),this._Fi},set:function(e){this._Fi=e,g(this,"FirstLineIndent",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"isLastParagraph",{get:function(){return _("isLastParagraph",this._Is,dr,this._isNull),b("Paragraph.isLastParagraph",u,"1.3",l),this._Is},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"isListItem",{get:function(){return _("isListItem",this._IsL,dr,this._isNull),b("Paragraph.isListItem",u,"1.3",l),this._IsL},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"leftIndent",{get:function(){return _("leftIndent",this._L,dr,this._isNull),this._L},set:function(e){this._L=e,g(this,"LeftIndent",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"lineSpacing",{get:function(){return _("lineSpacing",this._Li,dr,this._isNull),this._Li},set:function(e){this._Li=e,g(this,"LineSpacing",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"lineUnitAfter",{get:function(){return _("lineUnitAfter",this._Lin,dr,this._isNull),this._Lin},set:function(e){this._Lin=e,g(this,"LineUnitAfter",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"lineUnitBefore",{get:function(){return _("lineUnitBefore",this._Line,dr,this._isNull),this._Line},set:function(e){this._Line=e,g(this,"LineUnitBefore",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"outlineLevel",{get:function(){return _("outlineLevel",this._O,dr,this._isNull),this._O},set:function(e){this._O=e,g(this,"OutlineLevel",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"rightIndent",{get:function(){return _("rightIndent",this._R,dr,this._isNull),this._R},set:function(e){this._R=e,g(this,"RightIndent",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"spaceAfter",{get:function(){return _("spaceAfter",this._Sp,dr,this._isNull),this._Sp},set:function(e){this._Sp=e,g(this,"SpaceAfter",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"spaceBefore",{get:function(){return _("spaceBefore",this._Spa,dr,this._isNull),this._Spa},set:function(e){this._Spa=e,g(this,"SpaceBefore",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"style",{get:function(){return _("style",this._St,dr,this._isNull),this._St},set:function(e){this._St=e,g(this,"Style",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"styleBuiltIn",{get:function(){return _("styleBuiltIn",this._Sty,dr,this._isNull),b("Paragraph.styleBuiltIn",u,"1.3",l),this._Sty},set:function(e){this._Sty=e,g(this,"StyleBuiltIn",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"tableNestingLevel",{get:function(){return _("tableNestingLevel",this._T,dr,this._isNull),b("Paragraph.tableNestingLevel",u,"1.3",l),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"text",{get:function(){return _("text",this._Te,dr,this._isNull),this._Te},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"uniqueLocalId",{get:function(){return _("uniqueLocalId",this._U,dr,this._isNull),b("Paragraph.uniqueLocalId",u,"1.6",l),this._U},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"_Id",{get:function(){return _("_Id",this.__I,dr,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(gr.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,dr,this._isNull),this.__R},enumerable:!0,configurable:!0}),gr.prototype.set=function(e,t){this._recursivelySet(e,t,["style","alignment","firstLineIndent","leftIndent","rightIndent","lineSpacing","outlineLevel","spaceBefore","spaceAfter","lineUnitBefore","lineUnitAfter","styleBuiltIn"],["font","listItem","listItemOrNullObject"],["contentControls","endnotes","fields","footnotes","inlinePictures","list","listOrNullObject","parentBody","parentContentControl","parentContentControlOrNullObject","parentTable","parentTableCell","parentTableCellOrNullObject","parentTableOrNullObject","shapes"])},gr.prototype.update=function(e){this._recursivelyUpdate(e)},gr.prototype.attachToList=function(e,t){return b("Paragraph.attachToList",u,"1.3",l),p(i.List,this,"AttachToList",0,[e,t],!1,!1,null,0)},gr.prototype.clear=function(){d(this,"Clear",0,[],0,0)},gr.prototype.delete=function(){d(this,"Delete",0,[],0,0)},gr.prototype.detachFromList=function(){b("Paragraph.detachFromList",u,"1.3",l),d(this,"DetachFromList",0,[],0,0)},gr.prototype.getAnnotations=function(){return b("Paragraph.getAnnotations",u,"1.7",l),p(i.AnnotationCollection,this,"GetAnnotations",1,[],!0,!1,null,4)},gr.prototype.getComments=function(){return b("Paragraph.getComments",u,"1.4",l),p(i.CommentCollection,this,"GetComments",1,[],!0,!1,null,4)},gr.prototype.getContentControls=function(e){return b("Paragraph.getContentControls",u,"1.5",l),p(i.ContentControlCollection,this,"GetContentControls",1,[e],!0,!1,null,4)},gr.prototype.getHtml=function(){return d(this,"GetHtml",1,[],4,0)},gr.prototype.getMetadata=function(e){return d(this,"GetMetadata",1,[e],4,0)},gr.prototype.getNext=function(){return b("Paragraph.getNext",u,"1.3",l),p(i.Paragraph,this,"GetNext",1,[],!1,!1,null,4)},gr.prototype.getNextOrNullObject=function(){return b("Paragraph.getNextOrNullObject",u,"1.3",l),p(i.Paragraph,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},gr.prototype.getOoxml=function(){return d(this,"GetOoxml",1,[],4,0)},gr.prototype.getPrevious=function(){return b("Paragraph.getPrevious",u,"1.3",l),p(i.Paragraph,this,"GetPrevious",1,[],!1,!1,null,4)},gr.prototype.getPreviousOrNullObject=function(){return b("Paragraph.getPreviousOrNullObject",u,"1.3",l),p(i.Paragraph,this,"GetPreviousOrNullObject",1,[],!1,!1,null,4)},gr.prototype.getRange=function(e){return b("Paragraph.getRange",u,"1.3",l),p(i.Range,this,"GetRange",1,[e],!1,!1,null,4)},gr.prototype.getReviewedText=function(e){return b("Paragraph.getReviewedText",u,"1.4",l),d(this,"GetReviewedText",1,[e],4,0)},gr.prototype.getSubrange=function(e,t){return b("Paragraph.getSubrange",u,"1.3",l),p(i.Range,this,"GetSubrange",1,[e,t],!1,!1,null,4)},gr.prototype.getText=function(e){return b("Paragraph.getText",u,"1.7",l),d(this,"GetText",1,[e],4,0)},gr.prototype.getTextRanges=function(e,t){return b("Paragraph.getTextRanges",u,"1.3",l),p(i.RangeCollection,this,"GetTextRanges",1,[e,t],!0,!1,null,4)},gr.prototype.getTrackedChanges=function(){return b("Paragraph.getTrackedChanges",u,"1.6",l),p(i.TrackedChangeCollection,this,"GetTrackedChanges",1,[],!0,!1,null,4)},gr.prototype.insertAnnotations=function(e){return b("Paragraph.insertAnnotations",u,"1.7",l),d(this,"InsertAnnotations",0,[e],0,0)},gr.prototype.insertBreak=function(e,t){d(this,"InsertBreak",0,[e,t],0,0)},gr.prototype.insertCanvas=function(e){return b("Paragraph.insertCanvas","WordApiDesktop","1.2",l),p(i.Shape,this,"InsertCanvas",0,[e],!1,!1,null,0)},gr.prototype.insertContentControl=function(e){return p(i.ContentControl,this,"InsertContentControl",0,[e],!1,!0,null,0)},gr.prototype.insertFileFromBase64=function(e,t){return p(i.Range,this,"InsertFileFromBase64",0,[e,t],!1,!0,null,0)},gr.prototype.insertGeometricShape=function(e,t){return b("Paragraph.insertGeometricShape","WordApiDesktop","1.2",l),p(i.Shape,this,"InsertGeometricShape",0,[e,t],!1,!1,null,0)},gr.prototype.insertHtml=function(e,t){return p(i.Range,this,"InsertHtml",0,[e,t],!1,!0,null,0)},gr.prototype.insertInlinePictureFromBase64=function(e,t){return p(i.InlinePicture,this,"InsertInlinePictureFromBase64",0,[e,t],!1,!0,null,0)},gr.prototype.insertOoxml=function(e,t){return p(i.Range,this,"InsertOoxml",0,[e,t],!1,!0,null,0)},gr.prototype.insertParagraph=function(e,t){return p(i.Paragraph,this,"InsertParagraph",0,[e,t],!1,!0,null,0)},gr.prototype.insertPictureFromBase64=function(e,t){return b("Paragraph.insertPictureFromBase64","WordApiDesktop","1.2",l),p(i.Shape,this,"InsertPictureFromBase64",0,[e,t],!1,!1,null,0)},gr.prototype.insertTable=function(e,t,n,r){return b("Paragraph.insertTable",u,"1.3",l),p(i.Table,this,"InsertTable",0,[e,t,n,r],!1,!0,null,0)},gr.prototype.insertText=function(e,t){return p(i.Range,this,"InsertText",0,[e,t],!1,!0,null,0)},gr.prototype.insertTextBox=function(e,t){return b("Paragraph.insertTextBox","WordApiDesktop","1.2",l),p(i.Shape,this,"InsertTextBox",0,[e,t],!1,!1,null,0)},gr.prototype.search=function(e,t){var n=K.Paragraph_Search(this,e,t),r=n.handled,o=n.result;return r?o:p(i.RangeCollection,this,"Search",1,[e,t],!0,!1,null,4)},gr.prototype.select=function(e){d(this,"Select",1,[e],4,0)},gr.prototype.setMetadata=function(e,t){d(this,"SetMetadata",0,[e,t],0,0)},gr.prototype.split=function(e,t,n){return b("Paragraph.split",u,"1.3",l),p(i.RangeCollection,this,"Split",1,[e,t,n],!0,!1,null,4)},gr.prototype.startNewList=function(){return b("Paragraph.startNewList",u,"1.3",l),p(i.List,this,"StartNewList",0,[],!1,!1,null,0)},gr.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},gr.prototype._Search2=function(e,t){return p(i.RangeCollection,this,"_Search2",1,[e,t],!0,!1,null,4)},gr.prototype._handleResult=function(e){if(fr.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Alignment)||(this._A=t.Alignment),y(t.FirstLineIndent)||(this._Fi=t.FirstLineIndent),y(t.IsLastParagraph)||(this._Is=t.IsLastParagraph),y(t.IsListItem)||(this._IsL=t.IsListItem),y(t.LeftIndent)||(this._L=t.LeftIndent),y(t.LineSpacing)||(this._Li=t.LineSpacing),y(t.LineUnitAfter)||(this._Lin=t.LineUnitAfter),y(t.LineUnitBefore)||(this._Line=t.LineUnitBefore),y(t.OutlineLevel)||(this._O=t.OutlineLevel),y(t.RightIndent)||(this._R=t.RightIndent),y(t.SpaceAfter)||(this._Sp=t.SpaceAfter),y(t.SpaceBefore)||(this._Spa=t.SpaceBefore),y(t.Style)||(this._St=t.Style),y(t.StyleBuiltIn)||(this._Sty=t.StyleBuiltIn),y(t.TableNestingLevel)||(this._T=t.TableNestingLevel),y(t.Text)||(this._Te=t.Text),y(t.UniqueLocalId)||(this._U=t.UniqueLocalId),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["contentControls","ContentControls","endnotes","Endnotes","fields","Fields","font","Font","footnotes","Footnotes","inlinePictures","InlinePictures","list","List","listItem","ListItem","listItemOrNullObject","ListItemOrNullObject","listOrNullObject","ListOrNullObject","parentBody","ParentBody","parentContentControl","ParentContentControl","parentContentControlOrNullObject","ParentContentControlOrNullObject","parentTable","ParentTable","parentTableCell","ParentTableCell","parentTableCellOrNullObject","ParentTableCellOrNullObject","parentTableOrNullObject","ParentTableOrNullObject","shapes","Shapes"])}},gr.prototype.load=function(e){return v(this,e)},gr.prototype.retrieve=function(e){return O(this,e)},gr.prototype._handleIdResult=function(e){fr.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},gr.prototype._handleRetrieveResult=function(e,t){fr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},gr.prototype.track=function(){return this.context.trackedObjects.add(this),this},gr.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},gr.prototype.toJSON=function(){return C(this,{alignment:this._A,firstLineIndent:this._Fi,isLastParagraph:this._Is,isListItem:this._IsL,leftIndent:this._L,lineSpacing:this._Li,lineUnitAfter:this._Lin,lineUnitBefore:this._Line,outlineLevel:this._O,rightIndent:this._R,spaceAfter:this._Sp,spaceBefore:this._Spa,style:this._St,styleBuiltIn:this._Sty,tableNestingLevel:this._T,text:this._Te,uniqueLocalId:this._U},{fields:this._F,font:this._Fo,inlinePictures:this._I,listItem:this._List,listItemOrNullObject:this._ListI,shapes:this._S})},gr.prototype.setMockData=function(e){R(this,e)},gr.prototype.ensureUnchanged=function(e){h(this,e)},gr);function gr(){return null!==fr&&fr.apply(this,arguments)||this}i.Paragraph=hr;var mr=(yr.prototype.getDocument=function(){return m(this._document)&&(this._document=this.context.document),this._document},yr.prototype.getReferenceId=function(){return m(this._refId)&&(this._refId=this._ReferenceId),this._refId},yr.prototype._RegisterCommentAddedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentAdded")},yr.prototype._UnregisterCommentAddedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentAdded")},yr.prototype._RegisterCommentDeletedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentDeleted")},yr.prototype._UnregisterCommentDeletedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentDeleted")},yr.prototype._RegisterCommentChangedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentChanged")},yr.prototype._UnregisterCommentChangedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentChanged")},yr.prototype._RegisterCommentSelectedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentSelected")},yr.prototype._UnregisterCommentSelectedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentSelected")},yr.prototype._RegisterCommentDeselectedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentDeselected")},yr.prototype._UnregisterCommentDeselectedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentDeselected")},yr);function yr(){}i.ParagraphCustom=mr,OfficeExtension.Utility.applyMixin(hr,mr),(K=i._CC||(i._CC={})).Paragraph_Search=function(e,t,n){var r;if(s()){var o=c(n);r=e._Search2(t,o)}else n=a(e.context,n),r=p(i.RangeCollection,e,"Search",1,[t,n],!0,!1,null,4);return{handled:!0,result:r}};var _r,br="ParagraphCollection",vr=(_r=OfficeExtension.ClientObject,__extends(Or,_r),Object.defineProperty(Or.prototype,"_className",{get:function(){return"ParagraphCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Or.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Or.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Or.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Or.prototype,"items",{get:function(){return _("items",this.m__items,br,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Or.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,br,this._isNull),this.__R},enumerable:!0,configurable:!0}),Or.prototype.getById=function(e){return p(i.Paragraph,this,"GetById",1,[e],!1,!1,null,5)},Or.prototype.getByIdOrNullObject=function(e){return p(i.Paragraph,this,"GetByIdOrNullObject",1,[e],!1,!1,null,5)},Or.prototype.getFirst=function(){return b("ParagraphCollection.getFirst",u,"1.3",l),p(i.Paragraph,this,"GetFirst",1,[],!1,!1,null,4)},Or.prototype.getFirstOrNullObject=function(){return b("ParagraphCollection.getFirstOrNullObject",u,"1.3",l),p(i.Paragraph,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Or.prototype.getLast=function(){return b("ParagraphCollection.getLast",u,"1.3",l),p(i.Paragraph,this,"GetLast",1,[],!1,!1,null,4)},Or.prototype.getLastOrNullObject=function(){return b("ParagraphCollection.getLastOrNullObject",u,"1.3",l),p(i.Paragraph,this,"GetLastOrNullObject",1,[],!1,!1,null,4)},Or.prototype._GetItem=function(e){return r(i.Paragraph,this,[e])},Or.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Or.prototype._handleResult=function(e){if(_r.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Paragraph,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Or.prototype.load=function(e){return v(this,e)},Or.prototype.retrieve=function(e){return O(this,e)},Or.prototype._handleIdResult=function(e){_r.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Or.prototype._handleRetrieveResult=function(e,t){var n=this;_r.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Paragraph,!0,n,e,t)})},Or.prototype.track=function(){return this.context.trackedObjects.add(this),this},Or.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Or.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Or.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Paragraph,!0,n,e,t)},function(e){return n.m__items=e})},Or);function Or(){return null!==_r&&_r.apply(this,arguments)||this}i.ParagraphCollection=vr;var Cr,Pr="ParagraphFormat",Sr=(Cr=OfficeExtension.ClientObject,__extends(Ar,Cr),Object.defineProperty(Ar.prototype,"_className",{get:function(){return"ParagraphFormat"},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","alignment","firstLineIndent","keepTogether","keepWithNext","leftIndent","lineSpacing","lineUnitAfter","lineUnitBefore","mirrorIndents","outlineLevel","rightIndent","spaceAfter","spaceBefore","widowControl"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Alignment","FirstLineIndent","KeepTogether","KeepWithNext","LeftIndent","LineSpacing","LineUnitAfter","LineUnitBefore","MirrorIndents","OutlineLevel","RightIndent","SpaceAfter","SpaceBefore","WidowControl"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"alignment",{get:function(){return _("alignment",this._A,Pr,this._isNull),this._A},set:function(e){this._A=e,g(this,"Alignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"firstLineIndent",{get:function(){return _("firstLineIndent",this._F,Pr,this._isNull),this._F},set:function(e){this._F=e,g(this,"FirstLineIndent",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"keepTogether",{get:function(){return _("keepTogether",this._K,Pr,this._isNull),this._K},set:function(e){this._K=e,g(this,"KeepTogether",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"keepWithNext",{get:function(){return _("keepWithNext",this._Ke,Pr,this._isNull),this._Ke},set:function(e){this._Ke=e,g(this,"KeepWithNext",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"leftIndent",{get:function(){return _("leftIndent",this._L,Pr,this._isNull),this._L},set:function(e){this._L=e,g(this,"LeftIndent",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"lineSpacing",{get:function(){return _("lineSpacing",this._Li,Pr,this._isNull),this._Li},set:function(e){this._Li=e,g(this,"LineSpacing",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"lineUnitAfter",{get:function(){return _("lineUnitAfter",this._Lin,Pr,this._isNull),this._Lin},set:function(e){this._Lin=e,g(this,"LineUnitAfter",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"lineUnitBefore",{get:function(){return _("lineUnitBefore",this._Line,Pr,this._isNull),this._Line},set:function(e){this._Line=e,g(this,"LineUnitBefore",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"mirrorIndents",{get:function(){return _("mirrorIndents",this._M,Pr,this._isNull),this._M},set:function(e){this._M=e,g(this,"MirrorIndents",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"outlineLevel",{get:function(){return _("outlineLevel",this._O,Pr,this._isNull),this._O},set:function(e){this._O=e,g(this,"OutlineLevel",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"rightIndent",{get:function(){return _("rightIndent",this._R,Pr,this._isNull),this._R},set:function(e){this._R=e,g(this,"RightIndent",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"spaceAfter",{get:function(){return _("spaceAfter",this._S,Pr,this._isNull),this._S},set:function(e){this._S=e,g(this,"SpaceAfter",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"spaceBefore",{get:function(){return _("spaceBefore",this._Sp,Pr,this._isNull),this._Sp},set:function(e){this._Sp=e,g(this,"SpaceBefore",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"widowControl",{get:function(){return _("widowControl",this._W,Pr,this._isNull),this._W},set:function(e){this._W=e,g(this,"WidowControl",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ar.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Pr,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ar.prototype.set=function(e,t){this._recursivelySet(e,t,["alignment","firstLineIndent","keepTogether","keepWithNext","leftIndent","lineSpacing","lineUnitAfter","lineUnitBefore","mirrorIndents","outlineLevel","rightIndent","spaceAfter","spaceBefore","widowControl"],[],[])},Ar.prototype.update=function(e){this._recursivelyUpdate(e)},Ar.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ar.prototype._handleResult=function(e){if(Cr.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Alignment)||(this._A=t.Alignment),y(t.FirstLineIndent)||(this._F=t.FirstLineIndent),y(t.KeepTogether)||(this._K=t.KeepTogether),y(t.KeepWithNext)||(this._Ke=t.KeepWithNext),y(t.LeftIndent)||(this._L=t.LeftIndent),y(t.LineSpacing)||(this._Li=t.LineSpacing),y(t.LineUnitAfter)||(this._Lin=t.LineUnitAfter),y(t.LineUnitBefore)||(this._Line=t.LineUnitBefore),y(t.MirrorIndents)||(this._M=t.MirrorIndents),y(t.OutlineLevel)||(this._O=t.OutlineLevel),y(t.RightIndent)||(this._R=t.RightIndent),y(t.SpaceAfter)||(this._S=t.SpaceAfter),y(t.SpaceBefore)||(this._Sp=t.SpaceBefore),y(t.WidowControl)||(this._W=t.WidowControl),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Ar.prototype.load=function(e){return v(this,e)},Ar.prototype.retrieve=function(e){return O(this,e)},Ar.prototype._handleIdResult=function(e){Cr.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Ar.prototype._handleRetrieveResult=function(e,t){Cr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Ar.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ar.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ar.prototype.toJSON=function(){return C(this,{alignment:this._A,firstLineIndent:this._F,keepTogether:this._K,keepWithNext:this._Ke,leftIndent:this._L,lineSpacing:this._Li,lineUnitAfter:this._Lin,lineUnitBefore:this._Line,mirrorIndents:this._M,outlineLevel:this._O,rightIndent:this._R,spaceAfter:this._S,spaceBefore:this._Sp,widowControl:this._W},{})},Ar.prototype.setMockData=function(e){R(this,e)},Ar.prototype.ensureUnchanged=function(e){h(this,e)},Ar);function Ar(){return null!==Cr&&Cr.apply(this,arguments)||this}i.ParagraphFormat=Sr;var Ir,Rr="Range",Tr=(Ir=OfficeExtension.ClientObject,__extends(Er,Ir),Object.defineProperty(Er.prototype,"_className",{get:function(){return"Range"},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","style","text","isEmpty","hyperlink","styleBuiltIn"]},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","Style","Text","IsEmpty","Hyperlink","StyleBuiltIn"]},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!1,!1,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"_navigationPropertyNames",{get:function(){return["font","paragraphs","contentControls","parentContentControl","inlinePictures","lists","tables","parentTableCell","parentTable","parentBody","parentContentControlOrNullObject","parentTableCellOrNullObject","parentTableOrNullObject","footnotes","endnotes","fields","shapes","pages"]},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"contentControls",{get:function(){return this._C||(this._C=t(i.ContentControlCollection,this,"ContentControls",!0,4)),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"endnotes",{get:function(){return b("Range.endnotes",u,"1.5",l),this._E||(this._E=t(i.NoteItemCollection,this,"Endnotes",!0,4)),this._E},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"fields",{get:function(){return b("Range.fields",u,"1.4",l),this._F||(this._F=t(i.FieldCollection,this,"Fields",!0,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"font",{get:function(){return this._Fo||(this._Fo=t(i.Font,this,"Font",!1,4)),this._Fo},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"footnotes",{get:function(){return b("Range.footnotes",u,"1.5",l),this._Foo||(this._Foo=t(i.NoteItemCollection,this,"Footnotes",!0,4)),this._Foo},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"inlinePictures",{get:function(){return b("Range.inlinePictures",u,"1.2",l),this._I||(this._I=t(i.InlinePictureCollection,this,"InlinePictures",!0,4)),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"lists",{get:function(){return b("Range.lists",u,"1.3",l),this._L||(this._L=t(i.ListCollection,this,"Lists",!0,4)),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"pages",{get:function(){return b("Range.pages","WordApiDesktop","1.2",l),this._P||(this._P=t(i.PageCollection,this,"Pages",!0,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"paragraphs",{get:function(){return this._Pa||(this._Pa=t(i.ParagraphCollection,this,"Paragraphs",!0,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"parentBody",{get:function(){return b("Range.parentBody",u,"1.3",l),this._Par||(this._Par=t(i.Body,this,"ParentBody",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"parentContentControl",{get:function(){return this._Pare||(this._Pare=t(i.ContentControl,this,"ParentContentControl",!1,4)),this._Pare},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"parentContentControlOrNullObject",{get:function(){return b("Range.parentContentControlOrNullObject",u,"1.3",l),this._Paren||(this._Paren=t(i.ContentControl,this,"ParentContentControlOrNullObject",!1,4)),this._Paren},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"parentTable",{get:function(){return b("Range.parentTable",u,"1.3",l),this._Parent||(this._Parent=t(i.Table,this,"ParentTable",!1,4)),this._Parent},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"parentTableCell",{get:function(){return b("Range.parentTableCell",u,"1.3",l),this._ParentT||(this._ParentT=t(i.TableCell,this,"ParentTableCell",!1,4)),this._ParentT},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"parentTableCellOrNullObject",{get:function(){return b("Range.parentTableCellOrNullObject",u,"1.3",l),this._ParentTa||(this._ParentTa=t(i.TableCell,this,"ParentTableCellOrNullObject",!1,4)),this._ParentTa},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"parentTableOrNullObject",{get:function(){return b("Range.parentTableOrNullObject",u,"1.3",l),this._ParentTab||(this._ParentTab=t(i.Table,this,"ParentTableOrNullObject",!1,4)),this._ParentTab},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"shapes",{get:function(){return b("Range.shapes","WordApiDesktop","1.2",l),this._S||(this._S=t(i.ShapeCollection,this,"Shapes",!0,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"tables",{get:function(){return b("Range.tables",u,"1.3",l),this._T||(this._T=t(i.TableCollection,this,"Tables",!0,4)),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"hyperlink",{get:function(){return _("hyperlink",this._H,Rr,this._isNull),b("Range.hyperlink",u,"1.3",l),this._H},set:function(e){this._H=e,g(this,"Hyperlink",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"isEmpty",{get:function(){return _("isEmpty",this._Is,Rr,this._isNull),b("Range.isEmpty",u,"1.3",l),this._Is},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"style",{get:function(){return _("style",this._St,Rr,this._isNull),this._St},set:function(e){this._St=e,g(this,"Style",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"styleBuiltIn",{get:function(){return _("styleBuiltIn",this._Sty,Rr,this._isNull),b("Range.styleBuiltIn",u,"1.3",l),this._Sty},set:function(e){this._Sty=e,g(this,"StyleBuiltIn",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"text",{get:function(){return _("text",this._Te,Rr,this._isNull),this._Te},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"_Id",{get:function(){return _("_Id",this.__I,Rr,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Er.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Rr,this._isNull),this.__R},enumerable:!0,configurable:!0}),Er.prototype.set=function(e,t){this._recursivelySet(e,t,["style","hyperlink","styleBuiltIn"],["font"],["contentControls","endnotes","fields","footnotes","inlinePictures","lists","pages","paragraphs","parentBody","parentContentControl","parentContentControlOrNullObject","parentTable","parentTableCell","parentTableCellOrNullObject","parentTableOrNullObject","shapes","tables"])},Er.prototype.update=function(e){this._recursivelyUpdate(e)},Er.prototype.clear=function(){d(this,"Clear",0,[],0,0)},Er.prototype.compareLocationWith=function(e){return b("Range.compareLocationWith",u,"1.3",l),d(this,"CompareLocationWith",1,[e],4,0)},Er.prototype.delete=function(){d(this,"Delete",0,[],0,0)},Er.prototype.endPreview=function(){d(this,"EndPreview",1,[],4,0)},Er.prototype.expandTo=function(e){return b("Range.expandTo",u,"1.3",l),p(i.Range,this,"ExpandTo",0,[e],!1,!1,null,0)},Er.prototype.expandToOrNullObject=function(e){return b("Range.expandToOrNullObject",u,"1.3",l),p(i.Range,this,"ExpandToOrNullObject",0,[e],!1,!1,null,0)},Er.prototype.getBookmarks=function(e,t){return b("Range.getBookmarks",u,"1.4",l),d(this,"GetBookmarks",1,[e,t],4,0)},Er.prototype.getComments=function(){return b("Range.getComments",u,"1.4",l),p(i.CommentCollection,this,"GetComments",1,[],!0,!1,null,4)},Er.prototype.getContentControls=function(e){return b("Range.getContentControls",u,"1.5",l),p(i.ContentControlCollection,this,"GetContentControls",1,[e],!0,!1,null,4)},Er.prototype.getHtml=function(){return d(this,"GetHtml",1,[],4,0)},Er.prototype.getHyperlinkRanges=function(){return b("Range.getHyperlinkRanges",u,"1.3",l),p(i.RangeCollection,this,"GetHyperlinkRanges",1,[],!0,!1,null,4)},Er.prototype.getNextTextRange=function(e,t){return b("Range.getNextTextRange",u,"1.3",l),p(i.Range,this,"GetNextTextRange",1,[e,t],!1,!1,null,4)},Er.prototype.getNextTextRangeOrNullObject=function(e,t){return b("Range.getNextTextRangeOrNullObject",u,"1.3",l),p(i.Range,this,"GetNextTextRangeOrNullObject",1,[e,t],!1,!1,null,4)},Er.prototype.getOoxml=function(){return d(this,"GetOoxml",1,[],4,0)},Er.prototype.getRange=function(e){return b("Range.getRange",u,"1.3",l),p(i.Range,this,"GetRange",1,[e],!1,!1,null,4)},Er.prototype.getReviewedText=function(e){return b("Range.getReviewedText",u,"1.4",l),d(this,"GetReviewedText",1,[e],4,0)},Er.prototype.getTextRanges=function(e,t){return b("Range.getTextRanges",u,"1.3",l),p(i.RangeCollection,this,"GetTextRanges",1,[e,t],!0,!1,null,4)},Er.prototype.getTrackedChanges=function(){return b("Range.getTrackedChanges",u,"1.6",l),p(i.TrackedChangeCollection,this,"GetTrackedChanges",1,[],!0,!1,null,4)},Er.prototype.highlight=function(){b("Range.highlight",u,"1.8",l),d(this,"Highlight",1,[],4,0)},Er.prototype.insertBookmark=function(e){b("Range.insertBookmark",u,"1.4",l),d(this,"InsertBookmark",0,[e],0,0)},Er.prototype.insertBreak=function(e,t){d(this,"InsertBreak",0,[e,t],0,0)},Er.prototype.insertCanvas=function(e){return b("Range.insertCanvas","WordApiDesktop","1.2",l),p(i.Shape,this,"InsertCanvas",0,[e],!1,!1,null,0)},Er.prototype.insertComment=function(e){return b("Range.insertComment",u,"1.4",l),p(i.Comment,this,"InsertComment",0,[e],!1,!0,null,0)},Er.prototype.insertContentControl=function(e){return p(i.ContentControl,this,"InsertContentControl",0,[e],!1,!0,null,0)},Er.prototype.insertEndnote=function(e){return b("Range.insertEndnote",u,"1.5",l),p(i.NoteItem,this,"InsertEndnote",0,[e],!1,!0,null,0)},Er.prototype.insertField=function(e,t,n,r){return b("Range.insertField",u,"1.5",l),p(i.Field,this,"InsertField",0,[e,t,n,r],!1,!0,null,0)},Er.prototype.insertFileFromBase64=function(e,t){return p(i.Range,this,"InsertFileFromBase64",0,[e,t],!1,!0,null,0)},Er.prototype.insertFootnote=function(e){return b("Range.insertFootnote",u,"1.5",l),p(i.NoteItem,this,"InsertFootnote",0,[e],!1,!0,null,0)},Er.prototype.insertGeometricShape=function(e,t){return b("Range.insertGeometricShape","WordApiDesktop","1.2",l),p(i.Shape,this,"InsertGeometricShape",0,[e,t],!1,!1,null,0)},Er.prototype.insertHtml=function(e,t){return p(i.Range,this,"InsertHtml",0,[e,t],!1,!0,null,0)},Er.prototype.insertInlinePictureFromBase64=function(e,t){return b("Range.insertInlinePictureFromBase64",u,"1.2",l),p(i.InlinePicture,this,"InsertInlinePictureFromBase64",0,[e,t],!1,!0,null,0)},Er.prototype.insertOoxml=function(e,t){return p(i.Range,this,"InsertOoxml",0,[e,t],!1,!0,null,0)},Er.prototype.insertParagraph=function(e,t){return p(i.Paragraph,this,"InsertParagraph",0,[e,t],!1,!0,null,0)},Er.prototype.insertPictureFromBase64=function(e,t){return b("Range.insertPictureFromBase64","WordApiDesktop","1.2",l),p(i.Shape,this,"InsertPictureFromBase64",0,[e,t],!1,!1,null,0)},Er.prototype.insertTable=function(e,t,n,r){return b("Range.insertTable",u,"1.3",l),p(i.Table,this,"InsertTable",0,[e,t,n,r],!1,!0,null,0)},Er.prototype.insertTapObjectFromFileContent=function(e,t,n){return p(i.Range,this,"InsertTapObjectFromFileContent",0,[e,t,n],!1,!0,null,1)},Er.prototype.insertText=function(e,t){return p(i.Range,this,"InsertText",0,[e,t],!1,!0,null,0)},Er.prototype.insertTextBox=function(e,t){return b("Range.insertTextBox","WordApiDesktop","1.2",l),p(i.Shape,this,"InsertTextBox",0,[e,t],!1,!1,null,0)},Er.prototype.intersectWith=function(e){return b("Range.intersectWith",u,"1.3",l),p(i.Range,this,"IntersectWith",0,[e],!1,!1,null,0)},Er.prototype.intersectWithOrNullObject=function(e){return b("Range.intersectWithOrNullObject",u,"1.3",l),p(i.Range,this,"IntersectWithOrNullObject",0,[e],!1,!1,null,0)},Er.prototype.previewTextReplacement=function(e){d(this,"PreviewTextReplacement",1,[e],4,0)},Er.prototype.removeHighlight=function(){b("Range.removeHighlight",u,"1.8",l),d(this,"RemoveHighlight",1,[],4,0)},Er.prototype.scrollIntoView=function(){d(this,"ScrollIntoView",1,[],4,0)},Er.prototype.search=function(e,t){var n=K.Range_Search(this,e,t),r=n.handled,o=n.result;return r?o:p(i.RangeCollection,this,"Search",1,[e,t],!0,!1,null,4)},Er.prototype.select=function(e){d(this,"Select",1,[e],4,0)},Er.prototype.split=function(e,t,n,r){return b("Range.split",u,"1.3",l),p(i.RangeCollection,this,"Split",1,[e,t,n,r],!0,!1,null,4)},Er.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Er.prototype._Search2=function(e,t){return p(i.RangeCollection,this,"_Search2",1,[e,t],!0,!1,null,4)},Er.prototype._handleResult=function(e){if(Ir.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Hyperlink)||(this._H=t.Hyperlink),y(t.IsEmpty)||(this._Is=t.IsEmpty),y(t.Style)||(this._St=t.Style),y(t.StyleBuiltIn)||(this._Sty=t.StyleBuiltIn),y(t.Text)||(this._Te=t.Text),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["contentControls","ContentControls","endnotes","Endnotes","fields","Fields","font","Font","footnotes","Footnotes","inlinePictures","InlinePictures","lists","Lists","pages","Pages","paragraphs","Paragraphs","parentBody","ParentBody","parentContentControl","ParentContentControl","parentContentControlOrNullObject","ParentContentControlOrNullObject","parentTable","ParentTable","parentTableCell","ParentTableCell","parentTableCellOrNullObject","ParentTableCellOrNullObject","parentTableOrNullObject","ParentTableOrNullObject","shapes","Shapes","tables","Tables"])}},Er.prototype.load=function(e){return v(this,e)},Er.prototype.retrieve=function(e){return O(this,e)},Er.prototype._handleIdResult=function(e){Ir.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Er.prototype._handleRetrieveResult=function(e,t){Ir.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Er.prototype.track=function(){return this.context.trackedObjects.add(this),this},Er.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Er.prototype.toJSON=function(){return C(this,{hyperlink:this._H,isEmpty:this._Is,style:this._St,styleBuiltIn:this._Sty,text:this._Te},{fields:this._F,font:this._Fo,inlinePictures:this._I,pages:this._P,shapes:this._S})},Er.prototype.setMockData=function(e){R(this,e)},Er.prototype.ensureUnchanged=function(e){h(this,e)},Er);function Er(){return null!==Ir&&Ir.apply(this,arguments)||this}i.Range=Tr;var Nr=(Dr.prototype.getDocument=function(){return m(this._document)&&(this._document=this.context.document),this._document},Dr.prototype.getReferenceId=function(){return m(this._refId)&&(this._refId=this._ReferenceId),this._refId},Dr.prototype._RegisterCommentAddedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentAdded")},Dr.prototype._UnregisterCommentAddedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentAdded")},Dr.prototype._RegisterCommentChangedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentChanged")},Dr.prototype._UnregisterCommentChangedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentChanged")},Dr.prototype._RegisterCommentSelectedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentSelected")},Dr.prototype._UnregisterCommentSelectedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentSelected")},Dr.prototype._RegisterCommentDeselectedEvent=function(){this.getDocument()._RegisterEvent(this.getReferenceId(),"CommentDeselected")},Dr.prototype._UnregisterCommentDeselectedEvent=function(){this.getDocument()._UnregisterEvent(this.getReferenceId(),"CommentDeselected")},Dr);function Dr(){}i.RangeCustom=Nr,OfficeExtension.Utility.applyMixin(Tr,Nr),(K=i._CC||(i._CC={})).Range_Search=function(e,t,n){var r;if(s()){var o=c(n);r=e._Search2(t,o)}else n=a(e.context,n),r=p(i.RangeCollection,e,"Search",1,[t,n],!0,!1,null,4);return{handled:!0,result:r}};var xr,wr="RangeCollection",Fr=(xr=OfficeExtension.ClientObject,__extends(jr,xr),Object.defineProperty(jr.prototype,"_className",{get:function(){return"RangeCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(jr.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(jr.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(jr.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(jr.prototype,"items",{get:function(){return _("items",this.m__items,wr,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(jr.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,wr,this._isNull),this.__R},enumerable:!0,configurable:!0}),jr.prototype.getFirst=function(){return b("RangeCollection.getFirst",u,"1.3",l),p(i.Range,this,"GetFirst",1,[],!1,!1,null,4)},jr.prototype.getFirstOrNullObject=function(){return b("RangeCollection.getFirstOrNullObject",u,"1.3",l),p(i.Range,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},jr.prototype._GetItem=function(e){return r(i.Range,this,[e])},jr.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},jr.prototype._handleResult=function(e){if(xr.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Range,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},jr.prototype.load=function(e){return v(this,e)},jr.prototype.retrieve=function(e){return O(this,e)},jr.prototype._handleIdResult=function(e){xr.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},jr.prototype._handleRetrieveResult=function(e,t){var n=this;xr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Range,!0,n,e,t)})},jr.prototype.track=function(){return this.context.trackedObjects.add(this),this},jr.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},jr.prototype.toJSON=function(){return C(this,{},{},this.m__items)},jr.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Range,!0,n,e,t)},function(e){return n.m__items=e})},jr);function jr(){return null!==xr&&xr.apply(this,arguments)||this}i.RangeCollection=Fr;var kr,Mr="SearchOptions",Hr=(kr=OfficeExtension.ClientObject,__extends(Lr,kr),Object.defineProperty(Lr.prototype,"_className",{get:function(){return"SearchOptions"},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"_scalarPropertyNames",{get:function(){return["ignorePunct","ignoreSpace","matchCase","matchPrefix","matchSuffix","matchWildcards","matchWholeWord"]},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"_scalarPropertyOriginalNames",{get:function(){return["IgnorePunct","IgnoreSpace","MatchCase","MatchPrefix","MatchSuffix","MatchWildcards","MatchWholeWord"]},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"_scalarPropertyUpdateable",{get:function(){return[!0,!0,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"ignorePunct",{get:function(){return _("ignorePunct",this._I,Mr,this._isNull),this._I},set:function(e){this._I=e,g(this,"IgnorePunct",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"ignoreSpace",{get:function(){return _("ignoreSpace",this._Ig,Mr,this._isNull),this._Ig},set:function(e){this._Ig=e,g(this,"IgnoreSpace",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"matchCase",{get:function(){return _("matchCase",this._M,Mr,this._isNull),this._M},set:function(e){this._M=e,g(this,"MatchCase",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"matchPrefix",{get:function(){return _("matchPrefix",this._Ma,Mr,this._isNull),this._Ma},set:function(e){this._Ma=e,g(this,"MatchPrefix",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"matchSuffix",{get:function(){return _("matchSuffix",this._Mat,Mr,this._isNull),this._Mat},set:function(e){this._Mat=e,g(this,"MatchSuffix",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"matchWholeWord",{get:function(){return _("matchWholeWord",this._Matc,Mr,this._isNull),this._Matc},set:function(e){this._Matc=e,g(this,"MatchWholeWord",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Lr.prototype,"matchWildcards",{get:function(){return _("matchWildcards",this.m_matchWildcards,Mr,this._isNull),this.m_matchWildcards},set:function(e){this.m_matchWildcards=e,g(this,"MatchWildcards",e,0)},enumerable:!0,configurable:!0}),Lr.prototype.set=function(e,t){this._recursivelySet(e,t,["ignorePunct","ignoreSpace","matchCase","matchPrefix","matchSuffix","matchWildcards","matchWholeWord"],[],[])},Lr.prototype.update=function(e){this._recursivelyUpdate(e)},Lr.prototype._handleResult=function(e){if(kr.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.IgnorePunct)||(this._I=t.IgnorePunct),y(t.IgnoreSpace)||(this._Ig=t.IgnoreSpace),y(t.MatchCase)||(this._M=t.MatchCase),y(t.MatchPrefix)||(this._Ma=t.MatchPrefix),y(t.MatchSuffix)||(this._Mat=t.MatchSuffix),y(t.MatchWholeWord)||(this._Matc=t.MatchWholeWord),y(t.MatchWildcards)||(this.m_matchWildcards=t.MatchWildcards)}},Lr.prototype.load=function(e){return v(this,e)},Lr.prototype.retrieve=function(e){return O(this,e)},Lr.prototype._handleRetrieveResult=function(e,t){kr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Lr.newObject=function(e){return o(i.SearchOptions,e,"Microsoft.WordServices.SearchOptions",!1,4)},Lr.prototype.toJSON=function(){return C(this,{ignorePunct:this._I,ignoreSpace:this._Ig,matchCase:this._M,matchPrefix:this._Ma,matchSuffix:this._Mat,matchWholeWord:this._Matc,matchWildcards:this.m_matchWildcards},{})},Lr.prototype.setMockData=function(e){R(this,e)},Lr.prototype.ensureUnchanged=function(e){h(this,e)},Lr);function Lr(){return null!==kr&&kr.apply(this,arguments)||this}i.SearchOptions=Hr;var Ur=(Object.defineProperty(Br.prototype,"matchWildCards",{get:function(){return _("matchWildCards",this.m_matchWildcards),this.m_matchWildcards},set:function(e){this.m_matchWildcards=e,g(this,"MatchWildCards",e,0)},enumerable:!0,configurable:!0}),Br);function Br(){}i.SearchOptionsCustom=Ur,OfficeExtension.Utility.applyMixin(Hr,Ur);var Wr,Gr=(Wr=OfficeExtension.ClientObject,__extends(qr,Wr),Object.defineProperty(qr.prototype,"_className",{get:function(){return"Section"},enumerable:!0,configurable:!0}),Object.defineProperty(qr.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(qr.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(qr.prototype,"_navigationPropertyNames",{get:function(){return["body"]},enumerable:!0,configurable:!0}),Object.defineProperty(qr.prototype,"body",{get:function(){return this._B||(this._B=t(i.Body,this,"Body",!1,4)),this._B},enumerable:!0,configurable:!0}),Object.defineProperty(qr.prototype,"_Id",{get:function(){return _("_Id",this.__I,"Section",this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(qr.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,"Section",this._isNull),this.__R},enumerable:!0,configurable:!0}),qr.prototype.set=function(e,t){this._recursivelySet(e,t,[],["body"],[])},qr.prototype.update=function(e){this._recursivelyUpdate(e)},qr.prototype.getFooter=function(e){return p(i.Body,this,"GetFooter",1,[e],!1,!0,null,4)},qr.prototype.getHeader=function(e){return p(i.Body,this,"GetHeader",1,[e],!1,!0,null,4)},qr.prototype.getNext=function(){return b("Section.getNext",u,"1.3",l),p(i.Section,this,"GetNext",1,[],!1,!1,null,4)},qr.prototype.getNextOrNullObject=function(){return b("Section.getNextOrNullObject",u,"1.3",l),p(i.Section,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},qr.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},qr.prototype._handleResult=function(e){if(Wr.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["body","Body"])}},qr.prototype.load=function(e){return v(this,e)},qr.prototype.retrieve=function(e){return O(this,e)},qr.prototype._handleIdResult=function(e){Wr.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},qr.prototype._handleRetrieveResult=function(e,t){Wr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},qr.prototype.track=function(){return this.context.trackedObjects.add(this),this},qr.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},qr.prototype.toJSON=function(){return C(this,{},{body:this._B})},qr.prototype.setMockData=function(e){R(this,e)},qr.prototype.ensureUnchanged=function(e){h(this,e)},qr);function qr(){return null!==Wr&&Wr.apply(this,arguments)||this}i.Section=Gr;var Vr,zr="SectionCollection",Jr=(Vr=OfficeExtension.ClientObject,__extends(Kr,Vr),Object.defineProperty(Kr.prototype,"_className",{get:function(){return"SectionCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Kr.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Kr.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Kr.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Kr.prototype,"items",{get:function(){return _("items",this.m__items,zr,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Kr.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,zr,this._isNull),this.__R},enumerable:!0,configurable:!0}),Kr.prototype.getFirst=function(){return b("SectionCollection.getFirst",u,"1.3",l),p(i.Section,this,"GetFirst",1,[],!1,!1,null,4)},Kr.prototype.getFirstOrNullObject=function(){return b("SectionCollection.getFirstOrNullObject",u,"1.3",l),p(i.Section,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Kr.prototype._GetItem=function(e){return r(i.Section,this,[e])},Kr.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Kr.prototype._handleResult=function(e){if(Vr.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Section,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Kr.prototype.load=function(e){return v(this,e)},Kr.prototype.retrieve=function(e){return O(this,e)},Kr.prototype._handleIdResult=function(e){Vr.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Kr.prototype._handleRetrieveResult=function(e,t){var n=this;Vr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Section,!0,n,e,t)})},Kr.prototype.track=function(){return this.context.trackedObjects.add(this),this},Kr.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Kr.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Kr.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Section,!0,n,e,t)},function(e){return n.m__items=e})},Kr);function Kr(){return null!==Vr&&Vr.apply(this,arguments)||this}i.SectionCollection=Jr;var Xr,Qr="Setting",$r=(Xr=OfficeExtension.ClientObject,__extends(Zr,Xr),Object.defineProperty(Zr.prototype,"_className",{get:function(){return"Setting"},enumerable:!0,configurable:!0}),Object.defineProperty(Zr.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","key","value","_Id"]},enumerable:!0,configurable:!0}),Object.defineProperty(Zr.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Key","Value","_Id"]},enumerable:!0,configurable:!0}),Object.defineProperty(Zr.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(Zr.prototype,"key",{get:function(){return _("key",this._K,Qr,this._isNull),this._K},enumerable:!0,configurable:!0}),Object.defineProperty(Zr.prototype,"value",{get:function(){return _("value",this.m_value,Qr,this._isNull),this.m_value},set:function(e){K.Setting_Value_Set(this,e).handled||(this.m_value=e,g(this,"Value",e,0))},enumerable:!0,configurable:!0}),Object.defineProperty(Zr.prototype,"_Id",{get:function(){return _("_Id",this.__I,Qr,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Zr.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Qr,this._isNull),this.__R},enumerable:!0,configurable:!0}),Zr.prototype.set=function(e,t){this._recursivelySet(e,t,["value"],[],[])},Zr.prototype.update=function(e){this._recursivelyUpdate(e)},Zr.prototype.delete=function(){d(this,"Delete",0,[],0,0)},Zr.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Zr.prototype._handleResult=function(e){if(Xr.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),K.Setting_HandleResult(this,t),y(t.Key)||(this._K=t.Key),y(t.Value)||(this.m_value=t.Value),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Zr.prototype.load=function(e){return v(this,e)},Zr.prototype.retrieve=function(e){return O(this,e)},Zr.prototype._handleIdResult=function(e){Xr.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Zr.prototype._handleRetrieveResult=function(e,t){Xr.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Zr.prototype.track=function(){return this.context.trackedObjects.add(this),this},Zr.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Zr.prototype.toJSON=function(){return C(this,{key:this._K,value:this.m_value},{})},Zr.prototype.setMockData=function(e){R(this,e)},Zr.prototype.ensureUnchanged=function(e){h(this,e)},Zr);function Zr(){return null!==Xr&&Xr.apply(this,arguments)||this}i.Setting=$r;var Yr,eo=(to.replaceStringDateWithDate=function(e){var t=JSON.stringify(e);return e=JSON.parse(t,function(e,t){var n;return"string"==typeof t&&t&&6<t.length&&t.slice(0,5)===to.DateJSONPrefix&&t.slice(-1)===to.DateJSONSuffix&&(n=new Date(parseInt(t.slice(5,-1))))?n:t})},to.replaceDateWithStringDate=function(e){var t=JSON.stringify(e,function(e,t){return this[e]instanceof Date?to.DateJSONPrefix+this[e].getTime()+to.DateJSONSuffix:t});return e=JSON.parse(t)},to.DateJSONPrefix="Date(",to.DateJSONSuffix=")",to);function to(){}i.SettingCustom=eo,OfficeExtension.Utility.applyMixin($r,eo),(Yr=K=i._CC||(i._CC={})).Setting_HandleResult=function(e,t){if(!y(t.Value)&&"string"==typeof t.Value){var n=JSON.parse(t.Value,function(e,t){return/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2}(?:\.\d*)?)Z$/.exec(t)?new Date(t):t});t.Value=eo.replaceStringDateWithDate(n)}},Yr.Setting_Value_Set=function(e,t){var n=JSON.stringify(eo.replaceDateWithStringDate(t));if(null!==n)return this.m_value=n,g(e,"Value",n,0),{handled:!0}};var no,ro="SettingCollection",oo=(no=OfficeExtension.ClientObject,__extends(io,no),Object.defineProperty(io.prototype,"_className",{get:function(){return"SettingCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(io.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(io.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(io.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(io.prototype,"items",{get:function(){return _("items",this.m__items,ro,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(io.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ro,this._isNull),this.__R},enumerable:!0,configurable:!0}),io.prototype.add=function(e,t){var n=K.SettingCollection_Add(this,e,t),r=n.handled,o=n.result;return r?o:p(i.Setting,this,"Add",0,[e,t],!1,!0,null,0)},io.prototype.deleteAll=function(){d(this,"DeleteAll",0,[],0,0)},io.prototype.getCount=function(){return d(this,"GetCount",1,[],4,0)},io.prototype.getItem=function(e){return r(i.Setting,this,[e])},io.prototype.getItemOrNullObject=function(e){return p(i.Setting,this,"GetItemOrNullObject",1,[e],!1,!1,null,4)},io.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},io.prototype._handleResult=function(e){if(no.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Setting,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},io.prototype.load=function(e){return v(this,e)},io.prototype.retrieve=function(e){return O(this,e)},io.prototype._handleIdResult=function(e){no.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},io.prototype._handleRetrieveResult=function(e,t){var n=this;no.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Setting,!0,n,e,t)})},io.prototype.track=function(){return this.context.trackedObjects.add(this),this},io.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},io.prototype.toJSON=function(){return C(this,{},{},this.m__items)},io.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Setting,!0,n,e,t)},function(e){return n.m__items=e})},io);function io(){return null!==no&&no.apply(this,arguments)||this}i.SettingCollection=oo,(K=i._CC||(i._CC={})).SettingCollection_Add=function(e,t,n){var r=JSON.stringify(eo.replaceDateWithStringDate(n));return null===r?{handled:!1,result:null}:{handled:!0,result:p(i.Setting,e,"Add",0,[t,r],!1,!1,null,0)}};var ao,so="StyleCollection",co=(ao=OfficeExtension.ClientObject,__extends(lo,ao),Object.defineProperty(lo.prototype,"_className",{get:function(){return"StyleCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(lo.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(lo.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(lo.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(lo.prototype,"items",{get:function(){return _("items",this.m__items,so,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(lo.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,so,this._isNull),this.__R},enumerable:!0,configurable:!0}),lo.prototype.getByName=function(e){return p(i.Style,this,"GetByName",1,[e],!1,!1,null,4)},lo.prototype.getByNameOrNullObject=function(e){return p(i.Style,this,"GetByNameOrNullObject",1,[e],!1,!1,null,4)},lo.prototype.getCount=function(){return d(this,"GetCount",1,[],4,0)},lo.prototype.getItem=function(e){return r(i.Style,this,[e])},lo.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},lo.prototype._handleResult=function(e){if(ao.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Style,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},lo.prototype.load=function(e){return v(this,e)},lo.prototype.retrieve=function(e){return O(this,e)},lo.prototype._handleIdResult=function(e){ao.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},lo.prototype._handleRetrieveResult=function(e,t){var n=this;ao.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Style,!0,n,e,t)})},lo.prototype.track=function(){return this.context.trackedObjects.add(this),this},lo.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},lo.prototype.toJSON=function(){return C(this,{},{},this.m__items)},lo.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Style,!0,n,e,t)},function(e){return n.m__items=e})},lo);function lo(){return null!==ao&&ao.apply(this,arguments)||this}i.StyleCollection=co;var uo,po="Style",fo=(uo=OfficeExtension.ClientObject,__extends(ho,uo),Object.defineProperty(ho.prototype,"_className",{get:function(){return"Style"},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","baseStyle","builtIn","inUse","linked","nameLocal","nextParagraphStyle","priority","quickStyle","type","unhideWhenUsed","visibility"]},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","BaseStyle","BuiltIn","InUse","Linked","NameLocal","NextParagraphStyle","Priority","QuickStyle","Type","UnhideWhenUsed","Visibility"]},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!1,!1,!1,!1,!0,!0,!0,!1,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"_navigationPropertyNames",{get:function(){return["font","paragraphFormat","listTemplate","shading","tableStyle","borders"]},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"borders",{get:function(){return b("Style.borders","WordApiDesktop","1.1",l),this._Bo||(this._Bo=t(i.BorderCollection,this,"Borders",!0,4)),this._Bo},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"font",{get:function(){return b("Style.font",u,"1.5",l),this._F||(this._F=t(i.Font,this,"Font",!1,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"listTemplate",{get:function(){return b("Style.listTemplate","WordApiDesktop","1.1",l),this._Li||(this._Li=t(i.ListTemplate,this,"ListTemplate",!1,4)),this._Li},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"paragraphFormat",{get:function(){return b("Style.paragraphFormat",u,"1.5",l),this._P||(this._P=t(i.ParagraphFormat,this,"ParagraphFormat",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"shading",{get:function(){return b("Style.shading",u,"1.6",l),this._S||(this._S=t(i.Shading,this,"Shading",!1,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"tableStyle",{get:function(){return b("Style.tableStyle",u,"1.6",l),this._T||(this._T=t(i.TableStyle,this,"TableStyle",!1,4)),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"baseStyle",{get:function(){return _("baseStyle",this._B,po,this._isNull),b("Style.baseStyle",u,"1.5",l),this._B},set:function(e){this._B=e,g(this,"BaseStyle",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"builtIn",{get:function(){return _("builtIn",this._Bu,po,this._isNull),b("Style.builtIn",u,"1.5",l),this._Bu},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"inUse",{get:function(){return _("inUse",this._I,po,this._isNull),b("Style.inUse",u,"1.5",l),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"linked",{get:function(){return _("linked",this._L,po,this._isNull),b("Style.linked",u,"1.5",l),this._L},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"nameLocal",{get:function(){return _("nameLocal",this._N,po,this._isNull),b("Style.nameLocal",u,"1.5",l),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"nextParagraphStyle",{get:function(){return _("nextParagraphStyle",this._Ne,po,this._isNull),b("Style.nextParagraphStyle",u,"1.5",l),this._Ne},set:function(e){this._Ne=e,g(this,"NextParagraphStyle",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"priority",{get:function(){return _("priority",this._Pr,po,this._isNull),b("Style.priority",u,"1.5",l),this._Pr},set:function(e){this._Pr=e,g(this,"Priority",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"quickStyle",{get:function(){return _("quickStyle",this._Q,po,this._isNull),b("Style.quickStyle",u,"1.5",l),this._Q},set:function(e){this._Q=e,g(this,"QuickStyle",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"type",{get:function(){return _("type",this._Ty,po,this._isNull),b("Style.type",u,"1.5",l),this._Ty},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"unhideWhenUsed",{get:function(){return _("unhideWhenUsed",this._U,po,this._isNull),b("Style.unhideWhenUsed",u,"1.5",l),this._U},set:function(e){this._U=e,g(this,"UnhideWhenUsed",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"visibility",{get:function(){return _("visibility",this._V,po,this._isNull),b("Style.visibility",u,"1.5",l),this._V},set:function(e){this._V=e,g(this,"Visibility",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ho.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,po,this._isNull),this.__R},enumerable:!0,configurable:!0}),ho.prototype.set=function(e,t){this._recursivelySet(e,t,["baseStyle","nextParagraphStyle","priority","quickStyle","unhideWhenUsed","visibility"],["font","paragraphFormat","listTemplate","shading","tableStyle"],["borders"])},ho.prototype.update=function(e){this._recursivelyUpdate(e)},ho.prototype.delete=function(){b("Style.delete",u,"1.5",l),d(this,"Delete",0,[],0,0)},ho.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},ho.prototype._handleResult=function(e){if(uo.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.BaseStyle)||(this._B=t.BaseStyle),y(t.BuiltIn)||(this._Bu=t.BuiltIn),y(t.InUse)||(this._I=t.InUse),y(t.Linked)||(this._L=t.Linked),y(t.NameLocal)||(this._N=t.NameLocal),y(t.NextParagraphStyle)||(this._Ne=t.NextParagraphStyle),y(t.Priority)||(this._Pr=t.Priority),y(t.QuickStyle)||(this._Q=t.QuickStyle),y(t.Type)||(this._Ty=t.Type),y(t.UnhideWhenUsed)||(this._U=t.UnhideWhenUsed),y(t.Visibility)||(this._V=t.Visibility),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["borders","Borders","font","Font","listTemplate","ListTemplate","paragraphFormat","ParagraphFormat","shading","Shading","tableStyle","TableStyle"])}},ho.prototype.load=function(e){return v(this,e)},ho.prototype.retrieve=function(e){return O(this,e)},ho.prototype._handleIdResult=function(e){uo.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},ho.prototype._handleRetrieveResult=function(e,t){uo.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},ho.prototype.track=function(){return this.context.trackedObjects.add(this),this},ho.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},ho.prototype.toJSON=function(){return C(this,{baseStyle:this._B,builtIn:this._Bu,inUse:this._I,linked:this._L,nameLocal:this._N,nextParagraphStyle:this._Ne,priority:this._Pr,quickStyle:this._Q,type:this._Ty,unhideWhenUsed:this._U,visibility:this._V},{borders:this._Bo,font:this._F,listTemplate:this._Li,paragraphFormat:this._P,shading:this._S,tableStyle:this._T})},ho.prototype.setMockData=function(e){R(this,e)},ho.prototype.ensureUnchanged=function(e){h(this,e)},ho);function ho(){return null!==uo&&uo.apply(this,arguments)||this}i.Style=fo;var go,mo="Shading",yo=(go=OfficeExtension.ClientObject,__extends(_o,go),Object.defineProperty(_o.prototype,"_className",{get:function(){return"Shading"},enumerable:!0,configurable:!0}),Object.defineProperty(_o.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","backgroundPatternColor","foregroundPatternColor","texture"]},enumerable:!0,configurable:!0}),Object.defineProperty(_o.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","BackgroundPatternColor","ForegroundPatternColor","Texture"]},enumerable:!0,configurable:!0}),Object.defineProperty(_o.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(_o.prototype,"backgroundPatternColor",{get:function(){return _("backgroundPatternColor",this._B,mo,this._isNull),this._B},set:function(e){this._B=e,g(this,"BackgroundPatternColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(_o.prototype,"foregroundPatternColor",{get:function(){return _("foregroundPatternColor",this._F,mo,this._isNull),b("Shading.foregroundPatternColor","WordApiDesktop","1.1",l),this._F},set:function(e){this._F=e,g(this,"ForegroundPatternColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(_o.prototype,"texture",{get:function(){return _("texture",this._T,mo,this._isNull),b("Shading.texture","WordApiDesktop","1.1",l),this._T},set:function(e){this._T=e,g(this,"Texture",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(_o.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,mo,this._isNull),this.__R},enumerable:!0,configurable:!0}),_o.prototype.set=function(e,t){this._recursivelySet(e,t,["backgroundPatternColor","foregroundPatternColor","texture"],[],[])},_o.prototype.update=function(e){this._recursivelyUpdate(e)},_o.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},_o.prototype._handleResult=function(e){if(go.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.BackgroundPatternColor)||(this._B=t.BackgroundPatternColor),y(t.ForegroundPatternColor)||(this._F=t.ForegroundPatternColor),y(t.Texture)||(this._T=t.Texture),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},_o.prototype.load=function(e){return v(this,e)},_o.prototype.retrieve=function(e){return O(this,e)},_o.prototype._handleIdResult=function(e){go.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},_o.prototype._handleRetrieveResult=function(e,t){go.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},_o.prototype.track=function(){return this.context.trackedObjects.add(this),this},_o.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},_o.prototype.toJSON=function(){return C(this,{backgroundPatternColor:this._B,foregroundPatternColor:this._F,texture:this._T},{})},_o.prototype.setMockData=function(e){R(this,e)},_o.prototype.ensureUnchanged=function(e){h(this,e)},_o);function _o(){return null!==go&&go.apply(this,arguments)||this}i.Shading=yo;var bo,vo="Table",Oo=(bo=OfficeExtension.ClientObject,__extends(Co,bo),Object.defineProperty(Co.prototype,"_className",{get:function(){return"Table"},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","isUniform","nestingLevel","values","style","rowCount","headerRowCount","styleTotalRow","styleFirstColumn","styleLastColumn","styleBandedRows","styleBandedColumns","shadingColor","horizontalAlignment","verticalAlignment","width","styleBuiltIn","alignment"]},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","IsUniform","NestingLevel","Values","Style","RowCount","HeaderRowCount","StyleTotalRow","StyleFirstColumn","StyleLastColumn","StyleBandedRows","StyleBandedColumns","ShadingColor","HorizontalAlignment","VerticalAlignment","Width","StyleBuiltIn","Alignment"]},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!1,!0,!0,!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"_navigationPropertyNames",{get:function(){return["rows","tables","parentTableCell","parentTable","font","parentContentControl","parentBody","parentTableCellOrNullObject","parentTableOrNullObject","parentContentControlOrNullObject","footnotes","endnotes","fields"]},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"endnotes",{get:function(){return b("Table.endnotes",u,"1.5",l),this._E||(this._E=t(i.NoteItemCollection,this,"Endnotes",!0,4)),this._E},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"fields",{get:function(){return b("Table.fields",u,"1.4",l),this._F||(this._F=t(i.FieldCollection,this,"Fields",!0,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"font",{get:function(){return this._Fo||(this._Fo=t(i.Font,this,"Font",!1,4)),this._Fo},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"footnotes",{get:function(){return b("Table.footnotes",u,"1.5",l),this._Foo||(this._Foo=t(i.NoteItemCollection,this,"Footnotes",!0,4)),this._Foo},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"parentBody",{get:function(){return this._P||(this._P=t(i.Body,this,"ParentBody",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"parentContentControl",{get:function(){return this._Pa||(this._Pa=t(i.ContentControl,this,"ParentContentControl",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"parentContentControlOrNullObject",{get:function(){return this._Par||(this._Par=t(i.ContentControl,this,"ParentContentControlOrNullObject",!1,4)),this._Par},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"parentTable",{get:function(){return this._Pare||(this._Pare=t(i.Table,this,"ParentTable",!1,4)),this._Pare},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"parentTableCell",{get:function(){return this._Paren||(this._Paren=t(i.TableCell,this,"ParentTableCell",!1,4)),this._Paren},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"parentTableCellOrNullObject",{get:function(){return this._Parent||(this._Parent=t(i.TableCell,this,"ParentTableCellOrNullObject",!1,4)),this._Parent},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"parentTableOrNullObject",{get:function(){return this._ParentT||(this._ParentT=t(i.Table,this,"ParentTableOrNullObject",!1,4)),this._ParentT},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"rows",{get:function(){return this._Ro||(this._Ro=t(i.TableRowCollection,this,"Rows",!0,4)),this._Ro},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"tables",{get:function(){return this._T||(this._T=t(i.TableCollection,this,"Tables",!0,4)),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"alignment",{get:function(){return _("alignment",this._A,vo,this._isNull),this._A},set:function(e){this._A=e,g(this,"Alignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"headerRowCount",{get:function(){return _("headerRowCount",this._H,vo,this._isNull),this._H},set:function(e){this._H=e,g(this,"HeaderRowCount",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"horizontalAlignment",{get:function(){return _("horizontalAlignment",this._Ho,vo,this._isNull),this._Ho},set:function(e){this._Ho=e,g(this,"HorizontalAlignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"isUniform",{get:function(){return _("isUniform",this._I,vo,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"nestingLevel",{get:function(){return _("nestingLevel",this._N,vo,this._isNull),this._N},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"rowCount",{get:function(){return _("rowCount",this._R,vo,this._isNull),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"shadingColor",{get:function(){return _("shadingColor",this._S,vo,this._isNull),this._S},set:function(e){this._S=e,g(this,"ShadingColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"style",{get:function(){return _("style",this._St,vo,this._isNull),this._St},set:function(e){this._St=e,g(this,"Style",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"styleBandedColumns",{get:function(){return _("styleBandedColumns",this._Sty,vo,this._isNull),this._Sty},set:function(e){this._Sty=e,g(this,"StyleBandedColumns",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"styleBandedRows",{get:function(){return _("styleBandedRows",this._Styl,vo,this._isNull),this._Styl},set:function(e){this._Styl=e,g(this,"StyleBandedRows",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"styleBuiltIn",{get:function(){return _("styleBuiltIn",this._Style,vo,this._isNull),this._Style},set:function(e){this._Style=e,g(this,"StyleBuiltIn",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"styleFirstColumn",{get:function(){return _("styleFirstColumn",this._StyleF,vo,this._isNull),this._StyleF},set:function(e){this._StyleF=e,g(this,"StyleFirstColumn",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"styleLastColumn",{get:function(){return _("styleLastColumn",this._StyleL,vo,this._isNull),this._StyleL},set:function(e){this._StyleL=e,g(this,"StyleLastColumn",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"styleTotalRow",{get:function(){return _("styleTotalRow",this._StyleT,vo,this._isNull),this._StyleT},set:function(e){this._StyleT=e,g(this,"StyleTotalRow",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"values",{get:function(){return _("values",this._V,vo,this._isNull),this._V},set:function(e){this._V=e,g(this,"Values",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"verticalAlignment",{get:function(){return _("verticalAlignment",this._Ve,vo,this._isNull),this._Ve},set:function(e){this._Ve=e,g(this,"VerticalAlignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"width",{get:function(){return _("width",this._W,vo,this._isNull),this._W},set:function(e){this._W=e,g(this,"Width",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"_Id",{get:function(){return _("_Id",this.__I,vo,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Co.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,vo,this._isNull),this.__R},enumerable:!0,configurable:!0}),Co.prototype.set=function(e,t){this._recursivelySet(e,t,["values","style","headerRowCount","styleTotalRow","styleFirstColumn","styleLastColumn","styleBandedRows","styleBandedColumns","shadingColor","horizontalAlignment","verticalAlignment","width","styleBuiltIn","alignment"],["font"],["endnotes","fields","footnotes","parentBody","parentContentControl","parentContentControlOrNullObject","parentTable","parentTableCell","parentTableCellOrNullObject","parentTableOrNullObject","rows","tables"])},Co.prototype.update=function(e){this._recursivelyUpdate(e)},Co.prototype.addColumns=function(e,t,n){d(this,"AddColumns",0,[e,t,n],0,0)},Co.prototype.addRows=function(e,t,n){return p(i.TableRowCollection,this,"AddRows",0,[e,t,n],!0,!1,null,0)},Co.prototype.autoFitWindow=function(){d(this,"AutoFitWindow",0,[],0,0)},Co.prototype.clear=function(){d(this,"Clear",0,[],0,0)},Co.prototype.delete=function(){d(this,"Delete",0,[],0,0)},Co.prototype.deleteColumns=function(e,t){d(this,"DeleteColumns",0,[e,t],0,0)},Co.prototype.deleteRows=function(e,t){d(this,"DeleteRows",0,[e,t],0,0)},Co.prototype.distributeColumns=function(){d(this,"DistributeColumns",0,[],0,0)},Co.prototype.getBorder=function(e){return p(i.TableBorder,this,"GetBorder",1,[e],!1,!1,null,4)},Co.prototype.getCell=function(e,t){return p(i.TableCell,this,"GetCell",1,[e,t],!1,!1,null,4)},Co.prototype.getCellOrNullObject=function(e,t){return p(i.TableCell,this,"GetCellOrNullObject",1,[e,t],!1,!1,null,4)},Co.prototype.getCellPadding=function(e){return d(this,"GetCellPadding",1,[e],4,0)},Co.prototype.getNext=function(){return p(i.Table,this,"GetNext",1,[],!1,!1,null,4)},Co.prototype.getNextOrNullObject=function(){return p(i.Table,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},Co.prototype.getParagraphAfter=function(){return p(i.Paragraph,this,"GetParagraphAfter",1,[],!1,!1,null,4)},Co.prototype.getParagraphAfterOrNullObject=function(){return p(i.Paragraph,this,"GetParagraphAfterOrNullObject",1,[],!1,!1,null,4)},Co.prototype.getParagraphBefore=function(){return p(i.Paragraph,this,"GetParagraphBefore",1,[],!1,!1,null,4)},Co.prototype.getParagraphBeforeOrNullObject=function(){return p(i.Paragraph,this,"GetParagraphBeforeOrNullObject",1,[],!1,!1,null,4)},Co.prototype.getRange=function(e){return p(i.Range,this,"GetRange",1,[e],!1,!1,null,4)},Co.prototype.insertContentControl=function(){return p(i.ContentControl,this,"InsertContentControl",0,[],!1,!0,null,0)},Co.prototype.insertParagraph=function(e,t){return p(i.Paragraph,this,"InsertParagraph",0,[e,t],!1,!0,null,0)},Co.prototype.insertTable=function(e,t,n,r){return p(i.Table,this,"InsertTable",0,[e,t,n,r],!1,!0,null,0)},Co.prototype.mergeCells=function(e,t,n,r){return b("Table.mergeCells",u,"1.4",l),p(i.TableCell,this,"MergeCells",0,[e,t,n,r],!1,!0,null,0)},Co.prototype.search=function(e,t){var n=K.Table_Search(this,e,t),r=n.handled,o=n.result;return r?o:p(i.RangeCollection,this,"Search",1,[e,t],!0,!1,null,4)},Co.prototype.select=function(e){d(this,"Select",1,[e],4,0)},Co.prototype.setCellPadding=function(e,t){d(this,"SetCellPadding",0,[e,t],0,0)},Co.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Co.prototype._Search2=function(e,t){return p(i.RangeCollection,this,"_Search2",1,[e,t],!0,!1,null,4)},Co.prototype._handleResult=function(e){if(bo.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Alignment)||(this._A=t.Alignment),y(t.HeaderRowCount)||(this._H=t.HeaderRowCount),y(t.HorizontalAlignment)||(this._Ho=t.HorizontalAlignment),y(t.IsUniform)||(this._I=t.IsUniform),y(t.NestingLevel)||(this._N=t.NestingLevel),y(t.RowCount)||(this._R=t.RowCount),y(t.ShadingColor)||(this._S=t.ShadingColor),y(t.Style)||(this._St=t.Style),y(t.StyleBandedColumns)||(this._Sty=t.StyleBandedColumns),y(t.StyleBandedRows)||(this._Styl=t.StyleBandedRows),y(t.StyleBuiltIn)||(this._Style=t.StyleBuiltIn),y(t.StyleFirstColumn)||(this._StyleF=t.StyleFirstColumn),y(t.StyleLastColumn)||(this._StyleL=t.StyleLastColumn),y(t.StyleTotalRow)||(this._StyleT=t.StyleTotalRow),y(t.Values)||(this._V=t.Values),y(t.VerticalAlignment)||(this._Ve=t.VerticalAlignment),y(t.Width)||(this._W=t.Width),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["endnotes","Endnotes","fields","Fields","font","Font","footnotes","Footnotes","parentBody","ParentBody","parentContentControl","ParentContentControl","parentContentControlOrNullObject","ParentContentControlOrNullObject","parentTable","ParentTable","parentTableCell","ParentTableCell","parentTableCellOrNullObject","ParentTableCellOrNullObject","parentTableOrNullObject","ParentTableOrNullObject","rows","Rows","tables","Tables"])}},Co.prototype.load=function(e){return v(this,e)},Co.prototype.retrieve=function(e){return O(this,e)},Co.prototype._handleIdResult=function(e){bo.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Co.prototype._handleRetrieveResult=function(e,t){bo.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Co.prototype.track=function(){return this.context.trackedObjects.add(this),this},Co.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Co.prototype.toJSON=function(){return C(this,{alignment:this._A,headerRowCount:this._H,horizontalAlignment:this._Ho,isUniform:this._I,nestingLevel:this._N,rowCount:this._R,shadingColor:this._S,style:this._St,styleBandedColumns:this._Sty,styleBandedRows:this._Styl,styleBuiltIn:this._Style,styleFirstColumn:this._StyleF,styleLastColumn:this._StyleL,styleTotalRow:this._StyleT,values:this._V,verticalAlignment:this._Ve,width:this._W},{fields:this._F,font:this._Fo,rows:this._Ro,tables:this._T})},Co.prototype.setMockData=function(e){R(this,e)},Co.prototype.ensureUnchanged=function(e){h(this,e)},Co);function Co(){return null!==bo&&bo.apply(this,arguments)||this}i.Table=Oo,(K=i._CC||(i._CC={})).Table_Search=function(e,t,n){var r;if(s()){var o=c(n);r=e._Search2(t,o)}else n=a(e.context,n),r=p(i.RangeCollection,e,"Search",1,[t,n],!0,!1,null,4);return{handled:!0,result:r}};var Po,So="TableStyle",Ao=(Po=OfficeExtension.ClientObject,__extends(Io,Po),Object.defineProperty(Io.prototype,"_className",{get:function(){return"TableStyle"},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","allowBreakAcrossPage","alignment","bottomCellMargin","leftCellMargin","rightCellMargin","topCellMargin","cellSpacing"]},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","AllowBreakAcrossPage","Alignment","BottomCellMargin","LeftCellMargin","RightCellMargin","TopCellMargin","CellSpacing"]},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"alignment",{get:function(){return _("alignment",this._A,So,this._isNull),b("TableStyle.alignment","WordApiDesktop","1.1",l),this._A},set:function(e){this._A=e,g(this,"Alignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"allowBreakAcrossPage",{get:function(){return _("allowBreakAcrossPage",this._Al,So,this._isNull),b("TableStyle.allowBreakAcrossPage","WordApiDesktop","1.1",l),this._Al},set:function(e){this._Al=e,g(this,"AllowBreakAcrossPage",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"bottomCellMargin",{get:function(){return _("bottomCellMargin",this._B,So,this._isNull),this._B},set:function(e){this._B=e,g(this,"BottomCellMargin",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"cellSpacing",{get:function(){return _("cellSpacing",this._C,So,this._isNull),this._C},set:function(e){this._C=e,g(this,"CellSpacing",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"leftCellMargin",{get:function(){return _("leftCellMargin",this._L,So,this._isNull),this._L},set:function(e){this._L=e,g(this,"LeftCellMargin",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"rightCellMargin",{get:function(){return _("rightCellMargin",this._R,So,this._isNull),this._R},set:function(e){this._R=e,g(this,"RightCellMargin",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"topCellMargin",{get:function(){return _("topCellMargin",this._T,So,this._isNull),this._T},set:function(e){this._T=e,g(this,"TopCellMargin",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Io.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,So,this._isNull),this.__R},enumerable:!0,configurable:!0}),Io.prototype.set=function(e,t){this._recursivelySet(e,t,["allowBreakAcrossPage","alignment","bottomCellMargin","leftCellMargin","rightCellMargin","topCellMargin","cellSpacing"],[],[])},Io.prototype.update=function(e){this._recursivelyUpdate(e)},Io.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Io.prototype._handleResult=function(e){if(Po.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Alignment)||(this._A=t.Alignment),y(t.AllowBreakAcrossPage)||(this._Al=t.AllowBreakAcrossPage),y(t.BottomCellMargin)||(this._B=t.BottomCellMargin),y(t.CellSpacing)||(this._C=t.CellSpacing),y(t.LeftCellMargin)||(this._L=t.LeftCellMargin),y(t.RightCellMargin)||(this._R=t.RightCellMargin),y(t.TopCellMargin)||(this._T=t.TopCellMargin),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Io.prototype.load=function(e){return v(this,e)},Io.prototype.retrieve=function(e){return O(this,e)},Io.prototype._handleIdResult=function(e){Po.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Io.prototype._handleRetrieveResult=function(e,t){Po.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Io.prototype.track=function(){return this.context.trackedObjects.add(this),this},Io.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Io.prototype.toJSON=function(){return C(this,{alignment:this._A,allowBreakAcrossPage:this._Al,bottomCellMargin:this._B,cellSpacing:this._C,leftCellMargin:this._L,rightCellMargin:this._R,topCellMargin:this._T},{})},Io.prototype.setMockData=function(e){R(this,e)},Io.prototype.ensureUnchanged=function(e){h(this,e)},Io);function Io(){return null!==Po&&Po.apply(this,arguments)||this}i.TableStyle=Ao;var Ro,To="TableCollection",Eo=(Ro=OfficeExtension.ClientObject,__extends(No,Ro),Object.defineProperty(No.prototype,"_className",{get:function(){return"TableCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(No.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(No.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(No.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(No.prototype,"items",{get:function(){return _("items",this.m__items,To,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(No.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,To,this._isNull),this.__R},enumerable:!0,configurable:!0}),No.prototype.getFirst=function(){return p(i.Table,this,"GetFirst",1,[],!1,!1,null,4)},No.prototype.getFirstOrNullObject=function(){return p(i.Table,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},No.prototype._GetItem=function(e){return r(i.Table,this,[e])},No.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},No.prototype._handleResult=function(e){if(Ro.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Table,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},No.prototype.load=function(e){return v(this,e)},No.prototype.retrieve=function(e){return O(this,e)},No.prototype._handleIdResult=function(e){Ro.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},No.prototype._handleRetrieveResult=function(e,t){var n=this;Ro.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Table,!0,n,e,t)})},No.prototype.track=function(){return this.context.trackedObjects.add(this),this},No.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},No.prototype.toJSON=function(){return C(this,{},{},this.m__items)},No.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Table,!0,n,e,t)},function(e){return n.m__items=e})},No);function No(){return null!==Ro&&Ro.apply(this,arguments)||this}i.TableCollection=Eo;var Do,xo="TableRow",wo=(Do=OfficeExtension.ClientObject,__extends(Fo,Do),Object.defineProperty(Fo.prototype,"_className",{get:function(){return"TableRow"},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","cellCount","rowIndex","values","shadingColor","horizontalAlignment","verticalAlignment","isHeader","preferredHeight"]},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","CellCount","RowIndex","Values","ShadingColor","HorizontalAlignment","VerticalAlignment","IsHeader","PreferredHeight"]},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!1,!0,!0,!0,!0,!1,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"_navigationPropertyNames",{get:function(){return["cells","parentTable","font","footnotes","endnotes","fields"]},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"cells",{get:function(){return this._Ce||(this._Ce=t(i.TableCellCollection,this,"Cells",!0,4)),this._Ce},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"endnotes",{get:function(){return b("TableRow.endnotes",u,"1.5",l),this._E||(this._E=t(i.NoteItemCollection,this,"Endnotes",!0,4)),this._E},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"fields",{get:function(){return b("TableRow.fields",u,"1.4",l),this._F||(this._F=t(i.FieldCollection,this,"Fields",!0,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"font",{get:function(){return this._Fo||(this._Fo=t(i.Font,this,"Font",!1,4)),this._Fo},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"footnotes",{get:function(){return b("TableRow.footnotes",u,"1.5",l),this._Foo||(this._Foo=t(i.NoteItemCollection,this,"Footnotes",!0,4)),this._Foo},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"parentTable",{get:function(){return this._P||(this._P=t(i.Table,this,"ParentTable",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"cellCount",{get:function(){return _("cellCount",this._C,xo,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"horizontalAlignment",{get:function(){return _("horizontalAlignment",this._H,xo,this._isNull),this._H},set:function(e){this._H=e,g(this,"HorizontalAlignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"isHeader",{get:function(){return _("isHeader",this._I,xo,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"preferredHeight",{get:function(){return _("preferredHeight",this._Pr,xo,this._isNull),this._Pr},set:function(e){this._Pr=e,g(this,"PreferredHeight",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"rowIndex",{get:function(){return _("rowIndex",this._R,xo,this._isNull),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"shadingColor",{get:function(){return _("shadingColor",this._S,xo,this._isNull),this._S},set:function(e){this._S=e,g(this,"ShadingColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"values",{get:function(){return _("values",this._V,xo,this._isNull),this._V},set:function(e){this._V=e,g(this,"Values",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"verticalAlignment",{get:function(){return _("verticalAlignment",this._Ve,xo,this._isNull),this._Ve},set:function(e){this._Ve=e,g(this,"VerticalAlignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"_Id",{get:function(){return _("_Id",this.__I,xo,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Fo.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,xo,this._isNull),this.__R},enumerable:!0,configurable:!0}),Fo.prototype.set=function(e,t){this._recursivelySet(e,t,["values","shadingColor","horizontalAlignment","verticalAlignment","preferredHeight"],["font"],["cells","endnotes","fields","footnotes","parentTable"])},Fo.prototype.update=function(e){this._recursivelyUpdate(e)},Fo.prototype.clear=function(){d(this,"Clear",0,[],0,0)},Fo.prototype.delete=function(){d(this,"Delete",0,[],0,0)},Fo.prototype.getBorder=function(e){return p(i.TableBorder,this,"GetBorder",1,[e],!1,!1,null,4)},Fo.prototype.getCellPadding=function(e){return d(this,"GetCellPadding",1,[e],4,0)},Fo.prototype.getNext=function(){return p(i.TableRow,this,"GetNext",1,[],!1,!1,null,4)},Fo.prototype.getNextOrNullObject=function(){return p(i.TableRow,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},Fo.prototype.insertContentControl=function(){return b("TableRow.insertContentControl","WordApiDesktop","1.1",l),p(i.ContentControl,this,"InsertContentControl",0,[],!1,!1,null,0)},Fo.prototype.insertRows=function(e,t,n){return p(i.TableRowCollection,this,"InsertRows",1,[e,t,n],!0,!1,null,4)},Fo.prototype.merge=function(){return b("TableRow.merge",u,"1.4",l),p(i.TableCell,this,"Merge",0,[],!1,!1,null,0)},Fo.prototype.search=function(e,t){var n=K.TableRow_Search(this,e,t),r=n.handled,o=n.result;return r?o:p(i.RangeCollection,this,"Search",1,[e,t],!0,!1,null,4)},Fo.prototype.select=function(e){d(this,"Select",1,[e],4,0)},Fo.prototype.setCellPadding=function(e,t){d(this,"SetCellPadding",0,[e,t],0,0)},Fo.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Fo.prototype._Search2=function(e,t){return p(i.RangeCollection,this,"_Search2",1,[e,t],!0,!1,null,4)},Fo.prototype._handleResult=function(e){if(Do.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.CellCount)||(this._C=t.CellCount),y(t.HorizontalAlignment)||(this._H=t.HorizontalAlignment),y(t.IsHeader)||(this._I=t.IsHeader),y(t.PreferredHeight)||(this._Pr=t.PreferredHeight),y(t.RowIndex)||(this._R=t.RowIndex),y(t.ShadingColor)||(this._S=t.ShadingColor),y(t.Values)||(this._V=t.Values),y(t.VerticalAlignment)||(this._Ve=t.VerticalAlignment),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["cells","Cells","endnotes","Endnotes","fields","Fields","font","Font","footnotes","Footnotes","parentTable","ParentTable"])}},Fo.prototype.load=function(e){return v(this,e)},Fo.prototype.retrieve=function(e){return O(this,e)},Fo.prototype._handleIdResult=function(e){Do.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Fo.prototype._handleRetrieveResult=function(e,t){Do.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Fo.prototype.track=function(){return this.context.trackedObjects.add(this),this},Fo.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Fo.prototype.toJSON=function(){return C(this,{cellCount:this._C,horizontalAlignment:this._H,isHeader:this._I,preferredHeight:this._Pr,rowIndex:this._R,shadingColor:this._S,values:this._V,verticalAlignment:this._Ve},{cells:this._Ce,fields:this._F,font:this._Fo})},Fo.prototype.setMockData=function(e){R(this,e)},Fo.prototype.ensureUnchanged=function(e){h(this,e)},Fo);function Fo(){return null!==Do&&Do.apply(this,arguments)||this}i.TableRow=wo,(K=i._CC||(i._CC={})).TableRow_Search=function(e,t,n){var r;if(s()){var o=c(n);r=e._Search2(t,o)}else n=a(e.context,n),r=p(i.RangeCollection,e,"Search",1,[t,n],!0,!1,null,4);return{handled:!0,result:r}};var jo,ko="TableRowCollection",Mo=(jo=OfficeExtension.ClientObject,__extends(Ho,jo),Object.defineProperty(Ho.prototype,"_className",{get:function(){return"TableRowCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Ho.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Ho.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ho.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ho.prototype,"items",{get:function(){return _("items",this.m__items,ko,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Ho.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ko,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ho.prototype.getFirst=function(){return p(i.TableRow,this,"GetFirst",1,[],!1,!1,null,4)},Ho.prototype.getFirstOrNullObject=function(){return p(i.TableRow,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Ho.prototype._GetItem=function(e){return r(i.TableRow,this,[e])},Ho.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ho.prototype._handleResult=function(e){if(jo.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.TableRow,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Ho.prototype.load=function(e){return v(this,e)},Ho.prototype.retrieve=function(e){return O(this,e)},Ho.prototype._handleIdResult=function(e){jo.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Ho.prototype._handleRetrieveResult=function(e,t){var n=this;jo.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.TableRow,!0,n,e,t)})},Ho.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ho.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ho.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Ho.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.TableRow,!0,n,e,t)},function(e){return n.m__items=e})},Ho);function Ho(){return null!==jo&&jo.apply(this,arguments)||this}i.TableRowCollection=Mo;var Lo,Uo="TableCell",Bo=(Lo=OfficeExtension.ClientObject,__extends(Wo,Lo),Object.defineProperty(Wo.prototype,"_className",{get:function(){return"TableCell"},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"_scalarPropertyNames",{get:function(){return["_Id","_ReferenceId","rowIndex","cellIndex","value","shadingColor","horizontalAlignment","verticalAlignment","columnWidth","width"]},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_Id","_ReferenceId","RowIndex","CellIndex","Value","ShadingColor","HorizontalAlignment","VerticalAlignment","ColumnWidth","Width"]},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!1,!0,!0,!0,!0,!0,!1]},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"_navigationPropertyNames",{get:function(){return["parentTable","parentRow","body"]},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"body",{get:function(){return this._B||(this._B=t(i.Body,this,"Body",!1,4)),this._B},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"parentRow",{get:function(){return this._P||(this._P=t(i.TableRow,this,"ParentRow",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"parentTable",{get:function(){return this._Pa||(this._Pa=t(i.Table,this,"ParentTable",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"cellIndex",{get:function(){return _("cellIndex",this._C,Uo,this._isNull),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"columnWidth",{get:function(){return _("columnWidth",this._Co,Uo,this._isNull),this._Co},set:function(e){this._Co=e,g(this,"ColumnWidth",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"horizontalAlignment",{get:function(){return _("horizontalAlignment",this._H,Uo,this._isNull),this._H},set:function(e){this._H=e,g(this,"HorizontalAlignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"rowIndex",{get:function(){return _("rowIndex",this._R,Uo,this._isNull),this._R},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"shadingColor",{get:function(){return _("shadingColor",this._S,Uo,this._isNull),this._S},set:function(e){this._S=e,g(this,"ShadingColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"value",{get:function(){return _("value",this._V,Uo,this._isNull),this._V},set:function(e){this._V=e,g(this,"Value",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"verticalAlignment",{get:function(){return _("verticalAlignment",this._Ve,Uo,this._isNull),this._Ve},set:function(e){this._Ve=e,g(this,"VerticalAlignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"width",{get:function(){return _("width",this._W,Uo,this._isNull),this._W},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"_Id",{get:function(){return _("_Id",this.__I,Uo,this._isNull),this.__I},enumerable:!0,configurable:!0}),Object.defineProperty(Wo.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Uo,this._isNull),this.__R},enumerable:!0,configurable:!0}),Wo.prototype.set=function(e,t){this._recursivelySet(e,t,["value","shadingColor","horizontalAlignment","verticalAlignment","columnWidth"],["body"],["parentRow","parentTable"])},Wo.prototype.update=function(e){this._recursivelyUpdate(e)},Wo.prototype.deleteColumn=function(){d(this,"DeleteColumn",0,[],0,0)},Wo.prototype.deleteRow=function(){d(this,"DeleteRow",0,[],0,0)},Wo.prototype.getBorder=function(e){return p(i.TableBorder,this,"GetBorder",1,[e],!1,!1,null,4)},Wo.prototype.getCellPadding=function(e){return d(this,"GetCellPadding",1,[e],4,0)},Wo.prototype.getNext=function(){return p(i.TableCell,this,"GetNext",1,[],!1,!1,null,4)},Wo.prototype.getNextOrNullObject=function(){return p(i.TableCell,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},Wo.prototype.insertColumns=function(e,t,n){d(this,"InsertColumns",0,[e,t,n],0,0)},Wo.prototype.insertRows=function(e,t,n){return p(i.TableRowCollection,this,"InsertRows",0,[e,t,n],!0,!1,null,0)},Wo.prototype.setCellPadding=function(e,t){d(this,"SetCellPadding",0,[e,t],0,0)},Wo.prototype.split=function(e,t){b("TableCell.split",u,"1.4",l),d(this,"Split",0,[e,t],0,0)},Wo.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Wo.prototype._handleResult=function(e){if(Lo.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.CellIndex)||(this._C=t.CellIndex),y(t.ColumnWidth)||(this._Co=t.ColumnWidth),y(t.HorizontalAlignment)||(this._H=t.HorizontalAlignment),y(t.RowIndex)||(this._R=t.RowIndex),y(t.ShadingColor)||(this._S=t.ShadingColor),y(t.Value)||(this._V=t.Value),y(t.VerticalAlignment)||(this._Ve=t.VerticalAlignment),y(t.Width)||(this._W=t.Width),y(t._Id)||(this.__I=t._Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["body","Body","parentRow","ParentRow","parentTable","ParentTable"])}},Wo.prototype.load=function(e){return v(this,e)},Wo.prototype.retrieve=function(e){return O(this,e)},Wo.prototype._handleIdResult=function(e){Lo.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e._Id)||(this.__I=e._Id))},Wo.prototype._handleRetrieveResult=function(e,t){Lo.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Wo.prototype.track=function(){return this.context.trackedObjects.add(this),this},Wo.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Wo.prototype.toJSON=function(){return C(this,{cellIndex:this._C,columnWidth:this._Co,horizontalAlignment:this._H,rowIndex:this._R,shadingColor:this._S,value:this._V,verticalAlignment:this._Ve,width:this._W},{body:this._B})},Wo.prototype.setMockData=function(e){R(this,e)},Wo.prototype.ensureUnchanged=function(e){h(this,e)},Wo);function Wo(){return null!==Lo&&Lo.apply(this,arguments)||this}i.TableCell=Bo;var Go,qo="TableCellCollection",Vo=(Go=OfficeExtension.ClientObject,__extends(zo,Go),Object.defineProperty(zo.prototype,"_className",{get:function(){return"TableCellCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(zo.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(zo.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(zo.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(zo.prototype,"items",{get:function(){return _("items",this.m__items,qo,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(zo.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,qo,this._isNull),this.__R},enumerable:!0,configurable:!0}),zo.prototype.getFirst=function(){return p(i.TableCell,this,"GetFirst",1,[],!1,!1,null,4)},zo.prototype.getFirstOrNullObject=function(){return p(i.TableCell,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},zo.prototype._GetItem=function(e){return r(i.TableCell,this,[e])},zo.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},zo.prototype._handleResult=function(e){if(Go.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.TableCell,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},zo.prototype.load=function(e){return v(this,e)},zo.prototype.retrieve=function(e){return O(this,e)},zo.prototype._handleIdResult=function(e){Go.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},zo.prototype._handleRetrieveResult=function(e,t){var n=this;Go.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.TableCell,!0,n,e,t)})},zo.prototype.track=function(){return this.context.trackedObjects.add(this),this},zo.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},zo.prototype.toJSON=function(){return C(this,{},{},this.m__items)},zo.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.TableCell,!0,n,e,t)},function(e){return n.m__items=e})},zo);function zo(){return null!==Go&&Go.apply(this,arguments)||this}i.TableCellCollection=Vo;var Jo,Ko="TableBorder",Xo=(Jo=OfficeExtension.ClientObject,__extends(Qo,Jo),Object.defineProperty(Qo.prototype,"_className",{get:function(){return"TableBorder"},enumerable:!0,configurable:!0}),Object.defineProperty(Qo.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","color","type","width"]},enumerable:!0,configurable:!0}),Object.defineProperty(Qo.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Color","Type","Width"]},enumerable:!0,configurable:!0}),Object.defineProperty(Qo.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Qo.prototype,"color",{get:function(){return _("color",this._C,Ko,this._isNull),this._C},set:function(e){this._C=e,g(this,"Color",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Qo.prototype,"type",{get:function(){return _("type",this._T,Ko,this._isNull),this._T},set:function(e){this._T=e,g(this,"Type",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Qo.prototype,"width",{get:function(){return _("width",this._W,Ko,this._isNull),this._W},set:function(e){this._W=e,g(this,"Width",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Qo.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Ko,this._isNull),this.__R},enumerable:!0,configurable:!0}),Qo.prototype.set=function(e,t){this._recursivelySet(e,t,["color","type","width"],[],[])},Qo.prototype.update=function(e){this._recursivelyUpdate(e)},Qo.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Qo.prototype._handleResult=function(e){if(Jo.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Color)||(this._C=t.Color),y(t.Type)||(this._T=t.Type),y(t.Width)||(this._W=t.Width),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Qo.prototype.load=function(e){return v(this,e)},Qo.prototype.retrieve=function(e){return O(this,e)},Qo.prototype._handleIdResult=function(e){Jo.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Qo.prototype._handleRetrieveResult=function(e,t){Jo.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Qo.prototype.track=function(){return this.context.trackedObjects.add(this),this},Qo.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Qo.prototype.toJSON=function(){return C(this,{color:this._C,type:this._T,width:this._W},{})},Qo.prototype.setMockData=function(e){R(this,e)},Qo.prototype.ensureUnchanged=function(e){h(this,e)},Qo);function Qo(){return null!==Jo&&Jo.apply(this,arguments)||this}i.TableBorder=Xo;var $o,Zo="TrackedChange",Yo=($o=OfficeExtension.ClientObject,__extends(ei,$o),Object.defineProperty(ei.prototype,"_className",{get:function(){return"TrackedChange"},enumerable:!0,configurable:!0}),Object.defineProperty(ei.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","author","date","text","type"]},enumerable:!0,configurable:!0}),Object.defineProperty(ei.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Author","Date","Text","Type"]},enumerable:!0,configurable:!0}),Object.defineProperty(ei.prototype,"author",{get:function(){return _("author",this._A,Zo,this._isNull),this._A},enumerable:!0,configurable:!0}),Object.defineProperty(ei.prototype,"date",{get:function(){return _("date",this._D,Zo,this._isNull),this._D},enumerable:!0,configurable:!0}),Object.defineProperty(ei.prototype,"text",{get:function(){return _("text",this._T,Zo,this._isNull),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(ei.prototype,"type",{get:function(){return _("type",this._Ty,Zo,this._isNull),this._Ty},enumerable:!0,configurable:!0}),Object.defineProperty(ei.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Zo,this._isNull),this.__R},enumerable:!0,configurable:!0}),ei.prototype.accept=function(){d(this,"Accept",0,[],0,0)},ei.prototype.getNext=function(){return p(i.TrackedChange,this,"GetNext",1,[],!1,!1,null,4)},ei.prototype.getNextOrNullObject=function(){return p(i.TrackedChange,this,"GetNextOrNullObject",1,[],!1,!1,null,4)},ei.prototype.getRange=function(e){return p(i.Range,this,"GetRange",1,[e],!1,!1,null,4)},ei.prototype.reject=function(){d(this,"Reject",0,[],0,0)},ei.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},ei.prototype._handleResult=function(e){if($o.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Author)||(this._A=t.Author),y(t.Date)||(this._D=A(t.Date)),y(t.Text)||(this._T=t.Text),y(t.Type)||(this._Ty=t.Type),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},ei.prototype.load=function(e){return v(this,e)},ei.prototype.retrieve=function(e){return O(this,e)},ei.prototype._handleIdResult=function(e){$o.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},ei.prototype._handleRetrieveResult=function(e,t){if($o.prototype._handleRetrieveResult.call(this,e,t),!m(e)){var n=e;y(n.Date)||(n.date=A(n.date)),I(this,e,t)}},ei.prototype.track=function(){return this.context.trackedObjects.add(this),this},ei.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},ei.prototype.toJSON=function(){return C(this,{author:this._A,date:this._D,text:this._T,type:this._Ty},{})},ei.prototype.setMockData=function(e){R(this,e)},ei.prototype.ensureUnchanged=function(e){h(this,e)},ei);function ei(){return null!==$o&&$o.apply(this,arguments)||this}i.TrackedChange=Yo;var ti,ni="TrackedChangeCollection",ri=(ti=OfficeExtension.ClientObject,__extends(oi,ti),Object.defineProperty(oi.prototype,"_className",{get:function(){return"TrackedChangeCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(oi.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(oi.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(oi.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(oi.prototype,"items",{get:function(){return _("items",this.m__items,ni,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(oi.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ni,this._isNull),this.__R},enumerable:!0,configurable:!0}),oi.prototype.acceptAll=function(){d(this,"AcceptAll",0,[],0,0)},oi.prototype.getFirst=function(){return p(i.TrackedChange,this,"GetFirst",1,[],!1,!1,null,4)},oi.prototype.getFirstOrNullObject=function(){return p(i.TrackedChange,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},oi.prototype.rejectAll=function(){d(this,"RejectAll",0,[],0,0)},oi.prototype._GetItem=function(e){return r(i.TrackedChange,this,[e])},oi.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},oi.prototype._handleResult=function(e){if(ti.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.TrackedChange,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},oi.prototype.load=function(e){return v(this,e)},oi.prototype.retrieve=function(e){return O(this,e)},oi.prototype._handleIdResult=function(e){ti.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},oi.prototype._handleRetrieveResult=function(e,t){var n=this;ti.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.TrackedChange,!0,n,e,t)})},oi.prototype.track=function(){return this.context.trackedObjects.add(this),this},oi.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},oi.prototype.toJSON=function(){return C(this,{},{},this.m__items)},oi.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.TrackedChange,!0,n,e,t)},function(e){return n.m__items=e})},oi);function oi(){return null!==ti&&ti.apply(this,arguments)||this}i.TrackedChangeCollection=ri;var ii,ai="Shape",si=(ii=OfficeExtension.ClientObject,__extends(ci,ii),Object.defineProperty(ci.prototype,"_className",{get:function(){return"Shape"},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","id","type","height","width","left","top","relativeHorizontalPosition","relativeVerticalPosition","geometricShapeType","name","isChild","allowOverlap","leftRelative","topRelative","widthRelative","heightRelative","relativeHorizontalSize","relativeVerticalSize","altTextDescription","rotation","visible","lockAspectRatio"]},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Id","Type","Height","Width","Left","Top","RelativeHorizontalPosition","RelativeVerticalPosition","GeometricShapeType","Name","IsChild","AllowOverlap","LeftRelative","TopRelative","WidthRelative","HeightRelative","RelativeHorizontalSize","RelativeVerticalSize","AltTextDescription","Rotation","Visible","LockAspectRatio"]},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!1,!0,!0,!0,!0,!0,!0,!0,!0,!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"_navigationPropertyNames",{get:function(){return["body","shapeGroup","parentGroup","canvas","parentCanvas","fill","textFrame","textWrap"]},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"body",{get:function(){return this._B||(this._B=t(i.Body,this,"Body",!1,4)),this._B},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"canvas",{get:function(){return this._C||(this._C=t(i.Canvas,this,"Canvas",!1,4)),this._C},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"fill",{get:function(){return this._F||(this._F=t(i.ShapeFill,this,"Fill",!1,4)),this._F},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"parentCanvas",{get:function(){return this._P||(this._P=t(i.Shape,this,"ParentCanvas",!1,4)),this._P},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"parentGroup",{get:function(){return this._Pa||(this._Pa=t(i.Shape,this,"ParentGroup",!1,4)),this._Pa},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"shapeGroup",{get:function(){return this._S||(this._S=t(i.ShapeGroup,this,"ShapeGroup",!1,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"textFrame",{get:function(){return this._T||(this._T=t(i.TextFrame,this,"TextFrame",!1,4)),this._T},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"textWrap",{get:function(){return this._Te||(this._Te=t(i.ShapeTextWrap,this,"TextWrap",!1,4)),this._Te},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"allowOverlap",{get:function(){return _("allowOverlap",this._A,ai,this._isNull),this._A},set:function(e){this._A=e,g(this,"AllowOverlap",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"altTextDescription",{get:function(){return _("altTextDescription",this._Al,ai,this._isNull),this._Al},set:function(e){this._Al=e,g(this,"AltTextDescription",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"geometricShapeType",{get:function(){return _("geometricShapeType",this._G,ai,this._isNull),this._G},set:function(e){this._G=e,g(this,"GeometricShapeType",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"height",{get:function(){return _("height",this._H,ai,this._isNull),this._H},set:function(e){this._H=e,g(this,"Height",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"heightRelative",{get:function(){return _("heightRelative",this._He,ai,this._isNull),this._He},set:function(e){this._He=e,g(this,"HeightRelative",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"id",{get:function(){return _("id",this._I,ai,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"isChild",{get:function(){return _("isChild",this._Is,ai,this._isNull),this._Is},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"left",{get:function(){return _("left",this._L,ai,this._isNull),this._L},set:function(e){this._L=e,g(this,"Left",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"leftRelative",{get:function(){return _("leftRelative",this._Le,ai,this._isNull),this._Le},set:function(e){this._Le=e,g(this,"LeftRelative",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"lockAspectRatio",{get:function(){return _("lockAspectRatio",this._Lo,ai,this._isNull),this._Lo},set:function(e){this._Lo=e,g(this,"LockAspectRatio",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"name",{get:function(){return _("name",this._N,ai,this._isNull),this._N},set:function(e){this._N=e,g(this,"Name",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"relativeHorizontalPosition",{get:function(){return _("relativeHorizontalPosition",this._R,ai,this._isNull),this._R},set:function(e){this._R=e,g(this,"RelativeHorizontalPosition",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"relativeHorizontalSize",{get:function(){return _("relativeHorizontalSize",this._Re,ai,this._isNull),this._Re},set:function(e){this._Re=e,g(this,"RelativeHorizontalSize",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"relativeVerticalPosition",{get:function(){return _("relativeVerticalPosition",this._Rel,ai,this._isNull),this._Rel},set:function(e){this._Rel=e,g(this,"RelativeVerticalPosition",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"relativeVerticalSize",{get:function(){return _("relativeVerticalSize",this._Rela,ai,this._isNull),this._Rela},set:function(e){this._Rela=e,g(this,"RelativeVerticalSize",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"rotation",{get:function(){return _("rotation",this._Ro,ai,this._isNull),this._Ro},set:function(e){this._Ro=e,g(this,"Rotation",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"top",{get:function(){return _("top",this._To,ai,this._isNull),this._To},set:function(e){this._To=e,g(this,"Top",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"topRelative",{get:function(){return _("topRelative",this._Top,ai,this._isNull),this._Top},set:function(e){this._Top=e,g(this,"TopRelative",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"type",{get:function(){return _("type",this._Ty,ai,this._isNull),this._Ty},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"visible",{get:function(){return _("visible",this._V,ai,this._isNull),this._V},set:function(e){this._V=e,g(this,"Visible",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"width",{get:function(){return _("width",this._W,ai,this._isNull),this._W},set:function(e){this._W=e,g(this,"Width",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"widthRelative",{get:function(){return _("widthRelative",this._Wi,ai,this._isNull),this._Wi},set:function(e){this._Wi=e,g(this,"WidthRelative",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ci.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,ai,this._isNull),this.__R},enumerable:!0,configurable:!0}),ci.prototype.set=function(e,t){this._recursivelySet(e,t,["height","width","left","top","relativeHorizontalPosition","relativeVerticalPosition","geometricShapeType","name","allowOverlap","leftRelative","topRelative","widthRelative","heightRelative","relativeHorizontalSize","relativeVerticalSize","altTextDescription","rotation","visible","lockAspectRatio"],["body","shapeGroup","parentGroup","canvas","parentCanvas","fill","textFrame","textWrap"],[])},ci.prototype.update=function(e){this._recursivelyUpdate(e)},ci.prototype.delete=function(){d(this,"Delete",0,[],0,0)},ci.prototype.moveHorizontally=function(e){d(this,"MoveHorizontally",0,[e],0,0)},ci.prototype.moveVertically=function(e){d(this,"MoveVertically",0,[e],0,0)},ci.prototype.scaleHeight=function(e,t,n){d(this,"ScaleHeight",0,[e,t,n],0,0)},ci.prototype.scaleWidth=function(e,t,n){d(this,"ScaleWidth",0,[e,t,n],0,0)},ci.prototype.select=function(e){d(this,"Select",1,[e],4,0)},ci.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},ci.prototype._handleResult=function(e){if(ii.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.AllowOverlap)||(this._A=t.AllowOverlap),y(t.AltTextDescription)||(this._Al=t.AltTextDescription),y(t.GeometricShapeType)||(this._G=t.GeometricShapeType),y(t.Height)||(this._H=t.Height),y(t.HeightRelative)||(this._He=t.HeightRelative),y(t.Id)||(this._I=t.Id),y(t.IsChild)||(this._Is=t.IsChild),y(t.Left)||(this._L=t.Left),y(t.LeftRelative)||(this._Le=t.LeftRelative),y(t.LockAspectRatio)||(this._Lo=t.LockAspectRatio),y(t.Name)||(this._N=t.Name),y(t.RelativeHorizontalPosition)||(this._R=t.RelativeHorizontalPosition),y(t.RelativeHorizontalSize)||(this._Re=t.RelativeHorizontalSize),y(t.RelativeVerticalPosition)||(this._Rel=t.RelativeVerticalPosition),y(t.RelativeVerticalSize)||(this._Rela=t.RelativeVerticalSize),y(t.Rotation)||(this._Ro=t.Rotation),y(t.Top)||(this._To=t.Top),y(t.TopRelative)||(this._Top=t.TopRelative),y(t.Type)||(this._Ty=t.Type),y(t.Visible)||(this._V=t.Visible),y(t.Width)||(this._W=t.Width),y(t.WidthRelative)||(this._Wi=t.WidthRelative),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["body","Body","canvas","Canvas","fill","Fill","parentCanvas","ParentCanvas","parentGroup","ParentGroup","shapeGroup","ShapeGroup","textFrame","TextFrame","textWrap","TextWrap"])}},ci.prototype.load=function(e){return v(this,e)},ci.prototype.retrieve=function(e){return O(this,e)},ci.prototype._handleIdResult=function(e){ii.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},ci.prototype._handleRetrieveResult=function(e,t){ii.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},ci.prototype.track=function(){return this.context.trackedObjects.add(this),this},ci.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},ci.prototype.toJSON=function(){return C(this,{allowOverlap:this._A,altTextDescription:this._Al,geometricShapeType:this._G,height:this._H,heightRelative:this._He,id:this._I,isChild:this._Is,left:this._L,leftRelative:this._Le,lockAspectRatio:this._Lo,name:this._N,relativeHorizontalPosition:this._R,relativeHorizontalSize:this._Re,relativeVerticalPosition:this._Rel,relativeVerticalSize:this._Rela,rotation:this._Ro,top:this._To,topRelative:this._Top,type:this._Ty,visible:this._V,width:this._W,widthRelative:this._Wi},{body:this._B,canvas:this._C,fill:this._F,parentCanvas:this._P,parentGroup:this._Pa,shapeGroup:this._S,textFrame:this._T,textWrap:this._Te})},ci.prototype.setMockData=function(e){R(this,e)},ci.prototype.ensureUnchanged=function(e){h(this,e)},ci);function ci(){return null!==ii&&ii.apply(this,arguments)||this}i.Shape=si;function li(){}i.ShapeCustom=li,OfficeExtension.Utility.applyMixin(si,li);var ui,pi="ShapeGroup",fi=(ui=OfficeExtension.ClientObject,__extends(di,ui),Object.defineProperty(di.prototype,"_className",{get:function(){return"ShapeGroup"},enumerable:!0,configurable:!0}),Object.defineProperty(di.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","id"]},enumerable:!0,configurable:!0}),Object.defineProperty(di.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Id"]},enumerable:!0,configurable:!0}),Object.defineProperty(di.prototype,"_navigationPropertyNames",{get:function(){return["shape","shapes"]},enumerable:!0,configurable:!0}),Object.defineProperty(di.prototype,"shape",{get:function(){return this._S||(this._S=t(i.Shape,this,"Shape",!1,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(di.prototype,"shapes",{get:function(){return this._Sh||(this._Sh=t(i.ShapeCollection,this,"Shapes",!0,4)),this._Sh},enumerable:!0,configurable:!0}),Object.defineProperty(di.prototype,"id",{get:function(){return _("id",this._I,pi,this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(di.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,pi,this._isNull),this.__R},enumerable:!0,configurable:!0}),di.prototype.set=function(e,t){this._recursivelySet(e,t,[],["shape"],["shapes"])},di.prototype.update=function(e){this._recursivelyUpdate(e)},di.prototype.ungroup=function(){return p(i.ShapeCollection,this,"Ungroup",1,[],!0,!1,null,4)},di.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},di.prototype._handleResult=function(e){if(ui.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Id)||(this._I=t.Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["shape","Shape","shapes","Shapes"])}},di.prototype.load=function(e){return v(this,e)},di.prototype.retrieve=function(e){return O(this,e)},di.prototype._handleIdResult=function(e){ui.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},di.prototype._handleRetrieveResult=function(e,t){ui.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},di.prototype.track=function(){return this.context.trackedObjects.add(this),this},di.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},di.prototype.toJSON=function(){return C(this,{id:this._I},{shape:this._S,shapes:this._Sh})},di.prototype.setMockData=function(e){R(this,e)},di.prototype.ensureUnchanged=function(e){h(this,e)},di);function di(){return null!==ui&&ui.apply(this,arguments)||this}i.ShapeGroup=fi;function hi(){}i.ShapeGroupCustom=hi,OfficeExtension.Utility.applyMixin(fi,hi);var gi,mi=(gi=OfficeExtension.ClientObject,__extends(yi,gi),Object.defineProperty(yi.prototype,"_className",{get:function(){return"Canvas"},enumerable:!0,configurable:!0}),Object.defineProperty(yi.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","id"]},enumerable:!0,configurable:!0}),Object.defineProperty(yi.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Id"]},enumerable:!0,configurable:!0}),Object.defineProperty(yi.prototype,"_navigationPropertyNames",{get:function(){return["shape","shapes"]},enumerable:!0,configurable:!0}),Object.defineProperty(yi.prototype,"shape",{get:function(){return this._S||(this._S=t(i.Shape,this,"Shape",!1,4)),this._S},enumerable:!0,configurable:!0}),Object.defineProperty(yi.prototype,"shapes",{get:function(){return this._Sh||(this._Sh=t(i.ShapeCollection,this,"Shapes",!0,4)),this._Sh},enumerable:!0,configurable:!0}),Object.defineProperty(yi.prototype,"id",{get:function(){return _("id",this._I,"Canvas",this._isNull),this._I},enumerable:!0,configurable:!0}),Object.defineProperty(yi.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,"Canvas",this._isNull),this.__R},enumerable:!0,configurable:!0}),yi.prototype.set=function(e,t){this._recursivelySet(e,t,[],["shape"],["shapes"])},yi.prototype.update=function(e){this._recursivelyUpdate(e)},yi.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},yi.prototype._handleResult=function(e){if(gi.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.Id)||(this._I=t.Id),y(t._ReferenceId)||(this.__R=t._ReferenceId),S(this,t,["shape","Shape","shapes","Shapes"])}},yi.prototype.load=function(e){return v(this,e)},yi.prototype.retrieve=function(e){return O(this,e)},yi.prototype._handleIdResult=function(e){gi.prototype._handleIdResult.call(this,e),m(e)||(y(e._ReferenceId)||(this.__R=e._ReferenceId),y(e.Id)||(this._I=e.Id))},yi.prototype._handleRetrieveResult=function(e,t){gi.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},yi.prototype.track=function(){return this.context.trackedObjects.add(this),this},yi.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},yi.prototype.toJSON=function(){return C(this,{id:this._I},{shape:this._S,shapes:this._Sh})},yi.prototype.setMockData=function(e){R(this,e)},yi.prototype.ensureUnchanged=function(e){h(this,e)},yi);function yi(){return null!==gi&&gi.apply(this,arguments)||this}i.Canvas=mi;function _i(){}i.CanvasCustom=_i,OfficeExtension.Utility.applyMixin(mi,_i);var bi,vi="ShapeCollection",Oi=(bi=OfficeExtension.ClientObject,__extends(Ci,bi),Object.defineProperty(Ci.prototype,"_className",{get:function(){return"ShapeCollection"},enumerable:!0,configurable:!0}),Object.defineProperty(Ci.prototype,"_isCollection",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(Ci.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ci.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ci.prototype,"items",{get:function(){return _("items",this.m__items,vi,this._isNull),this.m__items},enumerable:!0,configurable:!0}),Object.defineProperty(Ci.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,vi,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ci.prototype.getByGeometricTypes=function(e){return p(i.ShapeCollection,this,"GetByGeometricTypes",1,[e],!0,!1,null,4)},Ci.prototype.getById=function(e){return p(i.Shape,this,"GetById",1,[e],!1,!1,null,4)},Ci.prototype.getByIdOrNullObject=function(e){return p(i.Shape,this,"GetByIdOrNullObject",1,[e],!1,!1,null,4)},Ci.prototype.getByIds=function(e){return p(i.ShapeCollection,this,"GetByIds",1,[e],!0,!1,null,4)},Ci.prototype.getByNames=function(e){return p(i.ShapeCollection,this,"GetByNames",1,[e],!0,!1,null,4)},Ci.prototype.getByTypes=function(e){return p(i.ShapeCollection,this,"GetByTypes",1,[e],!0,!1,null,4)},Ci.prototype.getFirst=function(){return p(i.Shape,this,"GetFirst",1,[],!1,!1,null,4)},Ci.prototype.getFirstOrNullObject=function(){return p(i.Shape,this,"GetFirstOrNullObject",1,[],!1,!1,null,4)},Ci.prototype.group=function(){return p(i.Shape,this,"Group",0,[],!1,!1,null,0)},Ci.prototype._GetItem=function(e){return r(i.Shape,this,[e])},Ci.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ci.prototype._handleResult=function(e){if(bi.prototype._handleResult.call(this,e),!m(e)){var t=e;if(P(this,t),y(t._ReferenceId)||(this.__R=t._ReferenceId),!m(t[OfficeExtension.Constants.items])){this.m__items=[];for(var n=t[OfficeExtension.Constants.items],r=0;r<n.length;r++){var o=f(i.Shape,!0,this,n[r],r);o._handleResult(n[r]),this.m__items.push(o)}}}},Ci.prototype.load=function(e){return v(this,e)},Ci.prototype.retrieve=function(e){return O(this,e)},Ci.prototype._handleIdResult=function(e){bi.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Ci.prototype._handleRetrieveResult=function(e,t){var n=this;bi.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t,function(e,t){return f(i.Shape,!0,n,e,t)})},Ci.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ci.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ci.prototype.toJSON=function(){return C(this,{},{},this.m__items)},Ci.prototype.setMockData=function(e){var n=this;R(this,e,function(e,t){return f(i.Shape,!0,n,e,t)},function(e){return n.m__items=e})},Ci);function Ci(){return null!==bi&&bi.apply(this,arguments)||this}i.ShapeCollection=Oi;var Pi,Si="ShapeFill",Ai=(Pi=OfficeExtension.ClientObject,__extends(Ii,Pi),Object.defineProperty(Ii.prototype,"_className",{get:function(){return"ShapeFill"},enumerable:!0,configurable:!0}),Object.defineProperty(Ii.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","type","backgroundColor","foregroundColor","transparency"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ii.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Type","BackgroundColor","ForegroundColor","Transparency"]},enumerable:!0,configurable:!0}),Object.defineProperty(Ii.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!1,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Ii.prototype,"backgroundColor",{get:function(){return _("backgroundColor",this._B,Si,this._isNull),this._B},set:function(e){this._B=e,g(this,"BackgroundColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ii.prototype,"foregroundColor",{get:function(){return _("foregroundColor",this._F,Si,this._isNull),this._F},set:function(e){this._F=e,g(this,"ForegroundColor",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ii.prototype,"transparency",{get:function(){return _("transparency",this._T,Si,this._isNull),this._T},set:function(e){this._T=e,g(this,"Transparency",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Ii.prototype,"type",{get:function(){return _("type",this._Ty,Si,this._isNull),this._Ty},enumerable:!0,configurable:!0}),Object.defineProperty(Ii.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Si,this._isNull),this.__R},enumerable:!0,configurable:!0}),Ii.prototype.set=function(e,t){this._recursivelySet(e,t,["backgroundColor","foregroundColor","transparency"],[],[])},Ii.prototype.update=function(e){this._recursivelyUpdate(e)},Ii.prototype.clear=function(){d(this,"Clear",0,[],0,0)},Ii.prototype.setSolidColor=function(e){d(this,"SetSolidColor",0,[e],0,0)},Ii.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Ii.prototype._handleResult=function(e){if(Pi.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.BackgroundColor)||(this._B=t.BackgroundColor),y(t.ForegroundColor)||(this._F=t.ForegroundColor),y(t.Transparency)||(this._T=t.Transparency),y(t.Type)||(this._Ty=t.Type),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Ii.prototype.load=function(e){return v(this,e)},Ii.prototype.retrieve=function(e){return O(this,e)},Ii.prototype._handleIdResult=function(e){Pi.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Ii.prototype._handleRetrieveResult=function(e,t){Pi.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Ii.prototype.track=function(){return this.context.trackedObjects.add(this),this},Ii.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Ii.prototype.toJSON=function(){return C(this,{backgroundColor:this._B,foregroundColor:this._F,transparency:this._T,type:this._Ty},{})},Ii.prototype.setMockData=function(e){R(this,e)},Ii.prototype.ensureUnchanged=function(e){h(this,e)},Ii);function Ii(){return null!==Pi&&Pi.apply(this,arguments)||this}i.ShapeFill=Ai;function Ri(){}i.ShapeFillCustom=Ri,OfficeExtension.Utility.applyMixin(Ai,Ri);var Ti,Ei="TextFrame",Ni=(Ti=OfficeExtension.ClientObject,__extends(Di,Ti),Object.defineProperty(Di.prototype,"_className",{get:function(){return"TextFrame"},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","leftMargin","rightMargin","topMargin","bottomMargin","verticalAlignment","autoSizeSetting","orientation","hasText","noTextRotation","wordWrap"]},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","LeftMargin","RightMargin","TopMargin","BottomMargin","VerticalAlignment","AutoSizeSetting","Orientation","HasText","NoTextRotation","WordWrap"]},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0,!0,!0,!0,!0,!1,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"autoSizeSetting",{get:function(){return _("autoSizeSetting",this._A,Ei,this._isNull),this._A},set:function(e){this._A=e,g(this,"AutoSizeSetting",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"bottomMargin",{get:function(){return _("bottomMargin",this._B,Ei,this._isNull),this._B},set:function(e){this._B=e,g(this,"BottomMargin",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"hasText",{get:function(){return _("hasText",this._H,Ei,this._isNull),this._H},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"leftMargin",{get:function(){return _("leftMargin",this._L,Ei,this._isNull),this._L},set:function(e){this._L=e,g(this,"LeftMargin",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"noTextRotation",{get:function(){return _("noTextRotation",this._N,Ei,this._isNull),this._N},set:function(e){this._N=e,g(this,"NoTextRotation",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"orientation",{get:function(){return _("orientation",this._O,Ei,this._isNull),this._O},set:function(e){this._O=e,g(this,"Orientation",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"rightMargin",{get:function(){return _("rightMargin",this._R,Ei,this._isNull),this._R},set:function(e){this._R=e,g(this,"RightMargin",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"topMargin",{get:function(){return _("topMargin",this._T,Ei,this._isNull),this._T},set:function(e){this._T=e,g(this,"TopMargin",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"verticalAlignment",{get:function(){return _("verticalAlignment",this._V,Ei,this._isNull),this._V},set:function(e){this._V=e,g(this,"VerticalAlignment",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"wordWrap",{get:function(){return _("wordWrap",this._W,Ei,this._isNull),this._W},set:function(e){this._W=e,g(this,"WordWrap",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(Di.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Ei,this._isNull),this.__R},enumerable:!0,configurable:!0}),Di.prototype.set=function(e,t){this._recursivelySet(e,t,["leftMargin","rightMargin","topMargin","bottomMargin","verticalAlignment","autoSizeSetting","orientation","noTextRotation","wordWrap"],[],[])},Di.prototype.update=function(e){this._recursivelyUpdate(e)},Di.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},Di.prototype._handleResult=function(e){if(Ti.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.AutoSizeSetting)||(this._A=t.AutoSizeSetting),y(t.BottomMargin)||(this._B=t.BottomMargin),y(t.HasText)||(this._H=t.HasText),y(t.LeftMargin)||(this._L=t.LeftMargin),y(t.NoTextRotation)||(this._N=t.NoTextRotation),y(t.Orientation)||(this._O=t.Orientation),y(t.RightMargin)||(this._R=t.RightMargin),y(t.TopMargin)||(this._T=t.TopMargin),y(t.VerticalAlignment)||(this._V=t.VerticalAlignment),y(t.WordWrap)||(this._W=t.WordWrap),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},Di.prototype.load=function(e){return v(this,e)},Di.prototype.retrieve=function(e){return O(this,e)},Di.prototype._handleIdResult=function(e){Ti.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},Di.prototype._handleRetrieveResult=function(e,t){Ti.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},Di.prototype.track=function(){return this.context.trackedObjects.add(this),this},Di.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},Di.prototype.toJSON=function(){return C(this,{autoSizeSetting:this._A,bottomMargin:this._B,hasText:this._H,leftMargin:this._L,noTextRotation:this._N,orientation:this._O,rightMargin:this._R,topMargin:this._T,verticalAlignment:this._V,wordWrap:this._W},{})},Di.prototype.setMockData=function(e){R(this,e)},Di.prototype.ensureUnchanged=function(e){h(this,e)},Di);function Di(){return null!==Ti&&Ti.apply(this,arguments)||this}i.TextFrame=Ni;function xi(){}i.TextFrameCustom=xi,OfficeExtension.Utility.applyMixin(Ni,xi);var wi,Fi="ShapeTextWrap",ji=(wi=OfficeExtension.ClientObject,__extends(ki,wi),Object.defineProperty(ki.prototype,"_className",{get:function(){return"ShapeTextWrap"},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"_scalarPropertyNames",{get:function(){return["_ReferenceId","type","leftDistance","rightDistance","topDistance","bottomDistance","side"]},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"_scalarPropertyOriginalNames",{get:function(){return["_ReferenceId","Type","LeftDistance","RightDistance","TopDistance","BottomDistance","Side"]},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"_scalarPropertyUpdateable",{get:function(){return[!1,!0,!0,!0,!0,!0,!0]},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"bottomDistance",{get:function(){return _("bottomDistance",this._B,Fi,this._isNull),this._B},set:function(e){this._B=e,g(this,"BottomDistance",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"leftDistance",{get:function(){return _("leftDistance",this._L,Fi,this._isNull),this._L},set:function(e){this._L=e,g(this,"LeftDistance",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"rightDistance",{get:function(){return _("rightDistance",this._R,Fi,this._isNull),this._R},set:function(e){this._R=e,g(this,"RightDistance",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"side",{get:function(){return _("side",this._S,Fi,this._isNull),this._S},set:function(e){this._S=e,g(this,"Side",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"topDistance",{get:function(){return _("topDistance",this._T,Fi,this._isNull),this._T},set:function(e){this._T=e,g(this,"TopDistance",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"type",{get:function(){return _("type",this._Ty,Fi,this._isNull),this._Ty},set:function(e){this._Ty=e,g(this,"Type",e,0)},enumerable:!0,configurable:!0}),Object.defineProperty(ki.prototype,"_ReferenceId",{get:function(){return _("_ReferenceId",this.__R,Fi,this._isNull),this.__R},enumerable:!0,configurable:!0}),ki.prototype.set=function(e,t){this._recursivelySet(e,t,["type","leftDistance","rightDistance","topDistance","bottomDistance","side"],[],[])},ki.prototype.update=function(e){this._recursivelyUpdate(e)},ki.prototype._KeepReference=function(){d(this,"_KeepReference",1,[],4,0)},ki.prototype._handleResult=function(e){if(wi.prototype._handleResult.call(this,e),!m(e)){var t=e;P(this,t),y(t.BottomDistance)||(this._B=t.BottomDistance),y(t.LeftDistance)||(this._L=t.LeftDistance),y(t.RightDistance)||(this._R=t.RightDistance),y(t.Side)||(this._S=t.Side),y(t.TopDistance)||(this._T=t.TopDistance),y(t.Type)||(this._Ty=t.Type),y(t._ReferenceId)||(this.__R=t._ReferenceId)}},ki.prototype.load=function(e){return v(this,e)},ki.prototype.retrieve=function(e){return O(this,e)},ki.prototype._handleIdResult=function(e){wi.prototype._handleIdResult.call(this,e),m(e)||y(e._ReferenceId)||(this.__R=e._ReferenceId)},ki.prototype._handleRetrieveResult=function(e,t){wi.prototype._handleRetrieveResult.call(this,e,t),I(this,e,t)},ki.prototype.track=function(){return this.context.trackedObjects.add(this),this},ki.prototype.untrack=function(){return this.context.trackedObjects.remove(this),this},ki.prototype.toJSON=function(){return C(this,{bottomDistance:this._B,leftDistance:this._L,rightDistance:this._R,side:this._S,topDistance:this._T,type:this._Ty},{})},ki.prototype.setMockData=function(e){R(this,e)},ki.prototype.ensureUnchanged=function(e){h(this,e)},ki);function ki(){return null!==wi&&wi.apply(this,arguments)||this}i.ShapeTextWrap=ji;function Mi(){}var Hi,Li,Ui,Bi,Wi,Gi,qi,Vi,zi,Ji,Ki,Xi,Qi,$i,Zi,Yi,ea,ta,na,ra,oa,ia,aa,sa,ca,la,ua,pa,fa,da,ha,ga,ma,ya,_a,ba,va,Oa,Ca,Pa,Sa,Aa,Ia,Ra,Ta,Ea,Na,Da,xa,wa,Fa,ja,ka,Ma,Ha,La,Ua,Ba,Wa;i.ShapeTextWrapCustom=Mi,OfficeExtension.Utility.applyMixin(ji,Mi),(Hi=i.ChangeTrackingMode||(i.ChangeTrackingMode={})).off="Off",Hi.trackAll="TrackAll",Hi.trackMineOnly="TrackMineOnly",(Li=i.ChangeTrackingVersion||(i.ChangeTrackingVersion={})).original="Original",Li.current="Current",(Ui=i.ChangeTrackingState||(i.ChangeTrackingState={})).unknown="Unknown",Ui.normal="Normal",Ui.added="Added",Ui.deleted="Deleted",(Bi=i.TrackedChangeType||(i.TrackedChangeType={})).none="None",Bi.added="Added",Bi.deleted="Deleted",Bi.formatted="Formatted",(Wi=i.NoteItemType||(i.NoteItemType={})).footnote="Footnote",Wi.endnote="Endnote",(Gi=i.EventType||(i.EventType={})).contentControlDeleted="ContentControlDeleted",Gi.contentControlSelectionChanged="ContentControlSelectionChanged",Gi.contentControlDataChanged="ContentControlDataChanged",Gi.contentControlAdded="ContentControlAdded",Gi.annotationAdded="AnnotationAdded",Gi.annotationChanged="AnnotationChanged",Gi.annotationDeleted="AnnotationDeleted",Gi.contentControlEntered="ContentControlEntered",Gi.contentControlExited="ContentControlExited",Gi.documentWordCountChanged="DocumentWordCountChanged",Gi.paragraphAdded="ParagraphAdded",Gi.paragraphChanged="ParagraphChanged",Gi.paragraphDeleted="ParagraphDeleted",Gi.annotationClicked="AnnotationClicked",Gi.annotationHovered="AnnotationHovered",Gi.annotationInserted="AnnotationInserted",Gi.annotationRemoved="AnnotationRemoved",Gi.annotationPopupAction="AnnotationPopupAction",(qi=i.EventSource||(i.EventSource={})).local="Local",qi.remote="Remote",(Vi=i.ContentControlType||(i.ContentControlType={})).unknown="Unknown",Vi.richTextInline="RichTextInline",Vi.richTextParagraphs="RichTextParagraphs",Vi.richTextTableCell="RichTextTableCell",Vi.richTextTableRow="RichTextTableRow",Vi.richTextTable="RichTextTable",Vi.plainTextInline="PlainTextInline",Vi.plainTextParagraph="PlainTextParagraph",Vi.picture="Picture",Vi.buildingBlockGallery="BuildingBlockGallery",Vi.checkBox="CheckBox",Vi.comboBox="ComboBox",Vi.dropDownList="DropDownList",Vi.datePicker="DatePicker",Vi.repeatingSection="RepeatingSection",Vi.richText="RichText",Vi.plainText="PlainText",Vi.group="Group",(zi=i.ContentControlAppearance||(i.ContentControlAppearance={})).boundingBox="BoundingBox",zi.tags="Tags",zi.hidden="Hidden",(Ji=i.ContentControlLevel||(i.ContentControlLevel={})).inline="Inline",Ji.paragraph="Paragraph",Ji.row="Row",Ji.cell="Cell",(Ki=i.UnderlineType||(i.UnderlineType={})).mixed="Mixed",Ki.none="None",Ki.hidden="Hidden",Ki.dotLine="DotLine",Ki.single="Single",Ki.word="Word",Ki.double="Double",Ki.thick="Thick",Ki.dotted="Dotted",Ki.dottedHeavy="DottedHeavy",Ki.dashLine="DashLine",Ki.dashLineHeavy="DashLineHeavy",Ki.dashLineLong="DashLineLong",Ki.dashLineLongHeavy="DashLineLongHeavy",Ki.dotDashLine="DotDashLine",Ki.dotDashLineHeavy="DotDashLineHeavy",Ki.twoDotDashLine="TwoDotDashLine",Ki.twoDotDashLineHeavy="TwoDotDashLineHeavy",Ki.wave="Wave",Ki.waveHeavy="WaveHeavy",Ki.waveDouble="WaveDouble",(Xi=i.BreakType||(i.BreakType={})).page="Page",Xi.next="Next",Xi.sectionNext="SectionNext",Xi.sectionContinuous="SectionContinuous",Xi.sectionEven="SectionEven",Xi.sectionOdd="SectionOdd",Xi.line="Line",(Qi=i.InsertLocation||(i.InsertLocation={})).before="Before",Qi.after="After",Qi.start="Start",Qi.end="End",Qi.replace="Replace",($i=i.Alignment||(i.Alignment={})).mixed="Mixed",$i.unknown="Unknown",$i.left="Left",$i.centered="Centered",$i.right="Right",$i.justified="Justified",(Zi=i.HeaderFooterType||(i.HeaderFooterType={})).primary="Primary",Zi.firstPage="FirstPage",Zi.evenPages="EvenPages",(Yi=i.BodyType||(i.BodyType={})).unknown="Unknown",Yi.mainDoc="MainDoc",Yi.section="Section",Yi.header="Header",Yi.footer="Footer",Yi.tableCell="TableCell",Yi.footnote="Footnote",Yi.endnote="Endnote",Yi.noteItem="NoteItem",(ea=i.SelectionMode||(i.SelectionMode={})).select="Select",ea.start="Start",ea.end="End",(ta=i.ImageFormat||(i.ImageFormat={})).unsupported="Unsupported",ta[void 0]="Undefined",ta.bmp="Bmp",ta.jpeg="Jpeg",ta.gif="Gif",ta.tiff="Tiff",ta.png="Png",ta.icon="Icon",ta.exif="Exif",ta.wmf="Wmf",ta.emf="Emf",ta.pict="Pict",ta.pdf="Pdf",ta.svg="Svg",(na=i.RangeLocation||(i.RangeLocation={})).whole="Whole",na.start="Start",na.end="End",na.before="Before",na.after="After",na.content="Content",(ra=i.LocationRelation||(i.LocationRelation={})).unrelated="Unrelated",ra.equal="Equal",ra.containsStart="ContainsStart",ra.containsEnd="ContainsEnd",ra.contains="Contains",ra.insideStart="InsideStart",ra.insideEnd="InsideEnd",ra.inside="Inside",ra.adjacentBefore="AdjacentBefore",ra.overlapsBefore="OverlapsBefore",ra.before="Before",ra.adjacentAfter="AdjacentAfter",ra.overlapsAfter="OverlapsAfter",ra.after="After",(oa=i.BorderLocation||(i.BorderLocation={})).top="Top",oa.left="Left",oa.bottom="Bottom",oa.right="Right",oa.insideHorizontal="InsideHorizontal",oa.insideVertical="InsideVertical",oa.inside="Inside",oa.outside="Outside",oa.all="All",(ia=i.CellPaddingLocation||(i.CellPaddingLocation={})).top="Top",ia.left="Left",ia.bottom="Bottom",ia.right="Right",(aa=i.BorderWidth||(i.BorderWidth={})).none="None",aa.pt025="Pt025",aa.pt050="Pt050",aa.pt075="Pt075",aa.pt100="Pt100",aa.pt150="Pt150",aa.pt225="Pt225",aa.pt300="Pt300",aa.pt450="Pt450",aa.pt600="Pt600",aa.mixed="Mixed",(sa=i.BorderType||(i.BorderType={})).mixed="Mixed",sa.none="None",sa.single="Single",sa.double="Double",sa.dotted="Dotted",sa.dashed="Dashed",sa.dotDashed="DotDashed",sa.dot2Dashed="Dot2Dashed",sa.triple="Triple",sa.thinThickSmall="ThinThickSmall",sa.thickThinSmall="ThickThinSmall",sa.thinThickThinSmall="ThinThickThinSmall",sa.thinThickMed="ThinThickMed",sa.thickThinMed="ThickThinMed",sa.thinThickThinMed="ThinThickThinMed",sa.thinThickLarge="ThinThickLarge",sa.thickThinLarge="ThickThinLarge",sa.thinThickThinLarge="ThinThickThinLarge",sa.wave="Wave",sa.doubleWave="DoubleWave",sa.dashedSmall="DashedSmall",sa.dashDotStroked="DashDotStroked",sa.threeDEmboss="ThreeDEmboss",sa.threeDEngrave="ThreeDEngrave",(ca=i.VerticalAlignment||(i.VerticalAlignment={})).mixed="Mixed",ca.top="Top",ca.center="Center",ca.bottom="Bottom",(la=i.ListLevelType||(i.ListLevelType={})).bullet="Bullet",la.number="Number",la.picture="Picture",(ua=i.ListBullet||(i.ListBullet={})).custom="Custom",ua.solid="Solid",ua.hollow="Hollow",ua.square="Square",ua.diamonds="Diamonds",ua.arrow="Arrow",ua.checkmark="Checkmark",(pa=i.ListNumbering||(i.ListNumbering={})).none="None",pa.arabic="Arabic",pa.upperRoman="UpperRoman",pa.lowerRoman="LowerRoman",pa.upperLetter="UpperLetter",pa.lowerLetter="LowerLetter",(fa=i.BuiltInStyleName||(i.BuiltInStyleName={})).other="Other",fa.normal="Normal",fa.heading1="Heading1",fa.heading2="Heading2",fa.heading3="Heading3",fa.heading4="Heading4",fa.heading5="Heading5",fa.heading6="Heading6",fa.heading7="Heading7",fa.heading8="Heading8",fa.heading9="Heading9",fa.toc1="Toc1",fa.toc2="Toc2",fa.toc3="Toc3",fa.toc4="Toc4",fa.toc5="Toc5",fa.toc6="Toc6",fa.toc7="Toc7",fa.toc8="Toc8",fa.toc9="Toc9",fa.footnoteText="FootnoteText",fa.header="Header",fa.footer="Footer",fa.caption="Caption",fa.footnoteReference="FootnoteReference",fa.endnoteReference="EndnoteReference",fa.endnoteText="EndnoteText",fa.title="Title",fa.subtitle="Subtitle",fa.hyperlink="Hyperlink",fa.strong="Strong",fa.emphasis="Emphasis",fa.noSpacing="NoSpacing",fa.listParagraph="ListParagraph",fa.quote="Quote",fa.intenseQuote="IntenseQuote",fa.subtleEmphasis="SubtleEmphasis",fa.intenseEmphasis="IntenseEmphasis",fa.subtleReference="SubtleReference",fa.intenseReference="IntenseReference",fa.bookTitle="BookTitle",fa.bibliography="Bibliography",fa.tocHeading="TocHeading",fa.tableGrid="TableGrid",fa.plainTable1="PlainTable1",fa.plainTable2="PlainTable2",fa.plainTable3="PlainTable3",fa.plainTable4="PlainTable4",fa.plainTable5="PlainTable5",fa.tableGridLight="TableGridLight",fa.gridTable1Light="GridTable1Light",fa.gridTable1Light_Accent1="GridTable1Light_Accent1",fa.gridTable1Light_Accent2="GridTable1Light_Accent2",fa.gridTable1Light_Accent3="GridTable1Light_Accent3",fa.gridTable1Light_Accent4="GridTable1Light_Accent4",fa.gridTable1Light_Accent5="GridTable1Light_Accent5",fa.gridTable1Light_Accent6="GridTable1Light_Accent6",fa.gridTable2="GridTable2",fa.gridTable2_Accent1="GridTable2_Accent1",fa.gridTable2_Accent2="GridTable2_Accent2",fa.gridTable2_Accent3="GridTable2_Accent3",fa.gridTable2_Accent4="GridTable2_Accent4",fa.gridTable2_Accent5="GridTable2_Accent5",fa.gridTable2_Accent6="GridTable2_Accent6",fa.gridTable3="GridTable3",fa.gridTable3_Accent1="GridTable3_Accent1",fa.gridTable3_Accent2="GridTable3_Accent2",fa.gridTable3_Accent3="GridTable3_Accent3",fa.gridTable3_Accent4="GridTable3_Accent4",fa.gridTable3_Accent5="GridTable3_Accent5",fa.gridTable3_Accent6="GridTable3_Accent6",fa.gridTable4="GridTable4",fa.gridTable4_Accent1="GridTable4_Accent1",fa.gridTable4_Accent2="GridTable4_Accent2",fa.gridTable4_Accent3="GridTable4_Accent3",fa.gridTable4_Accent4="GridTable4_Accent4",fa.gridTable4_Accent5="GridTable4_Accent5",fa.gridTable4_Accent6="GridTable4_Accent6",fa.gridTable5Dark="GridTable5Dark",fa.gridTable5Dark_Accent1="GridTable5Dark_Accent1",fa.gridTable5Dark_Accent2="GridTable5Dark_Accent2",fa.gridTable5Dark_Accent3="GridTable5Dark_Accent3",fa.gridTable5Dark_Accent4="GridTable5Dark_Accent4",fa.gridTable5Dark_Accent5="GridTable5Dark_Accent5",fa.gridTable5Dark_Accent6="GridTable5Dark_Accent6",fa.gridTable6Colorful="GridTable6Colorful",fa.gridTable6Colorful_Accent1="GridTable6Colorful_Accent1",fa.gridTable6Colorful_Accent2="GridTable6Colorful_Accent2",fa.gridTable6Colorful_Accent3="GridTable6Colorful_Accent3",fa.gridTable6Colorful_Accent4="GridTable6Colorful_Accent4",fa.gridTable6Colorful_Accent5="GridTable6Colorful_Accent5",fa.gridTable6Colorful_Accent6="GridTable6Colorful_Accent6",fa.gridTable7Colorful="GridTable7Colorful",fa.gridTable7Colorful_Accent1="GridTable7Colorful_Accent1",fa.gridTable7Colorful_Accent2="GridTable7Colorful_Accent2",fa.gridTable7Colorful_Accent3="GridTable7Colorful_Accent3",fa.gridTable7Colorful_Accent4="GridTable7Colorful_Accent4",fa.gridTable7Colorful_Accent5="GridTable7Colorful_Accent5",fa.gridTable7Colorful_Accent6="GridTable7Colorful_Accent6",fa.listTable1Light="ListTable1Light",fa.listTable1Light_Accent1="ListTable1Light_Accent1",fa.listTable1Light_Accent2="ListTable1Light_Accent2",fa.listTable1Light_Accent3="ListTable1Light_Accent3",fa.listTable1Light_Accent4="ListTable1Light_Accent4",fa.listTable1Light_Accent5="ListTable1Light_Accent5",fa.listTable1Light_Accent6="ListTable1Light_Accent6",fa.listTable2="ListTable2",fa.listTable2_Accent1="ListTable2_Accent1",fa.listTable2_Accent2="ListTable2_Accent2",fa.listTable2_Accent3="ListTable2_Accent3",fa.listTable2_Accent4="ListTable2_Accent4",fa.listTable2_Accent5="ListTable2_Accent5",fa.listTable2_Accent6="ListTable2_Accent6",fa.listTable3="ListTable3",fa.listTable3_Accent1="ListTable3_Accent1",fa.listTable3_Accent2="ListTable3_Accent2",fa.listTable3_Accent3="ListTable3_Accent3",fa.listTable3_Accent4="ListTable3_Accent4",fa.listTable3_Accent5="ListTable3_Accent5",fa.listTable3_Accent6="ListTable3_Accent6",fa.listTable4="ListTable4",fa.listTable4_Accent1="ListTable4_Accent1",fa.listTable4_Accent2="ListTable4_Accent2",fa.listTable4_Accent3="ListTable4_Accent3",fa.listTable4_Accent4="ListTable4_Accent4",fa.listTable4_Accent5="ListTable4_Accent5",fa.listTable4_Accent6="ListTable4_Accent6",fa.listTable5Dark="ListTable5Dark",fa.listTable5Dark_Accent1="ListTable5Dark_Accent1",fa.listTable5Dark_Accent2="ListTable5Dark_Accent2",fa.listTable5Dark_Accent3="ListTable5Dark_Accent3",fa.listTable5Dark_Accent4="ListTable5Dark_Accent4",fa.listTable5Dark_Accent5="ListTable5Dark_Accent5",fa.listTable5Dark_Accent6="ListTable5Dark_Accent6",fa.listTable6Colorful="ListTable6Colorful",fa.listTable6Colorful_Accent1="ListTable6Colorful_Accent1",fa.listTable6Colorful_Accent2="ListTable6Colorful_Accent2",fa.listTable6Colorful_Accent3="ListTable6Colorful_Accent3",fa.listTable6Colorful_Accent4="ListTable6Colorful_Accent4",fa.listTable6Colorful_Accent5="ListTable6Colorful_Accent5",fa.listTable6Colorful_Accent6="ListTable6Colorful_Accent6",fa.listTable7Colorful="ListTable7Colorful",fa.listTable7Colorful_Accent1="ListTable7Colorful_Accent1",fa.listTable7Colorful_Accent2="ListTable7Colorful_Accent2",fa.listTable7Colorful_Accent3="ListTable7Colorful_Accent3",fa.listTable7Colorful_Accent4="ListTable7Colorful_Accent4",fa.listTable7Colorful_Accent5="ListTable7Colorful_Accent5",fa.listTable7Colorful_Accent6="ListTable7Colorful_Accent6",(da=i.DocumentPropertyType||(i.DocumentPropertyType={})).string="String",da.number="Number",da.date="Date",da.boolean="Boolean",(ha=i.TapObjectType||(i.TapObjectType={})).chart="Chart",ha.smartArt="SmartArt",ha.table="Table",ha.image="Image",ha.slide="Slide",ha.ole="OLE",ha.text="Text",(ga=i.FileContentFormat||(i.FileContentFormat={})).base64="Base64",ga.html="Html",ga.ooxml="Ooxml",(ma=i.AnnotationParentType||(i.AnnotationParentType={})).none="None",ma.document="Document",ma.paragraph="Paragraph",ma.annotation="Annotation",(ya=i.AugloopAnnotationState||(i.AugloopAnnotationState={}))[void 0]="Undefined",ya.created="Created",ya.sent="Sent",ya.duplicated="Duplicated",ya.seen="Seen",ya.tried="Tried",ya.kept="Kept",ya.rejected="Rejected",(_a=i.StyleType||(i.StyleType={})).character="Character",_a.list="List",_a.paragraph="Paragraph",_a.table="Table",(ba=i.OutlineLevel||(i.OutlineLevel={})).outlineLevel1="OutlineLevel1",ba.outlineLevel2="OutlineLevel2",ba.outlineLevel3="OutlineLevel3",ba.outlineLevel4="OutlineLevel4",ba.outlineLevel5="OutlineLevel5",ba.outlineLevel6="OutlineLevel6",ba.outlineLevel7="OutlineLevel7",ba.outlineLevel8="OutlineLevel8",ba.outlineLevel9="OutlineLevel9",ba.outlineLevelBodyText="OutlineLevelBodyText",(va=i.CloseBehavior||(i.CloseBehavior={})).save="Save",va.skipSave="SkipSave",(Oa=i.SaveBehavior||(i.SaveBehavior={})).save="Save",Oa.prompt="Prompt",(Ca=i.FieldType||(i.FieldType={})).addin="Addin",Ca.addressBlock="AddressBlock",Ca.advance="Advance",Ca.ask="Ask",Ca.author="Author",Ca.autoText="AutoText",Ca.autoTextList="AutoTextList",Ca.barCode="BarCode",Ca.bibliography="Bibliography",Ca.bidiOutline="BidiOutline",Ca.citation="Citation",Ca.comments="Comments",Ca.compare="Compare",Ca.createDate="CreateDate",Ca.data="Data",Ca.database="Database",Ca.date="Date",Ca.displayBarcode="DisplayBarcode",Ca.docProperty="DocProperty",Ca.docVariable="DocVariable",Ca.editTime="EditTime",Ca.embedded="Embedded",Ca.eq="EQ",Ca.expression="Expression",Ca.fileName="FileName",Ca.fileSize="FileSize",Ca.fillIn="FillIn",Ca.formCheckbox="FormCheckbox",Ca.formDropdown="FormDropdown",Ca.formText="FormText",Ca.gotoButton="GotoButton",Ca.greetingLine="GreetingLine",Ca.hyperlink="Hyperlink",Ca.if="If",Ca.import="Import",Ca.include="Include",Ca.includePicture="IncludePicture",Ca.includeText="IncludeText",Ca.index="Index",Ca.info="Info",Ca.keywords="Keywords",Ca.lastSavedBy="LastSavedBy",Ca.link="Link",Ca.listNum="ListNum",Ca.macroButton="MacroButton",Ca.mergeBarcode="MergeBarcode",Ca.mergeField="MergeField",Ca.mergeRec="MergeRec",Ca.mergeSeq="MergeSeq",Ca.next="Next",Ca.nextIf="NextIf",Ca.noteRef="NoteRef",Ca.numChars="NumChars",Ca.numPages="NumPages",Ca.numWords="NumWords",Ca.ocx="OCX",Ca.page="Page",Ca.pageRef="PageRef",Ca.print="Print",Ca.printDate="PrintDate",Ca.private="Private",Ca.quote="Quote",Ca.rd="RD",Ca.ref="Ref",Ca.revNum="RevNum",Ca.saveDate="SaveDate",Ca.section="Section",Ca.sectionPages="SectionPages",Ca.seq="Seq",Ca.set="Set",Ca.shape="Shape",Ca.skipIf="SkipIf",Ca.styleRef="StyleRef",Ca.subject="Subject",Ca.subscriber="Subscriber",Ca.symbol="Symbol",Ca.ta="TA",Ca.tc="TC",Ca.template="Template",Ca.time="Time",Ca.title="Title",Ca.toa="TOA",Ca.toc="TOC",Ca.userAddress="UserAddress",Ca.userInitials="UserInitials",Ca.userName="UserName",Ca.xe="XE",Ca.empty="Empty",Ca.others="Others",Ca[void 0]="Undefined",(Pa=i.FieldKind||(i.FieldKind={})).none="None",Pa.hot="Hot",Pa.warm="Warm",Pa.cold="Cold",(Sa=i.TrailingCharacter||(i.TrailingCharacter={})).trailingTab="TrailingTab",Sa.trailingSpace="TrailingSpace",Sa.trailingNone="TrailingNone",(Aa=i.ListBuiltInNumberStyle||(i.ListBuiltInNumberStyle={})).none="None",Aa.arabic="Arabic",Aa.upperRoman="UpperRoman",Aa.lowerRoman="LowerRoman",Aa.upperLetter="UpperLetter",Aa.lowerLetter="LowerLetter",Aa.ordinal="Ordinal",Aa.cardinalText="CardinalText",Aa.ordinalText="OrdinalText",Aa.kanji="Kanji",Aa.kanjiDigit="KanjiDigit",Aa.aiueoHalfWidth="AiueoHalfWidth",Aa.irohaHalfWidth="IrohaHalfWidth",Aa.arabicFullWidth="ArabicFullWidth",Aa.kanjiTraditional="KanjiTraditional",Aa.kanjiTraditional2="KanjiTraditional2",Aa.numberInCircle="NumberInCircle",Aa.aiueo="Aiueo",Aa.iroha="Iroha",Aa.arabicLZ="ArabicLZ",Aa.bullet="Bullet",Aa.ganada="Ganada",Aa.chosung="Chosung",Aa.gbnum1="GBNum1",Aa.gbnum2="GBNum2",Aa.gbnum3="GBNum3",Aa.gbnum4="GBNum4",Aa.zodiac1="Zodiac1",Aa.zodiac2="Zodiac2",Aa.zodiac3="Zodiac3",Aa.tradChinNum1="TradChinNum1",Aa.tradChinNum2="TradChinNum2",Aa.tradChinNum3="TradChinNum3",Aa.tradChinNum4="TradChinNum4",Aa.simpChinNum1="SimpChinNum1",Aa.simpChinNum2="SimpChinNum2",Aa.simpChinNum3="SimpChinNum3",Aa.simpChinNum4="SimpChinNum4",Aa.hanjaRead="HanjaRead",Aa.hanjaReadDigit="HanjaReadDigit",Aa.hangul="Hangul",Aa.hanja="Hanja",Aa.hebrew1="Hebrew1",Aa.arabic1="Arabic1",Aa.hebrew2="Hebrew2",Aa.arabic2="Arabic2",Aa.hindiLetter1="HindiLetter1",Aa.hindiLetter2="HindiLetter2",Aa.hindiArabic="HindiArabic",Aa.hindiCardinalText="HindiCardinalText",Aa.thaiLetter="ThaiLetter",Aa.thaiArabic="ThaiArabic",Aa.thaiCardinalText="ThaiCardinalText",Aa.vietCardinalText="VietCardinalText",Aa.lowercaseRussian="LowercaseRussian",Aa.uppercaseRussian="UppercaseRussian",Aa.lowercaseGreek="LowercaseGreek",Aa.uppercaseGreek="UppercaseGreek",Aa.arabicLZ2="ArabicLZ2",Aa.arabicLZ3="ArabicLZ3",Aa.arabicLZ4="ArabicLZ4",Aa.lowercaseTurkish="LowercaseTurkish",Aa.uppercaseTurkish="UppercaseTurkish",Aa.lowercaseBulgarian="LowercaseBulgarian",Aa.uppercaseBulgarian="UppercaseBulgarian",Aa.pictureBullet="PictureBullet",Aa.legal="Legal",Aa.legalLZ="LegalLZ",(Ia=i.ShadingTextureType||(i.ShadingTextureType={})).darkDiagonalDown="DarkDiagonalDown",Ia.darkDiagonalUp="DarkDiagonalUp",Ia.darkGrid="DarkGrid",Ia.darkHorizontal="DarkHorizontal",Ia.darkTrellis="DarkTrellis",Ia.darkVertical="DarkVertical",Ia.lightDiagonalDown="LightDiagonalDown",Ia.lightDiagonalUp="LightDiagonalUp",Ia.lightGrid="LightGrid",Ia.lightHorizontal="LightHorizontal",Ia.lightTrellis="LightTrellis",Ia.lightVertical="LightVertical",Ia.none="None",Ia.percent10="Percent10",Ia.percent12Pt5="Percent12Pt5",Ia.percent15="Percent15",Ia.percent20="Percent20",Ia.percent25="Percent25",Ia.percent30="Percent30",Ia.percent35="Percent35",Ia.percent37Pt5="Percent37Pt5",Ia.percent40="Percent40",Ia.percent45="Percent45",Ia.percent5="Percent5",Ia.percent50="Percent50",Ia.percent55="Percent55",Ia.percent60="Percent60",Ia.percent62Pt5="Percent62Pt5",Ia.percent65="Percent65",Ia.percent70="Percent70",Ia.percent75="Percent75",Ia.percent80="Percent80",Ia.percent85="Percent85",Ia.percent87Pt5="Percent87Pt5",Ia.percent90="Percent90",Ia.percent95="Percent95",Ia.solid="Solid",(Ra=i.CompareTarget||(i.CompareTarget={})).compareTargetCurrent="CompareTargetCurrent",Ra.compareTargetSelected="CompareTargetSelected",Ra.compareTargetNew="CompareTargetNew",(Ta=i.ImportedStylesConflictBehavior||(i.ImportedStylesConflictBehavior={})).ignore="Ignore",Ta.overwrite="Overwrite",Ta.createNew="CreateNew",(Ea=i.ShapeType||(i.ShapeType={})).unsupported="Unsupported",Ea.textBox="TextBox",Ea.geometricShape="GeometricShape",Ea.group="Group",Ea.picture="Picture",Ea.canvas="Canvas",(Na=i.RelativeHorizontalPosition||(i.RelativeHorizontalPosition={})).margin="Margin",Na.page="Page",Na.column="Column",Na.character="Character",Na.leftMargin="LeftMargin",Na.rightMargin="RightMargin",Na.insideMargin="InsideMargin",Na.outsideMargin="OutsideMargin",(Da=i.RelativeVerticalPosition||(i.RelativeVerticalPosition={})).margin="Margin",Da.page="Page",Da.paragraph="Paragraph",Da.line="Line",Da.topMargin="TopMargin",Da.bottomMargin="BottomMargin",Da.insideMargin="InsideMargin",Da.outsideMargin="OutsideMargin",(xa=i.RelativeSize||(i.RelativeSize={})).margin="Margin",xa.page="Page",xa.topMargin="TopMargin",xa.bottomMargin="BottomMargin",xa.insideMargin="InsideMargin",xa.outsideMargin="OutsideMargin",(wa=i.GeometricShapeType||(i.GeometricShapeType={})).lineInverse="LineInverse",wa.triangle="Triangle",wa.rightTriangle="RightTriangle",wa.rectangle="Rectangle",wa.diamond="Diamond",wa.parallelogram="Parallelogram",wa.trapezoid="Trapezoid",wa.nonIsoscelesTrapezoid="NonIsoscelesTrapezoid",wa.pentagon="Pentagon",wa.hexagon="Hexagon",wa.heptagon="Heptagon",wa.octagon="Octagon",wa.decagon="Decagon",wa.dodecagon="Dodecagon",wa.star4="Star4",wa.star5="Star5",wa.star6="Star6",wa.star7="Star7",wa.star8="Star8",wa.star10="Star10",wa.star12="Star12",wa.star16="Star16",wa.star24="Star24",wa.star32="Star32",wa.roundRectangle="RoundRectangle",wa.round1Rectangle="Round1Rectangle",wa.round2SameRectangle="Round2SameRectangle",wa.round2DiagonalRectangle="Round2DiagonalRectangle",wa.snipRoundRectangle="SnipRoundRectangle",wa.snip1Rectangle="Snip1Rectangle",wa.snip2SameRectangle="Snip2SameRectangle",wa.snip2DiagonalRectangle="Snip2DiagonalRectangle",wa.plaque="Plaque",wa.ellipse="Ellipse",wa.teardrop="Teardrop",wa.homePlate="HomePlate",wa.chevron="Chevron",wa.pieWedge="PieWedge",wa.pie="Pie",wa.blockArc="BlockArc",wa.donut="Donut",wa.noSmoking="NoSmoking",wa.rightArrow="RightArrow",wa.leftArrow="LeftArrow",wa.upArrow="UpArrow",wa.downArrow="DownArrow",wa.stripedRightArrow="StripedRightArrow",wa.notchedRightArrow="NotchedRightArrow",wa.bentUpArrow="BentUpArrow",wa.leftRightArrow="LeftRightArrow",wa.upDownArrow="UpDownArrow",wa.leftUpArrow="LeftUpArrow",wa.leftRightUpArrow="LeftRightUpArrow",wa.quadArrow="QuadArrow",wa.leftArrowCallout="LeftArrowCallout",wa.rightArrowCallout="RightArrowCallout",wa.upArrowCallout="UpArrowCallout",wa.downArrowCallout="DownArrowCallout",wa.leftRightArrowCallout="LeftRightArrowCallout",wa.upDownArrowCallout="UpDownArrowCallout",wa.quadArrowCallout="QuadArrowCallout",wa.bentArrow="BentArrow",wa.uturnArrow="UturnArrow",wa.circularArrow="CircularArrow",wa.leftCircularArrow="LeftCircularArrow",wa.leftRightCircularArrow="LeftRightCircularArrow",wa.curvedRightArrow="CurvedRightArrow",wa.curvedLeftArrow="CurvedLeftArrow",wa.curvedUpArrow="CurvedUpArrow",wa.curvedDownArrow="CurvedDownArrow",wa.swooshArrow="SwooshArrow",wa.cube="Cube",wa.can="Can",wa.lightningBolt="LightningBolt",wa.heart="Heart",wa.sun="Sun",wa.moon="Moon",wa.smileyFace="SmileyFace",wa.irregularSeal1="IrregularSeal1",wa.irregularSeal2="IrregularSeal2",wa.foldedCorner="FoldedCorner",wa.bevel="Bevel",wa.frame="Frame",wa.halfFrame="HalfFrame",wa.corner="Corner",wa.diagonalStripe="DiagonalStripe",wa.chord="Chord",wa.arc="Arc",wa.leftBracket="LeftBracket",wa.rightBracket="RightBracket",wa.leftBrace="LeftBrace",wa.rightBrace="RightBrace",wa.bracketPair="BracketPair",wa.bracePair="BracePair",wa.callout1="Callout1",wa.callout2="Callout2",wa.callout3="Callout3",wa.accentCallout1="AccentCallout1",wa.accentCallout2="AccentCallout2",wa.accentCallout3="AccentCallout3",wa.borderCallout1="BorderCallout1",wa.borderCallout2="BorderCallout2",wa.borderCallout3="BorderCallout3",wa.accentBorderCallout1="AccentBorderCallout1",wa.accentBorderCallout2="AccentBorderCallout2",wa.accentBorderCallout3="AccentBorderCallout3",wa.wedgeRectCallout="WedgeRectCallout",wa.wedgeRRectCallout="WedgeRRectCallout",wa.wedgeEllipseCallout="WedgeEllipseCallout",wa.cloudCallout="CloudCallout",wa.cloud="Cloud",wa.ribbon="Ribbon",wa.ribbon2="Ribbon2",wa.ellipseRibbon="EllipseRibbon",wa.ellipseRibbon2="EllipseRibbon2",wa.leftRightRibbon="LeftRightRibbon",wa.verticalScroll="VerticalScroll",wa.horizontalScroll="HorizontalScroll",wa.wave="Wave",wa.doubleWave="DoubleWave",wa.plus="Plus",wa.flowChartProcess="FlowChartProcess",wa.flowChartDecision="FlowChartDecision",wa.flowChartInputOutput="FlowChartInputOutput",wa.flowChartPredefinedProcess="FlowChartPredefinedProcess",wa.flowChartInternalStorage="FlowChartInternalStorage",wa.flowChartDocument="FlowChartDocument",wa.flowChartMultidocument="FlowChartMultidocument",wa.flowChartTerminator="FlowChartTerminator",wa.flowChartPreparation="FlowChartPreparation",wa.flowChartManualInput="FlowChartManualInput",wa.flowChartManualOperation="FlowChartManualOperation",wa.flowChartConnector="FlowChartConnector",wa.flowChartPunchedCard="FlowChartPunchedCard",wa.flowChartPunchedTape="FlowChartPunchedTape",wa.flowChartSummingJunction="FlowChartSummingJunction",wa.flowChartOr="FlowChartOr",wa.flowChartCollate="FlowChartCollate",wa.flowChartSort="FlowChartSort",wa.flowChartExtract="FlowChartExtract",wa.flowChartMerge="FlowChartMerge",wa.flowChartOfflineStorage="FlowChartOfflineStorage",wa.flowChartOnlineStorage="FlowChartOnlineStorage",wa.flowChartMagneticTape="FlowChartMagneticTape",wa.flowChartMagneticDisk="FlowChartMagneticDisk",wa.flowChartMagneticDrum="FlowChartMagneticDrum",wa.flowChartDisplay="FlowChartDisplay",wa.flowChartDelay="FlowChartDelay",wa.flowChartAlternateProcess="FlowChartAlternateProcess",wa.flowChartOffpageConnector="FlowChartOffpageConnector",wa.actionButtonBlank="ActionButtonBlank",wa.actionButtonHome="ActionButtonHome",wa.actionButtonHelp="ActionButtonHelp",wa.actionButtonInformation="ActionButtonInformation",wa.actionButtonForwardNext="ActionButtonForwardNext",wa.actionButtonBackPrevious="ActionButtonBackPrevious",wa.actionButtonEnd="ActionButtonEnd",wa.actionButtonBeginning="ActionButtonBeginning",wa.actionButtonReturn="ActionButtonReturn",wa.actionButtonDocument="ActionButtonDocument",wa.actionButtonSound="ActionButtonSound",wa.actionButtonMovie="ActionButtonMovie",wa.gear6="Gear6",wa.gear9="Gear9",wa.funnel="Funnel",wa.mathPlus="MathPlus",wa.mathMinus="MathMinus",wa.mathMultiply="MathMultiply",wa.mathDivide="MathDivide",wa.mathEqual="MathEqual",wa.mathNotEqual="MathNotEqual",wa.cornerTabs="CornerTabs",wa.squareTabs="SquareTabs",wa.plaqueTabs="PlaqueTabs",wa.chartX="ChartX",wa.chartStar="ChartStar",wa.chartPlus="ChartPlus";(Fa=i.ShapeFillType||(i.ShapeFillType={})).noFill="NoFill",Fa.solid="Solid",Fa.gradient="Gradient",Fa.pattern="Pattern",Fa.picture="Picture",Fa.texture="Texture",Fa.mixed="Mixed",(ja=i.ShapeTextVerticalAlignment||(i.ShapeTextVerticalAlignment={})).top="Top",ja.middle="Middle",ja.bottom="Bottom",(ka=i.ShapeTextOrientation||(i.ShapeTextOrientation={})).none="None",ka.horizontal="Horizontal",ka.eastAsianVertical="EastAsianVertical",ka.vertical270="Vertical270",ka.vertical="Vertical",ka.eastAsianHorizontalRotated="EastAsianHorizontalRotated",ka.mixed="Mixed",(Ma=i.ShapeAutoSize||(i.ShapeAutoSize={})).none="None",Ma.textToFitShape="TextToFitShape",Ma.shapeToFitText="ShapeToFitText",Ma.mixed="Mixed",(Ha=i.ShapeTextWrapType||(i.ShapeTextWrapType={})).inline="Inline",Ha.square="Square",Ha.tight="Tight",Ha.through="Through",Ha.topBottom="TopBottom",Ha.behind="Behind",Ha.front="Front",(La=i.ShapeTextWrapSide||(i.ShapeTextWrapSide={})).none="None",La.both="Both",La.left="Left",La.right="Right",La.largest="Largest",(Ua=i.ShapeScaleType||(i.ShapeScaleType={})).currentSize="CurrentSize",Ua.originalSize="OriginalSize",(Ba=i.ShapeScaleFrom||(i.ShapeScaleFrom={})).scaleFromTopLeft="ScaleFromTopLeft",Ba.scaleFromMiddle="ScaleFromMiddle",Ba.scaleFromBottomRight="ScaleFromBottomRight",(Wa=i.ErrorCodes||(i.ErrorCodes={})).accessDenied="AccessDenied",Wa.generalException="GeneralException",Wa.invalidArgument="InvalidArgument",Wa.itemNotFound="ItemNotFound",Wa.notAllowed="NotAllowed",Wa.notImplemented="NotImplemented",Wa.searchDialogIsOpen="SearchDialogIsOpen",Wa.searchStringInvalidOrTooLong="SearchStringInvalidOrTooLong",i.Interfaces||(i.Interfaces={})}(Word=Word||{}),void 0!==Word.Style&&function(e){e.other="Other",e.normal="Normal",e.heading1="Heading1",e.heading2="Heading2",e.heading3="Heading3",e.heading4="Heading4",e.heading5="Heading5",e.heading6="Heading6",e.heading7="Heading7",e.heading8="Heading8",e.heading9="Heading9",e.toc1="Toc1",e.toc2="Toc2",e.toc3="Toc3",e.toc4="Toc4",e.toc5="Toc5",e.toc6="Toc6",e.toc7="Toc7",e.toc8="Toc8",e.toc9="Toc9",e.footnoteText="FootnoteText",e.header="Header",e.footer="Footer",e.caption="Caption",e.footnoteReference="FootnoteReference",e.endnoteReference="EndnoteReference",e.endnoteText="EndnoteText",e.title="Title",e.subtitle="Subtitle",e.hyperlink="Hyperlink",e.strong="Strong",e.emphasis="Emphasis",e.noSpacing="NoSpacing",e.listParagraph="ListParagraph",e.quote="Quote",e.intenseQuote="IntenseQuote",e.subtleEmphasis="SubtleEmphasis",e.intenseEmphasis="IntenseEmphasis",e.subtleReference="SubtleReference",e.intenseReference="IntenseReference",e.bookTitle="BookTitle",e.bibliography="Bibliography",e.tocHeading="TocHeading",e.tableGrid="TableGrid",e.plainTable1="PlainTable1",e.plainTable2="PlainTable2",e.plainTable3="PlainTable3",e.plainTable4="PlainTable4",e.plainTable5="PlainTable5",e.tableGridLight="TableGridLight",e.gridTable1Light="GridTable1Light",e.gridTable1Light_Accent1="GridTable1Light_Accent1",e.gridTable1Light_Accent2="GridTable1Light_Accent2",e.gridTable1Light_Accent3="GridTable1Light_Accent3",e.gridTable1Light_Accent4="GridTable1Light_Accent4",e.gridTable1Light_Accent5="GridTable1Light_Accent5",e.gridTable1Light_Accent6="GridTable1Light_Accent6",e.gridTable2="GridTable2",e.gridTable2_Accent1="GridTable2_Accent1",e.gridTable2_Accent2="GridTable2_Accent2",e.gridTable2_Accent3="GridTable2_Accent3",e.gridTable2_Accent4="GridTable2_Accent4",e.gridTable2_Accent5="GridTable2_Accent5",e.gridTable2_Accent6="GridTable2_Accent6",e.gridTable3="GridTable3",e.gridTable3_Accent1="GridTable3_Accent1",e.gridTable3_Accent2="GridTable3_Accent2",e.gridTable3_Accent3="GridTable3_Accent3",e.gridTable3_Accent4="GridTable3_Accent4",e.gridTable3_Accent5="GridTable3_Accent5",e.gridTable3_Accent6="GridTable3_Accent6",e.gridTable4="GridTable4",e.gridTable4_Accent1="GridTable4_Accent1",e.gridTable4_Accent2="GridTable4_Accent2",e.gridTable4_Accent3="GridTable4_Accent3",e.gridTable4_Accent4="GridTable4_Accent4",e.gridTable4_Accent5="GridTable4_Accent5",e.gridTable4_Accent6="GridTable4_Accent6",e.gridTable5Dark="GridTable5Dark",e.gridTable5Dark_Accent1="GridTable5Dark_Accent1",e.gridTable5Dark_Accent2="GridTable5Dark_Accent2",e.gridTable5Dark_Accent3="GridTable5Dark_Accent3",e.gridTable5Dark_Accent4="GridTable5Dark_Accent4",e.gridTable5Dark_Accent5="GridTable5Dark_Accent5",e.gridTable5Dark_Accent6="GridTable5Dark_Accent6",e.gridTable6Colorful="GridTable6Colorful",e.gridTable6Colorful_Accent1="GridTable6Colorful_Accent1",e.gridTable6Colorful_Accent2="GridTable6Colorful_Accent2",e.gridTable6Colorful_Accent3="GridTable6Colorful_Accent3",e.gridTable6Colorful_Accent4="GridTable6Colorful_Accent4",e.gridTable6Colorful_Accent5="GridTable6Colorful_Accent5",e.gridTable6Colorful_Accent6="GridTable6Colorful_Accent6",e.gridTable7Colorful="GridTable7Colorful",e.gridTable7Colorful_Accent1="GridTable7Colorful_Accent1",e.gridTable7Colorful_Accent2="GridTable7Colorful_Accent2",e.gridTable7Colorful_Accent3="GridTable7Colorful_Accent3",e.gridTable7Colorful_Accent4="GridTable7Colorful_Accent4",e.gridTable7Colorful_Accent5="GridTable7Colorful_Accent5",e.gridTable7Colorful_Accent6="GridTable7Colorful_Accent6",e.listTable1Light="ListTable1Light",e.listTable1Light_Accent1="ListTable1Light_Accent1",e.listTable1Light_Accent2="ListTable1Light_Accent2",e.listTable1Light_Accent3="ListTable1Light_Accent3",e.listTable1Light_Accent4="ListTable1Light_Accent4",e.listTable1Light_Accent5="ListTable1Light_Accent5",e.listTable1Light_Accent6="ListTable1Light_Accent6",e.listTable2="ListTable2",e.listTable2_Accent1="ListTable2_Accent1",e.listTable2_Accent2="ListTable2_Accent2",e.listTable2_Accent3="ListTable2_Accent3",e.listTable2_Accent4="ListTable2_Accent4",e.listTable2_Accent5="ListTable2_Accent5",e.listTable2_Accent6="ListTable2_Accent6",e.listTable3="ListTable3",e.listTable3_Accent1="ListTable3_Accent1",e.listTable3_Accent2="ListTable3_Accent2",e.listTable3_Accent3="ListTable3_Accent3",e.listTable3_Accent4="ListTable3_Accent4",e.listTable3_Accent5="ListTable3_Accent5",e.listTable3_Accent6="ListTable3_Accent6",e.listTable4="ListTable4",e.listTable4_Accent1="ListTable4_Accent1",e.listTable4_Accent2="ListTable4_Accent2",e.listTable4_Accent3="ListTable4_Accent3",e.listTable4_Accent4="ListTable4_Accent4",e.listTable4_Accent5="ListTable4_Accent5",e.listTable4_Accent6="ListTable4_Accent6",e.listTable5Dark="ListTable5Dark",e.listTable5Dark_Accent1="ListTable5Dark_Accent1",e.listTable5Dark_Accent2="ListTable5Dark_Accent2",e.listTable5Dark_Accent3="ListTable5Dark_Accent3",e.listTable5Dark_Accent4="ListTable5Dark_Accent4",e.listTable5Dark_Accent5="ListTable5Dark_Accent5",e.listTable5Dark_Accent6="ListTable5Dark_Accent6",e.listTable6Colorful="ListTable6Colorful",e.listTable6Colorful_Accent1="ListTable6Colorful_Accent1",e.listTable6Colorful_Accent2="ListTable6Colorful_Accent2",e.listTable6Colorful_Accent3="ListTable6Colorful_Accent3",e.listTable6Colorful_Accent4="ListTable6Colorful_Accent4",e.listTable6Colorful_Accent5="ListTable6Colorful_Accent5",e.listTable6Colorful_Accent6="ListTable6Colorful_Accent6",e.listTable7Colorful="ListTable7Colorful",e.listTable7Colorful_Accent1="ListTable7Colorful_Accent1",e.listTable7Colorful_Accent2="ListTable7Colorful_Accent2",e.listTable7Colorful_Accent3="ListTable7Colorful_Accent3",e.listTable7Colorful_Accent4="ListTable7Colorful_Accent4",e.listTable7Colorful_Accent5="ListTable7Colorful_Accent5",e.listTable7Colorful_Accent6="ListTable7Colorful_Accent6"}(Word.Style),function(n){var r,e=(r=OfficeCore.RequestContext,__extends(t,r),Object.defineProperty(t.prototype,"document",{get:function(){return this.m_document},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"application",{get:function(){return null==this.m_application&&(this.m_application=new n.Application(this,OfficeExtension.ObjectPathFactory.createNewObjectObjectPath(this,"Microsoft.WordServices.Application",!1))),this.m_application},enumerable:!0,configurable:!0}),t);function t(e){var t=r.call(this,e)||this;return t.m_document=new n.Document(t,OfficeExtension.ObjectPathFactory.createGlobalObjectObjectPath(t)),t._rootObject=t.m_document,t}n.RequestContext=e,n.run=function(e,t){return OfficeExtension.ClientRequestContext._runBatch("Word.run",arguments,function(){return new n.RequestContext})}}(Word=Word||{}),function(e){var t=(Object.defineProperty(n.prototype,"type",{get:function(){return e.EventType.ActiveViewChanged},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"activeView",{get:function(){return this.m_activeView.activeView},enumerable:!0,configurable:!0}),n);function n(e){this.m_activeView=e}e.ActiveViewChangedEventArgs=t}(OSF=OSF||{}),function(c){var e=(t.prototype.verifyArguments=function(e,t){for(var n in e){var r=e[n],o=t[n];if(r.enum)switch(typeof o){case"string":if(c.OUtil.listContainsValue(r.enum,o))break;case"undefined":throw 5007;default:throw this.getInvalidParameterString()}if(r.types&&!c.OUtil.listContainsValue(r.types,typeof o))throw this.getInvalidParameterString()}},t.prototype.extractRequiredArguments=function(e,t,n){if(e.length<this._requiredCount)throw c.Utility.createParameterException(Strings.OfficeOM.L_MissingRequiredArguments);var r,o=[];for(r=0;r<this._requiredCount;r++)o.push(e[r]);this.verifyArguments(this._requiredParameters,o);var i={};for(r=0;r<this._requiredCount;r++){var a=this._requiredParameters[r],s=o[r];if(a.verify&&!a.verify(s,t,n))throw this.getInvalidParameterString();i[a.name]=s}return i},t.prototype.fillOptions=function(e,t,n,r){for(var o in e=e||{},this._supportedOptions)if(!c.OUtil.listContainsKey(e,o)){var i=void 0,a=this._supportedOptions[o];a.calculate&&t&&(i=a.calculate(t,n,r)),i||void 0===a.defaultValue||(i=a.defaultValue),e[o]=i}return e},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 e=this;c.OUtil.delayExecutionAndCache(function(){return c.OUtil.formatString(Strings.OfficeOM.L_InvalidParameters,e._displayName)})},t);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}c.ApiMethodCall=e}(OSF=OSF||{}),function(c){var e=(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(e,t,n,r){return 0==e?this._onSucceeded?this._onSucceeded(t,n,r):t:this._onFailed?this._onFailed(e,t):c.DDA.ErrorCodeManager.getErrorArgs(e)},t.prototype.getCallArgs=function(e){for(var t,n,r=e.length-1;r>=this._requiredCount;r--){var o=e[r];switch(typeof o){case"object":t=o;break;case"function":n=o}}return t=t||{},n&&(t[c.ParameterNames.Callback]=n),t},t.prototype.extractOptions=function(e,t,n,r){if(e.length>this._requiredCount+2)throw c.Utility.createParameterException(Strings.OfficeOM.L_TooManyArguments);for(var o,i,a=e.length-1;a>=this._requiredCount;a--){var s=e[a];switch(typeof s){case"object":if(o)throw c.Utility.createParameterException(Strings.OfficeOM.L_TooManyOptionalObjects);o=s;break;case"function":if(i)throw c.Utility.createParameterException(Strings.OfficeOM.L_TooManyOptionalFunction);i=s;break;default:throw c.Utility.createArgumentException(Strings.OfficeOM.L_InValidOptionalArgument)}}if(o=this._apiMethods.fillOptions(o,t,n,r),i){if(o[c.ParameterNames.Callback])throw Strings.OfficeOM.L_RedundantCallbackSpecification;o[c.ParameterNames.Callback]=i}return this._apiMethods.verifyArguments(this._supportedOptions,o),o},t);function t(e,t,n,r,o,i,a){this._requiredParameters=e,this._supportedOptions=t,this._privateStateCallbacks=n,this._onSucceeded=r,this._onFailed=o,this._displayName=a,this._checkCallArgs=i,this._requiredCount=e.length,this._apiMethods=new c.ApiMethodCall(e,t,n,i,a)}c.AsyncMethodCall=e}(OSF=OSF||{}),function(o){var e,i;e=o.AsyncMethodCalls||(o.AsyncMethodCalls={}),i={},e.define=function(e){var t,n,r;i[e.method]=(n=(t=e).supportedOptions?o.OUtil.createObject(t.supportedOptions):[],r=t.privateStateCallbacks?o.OUtil.createObject(t.privateStateCallbacks):[],new o.AsyncMethodCall(t.requiredArguments||[],n,r,t.onSucceeded,t.onFailed,t.checkCallArgs,t.method))},e.get=function(e){return i[e]}}(OSF=OSF||{}),(OSF||(OSF={})).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"},function(e){var t;(t=e.PropertyDescriptors||(e.PropertyDescriptors={})).Subset="subset",t.BindingProperties="BindingProperties";var n=(Object.defineProperty(r.prototype,"startRow",{get:function(){return this.m_subset.startRow},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"startColumn",{get:function(){return this.m_subset.startColumn},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"rowCount",{get:function(){return this.m_subset.rowCount},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"columnCount",{get:function(){return this.m_subset.columnCount},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"type",{get:function(){return e.EventType.BindingSelectionChanged},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"binding",{get:function(){return this.m_bindingInstance},enumerable:!0,configurable:!0}),r);function r(e,t){this.m_bindingInstance=e,this.m_subset=t}e.BindingSelectionChangedEventArgs=n;var o=(Object.defineProperty(i.prototype,"type",{get:function(){return e.EventType.BindingDataChanged},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"binding",{get:function(){return this.m_bindingInstance},enumerable:!0,configurable:!0}),i);function i(e){this.m_bindingInstance=e}e.BindingDataChangedEventArgs=o}(OSF=OSF||{}),function(e){var t,n,r,o,i,a;(t=e.PropertyDescriptors||(e.PropertyDescriptors={})).DataPartProperties="DataPartProperties",t.DataNodeProperties="DataNodeProperties",n=e.Marshaling||(e.Marshaling={}),r=n.Customxml||(n.Customxml={}),(o=r.DataNodeEventProperties||(r.DataNodeEventProperties={})).OldNode="OldNode",o.NewNode="NewNode",o.NextSiblingNode="NextSiblingNode",o.InUndoRedo="InUndoRedo",(i=e.EventDescriptors||(e.EventDescriptors={})).DataNodeInsertedEvent="DataNodeInsertedEvent",i.DataNodeReplacedEvent="DataNodeReplacedEvent",i.DataNodeDeletedEvent="DataNodeDeletedEvent",(a=e.DataNodeEventProperties||(e.DataNodeEventProperties={})).OldNode="OldNode",a.NewNode="NewNode",a.NextSiblingNode="NextSiblingNode",a.InUndoRedo="InUndoRedo";var s=(Object.defineProperty(c.prototype,"type",{get:function(){return e.EventType.DataNodeInserted},enumerable:!0,configurable:!0}),Object.defineProperty(c.prototype,"newNode",{get:function(){return this.m_newNode},enumerable:!0,configurable:!0}),Object.defineProperty(c.prototype,"inUndoRedo",{get:function(){return this.m_inUndoRedo},enumerable:!0,configurable:!0}),c);function c(e,t){this.m_newNode=e,this.m_inUndoRedo=t}e.NodeInsertedEventArgs=s;var l=(Object.defineProperty(u.prototype,"type",{get:function(){return e.EventType.DataNodeReplaced},enumerable:!0,configurable:!0}),Object.defineProperty(u.prototype,"oldNode",{get:function(){return this.m_oldNode},enumerable:!0,configurable:!0}),Object.defineProperty(u.prototype,"newNode",{get:function(){return this.m_newNode},enumerable:!0,configurable:!0}),Object.defineProperty(u.prototype,"inUndoRedo",{get:function(){return this.m_inUndoRedo},enumerable:!0,configurable:!0}),u);function u(e,t,n){this.m_oldNode=e,this.m_newNode=t,this.m_inUndoRedo=n}e.NodeReplacedEventArgs=l;var p=(Object.defineProperty(f.prototype,"type",{get:function(){return e.EventType.DataNodeDeleted},enumerable:!0,configurable:!0}),Object.defineProperty(f.prototype,"oldNode",{get:function(){return this.m_oldNode},enumerable:!0,configurable:!0}),Object.defineProperty(f.prototype,"oldNextSibling",{get:function(){return this.m_oldNextSibling},enumerable:!0,configurable:!0}),Object.defineProperty(f.prototype,"inUndoRedo",{get:function(){return this.m_inUndoRedo},enumerable:!0,configurable:!0}),f);function f(e,t,n){this.m_oldNode=e,this.m_oldNextSibling=t,this.m_inUndoRedo=n}e.NodeDeletedEventArgs=p}(OSF=OSF||{}),function(t){function e(e){0==e[t.PropertyDescriptors.MessageType]?t.OUtil.defineEnumerableProperties(this,{type:{value:t.EventType.DialogMessageReceived},message:{value:e[t.PropertyDescriptors.MessageContent]},origin:{value:e[t.PropertyDescriptors.MessageOrigin]}}):t.OUtil.defineEnumerableProperties(this,{type:{value:t.EventType.DialogEventReceived},error:{value:e[t.PropertyDescriptors.MessageType]}})}var n;t.DialogEventArgs=e,(n=t.PropertyDescriptors||(t.PropertyDescriptors={})).MessageType="messageType",n.MessageContent="messageContent",n.MessageOrigin="messageOrigin"}(OSF=OSF||{}),function(e){var t=(Object.defineProperty(n.prototype,"type",{get:function(){return e.EventType.DocumentSelectionChanged},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"document",{get:function(){return this.m_docInstance},enumerable:!0,configurable:!0}),n);function n(e){this.m_docInstance=e}e.DocumentSelectionChangedEventArgs=t}(OSF=OSF||{}),function(t){function e(e){t.OUtil.defineEnumerableProperties(this,{type:{value:t.EventType.DialogParentMessageReceived},message:{value:e[t.PropertyDescriptors.MessageContent]},origin:{value:e[t.PropertyDescriptors.MessageOrigin]}})}t.DialogParentEventArgs=e}(OSF=OSF||{}),function(h){var e,i;function g(e){return e==h.EventDispId.dispidObjectDeletedEvent||e==h.EventDispId.dispidObjectSelectionChangedEvent||e==h.EventDispId.dispidObjectDataChangedEvent||e==h.EventDispId.dispidContentControlAddedEvent}function m(e,t,n,r){if("number"!=typeof e)throw e;b(r=r||t.getCallArgs(n),e,h.DDA.ErrorCodeManager.getErrorArgs(e))}function y(e){return(h._OfficeAppFactory.getHostInfo().hostPlatform==h.HostInfoPlatform.web?h.WACDelegate:h.SafeArrayDelegate)[e]}function _(){return i||function(){i={};var e={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 t in e)h.AsyncMethods[t]&&(i[h.AsyncMethods[t]]=e[t]);var n={MessageParent:144,SendMessage:145};for(var t in n)h.SyncMethods[t]&&(i[h.SyncMethods[t]]=n[t]);var r={SettingsChanged:h.EventDispId.dispidSettingsChangedEvent,DocumentSelectionChanged:h.EventDispId.dispidDocumentSelectionChangedEvent,BindingSelectionChanged:h.EventDispId.dispidBindingSelectionChangedEvent,BindingDataChanged:h.EventDispId.dispidBindingDataChangedEvent,ActiveViewChanged:h.EventDispId.dispidActiveViewChangedEvent,OfficeThemeChanged:h.EventDispId.dispidOfficeThemeChangedEvent,DocumentThemeChanged:h.EventDispId.dispidDocumentThemeChangedEvent,AppCommandInvoked:h.EventDispId.dispidAppCommandInvokedEvent,DialogMessageReceived:h.EventDispId.dispidDialogMessageReceivedEvent,DialogParentMessageReceived:h.EventDispId.dispidDialogParentMessageReceivedEvent,ObjectDeleted:h.EventDispId.dispidObjectDeletedEvent,ObjectSelectionChanged:h.EventDispId.dispidObjectSelectionChangedEvent,ObjectDataChanged:h.EventDispId.dispidObjectDataChangedEvent,ContentControlAdded:h.EventDispId.dispidContentControlAddedEvent,LiveShareStateChanged:h.EventDispId.dispidLiveShareStateChangedEvent,RichApiMessage:h.EventDispId.dispidRichApiMessageEvent,DataNodeInserted:h.EventDispId.dispidDataNodeAddedEvent,DataNodeReplaced:h.EventDispId.dispidDataNodeReplacedEvent,DataNodeDeleted:h.EventDispId.dispidDataNodeDeletedEvent};for(var o in r)h.EventType[o]&&(i[h.EventType[o]]=r[o])}(),i}function b(e,t,n){var r=e[h.ParameterNames.Callback];if(r){var o,i={};i[h.DDA.AsyncResultEnum.Properties.Context]=e[h.ParameterNames.AsyncContext],0==t?i[h.DDA.AsyncResultEnum.Properties.Value]=n:(o={},n=n||h.DDA.ErrorCodeManager.getErrorArgs(5001),o[h.DDA.AsyncResultEnum.ErrorProperties.Code]=t||5001,o[h.DDA.AsyncResultEnum.ErrorProperties.Name]=n.name||n,o[h.DDA.AsyncResultEnum.ErrorProperties.Message]=n.message||n),r(new h.DDA.AsyncResult(i,o))}}h.DialogShownStatus={hasDialogShown:!1,isWindowDialog:!1},(e=h.DispIdHost||(h.DispIdHost={})).InvokeMethod=function(e,t,o,n){var i;try{var a=h.AsyncMethodCalls.get(e);i=a.verifyAndExtractCall(t,o,n);var s=_()[e],r=y("executeAsync"),c=null;if(window.Excel&&window.Office.context.requirements.isSetSupported("RedirectV1Api")&&(window.Excel._RedirectV1APIs=!0),window.Excel&&window.Excel._RedirectV1APIs&&(c=window.Excel._V1APIMap[e])){var l=h.OUtil.shallowCopy(i);delete l[h.ParameterNames.AsyncContext],c.preprocess&&(l=c.preprocess(l));var u=new window.Excel.RequestContext,p=c.call(u,l);u.sync().then(function(){var e=p.value,t=e.status;delete e.status,delete e["@odata.type"],c.postprocess&&(e=c.postprocess(e,l)),0!=t&&(e=h.DDA.ErrorCodeManager.getErrorArgs(t)),b(i,t,e)}).catch(function(e){b(i,13991,null)})}else{var f;f=h.HostParameterMap.toHost(s,i);var d=(new Date).getTime();r({dispId:s,hostCallArgs:f,onCalling:function(){},onReceiving:function(){},onComplete:function(e,t){var n;n=0==e?h.HostParameterMap.fromHost(s,t):t;var r=a.processResponse(e,n,o,i);b(i,e,r),h.AppTelemetry&&h.AppTelemetry.onMethodDone(s,f,Math.abs((new Date).getTime()-d),e)}})}}catch(e){m(e,a,t,i)}},e.AddEventHandler=function(t,n,r,e){var o,i,a,s=!1;function c(e){var t;0==e&&((s?n.addObjectEventHandler(i,o[h.ParameterNames.Id],a):n.addEventHandler(i,a))||(e=13991));0!=e&&(t=h.DDA.ErrorCodeManager.getErrorArgs(e)),b(o,e,t)}try{var l=h.AsyncMethodCalls.get(h.AsyncMethods.AddHandlerAsync);if(o=l.verifyAndExtractCall(t,r,n),i=o[h.ParameterNames.EventType],a=o[h.ParameterNames.Handler],e)return void c(0);var u=_()[i],p=(s=g(u))?o[h.ParameterNames.Id]:r.id||"";if(0==(s?n.getObjectEventHandlerCount(i,p):n.getEventHandlerCount(i)))y("registerEventAsync")({eventType:i,dispId:u,targetId:p,onCalling:function(){},onReceiving:function(){},onComplete:c,onEvent:function(e){var t=h.HostParameterMap.fromHost(u,e);s?n.fireObjectEvent(p,h.manufactureEventArgs(i,p,t)):n.fireEvent(h.manufactureEventArgs(i,r,t))}});else c(0)}catch(e){m(e,l,t,o)}},e.RemoveEventHandler=function(t,e,n){var r,o,i,a=!1;function s(e){var t;0!=e&&(t=h.DDA.ErrorCodeManager.getErrorArgs(e)),b(r,e,t)}try{var c=h.AsyncMethodCalls.get(h.AsyncMethods.RemoveHandlerAsync);o=(r=c.verifyAndExtractCall(t,n,e))[h.ParameterNames.EventType],i=r[h.ParameterNames.Handler];var l,u,p=_()[o],f=(a=g(p))?r[h.ParameterNames.Id]:n.id||"";l=null===i?(u=a?e.clearObjectEventHandlers(o,f):e.clearEventHandlers(o),0):(u=a?e.removeObjectEventHandler(o,f,i):e.removeEventHandler(o,i))?0:5003;var d=a?e.getObjectEventHandlerCount(o,f):e.getEventHandlerCount(o);if(u&&0==d)y("unregisterEventAsync")({eventType:o,dispId:p,targetId:f,onCalling:function(){},onReceiving:function(){},onComplete:s});else s(l)}catch(e){m(e,c,t,r)}},e.OpenDialog=function(t,o,i){var r,a,s=h.EventType.DialogMessageReceived,c=h.EventType.DialogEventReceived;function e(e){if(0!=e)n=h.DDA.ErrorCodeManager.getErrorArgs(e);else{var t={};t.id=a,t.data=o;var n=l.processResponse(e,t,i,r);h.DialogShownStatus.hasDialogShown=!0,o.clearEventHandlers(s),o.clearEventHandlers(c)}b(r,e,n)}try{if(null!=s&&null!=c||e(5e3),null==h.AsyncMethods.DisplayDialogAsync)return void e(5001);var l=h.AsyncMethodCalls.get(h.AsyncMethods.DisplayDialogAsync);r=l.verifyAndExtractCall(t,i,o);var u=_()[s],n=y("openDialog");a=JSON.stringify(r),h.DialogShownStatus.hasDialogShown||(o.clearQueuedEvent(s),o.clearQueuedEvent(c),o.clearQueuedEvent(h.EventType.DialogParentMessageReceived)),n({eventType:s,dispId:u,targetId:a,onCalling:function(){},onReceiving:function(){},onComplete:e,onEvent:function(e){var t=h.HostParameterMap.fromHost(u,e),n=h.manufactureEventArgs(s,i,t);if(n.type==c){h.DDA.ErrorCodeManager.getErrorArgs(n.error);var r={};r.code=status||5001,n.error=new h.DDA.Error(r[h.DDA.AsyncResultEnum.ErrorProperties.Name],r[h.DDA.AsyncResultEnum.ErrorProperties.Message],r[h.DDA.AsyncResultEnum.ErrorProperties.Code])}o.fireOrQueueEvent(n),12006==t.messageType&&(o.clearEventHandlers(s),o.clearEventHandlers(c),o.clearEventHandlers(h.EventType.DialogParentMessageReceived),h.DialogShownStatus.hasDialogShown=!1)}})}catch(e){m(e,l,t,r)}},e.CloseDialog=function(t,e,n,r){var o,i,a;try{var s=h.AsyncMethodCalls.get(h.AsyncMethods.CloseAsync);o=s.verifyAndExtractCall(t,r,n),i=h.EventType.DialogMessageReceived,a=h.EventType.DialogEventReceived,n.clearEventHandlers(i),n.clearEventHandlers(a);var c=_()[i];y("closeDialog")({eventType:i,dispId:c,targetId:e,onCalling:function(){},onReceiving:function(){},onComplete:function(e){h.DialogShownStatus.hasDialogShown=!1}})}catch(e){m(e,s,t,o)}},e.MessageParent=function(e,t){var n=h.SyncMethodCalls.get(h.SyncMethods.MessageParent).verifyAndExtractCall(e,t,{});return y("messageParent")({dispId:_()[h.SyncMethods.MessageParent],hostCallArgs:n,onCalling:function(){},onReceiving:function(){}})},e.SendMessage=function(e,t,n){var r=h.SyncMethodCalls.get(h.SyncMethods.SendMessage).verifyAndExtractCall(e,n,{});return y("sendMessage")({dispId:_()[h.SyncMethods.SendMessage],hostCallArgs:r,onCalling:function(){},onReceiving:function(){}})},e.addAsyncMethods=function(t,e,n){for(var r in e){var o=e[r];t[o]||h.OUtil.defineEnumerableProperty(t,o,{value:function(e){return function(){(0,h.DispIdHost.InvokeMethod)(e,arguments,t,n)}}(o)})}},e.addEventSupport=function(e,t,n){var r=h.AsyncMethods.AddHandlerAsync,o=h.AsyncMethods.RemoveHandlerAsync;e[r]||h.OUtil.defineEnumerableProperty(e,r,{value:function(){(0,h.DispIdHost.AddEventHandler)(arguments,t,e,n)}}),e[o]||h.OUtil.defineEnumerableProperty(e,o,{value:function(){(0,h.DispIdHost.RemoveEventHandler)(arguments,t,e)}})},e.issueAsyncResult=b}(OSF=OSF||{}),function(o){o.manufactureEventArgs=function(e,t,n){var r;switch(e){case o.EventType.DocumentSelectionChanged:r=new o.DocumentSelectionChangedEventArgs(t);break;case o.EventType.BindingSelectionChanged:r=new o.BindingSelectionChangedEventArgs(o.manufactureBinding(n,t.document),n[o.PropertyDescriptors.Subset]);break;case o.EventType.BindingDataChanged:r=new o.BindingDataChangedEventArgs(o.manufactureBinding(n,t.document));break;case o.EventType.SettingsChanged:r=new o.SettingsChangedEventArgs(t);break;case o.EventType.ActiveViewChanged:r=new o.ActiveViewChangedEventArgs(n);break;case o.EventType.LiveShareStateChanged:r=new o.LiveShareStateChangedEventArgs(n);break;case o.EventType.OfficeThemeChanged:r=new o.DDA.Theming.OfficeThemeChangedEventArgs(n);break;case o.EventType.DocumentThemeChanged:r=new o.DDA.Theming.DocumentThemeChangedEventArgs(n);break;case o.EventType.DataNodeInserted:r=new o.NodeInsertedEventArgs(o.manufactureDataNode(n[o.DataNodeEventProperties.NewNode]),n[o.DataNodeEventProperties.InUndoRedo]);break;case o.EventType.DataNodeReplaced:r=new o.NodeReplacedEventArgs(o.manufactureDataNode(n[o.DataNodeEventProperties.OldNode]),o.manufactureDataNode(n[o.DataNodeEventProperties.NewNode]),n[o.DataNodeEventProperties.InUndoRedo]);break;case o.EventType.DataNodeDeleted:r=new o.NodeDeletedEventArgs(o.manufactureDataNode(n[o.DataNodeEventProperties.OldNode]),o.manufactureDataNode(n[o.DataNodeEventProperties.NextSiblingNode]),n[o.DataNodeEventProperties.InUndoRedo]);break;case o.EventType.DialogMessageReceived:r=new o.DialogEventArgs(n);break;case o.EventType.DialogParentMessageReceived:r=new o.DialogParentEventArgs(n)}return r}}(OSF=OSF||{}),function(d){var h="toHost",g="fromHost";!function(u){var t;u.self="self",u.dynamicTypes={},u.dynamicTypes[d.ParameterNames.Data]={toHost:function(e){if(null!=e&&void 0!==e.rows){var t={};t[d.TableDataProperties.TableRows]=e.rows,t[d.TableDataProperties.TableHeaders]=e.headers,e=t}return e},fromHost:function(e){return e}},u.dynamicTypes.sampleData=u.dynamicTypes.data;var p={};function r(e,t){var n,r;if(t.map)for(var o in r={},n=t.map){var i=n[o];i==u.self&&(i=o),r[i]=o}else n=t.toHost,r=t.fromHost;var a=p[e];if(a){var s=a[h];for(var c in s)n[c]=s[c];for(var l in s=a[g])r[l]=s[l]}else a=p[e]={};a[h]=n,a[g]=r}function o(e){f().addComplexType(e)}function l(e,t){var n=e?{}:void 0;for(var r in e){var o,i=e[r];if(d.ListType.isListType(r))for(var a in o=[],i)o.push(l(i[a],t));else if(d.OUtil.listContainsKey(u.dynamicTypes,r))o=u.dynamicTypes[r][t](i);else if(t==g&&f().preserveNesting(r))o=l(i,t);else{var s=p[r];if(s){var c=s[t];c&&void 0===(o=c[i])&&(o=i)}else o=i}n[r]=o}return n}function n(e,t,n){var r,o=p[e][n];if("toHost"==n)r=function e(t,n){var r;for(var o in n){var i;if(null!=(i=f().isComplexType(o)?e(t,p[o][h]):t[o])){r=r||{};var a=n[o];a==u.self&&(a=o),r[a]=f().pack(o,i)}}return r}(l(t,n),o);else if("fromHost"==n){r=l(function e(t,n,r){for(var o in r=r||{},n){var i,a,s=n[o];if(s==u.self)i=t;else{if("sourceData"==s){r[o]=t.toArray();continue}i=t[s]}if(null==i)r[o]=void 0;else if(i=f().unpack(o,i),f().isComplexType(o))a=p[o][g],f().preserveNesting(o)?r[o]=e(i,a):e(i,a,r);else if(d.ListType.isListType(o)){(a={})[d.ListType.getDescriptor(o)]=u.self;var c=new Array(i.length);for(var l in i)c[l]=e(i[l],a);r[o]=c}else r[o]=i}return r}(t,o),n)}return r}function f(){if(!t){var e=d._OfficeAppFactory.getHostInfo();t=e.hostPlatform==d.HostInfoPlatform.web?new d.WebSpecialProcessor:new d.SafeArraySpecialProcessor}return t}function i(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}u.define=function(e){var t={},n=i(e.toHost);e.invertible?t.map=n:e.canonical?t.toHost=t.fromHost=n:(t.toHost=n,t.fromHost=i(e.fromHost)),r(e.type,t),e.isComplexType&&o(e.type)},u.toHost=function(e,t){return n(e,t,h)},u.fromHost=function(e,t){return n(e,t,g)},u.addMapping=r,u.addComplexType=o,u.getDynamicType=function(e){return f().getDynamicType(e)},u.setDynamicType=function(e,t){f().setDynamicType(e,t)},u.doMapValues=function(e,t){return l(e,t)}}(d.HostParameterMap||(d.HostParameterMap={}))}(OSF=OSF||{}),function(t){var e,n;e=t.ListType||(t.ListType={}),n={},e.setListType=function(e,t){n[e]=t},e.isListType=function(e){return t.OUtil.listContainsKey(n,e)},e.getDescriptor=function(e){return n[e]}}(OSF=OSF||{}),function(e){var t=(Object.defineProperty(n.prototype,"type",{get:function(){return e.EventType.LiveShareStateChanged},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"liveShareState",{get:function(){return this.m_liveShareStateInstance},enumerable:!0,configurable:!0}),n);function n(e){this.m_liveShareStateInstance=e}e.LiveShareStateChangedEventArgs=t}(OSF=OSF||{}),function(e){var t;(t=e.EventType||(e.EventType={})).ActiveViewChanged="activeViewChanged",t.DialogMessageReceived="dialogMessageReceived",t.DialogParentMessageReceived="dialogParentMessageReceived",t.DialogParentEventReceived="dialogParentEventReceived",t.DialogEventReceived="dialogEventReceived",t.BindingDataChanged="bindingDataChanged",t.BindingSelectionChanged="bindingSelectionChanged",t.OfficeThemeChanged="officeThemeChanged",t.DocumentThemeChanged="documentThemeChanged",t.DataNodeDeleted="nodeDeleted",t.DataNodeInserted="nodeInserted",t.DataNodeReplaced="nodeReplaced",t.DocumentSelectionChanged="documentSelectionChanged",t.LiveShareStateChanged="liveShareStateChanged",t.NodeDeleted="nodeDeleted",t.NodeInserted="nodeInserted",t.NodeReplaced="nodeReplaced",t.SettingsChanged="settingsChanged"}(Office=Office||{}),function(e){var t;(t=e.TableDataProperties||(e.TableDataProperties={})).TableRows="TableRows",t.TableHeaders="TableHeaders"}(OSF=OSF||{}),function(d){!function(e){var t,n,r,o,i,a,s;function c(){try{var e=window.navigator.userAgent;return-1<e.indexOf("MSIE ")||-1<e.indexOf("Trident/")||-1<e.indexOf("Edge/")}catch(e){return f("Error happens in isInternetExplorer.",e),!1}}function l(e){if("undefined"!=typeof JSON)try{return JSON.stringify(e)}catch(e){}return""}(t=e.HostThemeButtonStyleKeys||(e.HostThemeButtonStyleKeys={})).ButtonBorderColor="buttonBorderColor",t.ButtonBackgroundColor="buttonBackgroundColor",(r=n=n||{}).HostButtonBorderColor="#86bfa0",r.HostButtonBackgroundColor="#d3f0e0",(i=o=o||{}).HostButtonBorderColor="#a3bde3",i.HostButtonBackgroundColor="#d5e1f2",(s=a=a||{}).HostButtonBorderColor="#f5ba9d",s.HostButtonBackgroundColor="#fcf0ed",e.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},e.defineEnumerableProperties=function(e,t){return function(e,t,n){for(var r in t=t||{})p(e,r,t[r],n);return e}(e,t,["enumerable"])},e.defineEnumerableProperty=function(e,t,n){return p(e,t,n,["enumerable"])},e.listContainsKey=function(e,t){for(var n in e)if(t==n)return!0;return!1},e.augmentList=function(n,e){var t=n.push?function(e,t){n.push(t)}:function(e,t){n[e]=t};for(var r in e)t(r,e[r])},e.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},e.listContainsValue=function(e,t){for(var n in e)if(t==e[n])return!0;return!1},e.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(-1<t.indexOf(e[n]))return c();return!1}catch(e){return f("Error happens in shouldUseLocalStorageToPassMessage.",e),!1}},e.isInternetExplorer=c,e.serializeObjectToString=l,e.formatString=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=e;return r[0].replace(/{(\d+)}/gm,function(e,t){var n=parseInt(t,10)+1;return void 0===r[n]?"{"+t+"}":r[n]})},e.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 1<s.length?n=i+"&_host_Info="+t:0<s.length&&(n=i+"?_host_Info="+t),a?[n,r,a].join(""):n},e.getHostnamePortionForLogging=function(e){var t=e.split("."),n=t.length;return 2<=n?t[n-2]+"."+t[n-1]:1==n?t[0]:void 0},e.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},e.getXdmEventName=function(e,t){return t==d.EventType.BindingSelectionChanged||t==d.EventType.BindingDataChanged||t==d.EventType.DataNodeDeleted||t==d.EventType.DataNodeInserted||t==d.EventType.DataNodeReplaced?e+"_"+t:t},e.getCommonUI=function(){switch(Office.context.host){case Office.HostType.Excel:return n;case Office.HostType.Word:return o;case Office.HostType.PowerPoint:return a}return null},e.getDomainForUrl=function(e){if(!e)return null;var t=document.createElement("a");return t.href=e,t.protocol+"//"+t.host},e.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 u=-1;function p(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 f(e,t){d.Utility.trace(e+" Exception details: "+l(t))}e.getUniqueId=function(){return(u+=1).toString()}}(d.OUtil||(d.OUtil={}))}(OSF=OSF||{}),function(e){var t;(t=e.ParameterNames||(e.ParameterNames={})).BindingType="bindingType",t.CoercionType="coercionType",t.ValueFormat="valueFormat",t.FilterType="filterType",t.Columns="columns",t.SampleData="sampleData",t.GoToType="goToType",t.SelectionMode="selectionMode",t.Id="id",t.PromptText="promptText",t.ItemName="itemName",t.FailOnCollision="failOnCollision",t.StartRow="startRow",t.StartColumn="startColumn",t.RowCount="rowCount",t.ColumnCount="columnCount",t.Rows="rows",t.OverwriteIfStale="overwriteIfStale",t.FileType="fileType",t.EventType="eventType",t.Handler="handler",t.SliceSize="sliceSize",t.SliceIndex="sliceIndex",t.ActiveView="activeView",t.Status="status",t.PlatformType="platformType",t.HostType="hostType",t.Email="email",t.OfficeTheme="officeTheme",t.DocumentTheme="documentTheme",t.ForceConsent="forceConsent",t.ForceAddAccount="forceAddAccount",t.AuthChallenge="authChallenge",t.AllowConsentPrompt="allowConsentPrompt",t.ForMSGraphAccess="forMSGraphAccess",t.AllowSignInPrompt="allowSignInPrompt",t.JsonPayload="jsonPayload",t.EnableNewHosts="enableNewHosts",t.AccountTypeFilter="accountTypeFilter",t.AddinTrustId="addinTrustId",t.Reserved="reserved",t.Tcid="tcid",t.Xml="xml",t.Namespace="namespace",t.Prefix="prefix",t.XPath="xPath",t.Text="text",t.ImageLeft="imageLeft",t.ImageTop="imageTop",t.ImageWidth="imageWidth",t.ImageHeight="imageHeight",t.TaskId="taskId",t.FieldId="fieldId",t.FieldValue="fieldValue",t.ServerUrl="serverUrl",t.ListName="listName",t.ResourceId="resourceId",t.ViewType="viewType",t.ViewName="viewName",t.GetRawValue="getRawValue",t.CellFormat="cellFormat",t.TableOptions="tableOptions",t.TaskIndex="taskIndex",t.ResourceIndex="resourceIndex",t.CustomFieldId="customFieldId",t.Url="url",t.MessageHandler="messageHandler",t.Width="width",t.Height="height",t.RequireHTTPs="requireHTTPS",t.DisplayInIframe="displayInIframe",t.HideTitle="hideTitle",t.UseDeviceIndependentPixels="useDeviceIndependentPixels",t.PromptBeforeOpen="promptBeforeOpen",t.EnforceAppDomain="enforceAppDomain",t.UrlNoHostInfo="urlNoHostInfo",t.Base64="base64",t.FormId="formId"}(OSF=OSF||{}),function(s){var e;function r(n,r){var o=(new Date).getTime();return function(e){r.onReceiving&&r.onReceiving();var t=e.toArray?e.toArray()[0]:e;return r.onComplete&&r.onComplete(t),s.AppTelemetry&&s.AppTelemetry.onRegisterDone(n,r.dispId,Math.abs((new Date).getTime()-o),t),!0}}function c(e){var t=e;if(null!=e&&e.toArray){var n=e.toArray();t=new Array(n.length);for(var r=0;r<n.length;r++)t[r]=c(n[r])}return t}(e=s.SafeArrayDelegate||(s.SafeArrayDelegate={})).executeAsync=function(a){try{a.onCalling&&a.onCalling(),s._OfficeAppFactory.getClientHostController().execute(a.dispId,function e(t){var n=t;if(s.OUtil.isArray(t))for(var r=n.length,o=0;o<r;o++)n[o]=e(n[o]);else if(s.OUtil.isDate(t))n=t.getVarDate();else if("object"==typeof t&&!s.OUtil.isArray(t))for(var i in n=[],t)s.OUtil.isFunction(t[i])||(n[i]=e(t[i]));return n}(a.hostCallArgs),function(e){var t,n;if(1==(n="number"==typeof e?(t=[],e):(t=e.toArray())[0]))return null!=(r=c(r=t[1]))&&(a._chunkResultData||(a._chunkResultData=new Array),a._chunkResultData[r[0]]=r[1]),!1;if(a.onReceiving&&a.onReceiving(),a.onComplete){var r;if(0==n){if(2<t.length){r=[];for(var o=1;o<t.length;o++)r[o-1]=t[o]}else r=t[1];if(a._chunkResultData&&null!=(r=c(r))){var i=r[r.length-1];a._chunkResultData.length==i?r[r.length-1]=a._chunkResultData:n=5001}}else r=t[1];a.onComplete(n,r)}return!0})}catch(e){s.SafeArrayDelegate.onException(e,a)}},e.registerEventAsync=function(n){n.onCalling&&n.onCalling();var e=r(!0,n);try{s._OfficeAppFactory.getClientHostController().registerEvent(n.dispId,void 0,n.targetId,function(e,t){n.onEvent&&n.onEvent(t),s.AppTelemetry&&s.AppTelemetry.onEventDone(n.dispId)},e)}catch(e){s.SafeArrayDelegate.onException(e,n)}},e.unregisterEventAsync=function(t){t.onCalling&&t.onCalling();var e=r(!1,t);try{s._OfficeAppFactory.getClientHostController().unregisterEvent(t.dispId,void 0,t.targetId,e)}catch(e){s.SafeArrayDelegate.onException(e,t)}},e.onException=function(e,t){var n,r=e.number;if(r)switch(r){case-2146828218:n=7e3;break;case-2147467259:n=t.dispId==s.EventDispId.dispidDialogMessageReceivedEvent?12007:5001;break;case-2146828283:case-2147209089:n=5010;break;case-2147208704:n=5100;break;case-2146827850:default:n=5001}t.onComplete&&t.onComplete(n||5001)},e.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},e.getOnAfterRegisterEvent=r}(OSF=OSF||{}),function(e){var t=(Object.defineProperty(n.prototype,"type",{get:function(){return e.EventType.SettingsChanged},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"settings",{get:function(){return this.m_settingsInstance},enumerable:!0,configurable:!0}),n);function n(e){this.m_settingsInstance=e}e.SettingsChangedEventArgs=t}(OSF=OSF||{}),function(t){var e=(n.prototype.addComplexType=function(e){this._complexTypes.push(e)},n.prototype.getDynamicType=function(e){return this.dynamicTypes[e]},n.prototype.setDynamicType=function(e,t){this.dynamicTypes[e]=t},n.prototype.isComplexType=function(e){return t.OUtil.listContainsValue(this._complexTypes,e)},n.prototype.isDynamicType=function(e){return t.OUtil.listContainsKey(this.dynamicTypes,e)},n.prototype.preserveNesting=function(e){return!1},n.prototype.pack=function(e,t){return this.isDynamicType(e)?this.dynamicTypes[e].toHost(t):t},n.prototype.unpack=function(e,t){return this.isDynamicType(e)?this.dynamicTypes[e].fromHost(t):t},n);function n(e,t){this._complexTypes=e,this.dynamicTypes=t}t.SpecialProcessor=e}(OSF=OSF||{});__extends=this&&this.__extends||function(){var r=function(e,t){return(r=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])})(e,t)};return function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}}();!function(r){var t,e=(t=r.SpecialProcessor,__extends(n,t),n.prototype.unpack=function(e,t){return this.isComplexType(e)||r.ListType.isListType(e)?void 0!==t&&void 0!==t.toArray?t.toArray():t||{}:this.isDynamicType(e)?this.dynamicTypes[e].fromHost(t):t},n);function n(){var e={};return e[r.ParameterNames.Data]={toHost:function(e){if(r.TableDataProperties&&"string"!=typeof e&&void 0!==e[r.TableDataProperties.TableRows]){var t=[];t[0]=e[r.TableDataProperties.TableRows],t[1]=e[r.TableDataProperties.TableHeaders],e=t}return e},fromHost:function(e){var t;if(e.toArray)if(2===e.dimensions())t=r.Utility.twoDVBArrayToJaggedArray(e);else{var n=e.toArray();2===n.length&&(null!=n[0]&&n[0].toArray||null!=n[1]&&n[1].toArray)?((t={})[r.TableDataProperties.TableRows]=r.Utility.twoDVBArrayToJaggedArray(n[0]),t[r.TableDataProperties.TableHeaders]=r.Utility.twoDVBArrayToJaggedArray(n[1])):t=n}else t=e;return t}},t.call(this,[],e)||this}r.SafeArraySpecialProcessor=e}(OSF=OSF||{}),function(s){var e=(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(e,t,n,r){if(e.length>this._requiredCount+1)throw s.Utility.createParameterException(Strings.OfficeOM.L_TooManyArguments);for(var o,i=e.length-1;i>=this._requiredCount;i--){var a=e[i];switch(typeof a){case"object":if(o)throw s.Utility.createParameterException(Strings.OfficeOM.L_TooManyArguments);o=a;break;default:throw s.Utility.createArgumentException(Strings.OfficeOM.L_InValidOptionalArgument)}}return o=this._apiMethods.fillOptions(o,t,n,r),this._apiMethods.verifyArguments(this._supportedOptions,o),o},t);function t(e,t,n,r,o){this._requiredCount=e.length,this._apiMethods=new s.ApiMethodCall(e,t,n,r,o),this._supportedOptions=t}s.SyncMethodCall=e}(OSF=OSF||{}),function(r){var e,o;e=r.SyncMethodCalls||(r.SyncMethodCalls={}),o={},e.define=function(e){var t,n;o[e.method]=(n=(t=e).supportedOptions?r.OUtil.createObject(t.supportedOptions):[],new r.SyncMethodCall(t.requiredArguments||[],n,t.privateStateCallbacks,t.checkCallArgs,t.method.displayName))},e.get=function(e){return o[e]}}(OSF=OSF||{}),(OSF||(OSF={})).SyncMethods={MessageParent:"messageParent",MessageChild:"messageChild",SendMessage:"sendMessage",AddMessageHandler:"addEventHandler"},function(l){var e;(function(e){var t,n,r,o;function i(e){for(var t=[{name:l.DDA.Theming.DocumentThemeEnum.PrimaryFontColor,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.PrimaryBackgroundColor,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.SecondaryFontColor,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.SecondaryBackgroundColor,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.Accent1,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.Accent2,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.Accent3,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.Accent4,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.Accent5,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.Accent6,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.Hyperlink,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.FollowedHyperlink,needToConvertToHex:!0},{name:l.DDA.Theming.DocumentThemeEnum.HeaderLatinFont,needToConvertToHex:!1},{name:l.DDA.Theming.DocumentThemeEnum.HeaderEastAsianFont,needToConvertToHex:!1},{name:l.DDA.Theming.DocumentThemeEnum.HeaderScriptFont,needToConvertToHex:!1},{name:l.DDA.Theming.DocumentThemeEnum.HeaderLocalizedFont,needToConvertToHex:!1},{name:l.DDA.Theming.DocumentThemeEnum.BodyLatinFont,needToConvertToHex:!1},{name:l.DDA.Theming.DocumentThemeEnum.BodyEastAsianFont,needToConvertToHex:!1},{name:l.DDA.Theming.DocumentThemeEnum.BodyScriptFont,needToConvertToHex:!1},{name:l.DDA.Theming.DocumentThemeEnum.BodyLocalizedFont,needToConvertToHex:!1}],n={},r=0;r<t.length;r++)t[r].needToConvertToHex?n[t[r].name]=l.OUtil.convertIntToCssHexColor(e[t[r].name]):n[t[r].name]=e[t[r].name];return n}function a(e){var t={};if(e){var n=l.DDA.Theming.OfficeThemeEnum,r={bodyBackgroundColor:{name:n.BodyBackgroundColor,convertToHex:!0},bodyForegroundColor:{name:n.BodyForegroundColor,convertToHex:!0},controlBackgroundColor:{name:n.ControlBackgroundColor,convertToHex:!0},controlForegroundColor:{name:n.ControlForegroundColor,convertToHex:!0},primaryFontColor:{name:n.BodyForegroundColor,convertToHex:!0},primaryBackgroundColor:{name:n.BodyBackgroundColor,convertToHex:!0},secondaryFontColor:{name:n.ControlForegroundColor,convertToHex:!0},secondaryBackgroundColor:{name:n.ControlBackgroundColor,convertToHex:!0},fluentThemeData:{name:n.FluentThemeData,convertToHex:!1}};for(var o in e){var i=!1,a=o;r[o]&&(a=r[o].name,i=r[o].convertToHex),t[a]=i?l.OUtil.convertIntToCssHexColor(e[o]):e[o]}null==t[n.IsDarkTheme]&&(t[n.IsDarkTheme]=l.DDA.Theming.GetIsDarkThemeFromCSSHexColor(t[n.BodyBackgroundColor])),null==t[n.ThemeId]&&(t[n.ThemeId]=t[n.IsDarkTheme]?l.DDA.Theming.ThemeId.Black:l.DDA.Theming.ThemeId.White)}return t}(t=e.DocumentThemeEnum||(e.DocumentThemeEnum={})).PrimaryFontColor="primaryFontColor",t.PrimaryBackgroundColor="primaryBackgroundColor",t.SecondaryFontColor="secondaryFontColor",t.SecondaryBackgroundColor="secondaryBackgroundColor",t.Accent1="accent1",t.Accent2="accent2",t.Accent3="accent3",t.Accent4="accent4",t.Accent5="accent5",t.Accent6="accent6",t.Hyperlink="hyperlink",t.FollowedHyperlink="followedHyperlink",t.HeaderLatinFont="headerLatinFont",t.HeaderEastAsianFont="headerEastAsianFont",t.HeaderScriptFont="headerScriptFont",t.HeaderLocalizedFont="headerLocalizedFont",t.BodyLatinFont="bodyLatinFont",t.BodyEastAsianFont="bodyEastAsianFont",t.BodyScriptFont="bodyScriptFont",t.BodyLocalizedFont="bodyLocalizedFont",(n=e.OfficeThemeEnum||(e.OfficeThemeEnum={})).BodyBackgroundColor="bodyBackgroundColor",n.BodyForegroundColor="bodyForegroundColor",n.ControlBackgroundColor="controlBackgroundColor",n.ControlForegroundColor="controlForegroundColor",n.IsDarkTheme="isDarkTheme",n.ThemeId="themeId",n.FluentThemeData="fluentThemeData",(r=e.OfficeThemeEnumWac||(e.OfficeThemeEnumWac={})).PrimaryFontColor="primaryFontColor",r.PrimaryBackgroundColor="primaryBackgroundColor",r.SecondaryFontColor="secondaryFontColor",r.SecondaryBackgroundColor="secondaryBackgroundColor",r.IsDarkTheme="isDarkTheme",r.ThemeId="themeId",(o=e.ThemeId||(e.ThemeId={}))[o.Colorful=0]="Colorful",o[o.DarkGray=1]="DarkGray",o[o.Black=2]="Black",o[o.White=3]="White",e.ConvertToDocumentTheme=i,e.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},e.ConvertToOfficeTheme=a;function s(e){var t=null,n=l._OfficeAppFactory.getHostInfo();t=n.hostPlatform==l.HostInfoPlatform.web?e:a(e);var r=l.DDA.Theming.OfficeThemeEnum;void 0===t[r.IsDarkTheme]&&(t.isDarkTheme=l.DDA.Theming.GetIsDarkThemeFromCSSHexColor(e[r.BodyBackgroundColor])),void 0===t[r.ThemeId]&&(t.themeId=t.isDarkTheme?l.DDA.Theming.ThemeId.Black:l.DDA.Theming.ThemeId.White),n.hostPlatform!=l.HostInfoPlatform.web&&"mac"!=n.hostPlatform.toLowerCase()&&"ios"!=n.hostPlatform.toLowerCase()||Office.context&&Office.context.officeTheme&&(Office.context.officeTheme.bodyBackgroundColor=t.bodyBackgroundColor,Office.context.officeTheme.bodyForegroundColor=t.bodyForegroundColor,Office.context.officeTheme.controlBackgroundColor=t.controlBackgroundColor,Office.context.officeTheme.controlForegroundColor=t.controlForegroundColor,Office.context.officeTheme.isDarkTheme=t.isDarkTheme,Office.context.officeTheme.themeId=t.themeId),l.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.OfficeThemeChanged},officeTheme:{value:t}})}e.OfficeThemeChangedEventArgs=s;function c(e){var t=i(e);l.OUtil.defineEnumerableProperties(this,{type:{value:Microsoft.Office.WebExtension.EventType.DocumentThemeChanged},documentTheme:{value:t}})}e.DocumentThemeChangedEventArgs=c})((e=l.DDA||(l.DDA={})).Theming||(e.Theming={}))}(OSF=OSF||{}),function(t){var e,n;e=t.V10ApiFeatureRegistry||(t.V10ApiFeatureRegistry={}),n=[],e.initialize=function(){n.forEach(function(e){e.defineMethodsFunc(),t.OUtil.getHostPlatform()==t.HostInfoPlatform.web?"function"==typeof e.defineWebParameterMapFunc&&e.defineWebParameterMapFunc():"function"==typeof e.defineSafeArrayParameterMapFunc&&e.defineSafeArrayParameterMapFunc(),"function"==typeof e.initializeFunc&&e.initializeFunc()})},e.register=function(e){n.push(e)}}(OSF=OSF||{}),function(a){var e,t;function n(r,o){var i=(new Date).getTime();return function(e,t){var n;if(o.onReceiving&&o.onReceiving(),0!=e)switch(e){case-5:n=7e3;break;default:n=5001}else n=t?t.Error?t.Error:0:5001;o.onComplete&&o.onComplete(n),a.AppTelemetry&&a.AppTelemetry.onRegisterDone(r,o.dispId,Math.abs((new Date).getTime()-i),n)}}(e=a.WACDelegate||(a.WACDelegate={})).version=1,(t=e.UniqueArguments||(e.UniqueArguments={})).Data="Data",t.Properties="Properties",t.BindingRequest="DdaBindingsMethod",t.BindingResponse="Bindings",t.SingleBindingResponse="singleBindingResponse",t.GetData="DdaGetBindingData",t.AddRowsColumns="DdaAddRowsColumns",t.SetData="DdaSetBindingData",t.ClearFormats="DdaClearBindingFormats",t.SetFormats="DdaSetBindingFormats",t.SettingsRequest="DdaSettingsMethod",t.BindingEventSource="ddaBinding",t.ArrayData="ArrayData",e.executeAsync=function(r){r.hostCallArgs||(r.hostCallArgs={}),r.hostCallArgs.DdaMethod={ControlId:a._OfficeAppFactory.getId(),Version:a.WACDelegate.version,DispatchId:r.dispId},r.hostCallArgs.__timeout__=-1,r.onCalling&&r.onCalling(),a.getClientEndPoint()&&a.getClientEndPoint().invoke("executeMethod",function(e,t){var n;if(r.onReceiving&&r.onReceiving(),0==e)a.WACDelegate.version=t.Version,n=t.Error;else switch(e){case-5:n=7e3;break;default:n=5001}r.onComplete&&r.onComplete(n,t)},r.hostCallArgs)},e.getOnAfterRegisterEvent=n,e.registerEventAsync=function(t){t.onCalling&&t.onCalling(),a.getClientEndPoint()&&a.getClientEndPoint().registerForEvent(a.OUtil.getXdmEventName(t.targetId,t.eventType),function(e){t.onEvent&&t.onEvent(e),a.AppTelemetry&&a.AppTelemetry.onEventDone(t.dispId)},n(!0,t),{controlId:a._OfficeAppFactory.getId(),eventDispId:t.dispId,targetId:t.targetId})},e.unregisterEventAsync=function(e){e.onCalling&&e.onCalling(),a.getClientEndPoint()&&a.getClientEndPoint().unregisterForEvent(a.OUtil.getXdmEventName(e.targetId,e.eventType),n(!1,e),{controlId:a._OfficeAppFactory.getId(),eventDispId:e.dispId,targetId:e.targetId})}}(OSF=OSF||{}),function(t){var n,e=(n=t.SpecialProcessor,__extends(r,n),r);function r(){var e=[t.WACDelegate.UniqueArguments.SingleBindingResponse,t.WACDelegate.UniqueArguments.BindingRequest,t.WACDelegate.UniqueArguments.BindingResponse,t.WACDelegate.UniqueArguments.GetData,t.WACDelegate.UniqueArguments.AddRowsColumns,t.WACDelegate.UniqueArguments.SetData,t.WACDelegate.UniqueArguments.ClearFormats,t.WACDelegate.UniqueArguments.SetFormats,t.WACDelegate.UniqueArguments.SettingsRequest,t.WACDelegate.UniqueArguments.BindingEventSource];return n.call(this,e,{})||this}t.WebSpecialProcessor=e}(OSF=OSF||{});__extends=this&&this.__extends||function(){var r=function(e,t){return(r=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])})(e,t)};return function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}}();!function(e){var t,n,r;t=e.context||(e.context={}),n=t.document||(t.document={}),(r=n.bindings||(n.bindings={}))._eventDispatches=[],r.addFromSelectionAsync=function(e,t,n){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.AddFromSelectionAsync,arguments,this,void 0)},r.addFromNamedItemAsync=function(e,t,n,r){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.AddFromNamedItemAsync,arguments,this,void 0)},r.addFromPromptAsync=function(e,t,n){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.AddFromPromptAsync,arguments,this,void 0)},r.getAllAsync=function(e,t){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.GetAllAsync,arguments,this,void 0)},r.getByIdAsync=function(e,t,n){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.GetByIdAsync,arguments,this,void 0)},r.releaseByIdAsync=function(e,t,n){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.ReleaseByIdAsync,arguments,this,void 0)}}(Office=Office||{}),function(s){var e,t,n,r,o,i,a;function c(e){return s.manufactureBinding(e,Office.context.document)}function l(e){return e.id}function u(e,t,n){var r=e[s.ParameterNames.Data];return s.TableDataProperties&&r&&(null!=r[s.TableDataProperties.TableRows]||null!=r[s.TableDataProperties.TableHeaders])&&(r=Office.manufactureTableData(r)),null==(r=s.DataCoercion.coerceData(r,n[s.ParameterNames.CoercionType]))?null:r}(e=s.BindingProperties||(s.BindingProperties={})).Id="BindingId",e.Type="bindingType",e.RowCount="RowCount",e.ColumnCount="BindingColumnCount",e.HasHeaders="HasHeaders",(s.ListDescriptors||(s.ListDescriptors={})).BindingList="BindingList",s.ListType.setListType(s.ListDescriptors.BindingList,s.PropertyDescriptors.BindingProperties),(s.EventDescriptors||(s.EventDescriptors={})).BindingSelectionChangedEvent="BindingSelectionChangedEvent",t=s.Marshaling||(s.Marshaling={}),(n=t.BindingParameterKeys||(t.BindingParameterKeys={})).Id="BindingId",n.BindingType="BindingType",n.ItemName="ItemName",n.StartRow="StartRow",n.StartCol="StartCol",n.RowCount="RowCount",n.ColCount="ColCount",(r=t.TableBindingParameterKeys||(t.TableBindingParameterKeys={})).TableHeaders="TableHeaders",r.TableRows="TableRows",(o=t.AppBindingKeys||(t.AppBindingKeys={})).BindingId="Name",o.BindingType="BindingType",o[o.BindingProperties=0]="BindingProperties",o.BindingEventSource="ddaBinding",o.RowCount="RowCount",o.ColumnCount="ColCount",o.HasHeaders="HasHeaders",(i=t.TableSubsetKeys||(t.TableSubsetKeys={})).TableSubset="subset",i.StartRow="startRow",i.StartColumn="startColumn",i.RowCount="rowCount",i.ColumnCount="columnCount",(a=t.BindingType||(t.BindingType={}))[a.Table=1]="Table",a[a.Text=2]="Text",a[a.Matrix=3]="Matrix",s.Bindings||(s.Bindings={}),s.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){s.AsyncMethodCalls.define({method:s.AsyncMethods.AddFromPromptAsync,requiredArguments:[{name:s.ParameterNames.BindingType,enum:Office.BindingType}],supportedOptions:[{name:s.ParameterNames.Id,value:{types:["string"],calculate:N}},{name:s.ParameterNames.PromptText,value:{types:["string"],calculate:function(){return Strings.OfficeOM.L_AddBindingFromPromptDefaultText}}},{name:s.ParameterNames.SampleData,value:{types:["object"],defaultValue:null}}],privateStateCallbacks:[],onSucceeded:function(e){return s.manufactureBinding(e,Office.context.document)}}),s.AsyncMethodCalls.define({method:s.AsyncMethods.AddFromSelectionAsync,requiredArguments:[{name:s.ParameterNames.BindingType,enum:Office.BindingType}],supportedOptions:[{name:s.ParameterNames.Id,value:{types:["string"],calculate:N}},{name:s.ParameterNames.Columns,value:{types:["object"],defaultValue:null}}],privateStateCallbacks:[],onSucceeded:c}),s.AsyncMethodCalls.define({method:s.AsyncMethods.AddFromNamedItemAsync,requiredArguments:[{name:s.ParameterNames.ItemName,types:["string"]},{name:s.ParameterNames.BindingType,enum:Office.BindingType}],supportedOptions:[{name:s.ParameterNames.Id,value:{types:["string"],calculate:N}},{name:s.ParameterNames.Columns,value:{types:["object"],defaultValue:null}}],privateStateCallbacks:[{name:s.ParameterNames.FailOnCollision,value:function(){return!0}}],onSucceeded:c}),s.AsyncMethodCalls.define({method:s.AsyncMethods.GetAllAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[],onSucceeded:function(e){return e[s.ListDescriptors.BindingList].map(c)}}),s.AsyncMethodCalls.define({method:s.AsyncMethods.GetByIdAsync,requiredArguments:[{name:s.ParameterNames.Id,types:["string"]}],supportedOptions:[],privateStateCallbacks:[],onSucceeded:c}),s.AsyncMethodCalls.define({method:s.AsyncMethods.ReleaseByIdAsync,requiredArguments:[{name:s.ParameterNames.Id,types:["string"]}],supportedOptions:[],privateStateCallbacks:[],onSucceeded:function(e,t,n){var r=n[s.ParameterNames.Id];delete t._eventDispatches[r]}}),s.AsyncMethodCalls.define({method:s.AsyncMethods.GetDataAsync,requiredArguments:[],supportedOptions:[{name:s.ParameterNames.CoercionType,value:{enum:Office.CoercionType,calculate:function(e,t){return s.DataCoercion.getCoercionDefaultForBinding(t.type)}}},{name:s.ParameterNames.ValueFormat,value:{enum:Office.ValueFormat,defaultValue:Office.ValueFormat.Unformatted}},{name:s.ParameterNames.FilterType,value:{enum:Office.FilterType,defaultValue:Office.FilterType.All}},{name:s.ParameterNames.Rows,value:{types:["object","string"],defaultValue:null}},{name:s.ParameterNames.Columns,value:{types:["object"],defaultValue:null}},{name:s.ParameterNames.StartRow,value:{types:["number"],defaultValue:0}},{name:s.ParameterNames.StartColumn,value:{types:["number"],defaultValue:0}},{name:s.ParameterNames.RowCount,value:{types:["number"],defaultValue:0}},{name:s.ParameterNames.ColumnCount,value:{types:["number"],defaultValue:0}}],checkCallArgs:function(e,t,n){if(0==e[s.ParameterNames.StartRow]&&0==e[s.ParameterNames.StartColumn]&&0==e[s.ParameterNames.RowCount]&&0==e[s.ParameterNames.ColumnCount]&&(delete e[s.ParameterNames.StartRow],delete e[s.ParameterNames.StartColumn],delete e[s.ParameterNames.RowCount],delete e[s.ParameterNames.ColumnCount]),e[s.ParameterNames.CoercionType]!=s.DataCoercion.getCoercionDefaultForBinding(t.type)&&(e[s.ParameterNames.StartRow]||e[s.ParameterNames.StartColumn]||e[s.ParameterNames.RowCount]||e[s.ParameterNames.ColumnCount]))throw 1002;return e},privateStateCallbacks:[{name:s.ParameterNames.Id,value:l}],onSucceeded:u}),s.AsyncMethodCalls.define({method:s.AsyncMethods.SetDataAsync,requiredArguments:[{name:s.ParameterNames.Data,types:["string","object","number","boolean"]}],supportedOptions:[{name:s.ParameterNames.CoercionType,value:{enum:Office.CoercionType,calculate:function(e){return s.DataCoercion.determineCoercionType(e[s.ParameterNames.Data])}}},{name:s.ParameterNames.Rows,value:{types:["object","string"],defaultValue:null}},{name:s.ParameterNames.Columns,value:{types:["object"],defaultValue:null}},{name:s.ParameterNames.StartRow,value:{types:["number"],defaultValue:0}},{name:s.ParameterNames.StartColumn,value:{types:["number"],defaultValue:0}}],checkCallArgs:function(e,t,n){if(0==e[s.ParameterNames.StartRow]&&0==e[s.ParameterNames.StartColumn]&&(delete e[s.ParameterNames.StartRow],delete e[s.ParameterNames.StartColumn]),e[s.ParameterNames.CoercionType]!=s.DataCoercion.getCoercionDefaultForBinding(t.type)&&(e[s.ParameterNames.StartRow]||e[s.ParameterNames.StartColumn]))throw 1002;return e},privateStateCallbacks:[{name:s.ParameterNames.Id,value:l}]})},defineSafeArrayParameterMapFunc:function(){s.HostParameterMap.define({type:"bindingSpecificData",fromHost:[{name:s.BindingProperties.RowCount,value:0},{name:s.BindingProperties.ColumnCount,value:1},{name:s.BindingProperties.HasHeaders,value:2}],isComplexType:!0}),s.HostParameterMap.define({type:s.PropertyDescriptors.Subset,toHost:[{name:"offset",value:0},{name:"run",value:1}],canonical:!0,isComplexType:!0}),s.HostParameterMap.define({type:"offset",toHost:[{name:s.ParameterNames.StartRow,value:0},{name:s.ParameterNames.StartColumn,value:1}],canonical:!0,isComplexType:!0}),s.HostParameterMap.define({type:"run",toHost:[{name:s.ParameterNames.RowCount,value:0},{name:s.ParameterNames.ColumnCount,value:1}],canonical:!0,isComplexType:!0}),s.HostParameterMap.define({type:"run",toHost:[{name:s.ParameterNames.RowCount,value:0},{name:s.ParameterNames.ColumnCount,value:1}],canonical:!0,isComplexType:!0}),s.HostParameterMap.define({type:79,toHost:[{name:s.ParameterNames.Id,value:0},{name:s.ParameterNames.Data,value:1}]}),s.HostParameterMap.define({type:73,toHost:[{name:s.ParameterNames.Id,value:0}]}),s.HostParameterMap.define({type:s.PropertyDescriptors.BindingProperties,fromHost:[{name:s.BindingProperties.Id,value:0},{name:s.BindingProperties.Type,value:1},{name:"bindingSpecificData",value:2}],isComplexType:!0}),s.HostParameterMap.define({type:s.ParameterNames.BindingType,toHost:[{name:Office.BindingType.Text,value:0},{name:Office.BindingType.Matrix,value:1},{name:Office.BindingType.Table,value:2}],invertible:!0}),s.HostParameterMap.define({type:66,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.HostParameterMap.self}],toHost:[{name:s.ParameterNames.Id,value:0},{name:s.ParameterNames.BindingType,value:1}]}),s.HostParameterMap.define({type:78,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.HostParameterMap.self}],toHost:[{name:s.ParameterNames.ItemName,value:0},{name:s.ParameterNames.Id,value:1},{name:s.ParameterNames.BindingType,value:2},{name:s.ParameterNames.FailOnCollision,value:3}]}),s.HostParameterMap.define({type:67,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.HostParameterMap.self}],toHost:[{name:s.ParameterNames.Id,value:0},{name:s.ParameterNames.BindingType,value:1},{name:s.ParameterNames.PromptText,value:2}]}),s.HostParameterMap.define({type:69,toHost:[{name:s.ParameterNames.Id,value:0}]}),s.HostParameterMap.define({type:68,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.HostParameterMap.self}],toHost:[{name:s.ParameterNames.Id,value:0}]}),s.HostParameterMap.define({type:74,fromHost:[{name:s.ListDescriptors.BindingList,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:70,fromHost:[{name:s.ParameterNames.Data,value:s.HostParameterMap.self}],toHost:[{name:s.ParameterNames.Id,value:0},{name:s.ParameterNames.CoercionType,value:1},{name:s.ParameterNames.ValueFormat,value:2},{name:s.ParameterNames.FilterType,value:3},{name:s.PropertyDescriptors.Subset,value:4}]}),s.HostParameterMap.define({type:71,toHost:[{name:s.ParameterNames.Id,value:0},{name:s.ParameterNames.CoercionType,value:1},{name:s.ParameterNames.Data,value:2},{name:"offset",value:3}]})},defineWebParameterMapFunc:function(){s.HostParameterMap.define({type:72,toHost:[{name:s.WACDelegate.UniqueArguments.AddRowsColumns,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:79,toHost:[{name:s.WACDelegate.UniqueArguments.AddRowsColumns,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:73,toHost:[{name:s.WACDelegate.UniqueArguments.BindingRequest,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:s.WACDelegate.UniqueArguments.AddRowsColumns,toHost:[{name:s.ParameterNames.Id,value:"BindingId"},{name:s.ParameterNames.Data,value:s.WACDelegate.UniqueArguments.Data}]}),s.HostParameterMap.define({type:s.PropertyDescriptors.Subset,fromHost:[{name:s.ParameterNames.StartRow,value:"StartRow"},{name:s.ParameterNames.StartColumn,value:"StartCol"},{name:s.ParameterNames.RowCount,value:"RowCount"},{name:s.ParameterNames.ColumnCount,value:"ColCount"}]}),s.HostParameterMap.define({type:s.WACDelegate.UniqueArguments.BindingRequest,toHost:[{name:s.ParameterNames.ItemName,value:"ItemName"},{name:s.ParameterNames.Id,value:"BindingId"},{name:s.ParameterNames.BindingType,value:"BindingType"},{name:s.ParameterNames.PromptText,value:"PromptText"},{name:s.ParameterNames.Columns,value:"Columns"},{name:s.ParameterNames.SampleData,value:"SampleData"},{name:s.ParameterNames.FailOnCollision,value:"FailOnCollision"}]}),s.HostParameterMap.addComplexType(s.PropertyDescriptors.BindingProperties),s.HostParameterMap.define({type:s.ParameterNames.BindingType,toHost:[{name:Office.BindingType.Text,value:2},{name:Office.BindingType.Matrix,value:3},{name:Office.BindingType.Table,value:1}],invertible:!0}),s.HostParameterMap.define({type:s.PropertyDescriptors.BindingProperties,fromHost:[{name:s.BindingProperties.Id,value:"Name"},{name:s.BindingProperties.Type,value:"BindingType"},{name:s.BindingProperties.RowCount,value:"RowCount"},{name:s.BindingProperties.ColumnCount,value:"ColCount"},{name:s.BindingProperties.HasHeaders,value:"HasHeaders"}]}),s.HostParameterMap.define({type:s.WACDelegate.UniqueArguments.SingleBindingResponse,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:0}]}),s.HostParameterMap.define({type:66,fromHost:[{name:s.WACDelegate.UniqueArguments.SingleBindingResponse,value:s.WACDelegate.UniqueArguments.BindingResponse}],toHost:[{name:s.WACDelegate.UniqueArguments.BindingRequest,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:67,fromHost:[{name:s.WACDelegate.UniqueArguments.SingleBindingResponse,value:s.WACDelegate.UniqueArguments.BindingResponse}],toHost:[{name:s.WACDelegate.UniqueArguments.BindingRequest,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:78,fromHost:[{name:s.WACDelegate.UniqueArguments.SingleBindingResponse,value:s.WACDelegate.UniqueArguments.BindingResponse}],toHost:[{name:s.WACDelegate.UniqueArguments.BindingRequest,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:69,toHost:[{name:s.WACDelegate.UniqueArguments.BindingRequest,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:68,fromHost:[{name:s.WACDelegate.UniqueArguments.SingleBindingResponse,value:s.WACDelegate.UniqueArguments.BindingResponse}],toHost:[{name:s.WACDelegate.UniqueArguments.BindingRequest,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:74,fromHost:[{name:s.ListDescriptors.BindingList,value:s.WACDelegate.UniqueArguments.BindingResponse}]}),s.HostParameterMap.define({type:70,fromHost:[{name:s.ParameterNames.Data,value:s.WACDelegate.UniqueArguments.Data}],toHost:[{name:s.WACDelegate.UniqueArguments.GetData,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:71,toHost:[{name:s.WACDelegate.UniqueArguments.SetData,value:s.HostParameterMap.self}]})},initializeFunc:function(){s.manufactureBinding=function(e,t){var n,r=e[s.BindingProperties.Id],o=e[s.BindingProperties.RowCount],i=e[s.BindingProperties.ColumnCount],a=e[s.BindingProperties.HasHeaders];switch(e[s.BindingProperties.Type]){case Office.BindingType.Text:n=new s.TextBinding(r,t);break;case Office.BindingType.Matrix:n=null,n=new s.MatrixBinding(r,t,o,i);break;case Office.BindingType.Table:n=new(s._OfficeAppFactory.getHostInfo().hostType==s.HostInfoHostType.excel&&Office.context.document&&s.ExcelTableBinding?s.ExcelTableBinding:s.TableBinding)(r,t,o,i,a);break;default:n=new s.UnknownBinding(r,t)}return n}}}),s.BindingEvents||(s.BindingEvents={}),s.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){},defineSafeArrayParameterMapFunc:function(){s.HostParameterMap.define({type:s.EventDispId.dispidBindingSelectionChangedEvent,fromHost:[{name:s.EventDescriptors.BindingSelectionChangedEvent,value:s.HostParameterMap.self}],isComplexType:!0}),s.HostParameterMap.define({type:s.EventDispId.dispidBindingDataChangedEvent,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.HostParameterMap.self}]})},defineWebParameterMapFunc:function(){s.HostParameterMap.define({type:s.EventDescriptors.BindingSelectionChangedEvent,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.WACDelegate.UniqueArguments.BindingEventSource},{name:s.PropertyDescriptors.Subset,value:s.PropertyDescriptors.Subset}]}),s.HostParameterMap.define({type:s.EventDispId.dispidBindingSelectionChangedEvent,fromHost:[{name:s.EventDescriptors.BindingSelectionChangedEvent,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:s.EventDispId.dispidBindingDataChangedEvent,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.WACDelegate.UniqueArguments.BindingEventSource}]})}});var p=(Object.defineProperty(f.prototype,"onFail",{get:function(){return this.m_errorCallback},set:function(e){var t=typeof e;if("undefined"!=t&&"function"!=t)throw s.OUtil.formatString(Strings.OfficeOM.L_CallbackNotAFunction,t);this.m_errorCallback=e},enumerable:!0,configurable:!0}),f.prototype._fetch=function(t){if(this.m_binding)t&&t(this.m_binding);else if(!this.m_binding){var n=this;Office.context.document.bindings.getByIdAsync(this.m_id,function(e){e.status==Office.AsyncResultStatus.Succeeded?(s.OUtil.defineEnumerableProperty(n,"binding",{value:e.value}),t&&t(n.m_binding)):n.onFail&&n.onFail(e)})}return this},f.prototype.getDataAsync=function(){var t=arguments;return this._fetch(function(e){e.getDataAsync.apply(e,t)}),this},f.prototype.setDataAsync=function(){var t=arguments;return this._fetch(function(e){e.setDataAsync.apply(e,t)}),this},f.prototype.addHandlerAsync=function(){var t=arguments;return this._fetch(function(e){e.addHandlerAsync.apply(e,t)}),this},f.prototype.removeHandlerAsync=function(){var t=arguments;return this._fetch(function(e){e.removeHandlerAsync.apply(e,t)}),this},f.prototype.setTableOptionsAsync=function(){var t=arguments;return this._fetch(function(e){e.setTableOptionsAsync.apply(e,t)}),this},f.prototype.setFormatsAsync=function(){var t=arguments;return this._fetch(function(e){e.setFormatsAsync.apply(e,t)}),this},f.prototype.clearFormatsAsync=function(){var t=arguments;return this._fetch(function(e){e.clearFormatsAsync.apply(e,t)}),this},f);function f(e){this.m_id=e}s.BindingPromise=p;var d=(Object.defineProperty(h.prototype,"document",{get:function(){return this.m_docInstance},enumerable:!0,configurable:!0}),Object.defineProperty(h.prototype,"id",{get:function(){return this.m_id},enumerable:!0,configurable:!0}),h);function h(e,t){this.m_id=e,this.m_docInstance=t}s.UnknownBinding=d;var g=(m.prototype.getDataAsync=function(e,t){s.DispIdHost.InvokeMethod(s.AsyncMethods.GetDataAsync,arguments,this,void 0)},m.prototype.setDataAsync=function(e,t,n){s.DispIdHost.InvokeMethod(s.AsyncMethods.SetDataAsync,arguments,this,void 0)},Object.defineProperty(m.prototype,"document",{get:function(){return this.m_docInstance},enumerable:!0,configurable:!0}),Object.defineProperty(m.prototype,"id",{get:function(){return this.m_id},enumerable:!0,configurable:!0}),m);function m(e,t){this.m_id=e,this.m_docInstance=t;var n=s.EventType,r=t.bindings._eventDispatches;r[e]||(r[e]=new s.EventDispatch([n.BindingSelectionChanged,n.BindingDataChanged]));var o=r[e];s.DispIdHost.addEventSupport(this,o)}s.Binding=g;var y,_=(y=s.Binding,__extends(b,y),Object.defineProperty(b.prototype,"type",{get:function(){return Office.BindingType.Matrix},enumerable:!0,configurable:!0}),Object.defineProperty(b.prototype,"rowCount",{get:function(){return this.m_rows?this.m_rows:0},enumerable:!0,configurable:!0}),Object.defineProperty(b.prototype,"columnCount",{get:function(){return this.m_cols?this.m_cols:0},enumerable:!0,configurable:!0}),b);function b(e,t,n,r){var o=y.call(this,e,t)||this;return o.m_rows=n,o.m_cols=r,o}s.MatrixBinding=_;var v,O=(v=s.Binding,__extends(C,v),Object.defineProperty(C.prototype,"type",{get:function(){return Office.BindingType.Table},enumerable:!0,configurable:!0}),Object.defineProperty(C.prototype,"rowCount",{get:function(){return this.m_rows?this.m_rows:0},enumerable:!0,configurable:!0}),Object.defineProperty(C.prototype,"columnCount",{get:function(){return this.m_cols?this.m_cols:0},enumerable:!0,configurable:!0}),Object.defineProperty(C.prototype,"hasHeaders",{get:function(){return!!this.m_hasHeaders&&this.m_hasHeaders},enumerable:!0,configurable:!0}),C.prototype.addRowsAsync=function(e,t,n){s.DispIdHost.InvokeMethod(s.AsyncMethods.AddRowsAsync,arguments,this,void 0)},C.prototype.addColumnsAsync=function(e,t,n){s.DispIdHost.InvokeMethod(s.AsyncMethods.AddColumnsAsync,arguments,this,void 0)},C.prototype.deleteAllDataValuesAsync=function(e,t){s.DispIdHost.InvokeMethod(s.AsyncMethods.DeleteAllDataValuesAsync,arguments,this,void 0)},C);function C(e,t,n,r,o){var i=v.call(this,e,t)||this;return i.m_rows=n,i.m_cols=r,i.m_hasHeaders=o,i}s.TableBinding=O;var P,S=(P=s.TableBinding,__extends(A,P),A.prototype.clearFormatsAsync=function(e,t){s.DispIdHost.InvokeMethod(s.AsyncMethods.ClearFormatsAsync,arguments,this,void 0)},A.prototype.setTableOptionsAsync=function(e,t,n){s.DispIdHost.InvokeMethod(s.AsyncMethods.SetTableOptionsAsync,arguments,this,void 0)},A.prototype.setFormatsAsync=function(e,t,n){s.DispIdHost.InvokeMethod(s.AsyncMethods.SetFormatsAsync,arguments,this,void 0)},A);function A(e,t,n,r,o){var i=P.call(this,e,t,n,r,o)||this;return s.OUtil.finalizeProperties(i),i}function I(e){return e.id}s.ExcelTableBinding=S,s.TableBindingMethods||(s.TableBindingMethods={}),s.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){s.AsyncMethodCalls.define({method:s.AsyncMethods.AddRowsAsync,requiredArguments:[{name:s.ParameterNames.Data,types:["object"]}],supportedOptions:[],privateStateCallbacks:[{name:s.ParameterNames.Id,value:I}]}),s.AsyncMethodCalls.define({method:s.AsyncMethods.AddColumnsAsync,requiredArguments:[{name:s.ParameterNames.Data,types:["object"]}],supportedOptions:[],privateStateCallbacks:[{name:s.ParameterNames.Id,value:I}]}),s.AsyncMethodCalls.define({method:s.AsyncMethods.DeleteAllDataValuesAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[{name:s.ParameterNames.Id,value:I}]})}});var R,T=(R=s.Binding,__extends(E,R),Object.defineProperty(E.prototype,"type",{get:function(){return Office.BindingType.Text},enumerable:!0,configurable:!0}),E);function E(e,t){return R.call(this,e,t)||this}function N(){return"UnnamedBinding_"+s.OUtil.getUniqueId()+"_"+(new Date).getTime()}s.TextBinding=T,s.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){s.AsyncMethodCalls.define({method:s.AsyncMethods.BindingSelectionChanged,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[]}),s.AsyncMethodCalls.define({method:s.AsyncMethods.BindingDataChanged,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[]})},defineSafeArrayParameterMapFunc:function(){s.HostParameterMap.define({type:s.EventDescriptors.BindingSelectionChangedEvent,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:0},{name:s.PropertyDescriptors.Subset,value:1}],isComplexType:!0}),s.HostParameterMap.define({type:s.EventDispId.dispidBindingSelectionChangedEvent,fromHost:[{name:s.EventDescriptors.BindingSelectionChangedEvent,value:s.HostParameterMap.self}],isComplexType:!0}),s.HostParameterMap.define({type:s.EventDispId.dispidBindingDataChangedEvent,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.HostParameterMap.self}]})},defineWebParameterMapFunc:function(){s.HostParameterMap.define({type:s.EventDescriptors.BindingSelectionChangedEvent,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.WACDelegate.UniqueArguments.BindingEventSource},{name:s.PropertyDescriptors.Subset,value:s.PropertyDescriptors.Subset}]}),s.HostParameterMap.define({type:s.EventDispId.dispidBindingSelectionChangedEvent,fromHost:[{name:s.EventDescriptors.BindingSelectionChangedEvent,value:s.HostParameterMap.self}]}),s.HostParameterMap.define({type:s.EventDispId.dispidBindingDataChangedEvent,fromHost:[{name:s.PropertyDescriptors.BindingProperties,value:s.WACDelegate.UniqueArguments.BindingEventSource}]})}})}(OSF=OSF||{}),function(e){var t,n,r;t=e.context||(e.context={}),n=t.document||(t.document={}),(r=n.customXmlParts||(n.customXmlParts={}))._eventDispatches=[],r.addAsync=function(e,t,n){"function"==typeof t&&(n=t);var r={toSafeArrayHost:function(){return[e]},fromSafeArrayHost:function(e){var t={id:e[0],DataPartBuiltIn:e[1]};return OSF.processDataPart(t)},toWebHost:function(){return{xml:e}},fromWebHost:function(e){var t={id:e.DataPartProperties.id,DataPartBuiltIn:e.DataPartProperties.DataPartBuiltIn};return OSF.processDataPart(t)}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(128,r,n,null!=t?t.asyncContext:void 0)},r.getByIdAsync=function(e,t,n){"function"==typeof t&&(n=t);var r={toSafeArrayHost:function(){return[e]},fromSafeArrayHost:function(e){var t={id:e[0],DataPartBuiltIn:e[1]};return OSF.processDataPart(t)},toWebHost:function(){return{id:e}},fromWebHost:function(e){var t={id:e.DataPartProperties.id,DataPartBuiltIn:e.DataPartProperties.DataPartBuiltIn};return OSF.processDataPart(t)}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(129,r,n,null!=t?t.asyncContext:void 0)},r.getByNamespaceAsync=function(e,t,n){"function"==typeof t&&(n=t);var r={toSafeArrayHost:function(){return[e]},fromSafeArrayHost:function(e){var t=[];if(e)for(var n=0;n<e.length;n++){var r={id:e[n][0],DataPartBuiltIn:e[n][1]},o=OSF.processDataPart(r);t.push(o)}return t},toWebHost:function(){return{namespace:e}},fromWebHost:function(e){for(var t=[],n=0;n<e.DataPartList.length;n++){var r={id:e.DataPartList[n].id,DataPartBuiltIn:e.DataPartList[n].DataPartBuiltIn},o=OSF.processDataPart(r);t.push(o)}return t}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(130,r,n,null!=t?t.asyncContext:void 0)}}(Office=Office||{}),function(a){var e,t,n;(e=a.DataPartProperties||(a.DataPartProperties={})).Id="id",e.BuiltIn="DataPartBuiltIn",(t=a.DataNodeProperties||(a.DataNodeProperties={})).Handle="DataNodeHandle",t.BaseName="DataNodeBaseName",t.NamespaceUri="DataNodeNamespaceUri",t.NodeType="DataNodeType",(n=a.ListDescriptors||(a.ListDescriptors={})).DataPartList="DataPartList",n.DataNodeList="DataNodeList",a.ListType.setListType(a.ListDescriptors.DataPartList,a.PropertyDescriptors.DataPartProperties),a.ListType.setListType(a.ListDescriptors.DataNodeList,a.PropertyDescriptors.DataPartProperties);var r=(Object.defineProperty(o.prototype,"builtIn",{get:function(){return this.m_builtIn},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"id",{get:function(){return this.m_id},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"namespaceManager",{get:function(){return new i(this.m_id)},enumerable:!0,configurable:!0}),o.prototype.deleteAsync=function(e,t){var n=this;"function"==typeof e&&(t=e);var r={toSafeArrayHost:function(){return[null==n.m_id?void 0:n.m_id]},fromSafeArrayHost:function(e){},toWebHost:function(){return{id:null==n.m_id?void 0:n.m_id}},fromWebHost:function(e){return{}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(133,r,t,null!=e?e.asyncContext:void 0)},o.prototype.getNodesAsync=function(e,t,n){var r=this;"function"==typeof t&&(n=t);var o={toSafeArrayHost:function(){return[null==r.m_id?void 0:r.m_id,e]},fromSafeArrayHost:function(e){for(var t=[],n=0;n<e.length;n++){var r={DataNodeHandle:e[n][0],DataNodeBaseName:e[n][1],DataNodeNamespaceUri:e[n][2],DataNodeType:e[n][3]},o=a.processDataNode(r);t.push(o)}return t},toWebHost:function(){return{id:null==r.m_id?void 0:r.m_id,xpath:e}},fromWebHost:function(e){for(var t=[],n=0;n<e.DataNodeList.length;n++){var r={DataNodeHandle:e.DataNodeList[n].DataNodeHandle,DataNodeBaseName:e.DataNodeList[n].DataNodeBaseName,DataNodeNamespaceUri:e.DataNodeList[n].DataNodeNamespaceUri,DataNodeType:e.DataNodeList[n].DataNodeType},o=a.processDataNode(r);t.push(o)}return t}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(132,o,n,null!=t?t.asyncContext:void 0)},o.prototype.getXmlAsync=function(e,t){var n=this;"function"==typeof e&&(t=e);var r={toSafeArrayHost:function(){return[null==n.m_id?void 0:n.m_id]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{id:null==n.m_id?void 0:n.m_id}},fromWebHost:function(e){return{data:e.Data}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(131,r,t,null!=e?e.asyncContext:void 0)},o);function o(e,t,n){this.m_customXmlParts=e,this.m_id=t,this.m_builtIn=n;var r=e._eventDispatches,o=r[t];if(!o){var i=a.EventType;o=new a.EventDispatch([i.DataNodeDeleted,i.DataNodeInserted,i.DataNodeReplaced]),r[t]=o}a.DispIdHost.addEventSupport(this,o)}a.CustomXmlPart=r;var i=(s.prototype.addNamespaceAsync=function(e,t,n,r){var o=this;"function"==typeof n&&(r=n);var i={toSafeArrayHost:function(){return[null==o.m_partId?void 0:o.m_partId,e,t]},fromSafeArrayHost:function(e){},toWebHost:function(){return{id:null==o.m_partId?void 0:o.m_partId,prefix:e,namespace:t}},fromWebHost:function(e){return{}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(139,i,r,null!=n?n.asyncContext:void 0)},s.prototype.getNamespaceAsync=function(e,t,n){var r=this;"function"==typeof t&&(n=t);var o={toSafeArrayHost:function(){return[null==r.m_partId?void 0:r.m_partId,e]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{id:null==r.m_partId?void 0:r.m_partId,prefix:e}},fromWebHost:function(e){return{data:e.Data}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(140,o,n,null!=t?t.asyncContext:void 0)},s.prototype.getPrefixAsync=function(e,t,n){var r=this;"function"==typeof t&&(n=t);var o={toSafeArrayHost:function(){return[null==r.m_partId?void 0:r.m_partId,e]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{id:null==r.m_partId?void 0:r.m_partId,namespace:e}},fromWebHost:function(e){return{data:e.Data}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(141,o,n,null!=t?t.asyncContext:void 0)},s);function s(e){this.m_partId=e}a.CustomXmlPrefixMappings=i;var c,l,u,p,f,d,h,g=(Object.defineProperty(m.prototype,"baseName",{get:function(){return this.m_baseName},enumerable:!0,configurable:!0}),Object.defineProperty(m.prototype,"namespaceUri",{get:function(){return this.m_ns},enumerable:!0,configurable:!0}),Object.defineProperty(m.prototype,"nodeType",{get:function(){return this.m_nodeType},enumerable:!0,configurable:!0}),m.prototype.getNodesAsync=function(e,t,n){var r=this;"function"==typeof t&&(n=t);var o={toSafeArrayHost:function(){return[y(r,r.m_handle),e]},fromSafeArrayHost:function(e){for(var t=[],n=0;n<e.length;n++){var r={DataNodeBaseName:e[n][2],DataNodeNamespaceUri:e[n][3],DataNodeType:e[n][4]},o=a.processDataNode(r);t.push(o)}return t},toWebHost:function(){return{DataNodeHandle:y(r,r.m_handle),xpath:e}},fromWebHost:function(e){for(var t=[],n=0;n<e.DataNodeList.length;n++){var r={DataNodeHandle:e.DataNodeList[n].DataNodeHandle,DataNodeBaseName:e.DataNodeList[n].DataNodeBaseName,DataNodeNamespaceUri:e.DataNodeList[n].DataNodeNamespaceUri,DataNodeType:e.DataNodeList[n].DataNodeType},o=a.processDataNode(r);t.push(o)}return t}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(136,o,n,null!=t?t.asyncContext:void 0)},m.prototype.getNodeValueAsync=function(e,t){var n=this;"function"==typeof e&&(t=e);var r={toSafeArrayHost:function(){return[y(n,n.m_handle)]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{DataNodeHandle:y(n,n.m_handle)}},fromWebHost:function(e){return{data:e.Data}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(134,r,t,null!=e?e.asyncContext:void 0)},m.prototype.setNodeValueAsync=function(e,t,n){var r=this;"function"==typeof t&&(n=t);var o={toSafeArrayHost:function(){return[y(r,r.m_handle),e]},fromSafeArrayHost:function(e){},toWebHost:function(){return{DataNodeHandle:y(r,r.m_handle),Data:e}},fromWebHost:function(e){return{}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(137,o,n,null!=t?t.asyncContext:void 0)},m.prototype.getXmlAsync=function(e,t){var n=this;"function"==typeof e&&(t=e);var r={toSafeArrayHost:function(){return[y(n,n.m_handle)]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{DataNodeHandle:y(n,n.m_handle)}},fromWebHost:function(e){return{data:e.Data}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(135,r,t,null!=e?e.asyncContext:void 0)},m.prototype.setXmlAsync=function(e,t,n){var r=this;"function"==typeof t&&(n=t);var o={toSafeArrayHost:function(){return[y(r,r.m_handle),e]},fromSafeArrayHost:function(e){},toWebHost:function(){return{DataNodeHandle:y(r,r.m_handle),xml:e}},fromWebHost:function(e){return{}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(138,o,n,null!=t?t.asyncContext:void 0)},m.prototype.getTextAsync=function(e,t){var n=this;"function"==typeof e&&(t=e);var r={toSafeArrayHost:function(){return[y(n,n.m_handle)]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{DataNodeHandle:y(n,n.m_handle)}},fromWebHost:function(e){return{data:e.Data}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(142,r,t,null!=e?e.asyncContext:void 0)},m.prototype.setTextAsync=function(e,t,n){var r=this;"function"==typeof t&&(n=t);var o={toSafeArrayHost:function(){return[y(r,r.m_handle),e]},fromSafeArrayHost:function(e){},toWebHost:function(){return{DataNodeHandle:y(r,r.m_handle),undefined:e}},fromWebHost:function(e){return{}}};a._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(143,o,n,null!=t?t.asyncContext:void 0)},m);function m(e,t,n,r){this.m_handle=e,this.m_nodeType=t,this.m_ns=n,this.m_baseName=r}function y(e,t){return t}a.CustomXmlNode=g,a.manufactureDataNode=function(e){if(e)return new a.CustomXmlNode(e[a.DataNodeProperties.Handle],e[a.DataNodeProperties.NodeType],e[a.DataNodeProperties.NamespaceUri],e[a.DataNodeProperties.BaseName])},a.manufactureDataPart=function(e,t){return new a.CustomXmlPart(t,e[a.DataPartProperties.Id],e[a.DataPartProperties.BuiltIn])},c=a.Marshaling||(a.Marshaling={}),l=c.Customxml||(c.Customxml={}),(u=l.CustomXmlPartsKeys||(l.CustomXmlPartsKeys={})).Id="id",u.Namespace="namespace",u.Xml="xml",u.XPath="xpath",u.Prefix="prefix",(p=l.DataPartProperties||(l.DataPartProperties={})).Id="id",p.BuiltIn="DataPartBuiltIn",(f=l.PropertyDescriptors||(l.PropertyDescriptors={})).DataPartProperties="DataPartProperties",f.DataNodeProperties="DataNodeProperties",(d=l.DataNodeProperties||(l.DataNodeProperties={})).Handle="DataNodeHandle",d.BaseName="DataNodeBaseName",d.NamespaceUri="DataNodeNamespaceUri",d.NodeType="DataNodeType",(h=l.ListDescriptors||(l.ListDescriptors={})).DataPartList="DataPartList",h.DataNodeList="DataNodeList",a.CustomXml||(a.CustomXml={}),a.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){},defineSafeArrayParameterMapFunc:function(){a.HostParameterMap.define({type:a.EventDescriptors.DataNodeInsertedEvent,fromHost:[{name:a.DataNodeEventProperties.InUndoRedo,value:0},{name:a.DataNodeEventProperties.NewNode,value:1}],isComplexType:!0}),a.HostParameterMap.define({type:a.EventDescriptors.DataNodeReplacedEvent,fromHost:[{name:a.DataNodeEventProperties.InUndoRedo,value:0},{name:a.DataNodeEventProperties.OldNode,value:1},{name:a.DataNodeEventProperties.NewNode,value:2}],isComplexType:!0}),a.HostParameterMap.define({type:a.EventDescriptors.DataNodeDeletedEvent,fromHost:[{name:a.DataNodeEventProperties.InUndoRedo,value:0},{name:a.DataNodeEventProperties.OldNode,value:1},{name:a.DataNodeEventProperties.NextSiblingNode,value:2}],isComplexType:!0}),a.HostParameterMap.define({type:a.DataNodeEventProperties.OldNode,fromHost:[{name:a.PropertyDescriptors.DataNodeProperties,value:a.HostParameterMap.self}],isComplexType:!0}),a.HostParameterMap.define({type:a.DataNodeEventProperties.NewNode,fromHost:[{name:a.PropertyDescriptors.DataNodeProperties,value:a.HostParameterMap.self}],isComplexType:!0}),a.HostParameterMap.define({type:a.DataNodeEventProperties.NextSiblingNode,fromHost:[{name:a.PropertyDescriptors.DataNodeProperties,value:a.HostParameterMap.self}],isComplexType:!0}),a.HostParameterMap.define({type:a.EventDispId.dispidDataNodeAddedEvent,fromHost:[{name:a.EventDescriptors.DataNodeInsertedEvent,value:a.HostParameterMap.self}]}),a.HostParameterMap.define({type:a.EventDispId.dispidDataNodeReplacedEvent,fromHost:[{name:a.EventDescriptors.DataNodeReplacedEvent,value:a.HostParameterMap.self}]}),a.HostParameterMap.define({type:a.EventDispId.dispidDataNodeDeletedEvent,fromHost:[{name:a.EventDescriptors.DataNodeDeletedEvent,value:a.HostParameterMap.self}]})},defineWebParameterMapFunc:function(){a.HostParameterMap.define({type:a.EventDescriptors.DataNodeInsertedEvent,fromHost:[{name:a.DataNodeEventProperties.InUndoRedo,value:a.Marshaling.Customxml.DataNodeEventProperties.InUndoRedo},{name:a.DataNodeEventProperties.NewNode,value:a.Marshaling.Customxml.DataNodeEventProperties.NewNode}],isComplexType:!0}),a.HostParameterMap.define({type:a.EventDescriptors.DataNodeReplacedEvent,fromHost:[{name:a.DataNodeEventProperties.InUndoRedo,value:a.Marshaling.Customxml.DataNodeEventProperties.InUndoRedo},{name:a.DataNodeEventProperties.OldNode,value:a.Marshaling.Customxml.DataNodeEventProperties.OldNode},{name:a.DataNodeEventProperties.NewNode,value:a.Marshaling.Customxml.DataNodeEventProperties.NewNode}],isComplexType:!0}),a.HostParameterMap.define({type:a.EventDescriptors.DataNodeDeletedEvent,fromHost:[{name:a.DataNodeEventProperties.InUndoRedo,value:a.Marshaling.Customxml.DataNodeEventProperties.InUndoRedo},{name:a.DataNodeEventProperties.OldNode,value:a.Marshaling.Customxml.DataNodeEventProperties.OldNode},{name:a.DataNodeEventProperties.NextSiblingNode,value:a.Marshaling.Customxml.DataNodeEventProperties.NextSiblingNode}],isComplexType:!0}),a.HostParameterMap.define({type:a.DataNodeEventProperties.OldNode,fromHost:[{name:a.PropertyDescriptors.DataNodeProperties,value:a.HostParameterMap.self}],isComplexType:!0}),a.HostParameterMap.define({type:a.DataNodeEventProperties.NewNode,fromHost:[{name:a.PropertyDescriptors.DataNodeProperties,value:a.HostParameterMap.self}],isComplexType:!0}),a.HostParameterMap.define({type:a.DataNodeEventProperties.NextSiblingNode,fromHost:[{name:a.PropertyDescriptors.DataNodeProperties,value:a.HostParameterMap.self}],isComplexType:!0}),a.HostParameterMap.define({type:a.EventDispId.dispidDataNodeAddedEvent,fromHost:[{name:a.EventDescriptors.DataNodeInsertedEvent,value:a.HostParameterMap.self}]}),a.HostParameterMap.define({type:a.EventDispId.dispidDataNodeReplacedEvent,fromHost:[{name:a.EventDescriptors.DataNodeReplacedEvent,value:a.HostParameterMap.self}]}),a.HostParameterMap.define({type:a.EventDispId.dispidDataNodeDeletedEvent,fromHost:[{name:a.EventDescriptors.DataNodeDeletedEvent,value:a.HostParameterMap.self}]})}}),a.processDataPart=function(e){return a.manufactureDataPart(e,Office.context.document.customXmlParts)},a.processDataNode=function(e){return a.manufactureDataNode(e)}}(OSF=OSF||{}),function(o){var e;function r(e){if(null==e||null==e)return null;var t=null,n=typeof e;return void 0!==e.rows?t=Office.CoercionType.Table:o.OUtil.isArray(e)?t=Office.CoercionType.Matrix:"string"!=n&&"number"!=n&&"boolean"!=n&&!o.OUtil.isDate(e)||(t=Office.CoercionType.Text),t}function i(e,t,n){return(n=n||r(e))&&n!=t&&(e=function(e,t){var n;switch(e){case Office.CoercionType.Table:n=t;break;case Office.CoercionType.Matrix:n=function(e){var t=e.rows;null!=e.headers&&t.unshift(e.headers);return t}(t);break;case Office.CoercionType.SlideRange:o.manufactureSlideRange&&null==(n=o.manufactureSlideRange(s(t)))&&(n=s(t));break;case Office.CoercionType.Text:case Office.CoercionType.Html:case Office.CoercionType.Ooxml:default:n=s(t)}return n}(t,function(e,t){null==t&&(t=r(e));var n;switch(t){case Office.CoercionType.Table:n=e;break;case Office.CoercionType.Matrix:n=new Office.TableData(e);break;case Office.CoercionType.Text:case Office.CoercionType.Html:case Office.CoercionType.Ooxml:default:n=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 n}(e,n))),e}function a(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 s(e){var t="";null!=e.headers&&(t=a([e.headers])+"\n");var n=a(e.rows);return""==n&&(t=t.substring(0,t.length-1)),t+n}e=o.DataCoercion||(o.DataCoercion={}),o.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){},defineSafeArrayParameterMapFunc:function(){o.HostParameterMap.define({type:o.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 e=o._OfficeAppFactory.getHostInfo();e.hostPlatform!=o.HostInfoPlatform.win32&&e.hostPlatform!=o.HostInfoPlatform.mac&&e.hostPlatform!=o.HostInfoPlatform.ios&&e.hostPlatform!=o.HostInfoPlatform.android||(o.OUtil.augmentList(Office.CoercionType,{Image:"image"}),o.OUtil.augmentList(Office.CoercionType,{XmlSvg:"xmlSvg"}),o.HostParameterMap.define({type:o.ParameterNames.CoercionType,toHost:[{name:"image",value:8},{name:"xmlSvg",value:9}]}));o.HostParameterMap.define({type:o.ParameterNames.ValueFormat,toHost:[{name:Office.ValueFormat.Unformatted,value:0},{name:Office.ValueFormat.Formatted,value:1}]}),o.HostParameterMap.define({type:o.ParameterNames.FilterType,toHost:[{name:Office.FilterType.All,value:0}]})},defineWebParameterMapFunc:function(){o.OUtil.augmentList(Office.CoercionType,{Image:"image"}),o.OUtil.augmentList(Office.CoercionType,{XmlSvg:"xmlSvg"}),o.HostParameterMap.define({type:o.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}]}),o.HostParameterMap.define({type:o.ParameterNames.ValueFormat,toHost:[{name:Office.ValueFormat.Unformatted,value:0},{name:Office.ValueFormat.Formatted,value:1}]}),o.HostParameterMap.define({type:o.ParameterNames.FilterType,toHost:[{name:Office.FilterType.All,value:0}]})}}),e.findArrayDimensionality=function e(t){if(o.OUtil.isArray(t)){for(var n=0,r=0;r<t.length;r++)n=Math.max(n,e(t[r]));return n+1}return 0},e.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}},e.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}},e.determineCoercionType=r,e.coerceData=i,e.serializeDynamicData=function(e){if(null!=e&&void 0!==e.rows){var t={};t[o.TableDataProperties.TableRows]=e.rows,t[o.TableDataProperties.TableHeaders]=e.headers,e=t}var n;if(o._OfficeAppFactory.getHostInfo().hostPlatform==o.HostInfoPlatform.web)return"string"!=typeof e&&void 0!==e[o.TableDataProperties.TableRows]?((n={}).Rows=e[o.TableDataProperties.TableRows],n.Headers=e[o.TableDataProperties.TableHeaders],e=n):o.DataCoercion.determineCoercionType(e)==Office.CoercionType.Text&&(e=[[e]]),e;if(o.TableDataProperties&&"string"!=typeof e&&void 0!==e[o.TableDataProperties.TableRows]){(n=[])[0]=e[o.TableDataProperties.TableRows],n[1]=e[o.TableDataProperties.TableHeaders],e=n}return e},e.deserializeDynamicData=function(e,t){var n=null;if(o._OfficeAppFactory.getHostInfo().hostPlatform==o.HostInfoPlatform.web)null!=e.Rows?((n={})[o.TableDataProperties.TableRows]=e.Rows,n[o.TableDataProperties.TableHeaders]=e.Headers):n=e,!n||null==n[o.TableDataProperties.TableRows]&&null==n[o.TableDataProperties.TableHeaders]||(n=Office.manufactureTableData(n)),n=i(n,t);else{if(2===e.length){(n={})[o.TableDataProperties.TableRows]=e[0],n[o.TableDataProperties.TableHeaders]=e[1],n=Office.manufactureTableData(n)}else n=e;n=i(n,t)}return n}}(OSF=OSF||{}),function(e){var t,n,r;((t=e.Marshaling||(e.Marshaling={})).GetDataKeys||(t.GetDataKeys={})).CoercionType="CoerceType",(n=t.SetDataKeys||(t.SetDataKeys={})).CoercionType="CoerceType",n.Data="Data",n.ImageLeft="ImageLeft",n.ImageTop="ImageTop",n.ImageWidth="ImageWidth",n.ImageHeight="ImageHeight",(r=t.CoercionTypeKeys||(t.CoercionTypeKeys={})).Html="html",r.Ooxml="ooxml",r.SlideRange="slideRange",r.Text="text",r.Table="table",r.Matrix="matrix",r.Image="image",r.XmlSvg="xmlSvg",e.DataIO||(e.DataIO={}),e.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){},defineWebParameterMapFunc:function(){e.HostParameterMap.define({type:e.WACDelegate.UniqueArguments.GetData,toHost:[{name:e.ParameterNames.Id,value:"BindingId"},{name:e.ParameterNames.CoercionType,value:"CoerceType"},{name:e.ParameterNames.ValueFormat,value:"ValueFormat"},{name:e.ParameterNames.FilterType,value:"FilterType"},{name:e.ParameterNames.Rows,value:"Rows"},{name:e.ParameterNames.Columns,value:"Columns"},{name:e.ParameterNames.StartRow,value:"StartRow"},{name:e.ParameterNames.StartColumn,value:"StartCol"},{name:e.ParameterNames.RowCount,value:"RowCount"},{name:e.ParameterNames.ColumnCount,value:"ColCount"}]}),e.HostParameterMap.define({type:e.WACDelegate.UniqueArguments.SetData,toHost:[{name:e.ParameterNames.Id,value:"BindingId"},{name:e.ParameterNames.CoercionType,value:"CoerceType"},{name:e.ParameterNames.Data,value:e.WACDelegate.UniqueArguments.Data},{name:e.ParameterNames.Rows,value:"Rows"},{name:e.ParameterNames.Columns,value:"Columns"},{name:e.ParameterNames.StartRow,value:"StartRow"},{name:e.ParameterNames.StartColumn,value:"StartCol"},{name:e.ParameterNames.ImageLeft,value:"ImageLeft"},{name:e.ParameterNames.ImageTop,value:"ImageTop"},{name:e.ParameterNames.ImageWidth,value:"ImageWidth"},{name:e.ParameterNames.ImageHeight,value:"ImageHeight"}]})}})}(OSF=OSF||{}),function(e){var t,n,r,o,i;t=e.Marshaling||(e.Marshaling={}),(n=t.DialogMessageReceivedEventKeys||(t.DialogMessageReceivedEventKeys={})).MessageType="messageType",n.MessageContent="messageContent",n.MessageOrigin="messageOrigin",(r=t.DialogParentMessageReceivedEventKeys||(t.DialogParentMessageReceivedEventKeys={})).MessageType="messageType",r.MessageContent="messageContent",r.MessageOrigin="messageOrigin",(o=t.MessageParentKeys||(t.MessageParentKeys={})).MessageToParent="messageToParent",o.TargetOrigin="targetOrigin",(t.DialogNotificationShownEventType||(t.DialogNotificationShownEventType={})).DialogNotificationShown="dialogNotificationShown",(i=t.SendMessageKeys||(t.SendMessageKeys={})).MessageContent="messageContent",i.TargetOrigin="targetOrigin"}(OSF=OSF||{}),function(u){var e;(e=u.EventDescriptors||(u.EventDescriptors={})).DialogParentMessageReceivedEvent="DialogParentMessageReceivedEvent",e.DialogMessageReceivedEvent="DialogMessageReceivedEvent",u.DialogParentMessageEventDispatch=new u.EventDispatch([u.EventType.DialogParentMessageReceived,u.EventType.DialogParentEventReceived]),u.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){u.AsyncMethodCalls.define({method:u.AsyncMethods.DisplayDialogAsync,requiredArguments:[{name:u.ParameterNames.Url,types:["string"]}],supportedOptions:[{name:u.ParameterNames.Width,value:{types:["number"],defaultValue:99}},{name:u.ParameterNames.Height,value:{types:["number"],defaultValue:99}},{name:u.ParameterNames.RequireHTTPs,value:{types:["boolean"],defaultValue:!0}},{name:u.ParameterNames.DisplayInIframe,value:{types:["boolean"],defaultValue:!1}},{name:u.ParameterNames.HideTitle,value:{types:["boolean"],defaultValue:!1}},{name:u.ParameterNames.UseDeviceIndependentPixels,value:{types:["boolean"],defaultValue:!1}},{name:u.ParameterNames.PromptBeforeOpen,value:{types:["boolean"],defaultValue:!0}},{name:u.ParameterNames.EnforceAppDomain,value:{types:["boolean"],defaultValue:!0}},{name:u.ParameterNames.UrlNoHostInfo,value:{types:["boolean"],defaultValue:!1}}],privateStateCallbacks:[],onSucceeded:function(e,t,n){var r=e[u.ParameterNames.Id],o=e[u.ParameterNames.Data],i={},a=u.AsyncMethods.CloseAsync;u.OUtil.defineEnumerableProperty(i,a,{value:function(){(0,u.DispIdHost.CloseDialog)(arguments,r,o,i)}});var s=u.SyncMethods.AddMessageHandler;if(u.OUtil.defineEnumerableProperty(i,s,{value:function(){var e=u.SyncMethodCalls.get(u.SyncMethods.AddMessageHandler).verifyAndExtractCall(arguments,i,o),t=e[u.ParameterNames.EventType],n=e[u.ParameterNames.Handler];return o.addEventHandlerAndFireQueuedEvent(t,n)}}),!0===u.EnableSendMessageDialogAPI){var c=u.SyncMethods.SendMessage;u.OUtil.defineEnumerableProperty(i,c,{value:function(){return(0,u.DispIdHost.SendMessage)(arguments,o,i)}})}if(!0===u.EnableMessageChildDialogAPI){var l=u.SyncMethods.MessageChild;u.OUtil.defineEnumerableProperty(i,l,{value:function(){return(0,u.DispIdHost.SendMessage)(arguments,o,i)}})}return i},checkCallArgs:function(e,t,n){return e[u.ParameterNames.Width]<=0&&(e[u.ParameterNames.Width]=1),!e[u.ParameterNames.UseDeviceIndependentPixels]&&100<e[u.ParameterNames.Width]&&(e[u.ParameterNames.Width]=99),e[u.ParameterNames.Height]<=0&&(e[u.ParameterNames.Height]=1),!e[u.ParameterNames.UseDeviceIndependentPixels]&&100<e[u.ParameterNames.Height]&&(e[u.ParameterNames.Height]=99),e[u.ParameterNames.RequireHTTPs]||(e[u.ParameterNames.RequireHTTPs]=!0),e}}),u.AsyncMethodCalls.define({method:u.AsyncMethods.CloseAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[]}),u.SyncMethodCalls.define({method:u.SyncMethods.MessageParent,requiredArguments:[{name:u.ParameterNames.MessageToParent,types:["string","number","boolean"]}],supportedOptions:[{name:u.ParameterNames.TargetOrigin,value:{types:["string"],defaultValue:""}}]}),u.SyncMethodCalls.define({method:u.SyncMethods.AddMessageHandler,requiredArguments:[{name:u.ParameterNames.EventType,enum:u.EventType,verify:function(e,t,n){return n.supportsEvent(e)}},{name:u.ParameterNames.Handler,types:["function"]}],supportedOptions:[]}),u.SyncMethodCalls.define({method:u.SyncMethods.SendMessage,requiredArguments:[{name:u.ParameterNames.MessageContent,types:["string"]}],supportedOptions:[{name:u.ParameterNames.TargetOrigin,value:{types:["string"],defaultValue:""}}],privateStateCallbacks:[]})},defineSafeArrayParameterMapFunc:function(){u.HostParameterMap.define({type:u.EventDispId.dispidDialogMessageReceivedEvent,fromHost:[{name:u.EventDescriptors.DialogMessageReceivedEvent,value:u.HostParameterMap.self}],isComplexType:!0}),u.HostParameterMap.define({type:u.EventDescriptors.DialogMessageReceivedEvent,fromHost:[{name:u.PropertyDescriptors.MessageType,value:0},{name:u.PropertyDescriptors.MessageContent,value:1},{name:u.PropertyDescriptors.MessageOrigin,value:2}],isComplexType:!0}),u.HostParameterMap.define({type:u.EventDispId.dispidDialogParentMessageReceivedEvent,fromHost:[{name:u.EventDescriptors.DialogParentMessageReceivedEvent,value:u.HostParameterMap.self}],isComplexType:!0}),u.HostParameterMap.define({type:u.EventDescriptors.DialogParentMessageReceivedEvent,fromHost:[{name:u.PropertyDescriptors.MessageType,value:0},{name:u.PropertyDescriptors.MessageContent,value:1},{name:u.PropertyDescriptors.MessageOrigin,value:2}],isComplexType:!0})},defineWebParameterMapFunc:function(){u.HostParameterMap.define({type:u.EventDispId.dispidDialogMessageReceivedEvent,fromHost:[{name:u.EventDescriptors.DialogMessageReceivedEvent,value:u.HostParameterMap.self}]}),u.HostParameterMap.addComplexType(u.EventDescriptors.DialogMessageReceivedEvent),u.HostParameterMap.define({type:u.EventDescriptors.DialogMessageReceivedEvent,fromHost:[{name:u.PropertyDescriptors.MessageType,value:u.Marshaling.DialogMessageReceivedEventKeys.MessageType},{name:u.PropertyDescriptors.MessageContent,value:u.Marshaling.DialogMessageReceivedEventKeys.MessageContent},{name:u.PropertyDescriptors.MessageOrigin,value:u.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin}]}),u.HostParameterMap.define({type:u.EventDispId.dispidDialogParentMessageReceivedEvent,fromHost:[{name:u.EventDescriptors.DialogParentMessageReceivedEvent,value:u.HostParameterMap.self}]}),u.HostParameterMap.addComplexType(u.EventDescriptors.DialogParentMessageReceivedEvent),u.HostParameterMap.define({type:u.EventDescriptors.DialogParentMessageReceivedEvent,fromHost:[{name:u.PropertyDescriptors.MessageType,value:u.Marshaling.DialogParentMessageReceivedEventKeys.MessageType},{name:u.PropertyDescriptors.MessageContent,value:u.Marshaling.DialogParentMessageReceivedEventKeys.MessageContent},{name:u.PropertyDescriptors.MessageOrigin,value:u.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin}]}),u.HostParameterMap.define({type:144,toHost:[{name:u.ParameterNames.MessageToParent,value:u.Marshaling.MessageParentKeys.MessageToParent},{name:u.ParameterNames.TargetOrigin,value:u.Marshaling.MessageParentKeys.TargetOrigin}]}),u.HostParameterMap.define({type:145,toHost:[{name:u.ParameterNames.MessageContent,value:u.Marshaling.SendMessageKeys.MessageContent},{name:u.ParameterNames.TargetOrigin,value:u.Marshaling.MessageParentKeys.TargetOrigin}]})},initializeFunc:function(){var e=u.OUtil.isPopupWindow();u.EnableMessageChildDialogAPI=!0,"onenote"==u._OfficeAppFactory.getHostInfo().hostType?u.EnableSendMessageDialogAPI=!1:u.EnableSendMessageDialogAPI=!0;var t=Office.context.ui;if(u.OUtil.isDialog()){var n=u.SyncMethods.MessageParent;t[n]||u.OUtil.defineEnumerableProperty(t,n,{value:function(){return(0,u.DispIdHost.MessageParent)(arguments,t)}});var r=u.SyncMethods.AddMessageHandler;t[r]||void 0===u.DialogParentMessageEventDispatch||u.DispIdHost.addEventSupport(t,u.DialogParentMessageEventDispatch,e),e&&u.WacDialogAction.registerMessageReceivedEvent()}else{var o;o=null!=u.EventType.DialogParentMessageReceived?new u.EventDispatch([u.EventType.DialogMessageReceived,u.EventType.DialogEventReceived,u.EventType.DialogParentMessageReceived]):new u.EventDispatch([u.EventType.DialogMessageReceived,u.EventType.DialogEventReceived]);var i=u.AsyncMethods.DisplayDialogAsync;t[i]||u.OUtil.defineEnumerableProperty(t,i,{value:function(){(0,u.DispIdHost.OpenDialog)(arguments,o,t)}})}u.OUtil.finalizeProperties(t)}})}(OSF=OSF||{});var OfficeExt,Office,OSF,DialogApiManager=function(){function e(){}return e.messageChildRichApiBridge=function(){if(!0===OSF.EnableMessageChildDialogAPI)return(0,OSF.DispIdHost.SendMessage)(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(b){var e,t,f,d,h,g,s,m,y,_,o,n,i,a,r,v,c,l,O,C;function u(e,t){var n=t.message,r=t.targetOrigin;if(r)e.postMessage(n,r);else{var o=b._OfficeAppFactory.getOfficeAppContext().get_appDomains(),i=window.location.origin;if(i=i||window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:""),o)for(var a=0;a<o.length&&-1!==o[a].indexOf("://");a++)e.postMessage(n,o[a]);b.XdmCommunicationManager.checkUrlWithAppDomains(o,i)||e.postMessage(n,i)}}function p(){try{g&&g.id==v&&m&&m(12009)}catch(e){b.AppTelemetry&&b.AppTelemetry.logAppException("Error happened during executing displayDialogAsync callback."+e)}N()}function P(e,t){var n=!1,r=b.WacCommonUICssManager.getDialogCssManager(t);h=x(r),document.body.insertBefore(h,document.body.firstChild),(g=function(e,t){var n=document.createElement("div");n.style.cssText=e.getDialogNotificationPanelCSS(),j(n);var r=document.createElement("div");r.style.cssText=e.getCrossZoneNotificationTextPanelCSS(),r.id=O;var o=document.createElement("a");o.id=l,o.href="#",o.innerText=Strings.OfficeOM.L_NewWindowCrossZoneConfigureBrowserLink,o.setAttribute("onclick","window.open('https://support.microsoft.com/en-us/help/17479/windows-internet-explorer-11-change-security-privacy-settings', '_blank', 'fullscreen=1')");var i=document.createElement("span");if(Strings.OfficeOM.L_NewWindowCrossZone){var a=Strings.OfficeOM.L_NewWindowCrossZone.replace(/{1+}/gm,b.OUtil.getDomainForUrl(t)).split("{0}");i.appendChild(document.createTextNode(a[0])),i.appendChild(o),i.appendChild(document.createTextNode(a[1]))}return r.appendChild(i),n.appendChild(r),n}(r,e)).id=c;var o=w(r),i=R(r,Strings.OfficeOM.L_DialogOK?Strings.OfficeOM.L_DialogOK:"OK");o.appendChild(i),g.appendChild(o),document.body.insertBefore(g,document.body.firstChild),y=!0,i.onclick=function(){N()},i.addEventListener("keydown",function(e){9==e.keyCode?(document.getElementById(l).focus(),e.preventDefault(),e.stopPropagation()):13==e.keyCode&&(n=!0,e.preventDefault(),e.stopPropagation())},!1),i.addEventListener("keyup",function(e){13==e.keyCode&&n&&(n=!1,N(),e.preventDefault(),e.stopPropagation())},!1),document.getElementById(l).addEventListener("keydown",function(e){9==e.keyCode&&(i.focus(),e.preventDefault(),e.stopPropagation())},!1),window.focus(),i.focus()}function S(e){if(e.source==f)try{var t=e.origin;if(!function(e,t,n){if(void 0===n&&(n=!0),!e||!t)return!1;var r=b.OUtil.parseUrl(e),o=b.OUtil.parseUrl(t),i=b._OfficeAppFactory.getOfficeAppContext().get_appDomains();if(!("https:"===r.protocol))return!1;var a=r.protocol===o.protocol&&r.hostname===o.hostname&&r.port===o.port,s=b.XdmCommunicationManager.checkUrlWithAppDomains(i,e),c=a||s;return!c&&n&&(c=b.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(t,e)),c}(t,b._OfficeAppFactory.getOfficeAppContext().get_docUrl(),!0))throw new Error("Received a message from a dialog with an untrusted domain.");var n={};n[b.Marshaling.DialogMessageReceivedEventKeys.MessageType]=0,n[b.Marshaling.DialogMessageReceivedEventKeys.MessageContent]=e.data,n[b.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin]=t,d(n)}catch(e){b.AppTelemetry&&b.AppTelemetry.logAppException("Error happened during receive message handler."+e)}}function A(e){var t=b._OfficeAppFactory.getId()+o;if(e.key==t)try{var n={};n[b.Marshaling.DialogMessageReceivedEventKeys.MessageType]=0,n[b.Marshaling.DialogMessageReceivedEventKeys.MessageContent]=e.newValue,n[b.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin]=e.origin,d(n)}catch(e){b.AppTelemetry&&b.AppTelemetry.logAppException("Error happened during storage changed handler."+e)}}function I(e){var t=b._OfficeAppFactory.getHostInfo(),n=[t.hostType,t.hostPlatform,t.hostSpecificFileVersion,t.hostLocale,t.osfControlAppCorrelationId,"isDialog",t.disableLogging?"disableLogging":"",t.flags&b.HostInfoFlags.PublicAddin].join("$"),r=b._OfficeAppFactory.getOfficeAppContext();r.set_taskpaneUrl(window.location.origin),r.get_taskpaneUrl()||r.set_taskpaneUrl(window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:""));var o=e.url;e[b.ShowWindowDialogParameterKeys.UrlNoHostInfo]||(o=b.OUtil.addHostInfoAsQueryParam(o,n));var i=JSON.parse(window.name);i.hostInfo=n;var a=__assign({},r);if(a._appName===b.AppName.ExcelWebApp){if(!a._settings&&a._settingsFunc){var s=a._settingsFunc();a._settings=Object.keys(s).map(function(e){return[e,s[e]]})}if(!a._hostSettings&&a._hostSettingsFunc){var c=a._hostSettingsFunc();a._hostSettings=Object.keys(c).map(function(e){return[e,c[e]]})}i.appContext=a}else i.appContext=r;var l=e[b.ShowWindowDialogParameterKeys.Width]*screen.width/100,u=e[b.ShowWindowDialogParameterKeys.Height]*screen.height/100,p="width="+l+", height="+u+", left="+(r.get_clientWindowWidth()/2-l/2)+", top="+(r.get_clientWindowHeight()/2-u/2)+",channelmode=no,directories=no,fullscreen=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=no,titlebar=yes,toolbar=no";if(null==(f=window.open(o,b.OUtil.serializeObjectToString(i),p)))return b.AppTelemetry.logAppCommonMessage("Encountered cross zone issue in displayDialogAsync api."),D(),P(o,t.hostType),void m(12011);b.OUtil.shouldUseLocalStorageToPassMessage()?window.addEventListener("storage",A):window.addEventListener("message",S),_=window.setInterval(function(){try{if(null==f||f.closed){window.clearInterval(_),b.OUtil.shouldUseLocalStorageToPassMessage()?window.removeEventListener("storage",A):window.removeEventListener("message",S);var e={};e[b.Marshaling.DialogMessageReceivedEventKeys.MessageType]=12006,d(e)}}catch(e){b.AppTelemetry&&b.AppTelemetry.logAppException("Error happened during check or handle window close."+e)}},1e3),null!=m?m(0):b.AppTelemetry&&b.AppTelemetry.logAppException("showDialogCallback can not be null.")}function R(e,t){var n=document.createElement("input");n.setAttribute("type","button"),n.style.cssText=e.getDialogButtonCSS(),n.style.borderColor=i,n.style.backgroundColor=a,n.setAttribute("value",t);function r(){T(n)}function o(){E(n)}return n.addEventListener("mouseover",r),n.addEventListener("focus",r),n.addEventListener("mouseout",o),n.addEventListener("focusout",o),n}function T(e){null!=n?(e.style.borderColor=n.HostButtonBorderColor,e.style.backgroundColor=n.HostButtonBackgroundColor):b.OUtil.getCommonUI()?(e.style.borderColor=b.OUtil.getCommonUI().HostButtonBorderColor,e.style.backgroundColor=b.OUtil.getCommonUI().HostButtonBackgroundColor):e.style.backgroundColor=r}function E(e){e.style.borderColor=i,e.style.backgroundColor=a}function N(){C.onCalling=function(e){D(),F(e)},b.WACDelegate.unregisterEventAsync(C)}function D(){null!=g&&(document.body.removeChild(g),g=null),null!=h&&(document.body.removeChild(h),h=null)}function x(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 F(e){if(0!=e){var t=document.querySelectorAll(b._OfficeAppFactory.getInitializationHelper().getTabbableElements());b.OUtil.focusToFirstTabbable(t,!1)}}function j(e){e.setAttribute("role","dialog"),e.setAttribute("aria-describedby",O)}(e=b.ShowWindowDialogParameterKeys||(b.ShowWindowDialogParameterKeys={})).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",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=(s.prototype.getOverlayElementCSS=function(){return this.overlayElementCSS.join(";")},s.prototype.getDialogNotificationPanelCSS=function(){return this.dialogNotificationPanelCSS.join(";")},s.prototype.getNewWindowNotificationTextPanelCSS=function(){return this.newWindowNotificationTextPanelCSS.join(";")},s.prototype.getNewWindowNotificationTextSpanCSS=function(){return this.newWindowNotificationTextSpanCSS.join(";")},s.prototype.getCrossZoneNotificationTextPanelCSS=function(){return this.crossZoneNotificationTextPanelCSS.join(";")},s.prototype.getDialogNotificationButtonPanelCSS=function(){return this.dialogNotificationButtonPanelCSS},s.prototype.getDialogButtonCSS=function(){return this.buttonStyleCSS.join(";")},s);function s(){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"]}e.DefaultDialogCSSManager=a}(b.WacCommonUICssManager||(b.WacCommonUICssManager={})),t=b.WacDialogAction||(b.WacDialogAction={}),y=!(s="osfDialogInternal:action=closeDialog"),_=-1,o="messageParentKey",n=m=g=h=d=f=null,i="#ababab",a="#ffffff",r="#ccc",v="newWindowNotificaiton",c="crossZoneNotification",l="configureBrowserLink",O="dialogNotificationTextPanel",C={dispId:b.EventDispId.dispidDialogNotificationShownInAddinEvent,eventType:b.Marshaling.DialogNotificationShownEventType.DialogNotificationShown,onComplete:null,onCalling:null},t.setHostThemeButtonStyle=function(e){var t=e.input;null!=t&&(n={HostButtonBorderColor:t[b.OUtil.HostThemeButtonStyleKeys.ButtonBorderColor],HostButtonBackgroundColor:t[b.OUtil.HostThemeButtonStyleKeys.ButtonBackgroundColor]}),e.completed()},t.removeEventListenersForDialog=function(e){!function(e){function t(){b._OfficeAppFactory.getWebAppState().focused||(b._OfficeAppFactory.getWebAppState().focused=!0),b.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,b.AgaveHostAction.Select])}function n(){b&&(b._OfficeAppFactory.getWebAppState().focused&&(b._OfficeAppFactory.getWebAppState().focused=!1),b.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,b.AgaveHostAction.UnSelect]))}function r(e){if(e.preventDefault=e.preventDefault||function(){e.returnValue=!1},117==e.keyCode&&(e.ctrlKey||e.metaKey)){e.preventDefault();var t=b.AgaveHostAction.CtrlF6Exit;e.shiftKey&&(t=b.AgaveHostAction.CtrlF6ExitShift),b.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,t])}else if(9==e.keyCode){e.preventDefault();var n=document.querySelectorAll(i._tabbableElements);b.OUtil.focusToNextTabbable(n,e.target||e.srcElement,e.shiftKey)||(i._hostInfo.isDialog?b.OUtil.focusToFirstTabbable(n,e.shiftKey):e.shiftKey?b.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,b.AgaveHostAction.TabExitShift]):b.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,b.AgaveHostAction.TabExit]))}else if(27==e.keyCode)e.preventDefault(),p(),b.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,b.AgaveHostAction.EscExit]);else if(113==e.keyCode)e.preventDefault(),b.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,b.AgaveHostAction.F2Exit]);else if((e.ctrlKey||e.metaKey||e.shiftKey||e.altKey)&&1<=e.keyCode&&e.keyCode<=255){var r={keyCode:e.keyCode,shiftKey:e.shiftKey,altKey:e.altKey,ctrlKey:e.ctrlKey,metaKey:e.metaKey};b.getClientEndPoint().invoke("ContextActivationManager_notifyHost",null,[i._webAppState.id,b.AgaveHostAction.KeyboardShortcuts,r])}}function o(e){117==e.keyCode&&e.ctrlKey&&(e.preventDefault?e.preventDefault():e.returnValue=!1)}var i=this;e?(b.OUtil.addEventListener(window,"focus",t),b.OUtil.addEventListener(window,"blur",n),b.OUtil.addEventListener(window,"keydown",r),b.OUtil.addEventListener(window,"keypress",o)):(b.OUtil.removeEventListener(window,"focus",t),b.OUtil.removeEventListener(window,"blur",n),b.OUtil.removeEventListener(window,"keydown",r),b.OUtil.removeEventListener(window,"keypress",o))}(!1),e.completed()},t.handleNewWindowDialog=function(t){try{if(l=t,u=b._OfficeAppFactory.getOfficeAppContext().get_appDomains(),p=l.url,!(b.XdmCommunicationManager.checkUrlWithAppDomains(u,p)||b._OfficeAppFactory.getOfficeAppContext().get_docUrl()&&b.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(b._OfficeAppFactory.getOfficeAppContext().get_docUrl(),p)))return void m(12004);if(!t[b.ShowWindowDialogParameterKeys.PromptBeforeOpen])return void I(t);var n=y=!1,e=b._OfficeAppFactory.getHostInfo(),r=b.WacCommonUICssManager.getDialogCssManager(e.hostType),o=b.OUtil.formatString(Strings.OfficeOM.L_ShowWindowDialogNotification,b._OfficeAppFactory.getOfficeAppContext().get_addinName());h=x(r),document.body.insertBefore(h,document.body.firstChild),(g=function(e,t){var n=document.createElement("div");n.style.cssText=e.getDialogNotificationPanelCSS(),j(n);var r=document.createElement("div");r.style.cssText=e.getNewWindowNotificationTextPanelCSS(),r.id=O,"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}(r,o)).id=v;var i=w(r),a=R(r,Strings.OfficeOM.L_ShowWindowDialogNotificationAllow),s=R(r,Strings.OfficeOM.L_ShowWindowDialogNotificationIgnore);function c(e){C.onCalling=function(e){D(),F(e),m(12009)},b.WACDelegate.unregisterEventAsync(C),e.preventDefault(),e.stopPropagation()}i.appendChild(a),i.appendChild(s),g.appendChild(i),document.body.insertBefore(g,document.body.firstChild),a.onclick=function(e){I(t),y||N(),e.preventDefault(),e.stopPropagation()},s.onclick=c,a.addEventListener("keydown",function(e){e.shiftKey&&9==e.keyCode&&(E(a),T(s),s.focus(),e.preventDefault(),e.stopPropagation())},!1),s.addEventListener("keydown",function(e){e.shiftKey||9!=e.keyCode?13==e.keyCode&&(n=!0,e.preventDefault(),e.stopPropagation()):(E(s),T(a),a.focus(),e.preventDefault(),e.stopPropagation())},!1),s.addEventListener("keyup",function(e){13==e.keyCode&&n&&(n=!1,c(e))},!1),window.focus(),C.onCalling=function(e){a.focus()},b.WACDelegate.registerEventAsync(C)}catch(e){b.AppTelemetry&&b.AppTelemetry.logAppException("Exception happens at new window dialog."+e),m(5001)}var l,u,p},t.closeDialog=function(t){try{if(null!=f){var e=b._OfficeAppFactory.getOfficeAppContext().get_appDomains();if(e)for(var n=0;n<e.length&&-1!==e[n].indexOf("://");n++)f.postMessage(s,e[n]);null==f||f.closed||f.close(),b.OUtil.shouldUseLocalStorageToPassMessage()?window.removeEventListener("storage",A):window.removeEventListener("message",S),window.clearInterval(_),f=null,t(0)}else t(5001)}catch(e){b.AppTelemetry&&b.AppTelemetry.logAppException("Exception happens at close window dialog."+e),t(5001)}},t.messageParent=function(e){var t=e.hostCallArgs[b.ParameterNames.MessageToParent],n=e.hostCallArgs[b.ParameterNames.TargetOrigin]||null;if(b.OUtil.shouldUseLocalStorageToPassMessage())try{var r=b._OfficeAppFactory.getId()+o;window.localStorage.setItem(r,t)}catch(e){b.AppTelemetry&&b.AppTelemetry.logAppException("Error happened during messageParent method:"+e)}else u(window.opener,{message:t,targetOrigin:n})},t.sendMessage=function(e){if(null!=f){var t=e.hostCallArgs,n=t[b.ParameterNames.TargetOrigin]||null;delete t[b.ParameterNames.TargetOrigin],"string"!=typeof t&&(t=JSON.stringify(t)),u(f,{message:t,targetOrigin:n})}},t.postDialogMessage=u,t.registerMessageReceivedEvent=function(){window.addEventListener("message",function(e){var t=e.origin;if(e.source==window.opener&&(!0===window.office_disable_receive_dialog_message_prompt||b.WacDialogAction.validateTaskpaneDomain(t,!0)))if("string"==typeof e.data&&-1<e.data.indexOf(s))window.close();else{var n=e.data,r=typeof n;if(n&&("object"==r||"string"==r)){var o="string"==r?JSON.parse(n):n,i={};i[b.Marshaling.DialogMessageReceivedEventKeys.MessageContent]=o.messageContent,i[b.Marshaling.DialogMessageReceivedEventKeys.MessageOrigin]=e.origin;var a=b.manufactureEventArgs(b.EventType.DialogParentMessageReceived,null,i);b.DialogParentMessageEventDispatch.fireEvent(a)}}})},t.setHandlerAndShowDialogCallback=function(e,t){d=e,m=t},t.escDismissDialogNotification=p,t.showCrossZoneNotification=P,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 b.SafeStorage?new b.SafeStorage(window.localStorage):window.localStorage},t.getSessionStorage=function(){return b.SafeStorage?new b.SafeStorage(window.sessionStorage):window.sessionStorage},t.getUrlProtocolHostnamePort=function(e){var t=e.port?":"+e.port:"";return e.protocol+"//"+e.hostname+t},t.validateTaskpaneDomain=function(e,t){try{if(!e)return!1;t=t||!0;var n=window.location.origin;n=n||window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:"");var r=b.OUtil.parseUrl(n,!0),o=b.OUtil.parseUrl(e,!0);if(!(r.protocol&&r.hostname&&o.protocol&&o.hostname&&void 0!==o.port))return!1;var i=(m=o,(g=r).hostname==m.hostname&&g.protocol==m.protocol&&(_=m,(y=g).port==_.port||""==y.port&&"http:"==y.protocol&&"80"==_.port||""==y.port&&"https:"==y.protocol&&"443"==_.port||""==_.port&&"http:"==_.protocol&&"80"==y.port||""==_.port&&"https:"==_.protocol&&"443"==y.port)),a=!1;if(t&&(a=b.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(e,n)),i||a)return!0;var s=this.getLocalStorage(),c=this.getSessionStorage(),l="_trusts_"+(o.protocol+"//"+o.hostname+(o.port?":"+o.port:"")),u=this.getWithExpiry(s,l),p=this.getWithExpiry(c,l);if("true"===u)return!0;if("false"===p)return!1;var f=this.getUrlProtocolHostnamePort(o),d=this.getUrlProtocolHostnamePort(r),h='You are about to send and receive potentially sensitive information from "'+d+'". Only click OK if you trust the following website recieving the sensitive information: "'+f+'".';return Strings.OfficeOM.L_ConfirmDialogApiTrustsParent&&(h=Strings.OfficeOM.L_ConfirmDialogApiTrustsParent.replace("{0}",d).replace("{1}",f)),window.confirm(h)?(this.setWithExpiry(s,l,"true"),this.setWithExpiry(c,l,"true"),!0):(this.setWithExpiry(s,l,"false"),this.setWithExpiry(c,l,"false"),!1)}catch(e){return b.AppTelemetry&&b.AppTelemetry.logAppException("Error happened during validateTaskpaneDomain method:"+e),!1}var g,m,y,_}}(OSF=OSF||{}),function(r){var e;(e=r.SafeArrayDelegate||(r.SafeArrayDelegate={})).openDialog=function(n){try{n.onCalling&&n.onCalling();var e=r.SafeArrayDelegate.getOnAfterRegisterEvent(!0,n);r._OfficeAppFactory.getClientHostController().openDialog(n.dispId,void 0,n.targetId,function(e,t){n.onEvent&&n.onEvent(t),r.AppTelemetry&&r.AppTelemetry.onEventDone(n.dispId)},e)}catch(e){r.SafeArrayDelegate.onException(e,n)}},e.closeDialog=function(t){t.onCalling&&t.onCalling();var e=r.SafeArrayDelegate.getOnAfterRegisterEvent(!1,t);try{r._OfficeAppFactory.getClientHostController().closeDialog(t.dispId,void 0,t.targetId,e)}catch(e){r.SafeArrayDelegate.onException(e,t)}},e.messageParent=function(e){try{e.onCalling&&e.onCalling();var t=(new Date).getTime(),n=r._OfficeAppFactory.getClientHostController().messageParent(e.hostCallArgs);return e.onReceiving&&e.onReceiving(),r.AppTelemetry&&r.AppTelemetry.onMethodDone(e.dispId,e.hostCallArgs,Math.abs((new Date).getTime()-t),n),n}catch(e){return r.SafeArrayDelegate.onExceptionSyncMethod(e)}},e.sendMessage=function(e){try{e.onCalling&&e.onCalling();(new Date).getTime();var t=r._OfficeAppFactory.getClientHostController().sendMessage(e.hostCallArgs);return e.onReceiving&&e.onReceiving(),t}catch(e){return r.SafeArrayDelegate.onExceptionSyncMethod(e)}}}(OSF=OSF||{}),function(m){var y;(y=m.WACDelegate||(m.WACDelegate={})).openDialog=function(t){var e=JSON.parse(t.targetId),n=y.getOnAfterRegisterEvent(!0,t);function r(e){var t={Error:e};try{n(0,t)}catch(e){m.AppTelemetry&&m.AppTelemetry.logAppException("Exception happens at showDialogCallback."+e)}}if(m.DialogShownStatus.hasDialogShown)r(12007);else{var o=e[m.ShowWindowDialogParameterKeys.Url].toLowerCase(),i=window.location.href.toLowerCase();if(m.AppTelemetry){var a=!1,s=!1,c=!1,l=!1,u="",p="";if(m.OUtil){var f=m.OUtil.parseUrl(o),d=m.OUtil.parseUrl(i);a=f.protocol===d.protocol&&f.hostname===d.hostname&&f.port===d.port,u=m.OUtil.getHostnamePortionForLogging(f.hostname),a?p=u:(p=m.OUtil.getHostnamePortionForLogging(d.hostname),s=m.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(o,i),c=m.XdmCommunicationManager.isTargetSubdomainOfSourceLocation(i,o));var h=m._OfficeAppFactory.getOfficeAppContext().get_appDomains();l=m.XdmCommunicationManager.checkUrlWithAppDomains(h,o)}var g="openDialog isInline: "+e[m.ShowWindowDialogParameterKeys.DisplayInIframe].toString()+", taskpaneHostname: "+p+", dialogHostName: "+u+", isSameDomain: "+a.toString()+", parentIsSubdomain: "+s.toString()+", childIsSubdomain: "+c.toString()+", isAppDomain: "+l.toString();m.AppTelemetry.logAppCommonMessage(g)}null!=o&&"https://"===o.substr(0,"https://".length)?e[m.ShowWindowDialogParameterKeys.DisplayInIframe]?(m.DialogShownStatus.isWindowDialog=!1,m.WACDelegate.registerEventAsync(t)):(m.DialogShownStatus.isWindowDialog=!0,m.WacDialogAction.setHandlerAndShowDialogCallback(function(e){t.onEvent&&t.onEvent(e),m.AppTelemetry&&m.AppTelemetry.onEventDone(t.dispId)},r),m.WacDialogAction.handleNewWindowDialog(e)):"http://"===o.substr(0,"http://".length)?r(12005):r(12003)}},y.validateTaskpaneDomain=function(e,t){return m.WacDialogAction.validateTaskpaneDomain(e,t)},y.messageParent=function(e){var t=e.hostCallArgs.targetOrigin,n=!!t;if(n&&"*"!=t){var r=m.WacDialogAction.getLocalStorage(),o=m.WacDialogAction.getSessionStorage(),i="_trusts_",a=m.OUtil.parseUrl(t,!0);i+=a.protocol+"//"+a.hostname+(a.port?":"+a.port:""),m.WacDialogAction.setWithExpiry(r,i,"true"),m.WacDialogAction.setWithExpiry(o,i,"true")}if(null!=window.opener){if(!n){var s=m._OfficeAppFactory.getOfficeAppContext().get_taskpaneUrl();if(s){if(!m.WacDialogAction.validateTaskpaneDomain(s,!0)){var c="messageParent called but the taskpane domain is untrusted: "+s;throw m.AppTelemetry&&m.AppTelemetry.logAppException(c),new Error(c)}}else s=window.location.origin;e.hostCallArgs.targetOrigin=s}m.WacDialogAction.messageParent(e)}else{var l=window.location.origin;l=l||window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:""),n||(e.hostCallArgs.targetOrigin=l),m.WACDelegate.executeAsync(e)}},y.sendMessage=function(e){m.DialogShownStatus.hasDialogShown&&(m.DialogShownStatus.isWindowDialog?m.WacDialogAction.sendMessage(e):m.WACDelegate.executeAsync(e))},y.closeDialog=function(e){var n=y.getOnAfterRegisterEvent(!1,e);function t(e){var t={Error:e};try{n(0,t)}catch(e){m.AppTelemetry&&m.AppTelemetry.logAppException("Exception happens at closeDialogCallback."+e)}}m.DialogShownStatus.hasDialogShown?m.DialogShownStatus.isWindowDialog?(e.onCalling&&e.onCalling(),m.WacDialogAction.closeDialog(t)):m.WACDelegate.unregisterEventAsync(e):t(12006)}}(OSF=OSF||{}),function(t){t.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){},defineSafeArrayParameterMapFunc:function(){t.HostParameterMap.define({type:t.EventDispId.dispidDocumentSelectionChangedEvent})},defineWebParameterMapFunc:function(){t.HostParameterMap.define({type:t.EventDispId.dispidDocumentSelectionChangedEvent})},initializeFunc:function(){var e=Office.context.document;t.DispIdHost.addEventSupport(e,new t.EventDispatch([t.EventType.DocumentSelectionChanged,t.EventType.ActiveViewChanged]))}})}(OSF=OSF||{}),function(e){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||{}),function(t){var e;function n(){t.HostParameterMap.define({type:t.PropertyDescriptors.FeatureProperties,fromHost:[{name:t.PropertyDescriptors.TcidEnabled,value:0},{name:t.PropertyDescriptors.TcidVisible,value:1}],isComplexType:!0}),t.HostParameterMap.define({type:146,toHost:[{name:t.ParameterNames.Tcid,value:0}]}),t.HostParameterMap.define({type:147,fromHost:[{name:t.PropertyDescriptors.FeatureProperties,value:t.HostParameterMap.self}],toHost:[{name:t.ParameterNames.Tcid,value:0}]})}(e=t.PropertyDescriptors||(t.PropertyDescriptors={})).FeatureProperties="FeatureProperties",e.TcidEnabled="TcidEnabled",e.TcidVisible="TcidVisible",t.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){t.AsyncMethodCalls.define({method:t.AsyncMethods.ExecuteFeature,requiredArguments:[{name:t.ParameterNames.Tcid,types:["number"]}],privateStateCallbacks:[]}),t.AsyncMethodCalls.define({method:t.AsyncMethods.QueryFeature,requiredArguments:[{name:t.ParameterNames.Tcid,types:["number"]}],privateStateCallbacks:[]})},defineSafeArrayParameterMapFunc:n,defineWebParameterMapFunc:n,initializeFunc:function(){var e=Office.context.ui;t.DispIdHost.addAsyncMethods(e,[t.AsyncMethods.ExecuteFeature]),t.DispIdHost.addAsyncMethods(e,[t.AsyncMethods.QueryFeature])}})}(OSF=OSF||{}),function(e){var t,n;((t=e.context||(e.context={})).extensionLifeCycle||(t.extensionLifeCycle={})).launchExtensionComponent=function(e,t,n,r,o){var i=OSF.OUtil.Guid.generateNewGuid();null==o&&(o={OptionalProperties:{},DevProperties:{}}),o.OptionalProperties.InstanceToken=i;var a={ExtId:e,ComponentType:t,ComponentId:n,HostProps:r,OptionalProps:o};if(OSF._OfficeAppFactory.getHostInfo().hostPlatform!=OSF.HostInfoPlatform.web)throw OSF.Utility.createNotImplementedException();var s=OSF._OfficeAppFactory.getWebAppState();return s.clientEndPoint.invoke("ContextActivationManager_notifyHost",null,[s.id,OSF.AgaveHostAction.LaunchExtensionComponent,a]),{Id:e,ComponentType:t,ComponentId:n,InstanceToken:i,LaunchProperties:o}},(n=e.ExtensionLifeCycle||(e.ExtensionLifeCycle={})).close=function(e){OSF._OfficeAppFactory.getClientHostController().closeSdxDialog(e)},n.resize=function(e,t){OSF.Utility.isNullOrUndefined(e)||OSF.Utility.isNullOrUndefined(t)||"number"!=typeof e||"number"!=typeof t?OSF.Utility.debugLog("Invaid dialog width or height. Kindly provide two numbers as input parameters."):OSF._OfficeAppFactory.getClientHostController().resizeSdxDialog(e,t)}}(Office=Office||{}),function(e){var t=(Object.defineProperty(n.prototype,"size",{get:function(){return this.m_fileSize},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"sliceCount",{get:function(){return Math.ceil(this.m_fileSize/this.m_sliceSize)},enumerable:!0,configurable:!0}),n.prototype.getSliceAsync=function(e,t){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.GetDocumentCopyChunkAsync,arguments,this,this.m_privateState)},n.prototype.closeAsync=function(e){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.ReleaseDocumentCopyAsync,arguments,this,this.m_privateState)},n);function n(e,t,n){this.m_fileSize=t,this.m_sliceSize=n,this.m_privateState={},this.m_privateState[OSF.FileProperties.Handle]=e,this.m_privateState[OSF.FileProperties.SliceSize]=n}e.File=t}(Office=Office||{}),function(r){var e;((e=r.context||(r.context={})).document||(e.document={})).getFileAsync=function(e,t,n){OSF.DispIdHost.InvokeMethod(OSF.AsyncMethods.GetDocumentCopyAsync,arguments,r.context.document,void 0)}}(Office=Office||{}),function(o){var e,t,n,r,i,a,s,c;(e=o.PropertyDescriptors||(o.PropertyDescriptors={})).FileProperties="FileProperties",e.FileSliceProperties="FileSliceProperties",(t=o.FileProperties||(o.FileProperties={})).Handle="FileHandle",t.FileSize="FileSize",t.SliceSize="sliceSize",(o.additionalParameter||(o.additionalParameter={})).FileSliceOffset="fileSliceoffset",n=o.Marshaling||(o.Marshaling={}),r=n.File||(n.File={}),(i=r.FilePropertiesKeys||(r.FilePropertiesKeys={}))[i.Handle=0]="Handle",i[i.FileSize=1]="FileSize",(a=r.SlicePropertiesKeys||(r.SlicePropertiesKeys={}))[a.Data=0]="Data",a[a.SliceSize=1]="SliceSize",(s=r.FileType||(r.FileType={}))[s.Text=0]="Text",s[s.Compressed=1]="Compressed",s[s.Pdf=2]="Pdf",(c=r.ParameterKeys||(r.ParameterKeys={}))[c.FileType=0]="FileType",c[c.SliceSize=1]="SliceSize",c[c.Handle=2]="Handle",c[c.SliceIndex=3]="SliceIndex",o.File||(o.File={}),o.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){o.AsyncMethodCalls.define({method:o.AsyncMethods.GetDocumentCopyAsync,requiredArguments:[{name:o.ParameterNames.FileType,enum:Office.FileType}],supportedOptions:[{name:o.ParameterNames.SliceSize,value:{types:["number"],defaultValue:o.OUtil.getHostPlatform()==o.HostInfoPlatform.ios?65536:4194304}}],checkCallArgs:function(e,t,n){var r=e[o.ParameterNames.SliceSize];if(r<=0||4194304<r)throw 11002;return e},onSucceeded:function(e,t,n){return new Office.File(e[o.FileProperties.Handle],e[o.FileProperties.FileSize],n[o.ParameterNames.SliceSize])}}),o.AsyncMethodCalls.define({method:o.AsyncMethods.GetDocumentCopyChunkAsync,requiredArguments:[{name:o.ParameterNames.SliceIndex,types:["number"]}],privateStateCallbacks:[{name:o.FileProperties.Handle,value:function(e,t){return t[o.FileProperties.Handle]}},{name:o.FileProperties.SliceSize,value:function(e,t){return t[o.FileProperties.SliceSize]}}],checkCallArgs:function(e,t,n){var r=e[o.ParameterNames.SliceIndex];if(r<0||r>=t.sliceCount)throw 5008;return e[o.additionalParameter.FileSliceOffset]=parseInt((r*n[o.FileProperties.SliceSize]).toString()),e},onSucceeded:function(e,t,n){var r={};return o.OUtil.defineEnumerableProperties(r,{data:{value:o.OUtil.getHostPlatform()==o.HostInfoPlatform.mac?o.OUtil.shallowCopy(e[o.ParameterNames.Data]):e[o.ParameterNames.Data]},index:{value:n[o.ParameterNames.SliceIndex]},size:{value:e[o.FileProperties.SliceSize]}}),r}}),o.AsyncMethodCalls.define({method:o.AsyncMethods.ReleaseDocumentCopyAsync,privateStateCallbacks:[{name:o.FileProperties.Handle,value:function(e,t){return t[o.FileProperties.Handle]}}]})},defineSafeArrayParameterMapFunc:function(){o.HostParameterMap.define({type:o.PropertyDescriptors.FileProperties,fromHost:[{name:o.FileProperties.Handle,value:0},{name:o.FileProperties.FileSize,value:1}],isComplexType:!0}),o.HostParameterMap.define({type:o.PropertyDescriptors.FileSliceProperties,fromHost:[{name:o.ParameterNames.Data,value:0},{name:o.FileProperties.SliceSize,value:1}],isComplexType:!0}),o.HostParameterMap.define({type:o.ParameterNames.FileType,toHost:[{name:Office.FileType.Text,value:0},{name:Office.FileType.Compressed,value:5},{name:Office.FileType.Pdf,value:6}]}),o.HostParameterMap.define({type:77,toHost:[{name:o.ParameterNames.FileType,value:0}],fromHost:[{name:o.PropertyDescriptors.FileProperties,value:o.HostParameterMap.self}]}),o.HostParameterMap.define({type:80,toHost:[{name:o.FileProperties.Handle,value:0},{name:o.additionalParameter.FileSliceOffset,value:1},{name:o.FileProperties.SliceSize,value:2}],fromHost:[{name:o.PropertyDescriptors.FileSliceProperties,value:o.HostParameterMap.self}]}),o.HostParameterMap.define({type:81,toHost:[{name:o.FileProperties.Handle,value:0}]})},defineWebParameterMapFunc:function(){o.HostParameterMap.addComplexType(o.PropertyDescriptors.FileProperties),o.HostParameterMap.addComplexType(o.PropertyDescriptors.FileSliceProperties),o.HostParameterMap.define({type:o.PropertyDescriptors.FileProperties,fromHost:[{name:o.FileProperties.Handle,value:o.Marshaling.File.FilePropertiesKeys.Handle},{name:o.FileProperties.FileSize,value:o.Marshaling.File.FilePropertiesKeys.FileSize}]}),o.HostParameterMap.define({type:o.PropertyDescriptors.FileSliceProperties,fromHost:[{name:o.ParameterNames.Data,value:o.Marshaling.File.SlicePropertiesKeys.Data},{name:o.FileProperties.SliceSize,value:o.Marshaling.File.SlicePropertiesKeys.SliceSize}]}),o.HostParameterMap.define({type:o.ParameterNames.FileType,toHost:[{name:Office.FileType.Text,value:o.Marshaling.File.FileType.Text},{name:Office.FileType.Compressed,value:o.Marshaling.File.FileType.Compressed},{name:Office.FileType.Pdf,value:o.Marshaling.File.FileType.Pdf}]}),o.HostParameterMap.define({type:77,toHost:[{name:o.ParameterNames.FileType,value:o.Marshaling.File.ParameterKeys.FileType},{name:o.ParameterNames.SliceSize,value:o.Marshaling.File.ParameterKeys.SliceSize}],fromHost:[{name:o.PropertyDescriptors.FileProperties,value:o.HostParameterMap.self}]}),o.HostParameterMap.define({type:80,toHost:[{name:o.FileProperties.Handle,value:o.Marshaling.File.ParameterKeys.Handle},{name:o.ParameterNames.SliceIndex,value:o.Marshaling.File.ParameterKeys.SliceIndex}],fromHost:[{name:o.PropertyDescriptors.FileSliceProperties,value:o.HostParameterMap.self}]}),o.HostParameterMap.define({type:81,toHost:[{name:o.FileProperties.Handle,value:o.Marshaling.File.ParameterKeys.Handle}]})}})}(OSF=OSF||{}),(OfficeExt||(OfficeExt={})).FileProperties=function(e){OSF.OUtil.defineEnumerableProperties(this,{url:{value:e[OSF.FilePropertiesDescriptor.Url]}})},function(t){var e,n;t.FilePropertiesDescriptor={Url:"Url"},(t.PropertyDescriptors||(t.PropertyDescriptors={})).FilePropertiesDescriptor="FilePropertiesDescriptor",e=t.Marshaling||(t.Marshaling={}),(n=e.FilePropertiesKeys||(e.FilePropertiesKeys={}))[n.Properties=0]="Properties",n[n.Url=1]="Url",t.FileProperties||(t.FileProperties={}),t.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){t.AsyncMethodCalls.define({method:t.AsyncMethods.GetFilePropertiesAsync,fromHost:[{name:t.PropertyDescriptors.FilePropertiesDescriptor,value:0}],requiredArguments:[],supportedOptions:[],onSucceeded:function(e,t,n){return new OfficeExt.FileProperties(e)}})},defineSafeArrayParameterMapFunc:function(){t.HostParameterMap.define({type:t.PropertyDescriptors.FilePropertiesDescriptor,fromHost:[{name:t.FilePropertiesDescriptor.Url,value:0}],isComplexType:!0}),t.HostParameterMap.define({type:86,fromHost:[{name:t.PropertyDescriptors.FilePropertiesDescriptor,value:t.HostParameterMap.self}]})},defineWebParameterMapFunc:function(){t.HostParameterMap.addComplexType(t.PropertyDescriptors.FilePropertiesDescriptor),t.HostParameterMap.define({type:t.PropertyDescriptors.FilePropertiesDescriptor,fromHost:[{name:t.FilePropertiesDescriptor.Url,value:t.Marshaling.FilePropertiesKeys.Url}]}),t.HostParameterMap.define({type:86,fromHost:[{name:t.PropertyDescriptors.FilePropertiesDescriptor,value:t.Marshaling.FilePropertiesKeys.Properties}]})},initializeFunc:function(){var e=Office.context.document;t.DispIdHost.addAsyncMethods(e,[t.AsyncMethods.GetFilePropertiesAsync])}})}(OSF=OSF||{}),(Office||(Office={})).select=function(e,t){var n;if(e&&"string"==typeof e){var r=e.indexOf("#");if(-1!=r){var o=e.substring(0,r),i=e.substring(r+1);switch(o){case"binding":case"bindings":i&&(n=new OSF.BindingPromise(i))}}}if(n)return n.onFail=t,n;if(t){var a=typeof t;if("function"!=a)throw OSF.OUtil.formatString(Strings.OfficeOM.L_CallbackNotAFunction,a);var s={};s[OSF.ParameterNames.Callback]=t,OSF.DispIdHost.issueAsyncResult(s,5004,OSF.DDA.ErrorCodeManager.getErrorArgs(5004))}},function(s){var e,t;function c(e){var t=0;switch(e){case s.CoercionType.Text:t=0;break;case s.CoercionType.Matrix:t=1;break;case s.CoercionType.Table:t=2;break;case s.CoercionType.Html:t=3;break;case s.CoercionType.Ooxml:t=4;break;case s.CoercionType.OoxmlPackage:t=5;break;case s.CoercionType.PdfFile:t=6;break;case s.CoercionType.SlideRange:t=7;break;case"image":t=8;break;case"xmlSvg":t=9}return t}e=s.context||(s.context={}),(t=e.document||(e.document={})).setSelectedDataAsync=function(t,n,e){var r=null==n.coercionType?OSF.DataCoercion.determineCoercionType(t):n.coercionType;"function"==typeof n&&(e=n);var o={toSafeArrayHost:function(){var e=OSF._OfficeAppFactory.getHostInfo();return e.hostType.toLowerCase()==s.HostType.Word.toLowerCase()||e.hostType.toLowerCase()==s.HostType.PowerPoint.toLowerCase()||e.hostType.toLowerCase()==s.HostType.OneNote.toLowerCase()||e.hostType.toLowerCase()==s.HostType.Visio.toLowerCase()||"image"==r||"xmlSvg"==r?[c(r),OSF.DataCoercion.serializeDynamicData(t),null!=n.imageLeft&&n.imageLeft,null!=n.imageTop&&n.imageTop,null!=n.imageWidth&&n.imageWidth,null!=n.imageHeight&&n.imageHeight]:e.hostType.toLowerCase()==s.HostType.Excel.toLowerCase()?[c(r),OSF.DataCoercion.serializeDynamicData(t),null==n.cellFormat?[]:n.cellFormat,null==n.tableOptions?[]:n.tableOptions,null!=n.imageWidth&&n.imageWidth,null!=n.imageHeight&&n.imageHeight]:[c(r),OSF.DataCoercion.serializeDynamicData(t),null==n.cellFormat?[]:n.cellFormat,null==n.tableOptions?[]:n.tableOptions]},fromSafeArrayHost:function(e){return e},toWebHost:function(){return{DdaSetBindingData:{CoerceType:r,Data:OSF.DataCoercion.serializeDynamicData(t),CellFormat:[],TableOptions:[]}}},fromWebHost:function(e){return e}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(65,o,e,null)},t.getSelectedDataAsync=function(t,e,n){var r,o=s.ValueFormat.Unformatted,i=s.FilterType.All;"function"==typeof e?n=e:void 0!==e&&(void 0!==e.valueFormat&&(o=e.valueFormat),void 0!==e.filterType&&(i=e.filterType),void 0!==e.asyncContext&&(r=e.asyncContext));var a={toSafeArrayHost:function(){return[c(t),function(e){var t=0;switch(e){case s.ValueFormat.Unformatted:t=0;break;case s.ValueFormat.Formatted:t=1}return t}(o),function(e){var t=0;switch(e){case s.FilterType.All:t=0;break;case s.FilterType.OnlyVisible:t=1}return t}(i)]},fromSafeArrayHost:function(e){return OSF.DataCoercion.deserializeDynamicData(e,t)},toWebHost:function(){return{DdaGetBindingData:{CoerceType:t,ValueFormat:o,FilterType:i}}},fromWebHost:function(e){return OSF.DataCoercion.deserializeDynamicData(e.Data,t)}};OSF._OfficeAppFactory.getAsyncMethodExecutor().executeAsync(64,a,n,r)}}(Office=Office||{}),function(t){var e=(Object.defineProperty(n.prototype,"headers",{get:function(){return this._header},set:function(e){this._header=this.fixData(e)},enumerable:!0,configurable:!0}),Object.defineProperty(n.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}),n.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){}},n);function n(e,t){this._rows=e,this._header=t}t.TableData=e,t.manufactureTableData=function(e){return new t.TableData(e[OSF.TableDataProperties.TableRows],e[OSF.TableDataProperties.TableHeaders])}}(Office=Office||{}),function(e){e.BootStrapExtension.prepareApiSurface=function(){return new Promise(function(){e.V10ApiFeatureRegistry.initialize()})}}(OSF=OSF||{}),function(a){var e;(function(r){var e;(e=r.EventDescriptors||(r.EventDescriptors={})).OfficeThemeChangedEvent="OfficeThemeChangedEvent",e.DocumentThemeChangedEvent="DocumentThemeChangedEvent",a.V10ApiFeatureRegistry.register({defineMethodsFunc:function(){a.AsyncMethodCalls.define({method:a.AsyncMethods.GetDocumentThemeAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[],onSucceeded:a.DDA.Theming.ConvertToDocumentTheme}),a.AsyncMethodCalls.define({method:a.AsyncMethods.GetOfficeThemeAsync,requiredArguments:[],supportedOptions:[],privateStateCallbacks:[],onSucceeded:a.DDA.Theming.ConvertToOfficeTheme})},defineSafeArrayParameterMapFunc:function(){a.HostParameterMap.define({type:85,fromHost:[{name:a.ParameterNames.OfficeTheme,value:a.HostParameterMap.self}]}),a.HostParameterMap.define({type:a.ParameterNames.OfficeTheme,fromHost:[{name:a.DDA.Theming.OfficeThemeEnum.BodyForegroundColor,value:0},{name:a.DDA.Theming.OfficeThemeEnum.BodyBackgroundColor,value:1},{name:a.DDA.Theming.OfficeThemeEnum.ControlForegroundColor,value:2},{name:a.DDA.Theming.OfficeThemeEnum.ControlBackgroundColor,value:3},{name:a.DDA.Theming.OfficeThemeEnum.ThemeId,value:4},{name:a.DDA.Theming.OfficeThemeEnum.IsDarkTheme,value:5},{name:a.DDA.Theming.OfficeThemeEnum.FluentThemeData,value:6}],isComplexType:!0}),a.HostParameterMap.define({type:a.EventDispId.dispidOfficeThemeChangedEvent,fromHost:[{name:a.DDA.Theming.EventDescriptors.OfficeThemeChangedEvent,value:a.HostParameterMap.self}],isComplexType:!0}),a.HostParameterMap.define({type:a.DDA.Theming.EventDescriptors.OfficeThemeChangedEvent,fromHost:[{name:a.ParameterNames.OfficeTheme,value:a.HostParameterMap.self}],isComplexType:!0})},defineWebParameterMapFunc:function(){a.HostParameterMap.addComplexType(a.ParameterNames.DocumentTheme),a.HostParameterMap.addComplexType(a.ParameterNames.OfficeTheme),a.HostParameterMap.define({type:a.EventDispId.dispidOfficeThemeChangedEvent,fromHost:[{name:a.ParameterNames.OfficeTheme,value:a.HostParameterMap.self}]}),a.HostParameterMap.define({type:a.ParameterNames.OfficeTheme,fromHost:[{name:a.DDA.Theming.OfficeThemeEnum.BodyForegroundColor,value:a.DDA.Theming.OfficeThemeEnumWac.PrimaryFontColor},{name:a.DDA.Theming.OfficeThemeEnum.BodyBackgroundColor,value:a.DDA.Theming.OfficeThemeEnumWac.PrimaryBackgroundColor},{name:a.DDA.Theming.OfficeThemeEnum.ControlForegroundColor,value:a.DDA.Theming.OfficeThemeEnumWac.SecondaryFontColor},{name:a.DDA.Theming.OfficeThemeEnum.ControlBackgroundColor,value:a.DDA.Theming.OfficeThemeEnumWac.SecondaryBackgroundColor}],isComplexType:!0})},initializeFunc:function(){var e=a._OfficeAppFactory.getHostInfo(),t=e.hostType.toLowerCase();if(e.hostPlatform==a.HostInfoPlatform.web&&(t==Office.HostType.Word.toLowerCase()||t==Office.HostType.PowerPoint.toLowerCase())&&Office.context.officeTheme){var n=r.GetIsDarkThemeFromCSSHexColor(Office.context.officeTheme.bodyBackgroundColor);Office.context.officeTheme[a.DDA.Theming.OfficeThemeEnum.IsDarkTheme]=n,Office.context.officeTheme[a.DDA.Theming.OfficeThemeEnum.ThemeId]=n?a.DDA.Theming.ThemeId.Black:a.DDA.Theming.ThemeId.White}Office.context&&Office.context.themeManager&&Office.context.themeManager.InitializeAndChangeOnce()}});var t=(n.prototype.InitializeThemeManager=function(){this._eventTarget=this,a.DispIdHost.addAsyncMethods(this,[a.AsyncMethods.GetOfficeThemeAsync,a.AsyncMethods.GetDocumentThemeAsync]),a.DispIdHost.addEventSupport(this,new a.EventDispatch([Microsoft.Office.WebExtension.EventType.OfficeThemeChanged,Microsoft.Office.WebExtension.EventType.DocumentThemeChanged]))},n.prototype.InitializeAndChangeOnce=function(e){var t=this;this._officeCss=this._getOfficeThemesCss(),this._officeCss?(this._onAsyncCallsCompleted=e,this._asyncCallsCompleted={},this._asyncCallsCompleted[a.AsyncMethods.GetOfficeThemeAsync]=!1,this._asyncCallsCompleted[a.AsyncMethods.GetDocumentThemeAsync]=!1,this._getAndProcessThemeData(this._eventTarget.getOfficeThemeAsync,function(e){t._processOfficeThemeData(e)},a.AsyncMethods.GetOfficeThemeAsync)):e&&e()},n.prototype.isDarkTheme=function(){var e=!1;if(Office.context&&Office.context.officeTheme&&Office.context.officeTheme.bodyBackgroundColor){var t=Office.context.officeTheme.bodyBackgroundColor;e=r.GetIsDarkThemeFromCSSHexColor(t)}return e},n.prototype._getOfficeThemesCss=function(){try{return function(){for(var e="officethemes.css",t=0;t<document.styleSheets.length;t++){var n=document.styleSheets[t];if(!n.disabled&&n.href&&e==n.href.substring(n.href.length-e.length,n.href.length).toLowerCase())return n.cssRules||n.rules?n:(a.AppTelemetry&&a.AppTelemetry.logAppException("Browser styleSheet object does not implement cssRules or rules property. Viloates browser's css access rule"),null)}}()}catch(e){return a.AppTelemetry&&a.AppTelemetry.logAppException("Exception thrown when trying to read officethems.css:["+e+"]"),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(e){for(var t=[{name:a.DDA.Theming.DocumentThemeEnum.PrimaryFontColor,cssSelector:".office-docTheme-primary-fontColor",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.PrimaryBackgroundColor,cssSelector:".office-docTheme-primary-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.DocumentThemeEnum.SecondaryFontColor,cssSelector:".office-docTheme-secondary-fontColor",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.SecondaryBackgroundColor,cssSelector:".office-docTheme-secondary-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent1,cssSelector:".office-contentAccent1-color",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent2,cssSelector:".office-contentAccent2-color",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent3,cssSelector:".office-contentAccent3-color",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent4,cssSelector:".office-contentAccent4-color",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent5,cssSelector:".office-contentAccent5-color",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent6,cssSelector:".office-contentAccent6-color",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent1,cssSelector:".office-contentAccent1-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent2,cssSelector:".office-contentAccent2-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent3,cssSelector:".office-contentAccent3-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent4,cssSelector:".office-contentAccent4-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent5,cssSelector:".office-contentAccent5-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent6,cssSelector:".office-contentAccent6-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent1,cssSelector:".office-contentAccent1-borderColor",cssProperty:"border-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent2,cssSelector:".office-contentAccent2-borderColor",cssProperty:"border-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent3,cssSelector:".office-contentAccent3-borderColor",cssProperty:"border-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent4,cssSelector:".office-contentAccent4-borderColor",cssProperty:"border-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent5,cssSelector:".office-contentAccent5-borderColor",cssProperty:"border-color"},{name:a.DDA.Theming.DocumentThemeEnum.Accent6,cssSelector:".office-contentAccent6-borderColor",cssProperty:"border-color"},{name:a.DDA.Theming.DocumentThemeEnum.Hyperlink,cssSelector:".office-a",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.FollowedHyperlink,cssSelector:".office-a:visited",cssProperty:"color"},{name:a.DDA.Theming.DocumentThemeEnum.HeaderLatinFont,cssSelector:".office-headerFont-latin",cssProperty:"font-family"},{name:a.DDA.Theming.DocumentThemeEnum.HeaderEastAsianFont,cssSelector:".office-headerFont-eastAsian",cssProperty:"font-family"},{name:a.DDA.Theming.DocumentThemeEnum.HeaderScriptFont,cssSelector:".office-headerFont-script",cssProperty:"font-family"},{name:a.DDA.Theming.DocumentThemeEnum.HeaderLocalizedFont,cssSelector:".office-headerFont-localized",cssProperty:"font-family"},{name:a.DDA.Theming.DocumentThemeEnum.BodyLatinFont,cssSelector:".office-bodyFont-latin",cssProperty:"font-family"},{name:a.DDA.Theming.DocumentThemeEnum.BodyEastAsianFont,cssSelector:".office-bodyFont-eastAsian",cssProperty:"font-family"},{name:a.DDA.Theming.DocumentThemeEnum.BodyScriptFont,cssSelector:".office-bodyFont-script",cssProperty:"font-family"},{name:a.DDA.Theming.DocumentThemeEnum.BodyLocalizedFont,cssSelector:".office-bodyFont-localized",cssProperty:"font-family"}],n=e.type==a.EventType.DocumentThemeChanged?e.documentTheme:e,r=0;r<t.length;r++)if(null===this._previousDocumentThemeData||this._previousDocumentThemeData[t[r].name]!=n[t[r].name])if(null!=n[t[r].name]&&""!=n[t[r].name]){var o=n[t[r].name];"font-family"===t[r].cssProperty&&(o='"'+o.replace(new RegExp('"',"g"),'\\"')+'"'),this._changeCss(this._officeCss,t[r].cssSelector,"{"+t[r].cssProperty+":"+o+";}")}else this._changeCss(this._officeCss,t[r].cssSelector,"{}");this._previousDocumentThemeData=n},n.prototype._changeOfficeThemeData=function(e){for(var t=[{name:a.DDA.Theming.OfficeThemeEnum.BodyForegroundColor,cssSelector:".office-officeTheme-primary-fontColor",cssProperty:"color"},{name:a.DDA.Theming.OfficeThemeEnum.BodyBackgroundColor,cssSelector:".office-officeTheme-primary-bgColor",cssProperty:"background-color"},{name:a.DDA.Theming.OfficeThemeEnum.ControlForegroundColor,cssSelector:".office-officeTheme-secondary-fontColor",cssProperty:"color"},{name:a.DDA.Theming.OfficeThemeEnum.ControlBackgroundColor,cssSelector:".office-officeTheme-secondary-bgColor",cssProperty:"background-color"}],n=e.type==a.EventType.OfficeThemeChanged?e.officeTheme:e,r=0;r<t.length;r++)null!==this._previousOfficeThemeData&&this._previousOfficeThemeData[t[r].name]==n[t[r].name]||void 0!==n[t[r].name]&&this._changeCss(this._officeCss,t[r].cssSelector,"{"+t[r].cssProperty+":"+n[t[r].name]+";}");this._previousOfficeThemeData=n},n.prototype._getAndProcessThemeData=function(e,n,r){var o=this,t=a._OfficeAppFactory.getHostInfo();if(t&&t.hostPlatform==a.HostInfoPlatform.web){if(r==a.AsyncMethods.GetOfficeThemeAsync&&Office.context.officeTheme){var i={};i[a.DDA.Theming.OfficeThemeEnum.BodyBackgroundColor]=Office.context.officeTheme.bodyBackgroundColor,i[a.DDA.Theming.OfficeThemeEnum.BodyForegroundColor]=Office.context.officeTheme.bodyForegroundColor,i[a.DDA.Theming.OfficeThemeEnum.ControlBackgroundColor]=Office.context.officeTheme.controlBackgroundColor,i[a.DDA.Theming.OfficeThemeEnum.ControlForegroundColor]=Office.context.officeTheme.controlForegroundColor,i[a.DDA.Theming.OfficeThemeEnum.IsDarkTheme]=Office.context.officeTheme.isDarkTheme,i[a.DDA.Theming.OfficeThemeEnum.ThemeId]=Office.context.officeTheme.isDarkTheme?a.DDA.Theming.ThemeId.Black:a.DDA.Theming.ThemeId.White,i[a.DDA.Theming.OfficeThemeEnum.FluentThemeData]=Office.context.officeTheme.fluentThemeData,n(i)}}else e(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);function n(){this._eventTarget=null,this._previousDocumentThemeData=null,this._previousOfficeThemeData=null,this._officeCss=null,this._asyncCallsCompleted=null,this._onAsyncCallsCompleted=null}r.InternalThemeHandler=t})((e=a.DDA||(a.DDA={})).Theming||(e.Theming={}))}(OSF=OSF||{}),function(e){var t,n;t=e.context||(e.context={}),OSF.definePropertyOnNamespace(t,"themeManager",function(){return n||(n=new OSF.DDA.Theming.InternalThemeHandler).InitializeThemeManager(),n})}(Office=Office||{}),function(e){if(!function(){try{return"object"==typeof process&&"[object process]"===String(process)}catch(e){return}}()&&!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();