@openfin/workspace 45.0.6 → 45.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/notifications.js CHANGED
@@ -1,2 +1,2 @@
1
- (()=>{"use strict";var e={78(e,t,n){n.d(t,{XI:()=>s,kz:()=>l});var a=n(438),o=(n(102),n(822)),r=n(70);const i=(0,o.h)("common.protocol.notifications"),s="of-workspace-notifications-sync";var c;async function l(){const e=await async function(){try{const e=await(0,a.S8)(),t=e?.notifications?.customManifest?.manifestUuid;return t||r.ct.uuid}catch(e){return i.warn("getNotificationCenterUuid","Could not get manifest options for notifications, using default",{error:e instanceof Error?e.message:String(e)}),r.ct.uuid}}();return e!==r.ct.uuid?`${e}-${s}`:s}!function(e){e.UpdatePlatformThemeScheme="update-platform-theme-scheme"}(c||(c={}))},79(e,t,n){n.d(t,{N:()=>s,OF:()=>o});const a=(0,n(822).h)("common.protocol.workspacePlatform");var o;!function(e){e.LaunchApp="launchApp",e.SavePage="savePage",e.GetSavedPage="getSavedPage",e.CreateSavedPage="createSavedPage",e.UpdateSavedPage="updateSavedPage",e.DeleteSavedPage="deleteSavedPage",e.GetSavedPages="getSavedPages",e.CreateSavedPageInternal="createSavedPageInternal",e.UpdateSavedPageInternal="updateSavedPageInternal",e.DeleteSavedPageInternal="deleteSavedPageInternal",e.UpdatePageForWindow="updatePageForWindow",e.AttachPagesToWindow="attachPagesToWindow",e.DetachPagesFromWindow="detachPagesFromWindow",e.ReorderPagesForWindow="reorderPagesForWindow",e.SetActivePage="setActivePage",e.AddPage="addPage",e.AddDefaultPage="addDefaultPage",e.GetAllAttachedPages="getAllAttachedPages",e.GetActivePageIdForWindow="getActivePageIdForWindow",e.GetPagesForWindow="getPagesForWindow",e.GetPageForWindow="getPageForWindow",e.GetSavedPageMetadata="getSavedPageMetadata",e.GetUniquePageTitle="getUniquePageTitle",e.GetLastFocusedBrowserWindow="getLastFocusedBrowserWindow",e.GetPageByViewIdentity="getPageByViewIdentity",e.GetThemes="getThemes",e.GetGeneratedPalettes="getGeneratedPalettes",e.GetThemePaletteSheet="getThemePaletteSheet",e.GetSelectedScheme="getSelectedScheme",e.SetSelectedScheme="setSelectedScheme",e.OpenGlobalContextMenuInternal="openGlobalContextMenuInternal",e.OpenViewTabContextMenuInternal="openViewTabContextMenuInternal",e.OpenPageTabContextMenuInternal="openPageTabContextMenuInternal",e.OpenSaveButtonContextMenuInternal="openSaveButtonContextMenuInternal",e.InvokeCustomActionInternal="invokeCustomActionInternal",e.RequestQuitPlatformDialogInternal="requestQuitPlatformDialogInternal",e.GetSavedWorkspace="getSavedWorkspace",e.CreateSavedWorkspace="createSavedWorkspace",e.UpdateSavedWorkspace="updateSavedWorkspace",e.DeleteSavedWorkspace="deleteSavedWorkspace",e.GetSavedWorkspaces="getSavedWorkspaces",e.GetSavedWorkspacesMetadata="getSavedWorkspacesMetadata",e.SaveWorkspace="saveWorkspace",e.GetCurrentWorkspace="getCurrentWorkspace",e.ApplyWorkspace="applyWorkspace",e.RestoreLastSavedWorkspaceInternal="restoreLastSavedWorkspaceInternal",e.SetActiveWorkspace="setActiveWorkspace",e.IsBrowserInitialized="isBrowserInitialized",e.Analytics="analyticsInternal",e.GetLanguage="getLanguage",e.GetLanguageResourcesInternal="getLanguageResourcesInternal",e.SetLanguage="setLanguage",e.GetDockProviderConfig="getDockProviderConfig",e.SaveDockProviderConfig="saveDockProviderConfig",e.HandleSaveModalOnPageClose="handleSaveModalOnPageClose",e.ShouldPageClose="shouldPageClose",e.ShouldWindowClose="shouldWindowClose",e.CopyPage="copyPage",e.HandlePageChanges="handlePageChanges",e.MarkUnsavedPagesAsSavedInternal="markUnsavedPagesAsSavedInternal",e.TrackRemovedTabInternal="trackRemovedTabInternal",e.RestoreRemovedTabInternal="restoreRemovedTabInternal",e.TrackVisitedSiteInternal="trackVisitedSiteInternal",e.GetRecentlyVisitedSitesInternal="getRecentlyVisitedSitesInternal",e.GetFrequentlyVisitedSitesInternal="getFrequentlyVisitedSitesInternal",e.SearchSitesInternal="searchSitesInternal",e.GetSearchProvidersInternal="getSearchProvidersInternal",e.GetCuratedContentInternal="getCuratedContentInternal",e.HandleRequestNavigationInternal="handleRequestNavigationInternal",e.RefreshBookmarksInternal="refreshBookmarksInternal",e.LaunchBookmarkInternal="launchBookmarkInternal",e.GetNotificationsConfig="getNotificationsConfig",e.UpdateDockFavoritesInternal="updateDockFavoritesInternal",e.UpdateContentMenuInternal="updateContentMenuInternal",e.LaunchDockEntryInternal="launchDockEntryInternal",e.SetDockFavoritesOrderInternal="setDockFavoritesOrderInternal",e.NavigateContentMenuInternal="navigateContentMenuInternal",e.SetDefaultDockButtonsOrderInternal="setDefaultDockButtonsOrderInternal",e.GetDockWorkspacesContextMenuInternal="getDockWorkspacesContextMenuInternal",e.HandleDockWorkspacesMenuResponseInternal="handleDockWorkspacesMenuResponseInternal",e.RefreshDockCollectionMenuInternal="refreshDockCollectionMenuInternal",e.LaunchCollectionInternal="launchCollectionInternal",e.RemoveDockFavoriteInternal="removeDockFavoriteInternal",e.AddDockFavoriteInternal="addDockFavoriteInternal",e.FocusAndExpandSearchInternal="focusAndExpandSearchInternal",e.SendUpdateVersionModalResponseInternal="sendUpdateVersionModalResponseInternal",e.ShowUpdateVersionModalInternal="showUpdateVersionModalInternal",e.ShowApplyAndPublishModalInternal="showApplyAndPublishModalInternal",e.GetNotificationIndicatorColorsInternal="getNotificationIndicatorColorsInternal",e.GetIsLegacySinglePaletteTheme="getIsLegacySinglePaletteTheme",e.GetLegacyNotificationsThemeInternal="getLegacyNotificationsThemeInternal"}(o||(o={}));const r=async e=>fin.Platform.wrapSync(e).getClient(),i=async e=>{const t=await r(e),n="Target is not a Workspace Platform. Target must call WorkspacePlatform.init";let o;try{o=await t.dispatch("isWorkspacePlatform")}catch(e){throw new Error(n)}if("boolean"==typeof o&&o)return a.warn("internalGetWorkspacePlatformChannelClient","You are using an older version of the workspace platform. Please update your workspace platform."),o;if("object"==typeof o&&o.isWorkspacePlatform)return o;throw new Error(n)},s=async e=>(await i(e),r(e))},438(e,t,n){n.d(t,{MW:()=>a,S8:()=>s});var a,o,r=n(723);!function(e){e.Workspace="openfin-workspace",e.OldWorkspace="openfin-browser"}(a||(a={})),function(e){e.FinProtocol="fin-protocol"}(o||(o={}));r.$h,a.Workspace;let i=null;const s=async()=>(i||(i=fin.Application.getCurrentSync().getManifest()),i)},102(e,t,n){var a=n(723);(0,n(822).h)("common.channels"),a.YY&&"complete"!==document.readyState&&new Promise(e=>document.addEventListener("readystatechange",()=>{"complete"===document.readyState&&e()}))},723(e,t,n){var a;n.d(t,{$h:()=>s,YY:()=>r,et:()=>d,vL:()=>c}),function(e){e.Local="local",e.Dev="dev",e.Staging="staging",e.Prod="prod"}(a||(a={}));const o="undefined"!=typeof window&&"undefined"!=typeof fin,r=("undefined"==typeof process||process.env,"undefined"!=typeof window),i=r?window.origin:a.Local,s=o&&fin.me.uuid,c=o&&fin.me.name,l=(o&&fin.me.entityType,a.Local,a.Dev,a.Staging,a.Prod,e=>e.startsWith("http://")||e.startsWith("https://")?e:i+e),d=(l("https://workspace.openfin.co/workspace/45.0.6"),l("https://workspace.openfin.co/workspace/45.0.6"),"undefined"!=typeof WORKSPACE_DOCS_PLATFORM_URL&&l(WORKSPACE_DOCS_PLATFORM_URL),"undefined"!=typeof WORKSPACE_DOCS_CLIENT_URL&&l(WORKSPACE_DOCS_CLIENT_URL),"45.0.6");"undefined"!=typeof WORKSPACE_BUILD_SHA&&WORKSPACE_BUILD_SHA},822(e,t,n){n.d(t,{h:()=>i});let a="undefined"==typeof LOG_STRINGIFY||!0===LOG_STRINGIFY;const o={includeTimestamp:!0,customPrefix:"",stringifyData:void 0},r=e=>{try{return JSON.stringify(e,null,2)}catch(t){try{const t=new WeakSet;return JSON.stringify(e,(e,n)=>{if("object"==typeof n&&null!==n){if(t.has(n))return"[Circular Reference]";t.add(n)}return"bigint"==typeof n?`[BigInt: ${n.toString()}]`:"function"==typeof n?`[Function: ${n.name||"anonymous"}]`:"symbol"==typeof n?`[Symbol: ${n.toString()}]`:void 0===n?"[Undefined]":n},2)}catch(t){try{return`[Non-serializable: ${Object.prototype.toString.call(e)}]`}catch{return"[Unable to serialize data]"}}}},i=(e,t={})=>{const n={...o,...t},i=(o,i,s,c)=>{try{const l=((e,t,n,a)=>{const o=a.includeTimestamp?(new Date).toISOString():"";return`${o?`${o} `:""}${a.customPrefix?`${a.customPrefix} `:""}[${e}][${t}] ${n}`})(e,i,s,n),d=((e,t)=>{if(!e)return;const n="function"==typeof e?e():e;return n?t?r(n):n:void 0})(c,void 0!==t.stringifyData?t.stringifyData:a),p=console[o];void 0!==d?p(l,d):p(l)}catch(t){try{console.error("[Logger Error] Failed to log message:",t),console[o](`[${e}][${i}]`,s,c)}catch(e){}}};return{debug:(e,t,n)=>i("debug",e,t,n),info:(e,t,n)=>i("info",e,t,n),warn:(e,t,n)=>i("warn",e,t,n),error:(e,t,n)=>i("error",e,t,n)}}},277(e,t,n){n.d(t,{os:()=>s});var a=n(723),o=n(822);n(70);(0,o.h)("common.usageRegister");var r;!function(e){e.Browser="Browser",e.Dock="Dock",e.EnterpriseDock="EnterpriseDock",e.Home="Home",e.Notification="Notification",e.Storefront="Storefront",e.Platform="Platform",e.Theming="Theming",e.Microflow="Microflow"}(r||(r={}));const i=async(e,t,n="workspace-licensing")=>{const o={apiVersion:t.apiVersion||a.et,componentName:e,componentVersion:t.componentVersion||a.et,allowed:t.allowed,rejectionCode:t.rejectionCode};fin.System.registerUsage({type:n,data:o})};const s=e=>{i(r.Notification,e)};new Map},70(e,t,n){n.d(t,{ct:()=>i});n(78);var a=n(438),o=n(723);(0,n(822).h)("common.window");var r;!function(e){e.Home="openfin-home",e.Dock="openfin-dock",e.Storefront="openfin-storefront",e.HomeInternal="openfin-home-internal",e.BrowserIndicator="openfin-browser-indicator",e.BrowserWindow="internal-generated-window",e.ClassicWindow="internal-generated-classic-window",e.BrowserAddressSearchPrefix="openfin-browser-menu-address-search-",e.DockCompanion="openfin-dock-companion",e.AICompanionPrefix="openfin-ai-companion-",e.AboutPageWindow="here-about-page",e.FindInPageViewPrefix="here-find-in-page-view-",e.BrowserMenu="openfin-browser-menu",e.BrowserSaveMenu="openfin-browser-save-menu",e.DockSaveWorkspaceMenu="openfin-dock3-save-workspace-menu",e.DropdownMenu="openfin-enterprise-dropdown-menu",e.EnterpriseContextMenu="openfin-enterprise-context-menu",e.TabSearchMenu="openfin-browser-tab-search-menu",e.EnterpriseBookmarkDialogWindow="openfin-enterprise-bookmark-dialog",e.ZoomControlsDialog="here-zoom-controls-dialog",e.UpdateVersionModal="here-update-version-modal",e.ApplyAndPublishModal="here-apply-and-publish-modal",e.PublishOnCloseModal="here-publish-on-close-modal",e.DesktopSignalsModal="here-desktop-signals-modal",e.IntentsResolverModal="here-intents-resolver-modal"}(r||(r={}));o.vL,o.$h;r.Home,a.MW.Workspace,r.Dock,a.MW.Workspace;const i={name:"Notification-Center",uuid:"notifications-service"};r.Storefront,a.MW.Workspace,a.MW.Workspace,a.MW.Workspace},812(e){e.exports=require("@openfin/notifications")}},t={};function n(a){var o=t[a];if(void 0!==o)return o.exports;var r=t[a]={exports:{}};return e[a](r,r.exports,n),r.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};n.r(a),n.d(a,{deregister:()=>v,isLegacyNotifications:()=>u,register:()=>S,usesNotificationsSyncChannel:()=>f});var o=n(277),r=n(78),i=n(79),s=n(812),c={};for(const e in s)["default","usesNotificationsSyncChannel","isLegacyNotifications","register","deregister"].indexOf(e)<0&&(c[e]=()=>s[e]);n.d(a,c);const l=async e=>{if(e instanceof Error){let t=e.message;if(e.message.includes("register-notifications-platform")){if(t="Notifications platforms are not supported in versions below 1.13.0, try updating your notifications-service.",s?.provider?.getStatus){const{version:e}=await s.provider.getStatus();t+=` Your version is: ${e}`}return t}return e.message}return"string"==typeof e?e:"unknown error registering Notifications"},d=async e=>{if(e instanceof Error&&e.message.includes("register-notifications-platform"))throw new Error(await l(e));throw e},p="of-notifications-service-v1",f=e=>{const[t]=e.split("."),n=Number.parseInt(t,10);return Number.isFinite(n)&&n>=2},u=e=>{const[t,n]=e.split(".").map(Number);return t<2||2===t&&n<=13},g={channelName:r.XI},m=async(e,t,n=!1)=>{const a=f(t.notificationsVersion)?g.channelName:p,o=await fin.InterApplicationBus.Channel.connect(a,{wait:n}),r=f(t.notificationsVersion)?"register-platform":"register-notifications-platform";await o.dispatch(r,e)};async function S(e){try{const t=await(0,r.kz)(),n=e&&"notificationsCustomManifest"in e?{customManifest:e.notificationsCustomManifest}:void 0;let a=!1;t!==r.XI?(g.channelName=t,a=!0):n&&n.customManifest?.manifestUuid&&(g.channelName=`${n.customManifest.manifestUuid}-${r.XI}`,console.warn("Using 'notificationsCustomManifest' is deprecated. Please include custom manifest in platform manifest."));const c=await s.register(n),l=await(0,i.N)(fin.me.identity),d=await l.dispatch(i.OF.GetThemePaletteSheet,void 0),p=await l.dispatch(i.OF.GetNotificationIndicatorColorsInternal,void 0);if(e){const t=await l.dispatch(i.OF.GetSelectedScheme,void 0),n=u(c.notificationsVersion),o=n?await l.dispatch(i.OF.GetLegacyNotificationsThemeInternal,void 0):null,r="notificationsPlatformOptions"in e?e.notificationsPlatformOptions:e,s=o??d;await m({theme:s,...n?{}:{notificationsIndicatorColors:p},scheme:t,...r,workspacePlatform:{identity:fin.Platform.getCurrentSync().identity,analytics:{isSupported:!0}}},{notificationsVersion:c.notificationsVersion},a)}return(0,o.os)({allowed:!0,apiVersion:s.VERSION,componentVersion:c.notificationsVersion}),c}catch(e){(0,o.os)({allowed:!1,rejectionCode:await l(e),apiVersion:s.VERSION}),await d(e)}}const v=async e=>{try{const{version:t}=await s.provider.getStatus();if(null===t)throw new Error("Notifications service is not currently running.");await(async(e,t)=>{const n=f(t.notificationsVersion)?g.channelName:p,a=await fin.InterApplicationBus.Channel.connect(n,{wait:!1}),o=f(t.notificationsVersion)?"deregister-platform":"deregister-notifications-platform";await a.dispatch(o,e)})({id:e},{notificationsVersion:t})}catch(e){await d(e)}};module.exports=a})();
1
+ (()=>{"use strict";var e={78(e,t,n){n.d(t,{XI:()=>s,kz:()=>l});var a=n(438),o=(n(102),n(822)),r=n(70);const i=(0,o.h)("common.protocol.notifications"),s="of-workspace-notifications-sync";var c;async function l(){const e=await async function(){try{const e=await(0,a.S8)(),t=e?.notifications?.customManifest?.manifestUuid;return t||r.ct.uuid}catch(e){return i.warn("getNotificationCenterUuid","Could not get manifest options for notifications, using default",{error:e instanceof Error?e.message:String(e)}),r.ct.uuid}}();return e!==r.ct.uuid?`${e}-${s}`:s}!function(e){e.UpdatePlatformThemeScheme="update-platform-theme-scheme"}(c||(c={}))},79(e,t,n){n.d(t,{N:()=>s,OF:()=>o});const a=(0,n(822).h)("common.protocol.workspacePlatform");var o;!function(e){e.LaunchApp="launchApp",e.SavePage="savePage",e.GetSavedPage="getSavedPage",e.CreateSavedPage="createSavedPage",e.UpdateSavedPage="updateSavedPage",e.DeleteSavedPage="deleteSavedPage",e.GetSavedPages="getSavedPages",e.CreateSavedPageInternal="createSavedPageInternal",e.UpdateSavedPageInternal="updateSavedPageInternal",e.DeleteSavedPageInternal="deleteSavedPageInternal",e.UpdatePageForWindow="updatePageForWindow",e.AttachPagesToWindow="attachPagesToWindow",e.DetachPagesFromWindow="detachPagesFromWindow",e.ReorderPagesForWindow="reorderPagesForWindow",e.SetActivePage="setActivePage",e.AddPage="addPage",e.AddDefaultPage="addDefaultPage",e.GetAllAttachedPages="getAllAttachedPages",e.GetActivePageIdForWindow="getActivePageIdForWindow",e.GetPagesForWindow="getPagesForWindow",e.GetPageForWindow="getPageForWindow",e.GetSavedPageMetadata="getSavedPageMetadata",e.GetUniquePageTitle="getUniquePageTitle",e.GetLastFocusedBrowserWindow="getLastFocusedBrowserWindow",e.GetPageByViewIdentity="getPageByViewIdentity",e.GetThemes="getThemes",e.GetGeneratedPalettes="getGeneratedPalettes",e.GetThemePaletteSheet="getThemePaletteSheet",e.GetSelectedScheme="getSelectedScheme",e.SetSelectedScheme="setSelectedScheme",e.OpenGlobalContextMenuInternal="openGlobalContextMenuInternal",e.OpenViewTabContextMenuInternal="openViewTabContextMenuInternal",e.OpenPageTabContextMenuInternal="openPageTabContextMenuInternal",e.OpenSaveButtonContextMenuInternal="openSaveButtonContextMenuInternal",e.InvokeCustomActionInternal="invokeCustomActionInternal",e.RequestQuitPlatformDialogInternal="requestQuitPlatformDialogInternal",e.GetSavedWorkspace="getSavedWorkspace",e.CreateSavedWorkspace="createSavedWorkspace",e.UpdateSavedWorkspace="updateSavedWorkspace",e.DeleteSavedWorkspace="deleteSavedWorkspace",e.GetSavedWorkspaces="getSavedWorkspaces",e.GetSavedWorkspacesMetadata="getSavedWorkspacesMetadata",e.SaveWorkspace="saveWorkspace",e.GetCurrentWorkspace="getCurrentWorkspace",e.ApplyWorkspace="applyWorkspace",e.RestoreLastSavedWorkspaceInternal="restoreLastSavedWorkspaceInternal",e.SetActiveWorkspace="setActiveWorkspace",e.IsBrowserInitialized="isBrowserInitialized",e.Analytics="analyticsInternal",e.GetLanguage="getLanguage",e.GetLanguageResourcesInternal="getLanguageResourcesInternal",e.SetLanguage="setLanguage",e.GetDockProviderConfig="getDockProviderConfig",e.SaveDockProviderConfig="saveDockProviderConfig",e.HandleSaveModalOnPageClose="handleSaveModalOnPageClose",e.ShouldPageClose="shouldPageClose",e.ShouldWindowClose="shouldWindowClose",e.CopyPage="copyPage",e.HandlePageChanges="handlePageChanges",e.MarkUnsavedPagesAsSavedInternal="markUnsavedPagesAsSavedInternal",e.TrackRemovedTabInternal="trackRemovedTabInternal",e.RestoreRemovedTabInternal="restoreRemovedTabInternal",e.TrackVisitedSiteInternal="trackVisitedSiteInternal",e.GetRecentlyVisitedSitesInternal="getRecentlyVisitedSitesInternal",e.GetFrequentlyVisitedSitesInternal="getFrequentlyVisitedSitesInternal",e.SearchSitesInternal="searchSitesInternal",e.GetSearchProvidersInternal="getSearchProvidersInternal",e.GetCuratedContentInternal="getCuratedContentInternal",e.HandleRequestNavigationInternal="handleRequestNavigationInternal",e.RefreshBookmarksInternal="refreshBookmarksInternal",e.LaunchBookmarkInternal="launchBookmarkInternal",e.GetNotificationsConfig="getNotificationsConfig",e.UpdateDockFavoritesInternal="updateDockFavoritesInternal",e.UpdateContentMenuInternal="updateContentMenuInternal",e.LaunchDockEntryInternal="launchDockEntryInternal",e.SetDockFavoritesOrderInternal="setDockFavoritesOrderInternal",e.NavigateContentMenuInternal="navigateContentMenuInternal",e.SetDefaultDockButtonsOrderInternal="setDefaultDockButtonsOrderInternal",e.GetDockWorkspacesContextMenuInternal="getDockWorkspacesContextMenuInternal",e.HandleDockWorkspacesMenuResponseInternal="handleDockWorkspacesMenuResponseInternal",e.RefreshDockCollectionMenuInternal="refreshDockCollectionMenuInternal",e.LaunchCollectionInternal="launchCollectionInternal",e.RemoveDockFavoriteInternal="removeDockFavoriteInternal",e.AddDockFavoriteInternal="addDockFavoriteInternal",e.FocusAndExpandSearchInternal="focusAndExpandSearchInternal",e.SendUpdateVersionModalResponseInternal="sendUpdateVersionModalResponseInternal",e.ShowUpdateVersionModalInternal="showUpdateVersionModalInternal",e.ShowApplyAndPublishModalInternal="showApplyAndPublishModalInternal",e.GetNotificationIndicatorColorsInternal="getNotificationIndicatorColorsInternal",e.GetIsLegacySinglePaletteTheme="getIsLegacySinglePaletteTheme",e.GetLegacyNotificationsThemeInternal="getLegacyNotificationsThemeInternal"}(o||(o={}));const r=async e=>fin.Platform.wrapSync(e).getClient(),i=async e=>{const t=await r(e),n="Target is not a Workspace Platform. Target must call WorkspacePlatform.init";let o;try{o=await t.dispatch("isWorkspacePlatform")}catch(e){throw new Error(n)}if("boolean"==typeof o&&o)return a.warn("internalGetWorkspacePlatformChannelClient","You are using an older version of the workspace platform. Please update your workspace platform."),o;if("object"==typeof o&&o.isWorkspacePlatform)return o;throw new Error(n)},s=async e=>(await i(e),r(e))},438(e,t,n){n.d(t,{MW:()=>a,S8:()=>s});var a,o,r=n(723);!function(e){e.Workspace="openfin-workspace",e.OldWorkspace="openfin-browser"}(a||(a={})),function(e){e.FinProtocol="fin-protocol"}(o||(o={}));r.$h,a.Workspace;let i=null;const s=async()=>(i||(i=fin.Application.getCurrentSync().getManifest()),i)},102(e,t,n){var a=n(723);(0,n(822).h)("common.channels"),a.YY&&"complete"!==document.readyState&&new Promise(e=>document.addEventListener("readystatechange",()=>{"complete"===document.readyState&&e()}))},723(e,t,n){var a;n.d(t,{$h:()=>s,YY:()=>r,et:()=>d,vL:()=>c}),function(e){e.Local="local",e.Dev="dev",e.Staging="staging",e.Prod="prod"}(a||(a={}));const o="undefined"!=typeof window&&"undefined"!=typeof fin,r=("undefined"==typeof process||process.env,"undefined"!=typeof window),i=r?window.origin:a.Local,s=o&&fin.me.uuid,c=o&&fin.me.name,l=(o&&fin.me.entityType,a.Local,a.Dev,a.Staging,a.Prod,e=>e.startsWith("http://")||e.startsWith("https://")?e:i+e),d=(l("https://workspace.openfin.co/workspace/45.0.7"),l("https://workspace.openfin.co/workspace/45.0.7"),"undefined"!=typeof WORKSPACE_DOCS_PLATFORM_URL&&l(WORKSPACE_DOCS_PLATFORM_URL),"undefined"!=typeof WORKSPACE_DOCS_CLIENT_URL&&l(WORKSPACE_DOCS_CLIENT_URL),"45.0.7");"undefined"!=typeof WORKSPACE_BUILD_SHA&&WORKSPACE_BUILD_SHA},822(e,t,n){n.d(t,{h:()=>i});let a="undefined"==typeof LOG_STRINGIFY||!0===LOG_STRINGIFY;const o={includeTimestamp:!0,customPrefix:"",stringifyData:void 0},r=e=>{try{return JSON.stringify(e,null,2)}catch(t){try{const t=new WeakSet;return JSON.stringify(e,(e,n)=>{if("object"==typeof n&&null!==n){if(t.has(n))return"[Circular Reference]";t.add(n)}return"bigint"==typeof n?`[BigInt: ${n.toString()}]`:"function"==typeof n?`[Function: ${n.name||"anonymous"}]`:"symbol"==typeof n?`[Symbol: ${n.toString()}]`:void 0===n?"[Undefined]":n},2)}catch(t){try{return`[Non-serializable: ${Object.prototype.toString.call(e)}]`}catch{return"[Unable to serialize data]"}}}},i=(e,t={})=>{const n={...o,...t},i=(o,i,s,c)=>{try{const l=((e,t,n,a)=>{const o=a.includeTimestamp?(new Date).toISOString():"";return`${o?`${o} `:""}${a.customPrefix?`${a.customPrefix} `:""}[${e}][${t}] ${n}`})(e,i,s,n),d=((e,t)=>{if(!e)return;const n="function"==typeof e?e():e;return n?t?r(n):n:void 0})(c,void 0!==t.stringifyData?t.stringifyData:a),p=console[o];void 0!==d?p(l,d):p(l)}catch(t){try{console.error("[Logger Error] Failed to log message:",t),console[o](`[${e}][${i}]`,s,c)}catch(e){}}};return{debug:(e,t,n)=>i("debug",e,t,n),info:(e,t,n)=>i("info",e,t,n),warn:(e,t,n)=>i("warn",e,t,n),error:(e,t,n)=>i("error",e,t,n)}}},277(e,t,n){n.d(t,{os:()=>s});var a=n(723),o=n(822);n(70);(0,o.h)("common.usageRegister");var r;!function(e){e.Browser="Browser",e.Dock="Dock",e.EnterpriseDock="EnterpriseDock",e.Home="Home",e.Notification="Notification",e.Storefront="Storefront",e.Platform="Platform",e.Theming="Theming",e.Microflow="Microflow"}(r||(r={}));const i=async(e,t,n="workspace-licensing")=>{const o={apiVersion:t.apiVersion||a.et,componentName:e,componentVersion:t.componentVersion||a.et,allowed:t.allowed,rejectionCode:t.rejectionCode};fin.System.registerUsage({type:n,data:o})};const s=e=>{i(r.Notification,e)};new Map},70(e,t,n){n.d(t,{ct:()=>i});n(78);var a=n(438),o=n(723);(0,n(822).h)("common.window");var r;!function(e){e.Home="openfin-home",e.Dock="openfin-dock",e.Storefront="openfin-storefront",e.HomeInternal="openfin-home-internal",e.BrowserIndicator="openfin-browser-indicator",e.BrowserWindow="internal-generated-window",e.ClassicWindow="internal-generated-classic-window",e.BrowserAddressSearchPrefix="openfin-browser-menu-address-search-",e.DockCompanion="openfin-dock-companion",e.AICompanionPrefix="openfin-ai-companion-",e.AboutPageWindow="here-about-page",e.FindInPageViewPrefix="here-find-in-page-view-",e.BrowserMenu="openfin-browser-menu",e.BrowserSaveMenu="openfin-browser-save-menu",e.DockSaveWorkspaceMenu="openfin-dock3-save-workspace-menu",e.DropdownMenu="openfin-enterprise-dropdown-menu",e.EnterpriseContextMenu="openfin-enterprise-context-menu",e.TabSearchMenu="openfin-browser-tab-search-menu",e.EnterpriseBookmarkDialogWindow="openfin-enterprise-bookmark-dialog",e.ZoomControlsDialog="here-zoom-controls-dialog",e.UpdateVersionModal="here-update-version-modal",e.ApplyAndPublishModal="here-apply-and-publish-modal",e.PublishOnCloseModal="here-publish-on-close-modal",e.DesktopSignalsModal="here-desktop-signals-modal",e.IntentsResolverModal="here-intents-resolver-modal"}(r||(r={}));o.vL,o.$h;r.Home,a.MW.Workspace,r.Dock,a.MW.Workspace;const i={name:"Notification-Center",uuid:"notifications-service"};r.Storefront,a.MW.Workspace,a.MW.Workspace,a.MW.Workspace},812(e){e.exports=require("@openfin/notifications")}},t={};function n(a){var o=t[a];if(void 0!==o)return o.exports;var r=t[a]={exports:{}};return e[a](r,r.exports,n),r.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};n.r(a),n.d(a,{deregister:()=>v,isLegacyNotifications:()=>u,register:()=>S,usesNotificationsSyncChannel:()=>f});var o=n(277),r=n(78),i=n(79),s=n(812),c={};for(const e in s)["default","usesNotificationsSyncChannel","isLegacyNotifications","register","deregister"].indexOf(e)<0&&(c[e]=()=>s[e]);n.d(a,c);const l=async e=>{if(e instanceof Error){let t=e.message;if(e.message.includes("register-notifications-platform")){if(t="Notifications platforms are not supported in versions below 1.13.0, try updating your notifications-service.",s?.provider?.getStatus){const{version:e}=await s.provider.getStatus();t+=` Your version is: ${e}`}return t}return e.message}return"string"==typeof e?e:"unknown error registering Notifications"},d=async e=>{if(e instanceof Error&&e.message.includes("register-notifications-platform"))throw new Error(await l(e));throw e},p="of-notifications-service-v1",f=e=>{const[t]=e.split("."),n=Number.parseInt(t,10);return Number.isFinite(n)&&n>=2},u=e=>{const[t,n]=e.split(".").map(Number);return t<2||2===t&&n<=13},g={channelName:r.XI},m=async(e,t,n=!1)=>{const a=f(t.notificationsVersion)?g.channelName:p,o=await fin.InterApplicationBus.Channel.connect(a,{wait:n}),r=f(t.notificationsVersion)?"register-platform":"register-notifications-platform";await o.dispatch(r,e)};async function S(e){try{const t=await(0,r.kz)(),n=e&&"notificationsCustomManifest"in e?{customManifest:e.notificationsCustomManifest}:void 0;let a=!1;t!==r.XI?(g.channelName=t,a=!0):n&&n.customManifest?.manifestUuid&&(g.channelName=`${n.customManifest.manifestUuid}-${r.XI}`,console.warn("Using 'notificationsCustomManifest' is deprecated. Please include custom manifest in platform manifest."));const c=await s.register(n),l=await(0,i.N)(fin.me.identity),d=await l.dispatch(i.OF.GetThemePaletteSheet,void 0),p=await l.dispatch(i.OF.GetNotificationIndicatorColorsInternal,void 0);if(e){const t=await l.dispatch(i.OF.GetSelectedScheme,void 0),n=u(c.notificationsVersion),o=n?await l.dispatch(i.OF.GetLegacyNotificationsThemeInternal,void 0):null,r="notificationsPlatformOptions"in e?e.notificationsPlatformOptions:e,s=o??d;await m({theme:s,...n?{}:{notificationsIndicatorColors:p},scheme:t,...r,workspacePlatform:{identity:fin.Platform.getCurrentSync().identity,analytics:{isSupported:!0}}},{notificationsVersion:c.notificationsVersion},a)}return(0,o.os)({allowed:!0,apiVersion:s.VERSION,componentVersion:c.notificationsVersion}),c}catch(e){(0,o.os)({allowed:!1,rejectionCode:await l(e),apiVersion:s.VERSION}),await d(e)}}const v=async e=>{try{const{version:t}=await s.provider.getStatus();if(null===t)throw new Error("Notifications service is not currently running.");await(async(e,t)=>{const n=f(t.notificationsVersion)?g.channelName:p,a=await fin.InterApplicationBus.Channel.connect(n,{wait:!1}),o=f(t.notificationsVersion)?"deregister-platform":"deregister-notifications-platform";await a.dispatch(o,e)})({id:e},{notificationsVersion:t})}catch(e){await d(e)}};module.exports=a})();
2
2
  //# sourceMappingURL=notifications.js.map
package/package.json CHANGED
@@ -2,18 +2,18 @@
2
2
  "name": "@openfin/workspace",
3
3
  "description": "An API for integrating with OpenFin Workspace.",
4
4
  "main": "index.js",
5
- "version": "45.0.6",
5
+ "version": "45.0.7",
6
6
  "sideEffects": false,
7
7
  "keywords": [
8
8
  "client api"
9
9
  ],
10
10
  "license": "SEE LICENSE IN LICENSE.MD",
11
11
  "peerDependencies": {
12
- "@openfin/core": "45.100.90"
12
+ "@openfin/core": "45.100.93"
13
13
  },
14
14
  "dependencies": {
15
15
  "@openfin/microsoft365": "^1.1.0",
16
- "@openfin/notifications": "45.0.0-alpha-4708",
16
+ "@openfin/notifications": "45.0.0-alpha-4712",
17
17
  "dexie": "^4.0.11",
18
18
  "i18next": "^23.7.16",
19
19
  "lodash.debounce": "^4.0.8",