@omnia/fx 7.11.0-preview.8 → 7.11.1

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.
Files changed (123) hide show
  1. package/LICENSE.txt +14 -0
  2. package/internal-do-not-import-from-here/contexts/InternalAppContext.d.ts +4 -4
  3. package/internal-do-not-import-from-here/core/Cookies.d.ts +1 -0
  4. package/internal-do-not-import-from-here/core/console/ConsoleKeyboardShortcuts.d.ts +1 -0
  5. package/internal-do-not-import-from-here/core/messaging/BuiltInTopics.d.ts +1 -0
  6. package/internal-do-not-import-from-here/core/utils/AlternateLayoutTitleUtils.d.ts +6 -0
  7. package/internal-do-not-import-from-here/core/utils/index.d.ts +1 -0
  8. package/internal-do-not-import-from-here/index.d.ts +1 -0
  9. package/internal-do-not-import-from-here/manifests/omnia.fx.core.manifest.json +1 -1
  10. package/internal-do-not-import-from-here/manifests/omnia.fx.manifest.json +1 -1
  11. package/internal-do-not-import-from-here/manifests/omnia.fx.ux.manifest.json +1 -1
  12. package/internal-do-not-import-from-here/manifests/omnia.fx.ux.richtexteditor.manifest.json +1 -1
  13. package/internal-do-not-import-from-here/manifests/omnia.fx.worker.manifest.json +1 -1
  14. package/internal-do-not-import-from-here/manifests/omnia.vendor.manifest.json +1 -1
  15. package/internal-do-not-import-from-here/runtime/clientboot/Boot.d.ts +1 -0
  16. package/internal-do-not-import-from-here/services/AzureOpenAIService.d.ts +2 -1
  17. package/internal-do-not-import-from-here/services/BusinessProfileService.d.ts +1 -0
  18. package/internal-do-not-import-from-here/services/permissions/PermissionService.d.ts +1 -0
  19. package/internal-do-not-import-from-here/spfx/components/SpfxCustomizeStyle.d.ts +5 -0
  20. package/internal-do-not-import-from-here/stores/BusinessProfileStore.d.ts +1 -0
  21. package/internal-do-not-import-from-here/stores/EnterprisePropertyStore.d.ts +0 -1
  22. package/internal-do-not-import-from-here/stores/ProfileCardStore.d.ts +9 -5
  23. package/internal-do-not-import-from-here/ux/AnchorLink.d.ts +3 -0
  24. package/internal-do-not-import-from-here/ux/ComponentDefinitions.d.ts +1 -1
  25. package/internal-do-not-import-from-here/ux/TokenBasedRouter.d.ts +2 -0
  26. package/internal-do-not-import-from-here/ux/UxModels.d.ts +26 -0
  27. package/internal-do-not-import-from-here/ux/appprovisioning/apptitledescription/AppDescriptionInput.d.ts +2 -0
  28. package/internal-do-not-import-from-here/ux/appprovisioning/apptitledescription/IAppDescriptionInput.d.ts +1 -0
  29. package/internal-do-not-import-from-here/ux/confirmdialog/ConfirmDialog.d.ts +2 -0
  30. package/internal-do-not-import-from-here/ux/confirmdialog/IConfirmDialog.d.ts +1 -0
  31. package/internal-do-not-import-from-here/ux/draggable/Draggable.d.ts +1 -1
  32. package/internal-do-not-import-from-here/ux/features/FeatureActivation.d.ts +1 -0
  33. package/internal-do-not-import-from-here/ux/features/loc/localize.d.ts +1 -0
  34. package/internal-do-not-import-from-here/ux/filterengine/FilterEngineSettings.d.ts +4 -0
  35. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/LayoutEditorCanvas.d.ts +3 -0
  36. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/layoutitemactiontoolbar/LayoutItemActionToolbar.d.ts +5 -0
  37. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/layoutitems/LayoutColumn.d.ts +7 -0
  38. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/layoutitems/LayoutSection.d.ts +2 -0
  39. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/settings/BlockSettingsPanel.d.ts +1 -0
  40. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/settings/LayoutStructure.d.ts +4 -2
  41. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/settings/blocktitle/BlockTitle.d.ts +1 -0
  42. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/settings/blocktitle/IBlockTitle.d.ts +1 -0
  43. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/settings/breakpoints/BreakPointSectionSettingsComponent.d.ts +1 -0
  44. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/settings/breakpoints/BreakPointSettingsComponent.d.ts +2 -0
  45. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/settings/section/General.d.ts +1 -0
  46. package/internal-do-not-import-from-here/ux/layoutcanvas/editor/settings/tabs/TabBlockSettings.d.ts +1 -0
  47. package/internal-do-not-import-from-here/ux/layoutcanvas/factories/EditorLayoutItemFactory.d.ts +1 -0
  48. package/internal-do-not-import-from-here/ux/layoutcanvas/renderer/LayoutRendererCanvas.d.ts +3 -1
  49. package/internal-do-not-import-from-here/ux/layoutcanvas/rules/LayoutItemRules.d.ts +2 -1
  50. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/BlockSettingsProvider.d.ts +4 -4
  51. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/BreakPointManager.d.ts +3 -0
  52. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/LayoutItemDelegator.d.ts +16 -0
  53. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/LayoutManager.d.ts +3 -1
  54. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/index.d.ts +1 -0
  55. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/layoutdefinitionsettings/LayoutItemSettingsDefinitions.d.ts +2 -2
  56. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/layoutitemsrenderer/LayoutBlockRenderer.d.ts +4 -0
  57. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/layoutitemsrenderer/LayoutColumnRenderer.d.ts +6 -0
  58. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/layoutitemsrenderer/LayoutSectionRenderer.d.ts +4 -0
  59. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/styles/LayoutSectionContainerHelper.d.ts +10 -0
  60. package/internal-do-not-import-from-here/ux/layoutcanvas/shared/styles/SharedRendererStyles.css.d.ts +2 -0
  61. package/internal-do-not-import-from-here/ux/layoutcanvas/stores/LayoutCanvasStore.d.ts +35 -17
  62. package/internal-do-not-import-from-here/ux/mediapickerproviders/Youtube/YouTubeProvider.d.ts +1 -0
  63. package/internal-do-not-import-from-here/ux/mediapickerproviders/gptimageprovider/GptImageProvider.css.d.ts +41 -0
  64. package/internal-do-not-import-from-here/ux/mediapickerproviders/gptimageprovider/GptImageProvider.d.ts +53 -0
  65. package/internal-do-not-import-from-here/ux/mediapickerproviders/gptimageprovider/PollingImageComponent.d.ts +47 -0
  66. package/internal-do-not-import-from-here/ux/mediapickerproviders/gptimageprovider/loc/localize.d.ts +23 -0
  67. package/internal-do-not-import-from-here/ux/mediapickerproviders/mediaflow/models/MediaflowMedia.d.ts +1 -0
  68. package/internal-do-not-import-from-here/ux/print/api/PrintHandlerApi.d.ts +1 -0
  69. package/internal-do-not-import-from-here/ux/profilecard/ProfileCard.d.ts +2 -0
  70. package/internal-do-not-import-from-here/ux/richtexteditor/RichTextEditorSettings.d.ts +11 -1
  71. package/internal-do-not-import-from-here/ux/richtexteditor/extensions/Alignment/AlignmentNode.d.ts +2 -2
  72. package/internal-do-not-import-from-here/ux/richtexteditor/extensions/MediaPicker/MediaPickerEditorExtension.d.ts +7 -2
  73. package/internal-do-not-import-from-here/ux/richtexteditor/extensions/loc/localize.d.ts +4 -0
  74. package/internal-do-not-import-from-here/ux/settings/ISettingsPane.d.ts +1 -0
  75. package/internal-do-not-import-from-here/ux/settings/SettingsPane.css.d.ts +1 -0
  76. package/internal-do-not-import-from-here/ux/settings/SettingsPane.d.ts +1 -0
  77. package/internal-do-not-import-from-here/ux/signin/omnia/Renderer.d.ts +4 -4
  78. package/internal-do-not-import-from-here/ux/social/templates/CommentLikeTemplate.d.ts +2 -0
  79. package/internal-do-not-import-from-here/wcdefinitions.json +1 -1
  80. package/internal-do-not-import-from-here/wctypings.d.ts +177 -175
  81. package/package.json +4 -4
  82. package/internal-do-not-import-from-here/microsoftteams/MicrosoftTeams.d.ts +0 -5
  83. package/internal-do-not-import-from-here/shared/models/Bring.d.ts +0 -23
  84. package/internal-do-not-import-from-here/shared/models/Bring.js +0 -2
  85. package/internal-do-not-import-from-here/shared/models/Broadcasting.d.ts +0 -25
  86. package/internal-do-not-import-from-here/shared/models/Broadcasting.js +0 -12
  87. package/internal-do-not-import-from-here/shared/models/Future.d.ts +0 -52
  88. package/internal-do-not-import-from-here/shared/models/Future.js +0 -158
  89. package/internal-do-not-import-from-here/shared/models/Guid.d.ts +0 -17
  90. package/internal-do-not-import-from-here/shared/models/Guid.js +0 -51
  91. package/internal-do-not-import-from-here/shared/models/OmniaSharedBootstrapData.d.ts +0 -32
  92. package/internal-do-not-import-from-here/shared/models/OmniaSharedBootstrapData.js +0 -2
  93. package/internal-do-not-import-from-here/shared/models/Realtime.d.ts +0 -40
  94. package/internal-do-not-import-from-here/shared/models/Realtime.js +0 -40
  95. package/internal-do-not-import-from-here/shared/models/SharedConstants.d.ts +0 -6
  96. package/internal-do-not-import-from-here/shared/models/SharedConstants.js +0 -10
  97. package/internal-do-not-import-from-here/shared/models/StringExtensions.d.ts +0 -6
  98. package/internal-do-not-import-from-here/shared/models/StringExtensions.js +0 -3
  99. package/internal-do-not-import-from-here/shared/models/Tenant.d.ts +0 -4
  100. package/internal-do-not-import-from-here/shared/models/Tenant.js +0 -2
  101. package/internal-do-not-import-from-here/shared/models/Tokens.d.ts +0 -14
  102. package/internal-do-not-import-from-here/shared/models/Tokens.js +0 -2
  103. package/internal-do-not-import-from-here/shared/models/Topic.d.ts +0 -10
  104. package/internal-do-not-import-from-here/shared/models/Topic.js +0 -2
  105. package/internal-do-not-import-from-here/shared/models/WorkerProxyFuncs.d.ts +0 -8
  106. package/internal-do-not-import-from-here/shared/models/WorkerProxyFuncs.js +0 -14
  107. package/internal-do-not-import-from-here/shared/models/Workers.d.ts +0 -29
  108. package/internal-do-not-import-from-here/shared/models/Workers.js +0 -8
  109. package/internal-do-not-import-from-here/shared/models/index.d.ts +0 -14
  110. package/internal-do-not-import-from-here/shared/models/index.js +0 -18
  111. package/internal-do-not-import-from-here/shared/models/theming/BlueprintDefinition.d.ts +0 -27
  112. package/internal-do-not-import-from-here/shared/models/theming/BlueprintDefinition.js +0 -2
  113. package/internal-do-not-import-from-here/shared/models/theming/OmniaThemes.d.ts +0 -5
  114. package/internal-do-not-import-from-here/shared/models/theming/OmniaThemes.js +0 -18
  115. package/internal-do-not-import-from-here/shared/models/theming/ThemeDefinitionV2.d.ts +0 -61
  116. package/internal-do-not-import-from-here/shared/models/theming/ThemeDefinitionV2.js +0 -24
  117. package/internal-do-not-import-from-here/shared/models/theming/ThemeMethods.d.ts +0 -11
  118. package/internal-do-not-import-from-here/shared/models/theming/ThemeMethods.js +0 -143
  119. package/internal-do-not-import-from-here/shared/models/theming/TypographyDefinition.d.ts +0 -29
  120. package/internal-do-not-import-from-here/shared/models/theming/TypographyDefinition.js +0 -11
  121. package/internal-do-not-import-from-here/shared/models/theming/index.d.ts +0 -4
  122. package/internal-do-not-import-from-here/shared/models/theming/index.js +0 -7
  123. package/internal-do-not-import-from-here/ux/shim-tsx.d.ts +0 -14
@@ -1,23 +0,0 @@
1
- export type BringMethods = "GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "HEAD" | "OPTIONS";
2
- export type BringCacheOptions = "no-cache" | "reload" | "force-cache" | "only-if-cached";
3
- export type BringCredentials = "include" | "omit" | "same-origin";
4
- export interface BringInterceptOptions {
5
- beforeRequest?: (request: BringConfig) => BringConfig;
6
- afterRequest?: <T>(response: BringResponse<T>, request: BringConfig) => BringResponse<T>;
7
- }
8
- export interface BringConfig {
9
- baseUrl?: string;
10
- headers?: {
11
- [key: string]: string;
12
- };
13
- cache?: BringCacheOptions;
14
- interceptors?: BringInterceptOptions;
15
- abortable?: boolean;
16
- credentials?: BringCredentials;
17
- }
18
- export interface BringResponse<TData> {
19
- data?: TData;
20
- status: Number;
21
- statusText: String;
22
- ok: Boolean;
23
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,25 +0,0 @@
1
- import { Topic } from "./Topic";
2
- export declare enum BroadcastTopicScopes {
3
- localUi = "localUi",
4
- localWorker = "localWorker",
5
- localAll = "localAll",
6
- globalUi = "globalUi",
7
- globalWorker = "globalWorker",
8
- globalAll = "globalAll"
9
- }
10
- export interface BroadcastTopic<TMessage> extends Topic<TMessage> {
11
- scope: BroadcastTopicScopes;
12
- }
13
- export interface BroadcastInvokeTopic<TMessage, TReturnValue> extends Topic<TMessage> {
14
- scope: BroadcastTopicScopes;
15
- }
16
- export interface BroadcastMessage<TMessage> extends BroadcastTopic<TMessage> {
17
- message: TMessage;
18
- }
19
- export interface BroadcastInvokeMessage<TMessage, TReturnValue> extends BroadcastInvokeTopic<TMessage, TReturnValue> {
20
- messageId: string;
21
- message: TMessage;
22
- type: "request" | "response";
23
- error?: string;
24
- response?: TReturnValue;
25
- }
@@ -1,12 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.BroadcastTopicScopes = void 0;
4
- var BroadcastTopicScopes;
5
- (function (BroadcastTopicScopes) {
6
- BroadcastTopicScopes["localUi"] = "localUi";
7
- BroadcastTopicScopes["localWorker"] = "localWorker";
8
- BroadcastTopicScopes["localAll"] = "localAll";
9
- BroadcastTopicScopes["globalUi"] = "globalUi";
10
- BroadcastTopicScopes["globalWorker"] = "globalWorker";
11
- BroadcastTopicScopes["globalAll"] = "globalAll";
12
- })(BroadcastTopicScopes = exports.BroadcastTopicScopes || (exports.BroadcastTopicScopes = {}));
@@ -1,52 +0,0 @@
1
- export declare class Future<T> extends Promise<T> {
2
- resolve: (value: T) => void;
3
- reject: (reason: any) => void;
4
- resolving: boolean;
5
- private _resolved;
6
- private _rejected;
7
- private onAborted;
8
- constructor(executor: (resolve: (value: T) => void, reject: (reason?: any) => void, onAborted: (cb: (reason?: any) => void) => void) => void);
9
- /**
10
- * Handles success / rejection from Promise and returns the result as an object.
11
- * If the promise is rejected, the error will be in the error property.
12
- * No need to try/catch the promise when using this method.
13
- *
14
- * @return {*} {Future<{ success?: T, error?: Error; }>}
15
- * @memberof Future
16
- */
17
- tryCatch(): Future<[success: T, error: Error]>;
18
- unwrapAxiosApiResponse<T2>(): Future<T2>;
19
- unwrap<T2>(executor: (value: T, resolve: (value: T2) => void, reject: (reason?: any) => void) => void): Future<T2>;
20
- /**
21
- * Expose abort for other future to use.
22
- * chain method for future
23
- * @param onAbort
24
- */
25
- abortIf(onAbort: (cb: (reason?: any) => void) => void): this;
26
- /**
27
- * Aborts the request
28
- *
29
- * @param {*} [reason]
30
- * @memberof Future
31
- */
32
- abort(reason?: any): void;
33
- /**
34
- * Creates a Promise that is resolved with an array of results when all of the provided Promises
35
- * resolve, or rejected when any Promise is rejected.
36
- * @param values An array of Promises.
37
- * @returns A new Promise.
38
- */
39
- static all<T extends readonly unknown[] | []>(values: T): Promise<{
40
- -readonly [P in keyof T]: Awaited<T[P]>;
41
- }>;
42
- get resolved(): boolean;
43
- get rejected(): boolean;
44
- static get [Symbol.species](): PromiseConstructor;
45
- get [Symbol.toStringTag](): string;
46
- static new<TReturnValue>(): Future<TReturnValue>;
47
- }
48
- export declare class ResponsePromise<T> extends Promise<T> {
49
- cancelCb: (() => void);
50
- constructor(executor: any);
51
- cancel(): void;
52
- }
@@ -1,158 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ResponsePromise = exports.Future = void 0;
4
- class Future extends Promise {
5
- constructor(executor) {
6
- let resolveLocal;
7
- let rejectLocal;
8
- const onAborted = (cb) => {
9
- setTimeout(() => {
10
- this.onAborted = cb;
11
- });
12
- };
13
- const exec = (resolve, reject) => {
14
- // assign to local to prevent error assignbefore call super;
15
- resolveLocal = resolve;
16
- rejectLocal = reject;
17
- };
18
- super(exec);
19
- this.resolving = false;
20
- this._resolved = false;
21
- this._rejected = false;
22
- this.resolve = (value) => {
23
- this.resolving = false;
24
- this._resolved = true;
25
- resolveLocal(value);
26
- };
27
- this.reject = (reason) => {
28
- this.resolving = false;
29
- this._rejected = true;
30
- rejectLocal(reason);
31
- };
32
- if (executor) {
33
- executor(this.resolve, this.reject, onAborted);
34
- }
35
- }
36
- /**
37
- * Handles success / rejection from Promise and returns the result as an object.
38
- * If the promise is rejected, the error will be in the error property.
39
- * No need to try/catch the promise when using this method.
40
- *
41
- * @return {*} {Future<{ success?: T, error?: Error; }>}
42
- * @memberof Future
43
- */
44
- //tryCatch(): Future<{ success?: T, error?: Error; }> {
45
- tryCatch() {
46
- return new Future(async (resolve) => {
47
- try {
48
- const data = await this;
49
- resolve([data, undefined]);
50
- }
51
- catch (err) {
52
- resolve([undefined, err]);
53
- }
54
- });
55
- }
56
- unwrapAxiosApiResponse() {
57
- return new Future((resolve, reject, abort) => {
58
- this.abortIf(abort);
59
- return this.then(response => {
60
- const apiResponse = response;
61
- if (apiResponse?.data.success) {
62
- resolve(apiResponse.data.data);
63
- }
64
- else {
65
- reject(apiResponse.data.errorMessage);
66
- }
67
- }).catch(() => {
68
- reject();
69
- });
70
- });
71
- }
72
- unwrap(executor) {
73
- return new Future((resolve, reject, abort) => {
74
- this.abortIf(abort);
75
- return this.then(q => executor(q, resolve, reject));
76
- });
77
- }
78
- /**
79
- * Expose abort for other future to use.
80
- * chain method for future
81
- * @param onAbort
82
- */
83
- abortIf(onAbort) {
84
- //to avoid "Illegal invocation" from lost context of this
85
- const abort = (reason) => { this.abort(reason); };
86
- onAbort(abort);
87
- return this;
88
- }
89
- // then<TResult1 = T, TResult2 = never>(onfulfilled?: (value: T) => TResult1 | PromiseLike<TResult1>, onrejected?: (reason: any) => TResult2 | PromiseLike<TResult2>): Promise<TResult1 | TResult2> {
90
- // this.then();
91
- // }
92
- /**
93
- * Aborts the request
94
- *
95
- * @param {*} [reason]
96
- * @memberof Future
97
- */
98
- abort(reason) {
99
- if (this.onAborted) {
100
- this.onAborted(reason);
101
- }
102
- else {
103
- throw "Failed calling abort() => The future has no onAborted callback or you tried to call abort immediately after the future was created.";
104
- }
105
- }
106
- /**
107
- * Creates a Promise that is resolved with an array of results when all of the provided Promises
108
- * resolve, or rejected when any Promise is rejected.
109
- * @param values An array of Promises.
110
- * @returns A new Promise.
111
- */
112
- static all(values) {
113
- // have issue with Promise.all not working when promises is mixin Future and promise
114
- // so implement Future.all to make a wrapper promise to Future to resolve that issue.
115
- const promises = values.map(p => p instanceof Future ? new Promise((resolve, reject) => p.then(resolve, reject)) : p);
116
- return Promise.all(promises);
117
- }
118
- get resolved() {
119
- return this._resolved;
120
- }
121
- get rejected() {
122
- return this._rejected;
123
- }
124
- static get [Symbol.species]() {
125
- return Promise;
126
- }
127
- get [Symbol.toStringTag]() {
128
- // return Object value to make vue can build get/set reactive.
129
- return "Object";
130
- }
131
- static new() {
132
- return new Future(() => { });
133
- }
134
- }
135
- exports.Future = Future;
136
- class ResponsePromise extends Promise {
137
- constructor(executor) {
138
- const onCancel = (cb) => {
139
- //using nextTick because we cant use "this" before super()
140
- setTimeout(() => {
141
- this.cancelCb = cb;
142
- });
143
- };
144
- const oExecutor = (resolve, reject) => {
145
- executor(resolve, reject, onCancel);
146
- };
147
- super(oExecutor);
148
- }
149
- cancel() {
150
- if (this.cancelCb) {
151
- this.cancelCb();
152
- }
153
- else {
154
- console.warn("onCancel not provided");
155
- }
156
- }
157
- }
158
- exports.ResponsePromise = ResponsePromise;
@@ -1,17 +0,0 @@
1
- export interface GuidValue {
2
- toString: () => string;
3
- }
4
- /**
5
- * Class to create a guid
6
- */
7
- export declare class Guid implements GuidValue {
8
- private static _empty;
9
- static newGuid(): GuidValue;
10
- static get empty(): GuidValue;
11
- static isValid(guid: string | GuidValue): boolean;
12
- private value;
13
- constructor(guid: string);
14
- toString(): string;
15
- toJSON: () => string;
16
- valueOf(): string;
17
- }
@@ -1,51 +0,0 @@
1
- "use strict";
2
- //export interface GuidValue {
3
- // :string;
4
- //}
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.Guid = void 0;
7
- /**
8
- * Class to create a guid
9
- */
10
- class Guid {
11
- static newGuid() {
12
- return new Guid("xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, c => {
13
- const r = Math.random() * 16 | 0;
14
- const v = (c == "x") ? r : (r & 0x3 | 0x8);
15
- return v.toString(16);
16
- }));
17
- }
18
- static get empty() {
19
- return this._empty;
20
- }
21
- static isValid(guid) {
22
- if (guid === undefined || guid === null) {
23
- return false;
24
- }
25
- const validRegex = /^[{]?[0-9a-fA-F]{8}[-]?([0-9a-fA-F]{4}[-]?){3}[0-9a-fA-F]{12}[}]?$/;
26
- return validRegex.test(guid.toString());
27
- }
28
- constructor(guid) {
29
- this.value = Guid._empty;
30
- //We serialize as string value
31
- this.toJSON = () => {
32
- return this.value.toLowerCase();
33
- };
34
- if (guid) {
35
- if (Guid.isValid(guid)) {
36
- this.value = guid;
37
- }
38
- else {
39
- throw `The string '${guid}' is not a valid Guid`;
40
- }
41
- }
42
- }
43
- toString() {
44
- return this.value.toLowerCase();
45
- }
46
- valueOf() {
47
- return this.value.toLowerCase();
48
- }
49
- }
50
- exports.Guid = Guid;
51
- Guid._empty = "00000000-0000-0000-0000-000000000000";
@@ -1,32 +0,0 @@
1
- import { OmniaToken } from ".";
2
- import { Guid, GuidValue } from "./Guid";
3
- import { TenantIdentifier } from "./Tenant";
4
- export interface OmniaSharedBootstrapData {
5
- uiThreadId: GuidValue;
6
- workerThreadId: GuidValue;
7
- customDomain?: string;
8
- defaultDomain: string;
9
- routePrefixes: string[];
10
- language: string;
11
- /**
12
- * The tokenKey is only avilable if we are running ITP or Dev intent
13
- */
14
- tokenKey?: OmniaToken;
15
- tokenRef: GuidValue;
16
- identity: string;
17
- licenses: Array<Guid>;
18
- hubDev?: boolean;
19
- realtimeDevPort?: string;
20
- tenant: TenantIdentifier;
21
- servingMode?: boolean;
22
- serviceDnsMapping: OmniaServiceToDnsMapping;
23
- authDisabled?: boolean;
24
- analytics: OmniaAnalytics;
25
- }
26
- export interface OmniaAnalytics {
27
- paq: any[];
28
- enabled: boolean;
29
- }
30
- export interface OmniaServiceToDnsMapping {
31
- [serviceId: string]: string;
32
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,40 +0,0 @@
1
- import { Guid, GuidValue } from "./Guid";
2
- export declare abstract class RealtimeChannel {
3
- /**
4
- * Construct a unique channel id that can be targeted to users who are set to be in that channel on the client
5
- * @returns id
6
- */
7
- abstract getId(): string;
8
- }
9
- export declare class BusinuessProfileChannel extends RealtimeChannel {
10
- private _profileId;
11
- constructor(profileId: Guid);
12
- getId(): string;
13
- }
14
- export declare abstract class RealtimeData<TRealtimeChannel extends RealtimeChannel, TRealtimeData> {
15
- private _channel;
16
- private _value;
17
- get channel(): TRealtimeChannel;
18
- get value(): TRealtimeData;
19
- abstract getId(): GuidValue;
20
- constructor(channel: TRealtimeChannel, value?: TRealtimeData);
21
- }
22
- export declare class PageChatRealtimeData extends RealtimeData<BusinuessProfileChannel, {
23
- x: number;
24
- y: number;
25
- }> {
26
- constructor(channel: BusinuessProfileChannel);
27
- getId(): GuidValue;
28
- }
29
- export type RealtimeChannelUpdateTypes = "activate" | "deactivate";
30
- export interface RealtimeChannelUpdateMessage extends RealtimChannelMessage {
31
- threadId: GuidValue;
32
- type: RealtimeChannelUpdateTypes;
33
- }
34
- export interface RealtimeSendMessage extends RealtimChannelMessage {
35
- dataId: GuidValue;
36
- data: any;
37
- }
38
- export interface RealtimChannelMessage {
39
- channelId: string;
40
- }
@@ -1,40 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.PageChatRealtimeData = exports.RealtimeData = exports.BusinuessProfileChannel = exports.RealtimeChannel = void 0;
4
- const Guid_1 = require("./Guid");
5
- class RealtimeChannel {
6
- }
7
- exports.RealtimeChannel = RealtimeChannel;
8
- class BusinuessProfileChannel extends RealtimeChannel {
9
- constructor(profileId) {
10
- super();
11
- this._profileId = profileId;
12
- }
13
- getId() {
14
- return this._profileId.toString();
15
- }
16
- }
17
- exports.BusinuessProfileChannel = BusinuessProfileChannel;
18
- class RealtimeData {
19
- get channel() {
20
- return this._channel;
21
- }
22
- get value() {
23
- return this._value;
24
- }
25
- constructor(channel, value) {
26
- this._channel = channel;
27
- this._value = value;
28
- }
29
- }
30
- exports.RealtimeData = RealtimeData;
31
- //FIXME: This is a test implementation remove when tested
32
- class PageChatRealtimeData extends RealtimeData {
33
- constructor(channel) {
34
- super(channel);
35
- }
36
- getId() {
37
- return new Guid_1.Guid("0366c62b-da25-4ed1-b5dc-de7e9934249f");
38
- }
39
- }
40
- exports.PageChatRealtimeData = PageChatRealtimeData;
@@ -1,6 +0,0 @@
1
- export declare const SharedConstants: {
2
- broadcast: {
3
- channelName: string;
4
- };
5
- commaSeparatedValue: string;
6
- };
@@ -1,10 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SharedConstants = void 0;
4
- //TODO: Consider moving Constants from fx models here and merge them
5
- exports.SharedConstants = {
6
- broadcast: {
7
- channelName: "omnia-fx-broadcast"
8
- },
9
- commaSeparatedValue: ","
10
- };
@@ -1,6 +0,0 @@
1
- declare global {
2
- interface StringConstructor {
3
- empty: string;
4
- }
5
- }
6
- export {};
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- String.empty = "";
@@ -1,4 +0,0 @@
1
- import { GuidValue } from "./Guid";
2
- export interface TenantIdentifier {
3
- id: GuidValue;
4
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,14 +0,0 @@
1
- import { GuidValue } from "./Guid";
2
- export interface OmniaToken {
3
- tokenKey: string;
4
- tokenRef: GuidValue;
5
- loginName: string;
6
- expires: number;
7
- forDevIntent: boolean;
8
- }
9
- export interface OmniaTokenRef {
10
- tenantId: GuidValue;
11
- identityId: string;
12
- tokenRef: GuidValue;
13
- localDev: boolean;
14
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,10 +0,0 @@
1
- export interface Topic<T> {
2
- namespace: string;
3
- name: string;
4
- }
5
- export interface TopicSettings {
6
- caching?: TopicCacheSettings;
7
- }
8
- export interface TopicCacheSettings {
9
- size: number;
10
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,8 +0,0 @@
1
- import { Guid } from "./Guid";
2
- import { WorkerProxyFunction } from "./Workers";
3
- export declare const WorkerProxyFuncs: {
4
- ui: {
5
- loadManifests: WorkerProxyFunction<Guid[], Guid[]>;
6
- };
7
- worker: {};
8
- };
@@ -1,14 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.WorkerProxyFuncs = void 0;
4
- const Guid_1 = require("./Guid");
5
- exports.WorkerProxyFuncs = {
6
- //Worker to Ui functions
7
- ui: {
8
- loadManifests: {
9
- id: new Guid_1.Guid("8fb843b7-936f-4fec-a462-77c087adb7de")
10
- }
11
- },
12
- //Ui to worker functions
13
- worker: {}
14
- };
@@ -1,29 +0,0 @@
1
- import { GuidValue } from "./Guid";
2
- import { OmniaSharedBootstrapData } from "./OmniaSharedBootstrapData";
3
- export interface WorkerProxyAction<TParamType> {
4
- id: GuidValue;
5
- }
6
- export interface WorkerProxyFunction<TParamType, TReturnType> extends WorkerProxyAction<TParamType> {
7
- }
8
- export interface WorkerProxyMessage<T> {
9
- id: GuidValue;
10
- data: T;
11
- handlerId: GuidValue;
12
- initiator: WorkerProxyFunctionInitiators;
13
- }
14
- export declare enum WorkerProxyFunctionInitiators {
15
- ui = "main",
16
- worker = "worker"
17
- }
18
- export interface LoadManifestsMessage extends PostMessageWithType {
19
- type: "loadManifests";
20
- resourceUrls: Array<string>;
21
- }
22
- export interface BootWorkerMessage {
23
- type: "bootWorker";
24
- loadManifests: LoadManifestsMessage;
25
- bootData: OmniaSharedBootstrapData;
26
- }
27
- export interface PostMessageWithType {
28
- type: "bootWorker" | "loadManifests";
29
- }
@@ -1,8 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.WorkerProxyFunctionInitiators = void 0;
4
- var WorkerProxyFunctionInitiators;
5
- (function (WorkerProxyFunctionInitiators) {
6
- WorkerProxyFunctionInitiators["ui"] = "main";
7
- WorkerProxyFunctionInitiators["worker"] = "worker";
8
- })(WorkerProxyFunctionInitiators = exports.WorkerProxyFunctionInitiators || (exports.WorkerProxyFunctionInitiators = {}));
@@ -1,14 +0,0 @@
1
- export * from "./Guid";
2
- export * from "./Broadcasting";
3
- export * from "./Topic";
4
- export * from "./Workers";
5
- export * from "./SharedConstants";
6
- export * from "./WorkerProxyFuncs";
7
- export * from "./Bring";
8
- export * from "./Future";
9
- export * from "./Tokens";
10
- export * from "./Tenant";
11
- export * from "./Realtime";
12
- export * from "./OmniaSharedBootstrapData";
13
- export * from "./StringExtensions";
14
- export * from "./theming";
@@ -1,18 +0,0 @@
1
- "use strict";
2
- //! <omnia-transform-resource path="9a75501c-254b-46d1-9010-7b13681e06f4" />
3
- Object.defineProperty(exports, "__esModule", { value: true });
4
- const tslib_1 = require("tslib");
5
- tslib_1.__exportStar(require("./Guid"), exports);
6
- tslib_1.__exportStar(require("./Broadcasting"), exports);
7
- tslib_1.__exportStar(require("./Topic"), exports);
8
- tslib_1.__exportStar(require("./Workers"), exports);
9
- tslib_1.__exportStar(require("./SharedConstants"), exports);
10
- tslib_1.__exportStar(require("./WorkerProxyFuncs"), exports);
11
- tslib_1.__exportStar(require("./Bring"), exports);
12
- tslib_1.__exportStar(require("./Future"), exports);
13
- tslib_1.__exportStar(require("./Tokens"), exports);
14
- tslib_1.__exportStar(require("./Tenant"), exports);
15
- tslib_1.__exportStar(require("./Realtime"), exports);
16
- tslib_1.__exportStar(require("./OmniaSharedBootstrapData"), exports);
17
- tslib_1.__exportStar(require("./StringExtensions"), exports);
18
- tslib_1.__exportStar(require("./theming"), exports);