@omnia/fx-models 7.5.74-dev → 8.0.0-dev
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/BlockTitleSettings.d.ts +5 -5
- package/ClientManifests.d.ts +23 -8
- package/ClientManifests.js +8 -0
- package/Constants.d.ts +1 -0
- package/Constants.js +1 -0
- package/Enums.d.ts +14 -1
- package/Enums.js +17 -2
- package/Exposes.d.ts +7 -1
- package/Exposes.js +7 -1
- package/Extends.d.ts +2 -2
- package/FilterEngineStyles.d.ts +1 -1
- package/FilterpickerModel.d.ts +9 -0
- package/Func.d.ts +28 -0
- package/IPropertiesApi.d.ts +1 -1
- package/Icon.d.ts +17 -0
- package/Icon.js +66 -1
- package/Journey.d.ts +8 -2
- package/Layout.d.ts +15 -17
- package/LayoutDefinition.d.ts +5 -1
- package/LinkHandler/linktype/DefaultLinkType.js +1 -1
- package/LinkHandler/linktype/DocumentLinkType.js +1 -1
- package/ManifestIds.d.ts +60 -4
- package/ManifestIds.js +172 -9
- package/MediaScalingSettings.d.ts +6 -0
- package/Messaging.d.ts +1 -0
- package/Secrets.d.ts +1 -0
- package/TargetingProperty.js +1 -1
- package/TokenDefinition.d.ts +1 -1
- package/apps/AppInstanceRollup.d.ts +1 -1
- package/apps/AppInstanceRollup.js +1 -1
- package/azure-openai/dalle/ErrorResponse.js +1 -1
- package/azure-openai/dalle/StatusRequest.js +1 -1
- package/componentproptypes/ThemeableComponents.d.ts +7 -0
- package/componentproptypes/ThemeableComponents.js +2 -0
- package/componentproptypes/index.d.ts +1 -0
- package/componentproptypes/index.js +4 -0
- package/docs/Api.d.ts +37 -0
- package/docs/Api.js +2 -0
- package/docs/index.d.ts +1 -0
- package/docs/index.js +4 -0
- package/editor-chrome/IActionButton.d.ts +1 -2
- package/editor-chrome/IEditorItemPanelsRenderer.d.ts +1 -1
- package/enterprise-glossary/EnterpriseGlossaryApis.d.ts +1 -1
- package/identities/Identity.d.ts +11 -3
- package/identities/Identity.js +17 -0
- package/identities/IdentityCreationRequest.js +1 -1
- package/internal-do-not-import-from-here/shared/models/Bring.d.ts +1 -0
- package/internal-do-not-import-from-here/shared/models/DynamicState.d.ts +1 -0
- package/internal-do-not-import-from-here/shared/models/DynamicState.js +2 -0
- package/internal-do-not-import-from-here/shared/models/Equals.d.ts +3 -0
- package/internal-do-not-import-from-here/shared/models/Equals.js +45 -0
- package/internal-do-not-import-from-here/shared/models/Future.d.ts +4 -1
- package/internal-do-not-import-from-here/shared/models/Future.js +14 -6
- package/internal-do-not-import-from-here/shared/models/Guid.d.ts +9 -2
- package/internal-do-not-import-from-here/shared/models/Guid.js +26 -4
- package/internal-do-not-import-from-here/shared/models/StronglyTypedId.d.ts +3 -0
- package/internal-do-not-import-from-here/shared/models/StronglyTypedId.js +2 -0
- package/internal-do-not-import-from-here/shared/models/WorkerProxyFuncs.d.ts +7 -1
- package/internal-do-not-import-from-here/shared/models/WorkerProxyFuncs.js +5 -1
- package/internal-do-not-import-from-here/shared/models/hub/activities/Activity.d.ts +35 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/Activity.js +7 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/ActivityChannel.d.ts +7 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/ActivityChannel.js +5 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/ActivityRenderer.d.ts +10 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/ActivityRenderer.js +5 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/ActivitySender.d.ts +11 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/ActivitySender.js +6 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/FeedResult.d.ts +11 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/FeedResult.js +2 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/IdentityActivity.d.ts +18 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/IdentityActivity.js +31 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/index.d.ts +6 -0
- package/internal-do-not-import-from-here/shared/models/hub/activities/index.js +9 -0
- package/internal-do-not-import-from-here/shared/models/hub/index.d.ts +1 -0
- package/internal-do-not-import-from-here/shared/models/hub/index.js +4 -0
- package/internal-do-not-import-from-here/shared/models/index.d.ts +4 -0
- package/internal-do-not-import-from-here/shared/models/index.js +4 -0
- package/internal-do-not-import-from-here/shared/models/theming/BlueprintDefinition.d.ts +54 -18
- package/internal-do-not-import-from-here/shared/models/theming/BlueprintDefinition.js +16 -0
- package/internal-do-not-import-from-here/shared/models/theming/SharedBlueprintMethods.d.ts +2 -0
- package/internal-do-not-import-from-here/shared/models/theming/SharedBlueprintMethods.js +37 -0
- package/internal-do-not-import-from-here/shared/models/theming/SharedColorMethods.d.ts +1 -0
- package/internal-do-not-import-from-here/shared/models/theming/SharedColorMethods.js +45 -0
- package/internal-do-not-import-from-here/shared/models/theming/SpacingSetting.d.ts +23 -0
- package/internal-do-not-import-from-here/shared/models/theming/SpacingSetting.js +11 -0
- package/internal-do-not-import-from-here/shared/models/theming/ThemeDefinitionV2.d.ts +55 -34
- package/internal-do-not-import-from-here/shared/models/theming/ThemeDefinitionV2.js +27 -22
- package/internal-do-not-import-from-here/shared/models/theming/TypographyDefinition.d.ts +35 -15
- package/internal-do-not-import-from-here/shared/models/theming/TypographyDefinition.js +15 -9
- package/internal-do-not-import-from-here/shared/models/theming/UseThemeMethods.d.ts +13 -0
- package/internal-do-not-import-from-here/shared/models/theming/{ThemeMethods.js → UseThemeMethods.js} +56 -70
- package/internal-do-not-import-from-here/shared/models/theming/index.d.ts +5 -1
- package/internal-do-not-import-from-here/shared/models/theming/index.js +5 -1
- package/internal-do-not-import-from-here/velcron/core/models/Enums.d.ts +7 -16
- package/internal-do-not-import-from-here/velcron/core/models/Enums.js +14 -24
- package/internal-do-not-import-from-here/velcron/core/models/VelcronDefinitions.d.ts +131 -83
- package/internal-do-not-import-from-here/velcron/core/models/VelcronDefinitions.js +2 -2
- package/internal-do-not-import-from-here/velcron/core/models/VelcronEvents.d.ts +5 -2
- package/internal-do-not-import-from-here/velcron/core/models/VelcronPropertyEditorDefinitions.d.ts +120 -0
- package/internal-do-not-import-from-here/velcron/core/models/VelcronPropertyEditorDefinitions.js +16 -0
- package/internal-do-not-import-from-here/velcron/core/models/index.d.ts +1 -1
- package/internal-do-not-import-from-here/velcron/core/models/index.js +1 -1
- package/media-picker/MediaPickerImageRendition.d.ts +4 -4
- package/media-picker/MediaPickerSearchProvider.d.ts +5 -0
- package/media-picker/MediaPickerSearchProvider.js +2 -0
- package/media-picker/MediaPickerTransformations.d.ts +5 -4
- package/media-picker/Providers/CentralImageLocationProvider.js +1 -1
- package/media-picker/Providers/DallEProvider.js +1 -1
- package/media-picker/Providers/MyComputerProvider.js +1 -1
- package/media-picker/Providers/PexelProvider.js +2 -2
- package/media-picker/Providers/UnsplashProvider.d.ts +18 -0
- package/media-picker/Providers/UnsplashProvider.js +23 -0
- package/media-picker/Providers/index.d.ts +1 -0
- package/media-picker/Providers/index.js +1 -0
- package/media-picker/Shared.d.ts +7 -1
- package/media-picker/index.d.ts +2 -0
- package/media-picker/index.js +2 -0
- package/media-picker/localize.d.ts +26 -0
- package/media-picker/localize.js +7 -0
- package/mediaflow/Constants.js +2 -2
- package/oxide/OxideTypeDefinitions.d.ts +147 -0
- package/oxide/OxideTypeDefinitions.js +112 -0
- package/oxide/SharedSettings.d.ts +8 -0
- package/oxide/SharedSettings.js +2 -0
- package/oxide/TreeView.d.ts +10 -0
- package/oxide/TreeView.js +2 -0
- package/oxide/index.d.ts +3 -0
- package/oxide/index.js +6 -0
- package/package.json +1 -1
- package/properties/IPropertyValueRenderer.d.ts +3 -4
- package/properties/PropertyDefinition.d.ts +5 -1
- package/properties/PropertyDefinition.js +4 -1
- package/properties/definitions/BirthdayPropertyDefinition.d.ts +5 -6
- package/properties/definitions/BirthdayPropertyDefinition.js +7 -1
- package/properties/definitions/BooleanPropertyDefinition.d.ts +3 -2
- package/properties/definitions/BooleanPropertyDefinition.js +4 -1
- package/properties/definitions/DatePropertyDefinition.d.ts +5 -5
- package/properties/definitions/DatePropertyDefinition.js +7 -1
- package/properties/definitions/DateTimePropertyDefinition.d.ts +5 -5
- package/properties/definitions/DateTimePropertyDefinition.js +7 -1
- package/properties/definitions/EmailPropertyDefinition.d.ts +3 -3
- package/properties/definitions/EmailPropertyDefinition.js +4 -1
- package/properties/definitions/HtmlPropertyDefinition.d.ts +5 -6
- package/properties/definitions/HtmlPropertyDefinition.js +7 -1
- package/properties/definitions/IdentityPropertyDefinition.d.ts +3 -4
- package/properties/definitions/IdentityPropertyDefinition.js +4 -1
- package/properties/definitions/ImagePropertyDefinition.d.ts +5 -5
- package/properties/definitions/ImagePropertyDefinition.js +7 -1
- package/properties/definitions/IntegerPropertyDefinition.d.ts +3 -4
- package/properties/definitions/IntegerPropertyDefinition.js +4 -1
- package/properties/definitions/LanguagePropertyDefinition.d.ts +3 -5
- package/properties/definitions/LanguagePropertyDefinition.js +4 -1
- package/properties/definitions/LinkPropertyDefinition.d.ts +3 -4
- package/properties/definitions/LinkPropertyDefinition.js +4 -1
- package/properties/definitions/MediaPropertyDefinition.d.ts +3 -3
- package/properties/definitions/MediaPropertyDefinition.js +4 -1
- package/properties/definitions/MultilineTextPropertyDefinition.d.ts +3 -4
- package/properties/definitions/MultilineTextPropertyDefinition.js +4 -1
- package/properties/definitions/MultilingualTextPropertyDefinition.d.ts +5 -6
- package/properties/definitions/MultilingualTextPropertyDefinition.js +6 -3
- package/properties/definitions/PhoneNumberPropertyDefinition.d.ts +3 -4
- package/properties/definitions/PhoneNumberPropertyDefinition.js +4 -1
- package/properties/definitions/TagsPropertyDefinition.d.ts +3 -2
- package/properties/definitions/TagsPropertyDefinition.js +4 -1
- package/properties/definitions/TextPropertyDefinition.d.ts +3 -4
- package/properties/definitions/TextPropertyDefinition.js +4 -1
- package/properties/definitions/TimePropertyDefinition.d.ts +5 -6
- package/properties/definitions/TimePropertyDefinition.js +7 -1
- package/properties/values/DatePropertyValue.d.ts +1 -1
- package/properties/values/DatePropertyValue.js +1 -1
- package/richtext-editor-extensions/BoldExtension.d.ts +1 -1
- package/richtext-editor-extensions/TipTapEditor.d.ts +9 -10
- package/ux/LayoutEditorCanvas.d.ts +2 -1
- package/ux/ThemingApi.d.ts +19 -0
- package/ux/ThemingApi.js +2 -0
- package/ux/UxApi.d.ts +1 -1
- package/ux/VelcronDefinitionApi.d.ts +24 -0
- package/ux/VelcronDefinitionApi.js +2 -0
- package/ux/index.d.ts +2 -0
- package/ux/index.js +2 -0
- package/velcron/VelcronDefinitionRegistration.d.ts +9 -0
- package/velcron/VelcronDefinitionRegistration.js +2 -0
- package/velcron/index.d.ts +1 -0
- package/velcron/index.js +4 -0
- package/SpacingSetting.d.ts +0 -6
- package/VueInject.d.ts +0 -5
- package/internal-do-not-import-from-here/shared/models/theming/ThemeMethods.d.ts +0 -11
- package/internal-do-not-import-from-here/velcron/core/models/VelcronDescriptors.d.ts +0 -35
- /package/{SpacingSetting.js → FilterpickerModel.js} +0 -0
- /package/{VueInject.js → Func.js} +0 -0
- /package/{internal-do-not-import-from-here/velcron/core/models/VelcronDescriptors.js → MediaScalingSettings.js} +0 -0
package/identities/Identity.d.ts
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
import { GuidValue } from "@omnia/fx-models/internal-do-not-import-from-here/shared/models";
|
|
1
|
+
import { GuidValue, IEquals } from "@omnia/fx-models/internal-do-not-import-from-here/shared/models";
|
|
2
2
|
import { PropertyValueBinding } from "../properties";
|
|
3
3
|
import { IdentityTypes } from "./IdentityTypes";
|
|
4
|
-
|
|
4
|
+
interface IIdentityEqual extends IEquals<{
|
|
5
|
+
identity(value: Identity): boolean;
|
|
6
|
+
}> {
|
|
7
|
+
}
|
|
8
|
+
export interface IResolvedIdentity extends Partial<IIdentityEqual> {
|
|
5
9
|
id: GuidValue;
|
|
6
10
|
type: IdentityTypes;
|
|
7
11
|
providerId: GuidValue;
|
|
@@ -9,11 +13,14 @@ export interface IResolvedIdentity {
|
|
|
9
13
|
propertyValues: PropertyValueBinding<any>[];
|
|
10
14
|
toIdString?: () => string;
|
|
11
15
|
}
|
|
12
|
-
export declare abstract class Identity {
|
|
16
|
+
export declare abstract class Identity implements IIdentityEqual {
|
|
13
17
|
readonly id: GuidValue;
|
|
14
18
|
abstract readonly type: IdentityTypes;
|
|
15
19
|
constructor(id: GuidValue);
|
|
16
20
|
toIdString(): string;
|
|
21
|
+
get equals(): {
|
|
22
|
+
identity: (value: Identity) => boolean;
|
|
23
|
+
};
|
|
17
24
|
static parse(identity: Identity | IResolvedIdentity | string): Identity;
|
|
18
25
|
static isValid(identity: Identity): boolean;
|
|
19
26
|
static createFromString(idAndType: string): Identity;
|
|
@@ -28,3 +35,4 @@ export declare enum ArchiveSortColumn {
|
|
|
28
35
|
ProviderId = 5,
|
|
29
36
|
TypeId = 6
|
|
30
37
|
}
|
|
38
|
+
export {};
|
package/identities/Identity.js
CHANGED
|
@@ -10,6 +10,13 @@ class Identity {
|
|
|
10
10
|
toIdString() {
|
|
11
11
|
return Identity.getIdAsString(this.id, this.type);
|
|
12
12
|
}
|
|
13
|
+
get equals() {
|
|
14
|
+
return {
|
|
15
|
+
identity: (value) => {
|
|
16
|
+
return this.toIdString() === value.toIdString();
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
}
|
|
13
20
|
static parse(identity) {
|
|
14
21
|
if (typeof identity === "string") {
|
|
15
22
|
return this.createFromString(identity);
|
|
@@ -92,4 +99,14 @@ if (globalThis.omnia) {
|
|
|
92
99
|
configurable: false,
|
|
93
100
|
enumerable: false
|
|
94
101
|
});
|
|
102
|
+
Object.defineProperty(String.prototype["equals"], "identity", {
|
|
103
|
+
value: function () {
|
|
104
|
+
return function (value) {
|
|
105
|
+
return this.toIdString() === value.toIdString();
|
|
106
|
+
};
|
|
107
|
+
},
|
|
108
|
+
writable: false,
|
|
109
|
+
configurable: false,
|
|
110
|
+
enumerable: false
|
|
111
|
+
});
|
|
95
112
|
}
|
|
@@ -40,5 +40,5 @@ class BusinessProfileIdentityCreationRequestSettings extends BusinessProfile_1.B
|
|
|
40
40
|
this.settings = new IdentityCreationRequestSettings();
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
|
-
exports.BusinessProfileIdentityCreationRequestSettings = BusinessProfileIdentityCreationRequestSettings;
|
|
44
43
|
BusinessProfileIdentityCreationRequestSettings.UniqueName = "self-service";
|
|
44
|
+
exports.BusinessProfileIdentityCreationRequestSettings = BusinessProfileIdentityCreationRequestSettings;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type DynamicState = object;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
//have issue with guidvalue can't auto cast to string if have more extension method here.
|
|
4
|
+
// declare global {
|
|
5
|
+
// interface String {
|
|
6
|
+
// equals?: {
|
|
7
|
+
// component<TElement = typeof omfx>(cb: (elements: TElement) => any): boolean;
|
|
8
|
+
// }
|
|
9
|
+
// }
|
|
10
|
+
// }
|
|
11
|
+
const _equalsObject = {};
|
|
12
|
+
// only add extension methods when running in browser, not in node.js
|
|
13
|
+
if (globalThis.omnia) {
|
|
14
|
+
Object.defineProperty(String.prototype, "equals", {
|
|
15
|
+
value: function () {
|
|
16
|
+
return _equalsObject;
|
|
17
|
+
},
|
|
18
|
+
writable: false,
|
|
19
|
+
configurable: false,
|
|
20
|
+
enumerable: false
|
|
21
|
+
});
|
|
22
|
+
Object.defineProperty(Object.prototype, "equals", {
|
|
23
|
+
value: function () {
|
|
24
|
+
return _equalsObject;
|
|
25
|
+
},
|
|
26
|
+
writable: true,
|
|
27
|
+
configurable: false,
|
|
28
|
+
enumerable: false
|
|
29
|
+
});
|
|
30
|
+
// Object.defineProperty(String.prototype["equals"], "element", {
|
|
31
|
+
// value: function () {
|
|
32
|
+
// return function (cb: (elements) => any) {
|
|
33
|
+
// const elementName = cb(new Proxy({}, {
|
|
34
|
+
// get(target, key: string) {
|
|
35
|
+
// return key;
|
|
36
|
+
// }
|
|
37
|
+
// }) as any);
|
|
38
|
+
// return this.toString().replace(/-/g, "").toLowerCase().indexof(elementName.toLowerCase()) > -1;
|
|
39
|
+
// };
|
|
40
|
+
// },
|
|
41
|
+
// writable: false,
|
|
42
|
+
// configurable: false,
|
|
43
|
+
// enumerable: false
|
|
44
|
+
// });
|
|
45
|
+
}
|
|
@@ -14,7 +14,10 @@ export declare class Future<T> extends Promise<T> {
|
|
|
14
14
|
* @return {*} {Future<{ success?: T, error?: Error; }>}
|
|
15
15
|
* @memberof Future
|
|
16
16
|
*/
|
|
17
|
-
tryCatch(): Future<
|
|
17
|
+
tryCatch(): Future<{
|
|
18
|
+
success: T;
|
|
19
|
+
error: Error;
|
|
20
|
+
}>;
|
|
18
21
|
/**
|
|
19
22
|
* Aborts the request
|
|
20
23
|
*
|
|
@@ -5,16 +5,18 @@ class Future extends Promise {
|
|
|
5
5
|
constructor(executor) {
|
|
6
6
|
let resolveLocal;
|
|
7
7
|
let rejectLocal;
|
|
8
|
+
// Cant have function here since this is undefined in setTimeout
|
|
9
|
+
// eslint-disable-next-line func-style
|
|
8
10
|
const onAborted = (cb) => {
|
|
9
11
|
setTimeout(() => {
|
|
10
12
|
this.onAborted = cb;
|
|
11
13
|
});
|
|
12
14
|
};
|
|
13
|
-
|
|
15
|
+
function exec(resolve, reject) {
|
|
14
16
|
// assign to local to prevent error assignbefore call super;
|
|
15
17
|
resolveLocal = resolve;
|
|
16
18
|
rejectLocal = reject;
|
|
17
|
-
}
|
|
19
|
+
}
|
|
18
20
|
super(exec);
|
|
19
21
|
this.resolving = false;
|
|
20
22
|
this._resolved = false;
|
|
@@ -46,10 +48,10 @@ class Future extends Promise {
|
|
|
46
48
|
return new Future(async (resolve) => {
|
|
47
49
|
try {
|
|
48
50
|
const data = await this;
|
|
49
|
-
resolve(
|
|
51
|
+
resolve({ success: data, error: undefined });
|
|
50
52
|
}
|
|
51
|
-
catch (
|
|
52
|
-
resolve(
|
|
53
|
+
catch (error) {
|
|
54
|
+
resolve({ success: undefined, error });
|
|
53
55
|
}
|
|
54
56
|
});
|
|
55
57
|
}
|
|
@@ -90,13 +92,19 @@ class Future extends Promise {
|
|
|
90
92
|
}
|
|
91
93
|
get [Symbol.toStringTag]() {
|
|
92
94
|
// return Object value to make vue can build get/set reactive.
|
|
93
|
-
return "Object";
|
|
95
|
+
// return "Object";
|
|
96
|
+
//<<vue3>> back to normal because vue 3 use native proxy.
|
|
97
|
+
return "Future";
|
|
94
98
|
}
|
|
95
99
|
static new() {
|
|
96
100
|
return new Future(() => { });
|
|
97
101
|
}
|
|
98
102
|
}
|
|
99
103
|
exports.Future = Future;
|
|
104
|
+
// Future.prototype["promise_then"] = Promise.prototype.then;
|
|
105
|
+
// Future.prototype["then"] = function (resolve, reject) {
|
|
106
|
+
// return Future.prototype["promise_then"].apply(this, arguments);
|
|
107
|
+
// };
|
|
100
108
|
class ResponsePromise extends Promise {
|
|
101
109
|
constructor(executor) {
|
|
102
110
|
const onCancel = (cb) => {
|
|
@@ -1,4 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
import "./Equals";
|
|
2
|
+
import { IEquals } from "./Equals";
|
|
3
|
+
export interface GuidValue extends Partial<IEquals<{
|
|
4
|
+
guid(value: GuidValue): boolean;
|
|
5
|
+
}>> {
|
|
2
6
|
toString: () => string;
|
|
3
7
|
}
|
|
4
8
|
/**
|
|
@@ -6,10 +10,13 @@ export interface GuidValue {
|
|
|
6
10
|
*/
|
|
7
11
|
export declare class Guid implements GuidValue {
|
|
8
12
|
private static _empty;
|
|
13
|
+
private value;
|
|
14
|
+
equals: {
|
|
15
|
+
guid: (value: GuidValue) => boolean;
|
|
16
|
+
};
|
|
9
17
|
static newGuid(): GuidValue;
|
|
10
18
|
static get empty(): GuidValue;
|
|
11
19
|
static isValid(guid: string | GuidValue): boolean;
|
|
12
|
-
private value;
|
|
13
20
|
constructor(guid: string);
|
|
14
21
|
toString(): string;
|
|
15
22
|
toJSON: () => string;
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Guid = void 0;
|
|
2
4
|
//export interface GuidValue {
|
|
3
5
|
// :string;
|
|
4
6
|
//}
|
|
5
|
-
|
|
6
|
-
|
|
7
|
+
require("./Equals"); // ensure execute code in equals first
|
|
8
|
+
// export interface GuidValue {
|
|
9
|
+
// toString: () => string;
|
|
10
|
+
// }
|
|
7
11
|
/**
|
|
8
12
|
* Class to create a guid
|
|
9
13
|
*/
|
|
@@ -26,7 +30,12 @@ class Guid {
|
|
|
26
30
|
return validRegex.test(guid.toString());
|
|
27
31
|
}
|
|
28
32
|
constructor(guid) {
|
|
29
|
-
this.value =
|
|
33
|
+
this.value = "";
|
|
34
|
+
this.equals = {
|
|
35
|
+
guid: (value) => {
|
|
36
|
+
return this.toString() === value.toString();
|
|
37
|
+
}
|
|
38
|
+
};
|
|
30
39
|
//We serialize as string value
|
|
31
40
|
this.toJSON = () => {
|
|
32
41
|
return this.value.toLowerCase();
|
|
@@ -47,5 +56,18 @@ class Guid {
|
|
|
47
56
|
return this.value.toLowerCase();
|
|
48
57
|
}
|
|
49
58
|
}
|
|
59
|
+
Guid._empty = new Guid("00000000-0000-0000-0000-000000000000");
|
|
50
60
|
exports.Guid = Guid;
|
|
51
|
-
|
|
61
|
+
// only add extension methods when running in browser, not in node.js
|
|
62
|
+
if (globalThis.omnia) {
|
|
63
|
+
Object.defineProperty(String.prototype["equals"], "guid", {
|
|
64
|
+
value: function () {
|
|
65
|
+
return function (value) {
|
|
66
|
+
return this.toString() === value.toString();
|
|
67
|
+
};
|
|
68
|
+
},
|
|
69
|
+
writable: false,
|
|
70
|
+
configurable: false,
|
|
71
|
+
enumerable: false
|
|
72
|
+
});
|
|
73
|
+
}
|
|
@@ -1,8 +1,14 @@
|
|
|
1
|
+
import { BringResponse } from "./Bring";
|
|
1
2
|
import { Guid } from "./Guid";
|
|
2
3
|
import { WorkerProxyFunction } from "./Workers";
|
|
3
4
|
export declare const WorkerProxyFuncs: {
|
|
4
5
|
ui: {
|
|
5
6
|
loadManifests: WorkerProxyFunction<Guid[], Guid[]>;
|
|
6
7
|
};
|
|
7
|
-
worker: {
|
|
8
|
+
worker: {
|
|
9
|
+
httpRequest: WorkerProxyFunction<{
|
|
10
|
+
url: string;
|
|
11
|
+
reqInit: Omit<RequestInit, "window" | "signal">;
|
|
12
|
+
}, Promise<BringResponse<any>>>;
|
|
13
|
+
};
|
|
8
14
|
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { DynamicState, GuidValue, StronglyTypedId } from "../..";
|
|
2
|
+
import { ChannelId } from "./ActivityChannel";
|
|
3
|
+
import { ActivitySenderId } from "./ActivitySender";
|
|
4
|
+
export type ActivityId = StronglyTypedId<number, "ActivityId">;
|
|
5
|
+
export declare function ActivityId(id: number): ActivityId;
|
|
6
|
+
export type ActivityTypeId = StronglyTypedId<GuidValue, "ActivityTypeId">;
|
|
7
|
+
export declare function ActivityTypeId(id: GuidValue): ActivityTypeId;
|
|
8
|
+
export interface Activity<TRenderState = DynamicState> extends ActivityBase {
|
|
9
|
+
id: ActivityId;
|
|
10
|
+
state: TRenderState;
|
|
11
|
+
senderId: ActivitySenderId;
|
|
12
|
+
}
|
|
13
|
+
export interface ActivityResponse extends ActivityBase {
|
|
14
|
+
id: ActivityId;
|
|
15
|
+
senderId: ActivitySenderId;
|
|
16
|
+
stateJson: string;
|
|
17
|
+
rendererJson: string;
|
|
18
|
+
}
|
|
19
|
+
export interface ActivityBase {
|
|
20
|
+
channelId: ChannelId;
|
|
21
|
+
activityTypeId: ActivityTypeId;
|
|
22
|
+
targeting: Array<Array<HubIdentityProperty>>;
|
|
23
|
+
notificationTeaser: NotificationTeaser;
|
|
24
|
+
expires?: Date;
|
|
25
|
+
createdAt: Date;
|
|
26
|
+
}
|
|
27
|
+
export interface HubIdentityProperty {
|
|
28
|
+
name: string;
|
|
29
|
+
values: Array<string>;
|
|
30
|
+
}
|
|
31
|
+
export interface NotificationTeaser {
|
|
32
|
+
title: string;
|
|
33
|
+
description: string;
|
|
34
|
+
url: string;
|
|
35
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ActivityTypeId = exports.ActivityId = void 0;
|
|
4
|
+
function ActivityId(id) { return id; }
|
|
5
|
+
exports.ActivityId = ActivityId;
|
|
6
|
+
function ActivityTypeId(id) { return id; }
|
|
7
|
+
exports.ActivityTypeId = ActivityTypeId;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { GuidValue, StronglyTypedId } from "../..";
|
|
2
|
+
export type ActivityRendererId = StronglyTypedId<string, "ActivityRendererId">;
|
|
3
|
+
export declare function ActivityRendererId(id: GuidValue): ActivityRendererId;
|
|
4
|
+
export interface ActivityRendererReference {
|
|
5
|
+
id: ActivityRendererId;
|
|
6
|
+
version: string;
|
|
7
|
+
}
|
|
8
|
+
export interface ActivityRenderer extends ActivityRendererReference {
|
|
9
|
+
definition: string;
|
|
10
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare enum ActivitySenderId {
|
|
2
|
+
}
|
|
3
|
+
export interface ActivitySender extends ActivitySenderBase {
|
|
4
|
+
id: ActivitySenderId;
|
|
5
|
+
imageUrl: string;
|
|
6
|
+
}
|
|
7
|
+
export interface ActivitySenderBase {
|
|
8
|
+
name: Record<string, string>;
|
|
9
|
+
description: Record<string, string>;
|
|
10
|
+
externalId: string;
|
|
11
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Activity, ActivityId } from "./Activity";
|
|
2
|
+
import { ActivityRenderer, ActivityRendererId } from "./ActivityRenderer";
|
|
3
|
+
import { IdentityActivity } from "./IdentityActivity";
|
|
4
|
+
export interface FeedResult {
|
|
5
|
+
renderers: {
|
|
6
|
+
[key: ActivityRendererId]: ActivityRenderer;
|
|
7
|
+
};
|
|
8
|
+
identityActivities: Array<IdentityActivity>;
|
|
9
|
+
activities: Array<Activity>;
|
|
10
|
+
nextStartingFromId: ActivityId;
|
|
11
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { DynamicState } from "../..";
|
|
2
|
+
import { Activity, ActivityId } from "./Activity";
|
|
3
|
+
export declare enum IdentityActivityStatus {
|
|
4
|
+
unRead = 0,
|
|
5
|
+
read = 1,
|
|
6
|
+
completed = 2
|
|
7
|
+
}
|
|
8
|
+
export interface IdentityActivityBase {
|
|
9
|
+
activityId: ActivityId;
|
|
10
|
+
status: IdentityActivityStatus;
|
|
11
|
+
}
|
|
12
|
+
export interface IdentityActivity<TRenderState extends DynamicState | undefined = undefined, TState extends DynamicState | undefined = undefined> extends IdentityActivityBase {
|
|
13
|
+
activity: Activity<TRenderState>;
|
|
14
|
+
state?: TState;
|
|
15
|
+
}
|
|
16
|
+
export interface IdentityActivityWithJson extends IdentityActivityBase {
|
|
17
|
+
stateJson: string;
|
|
18
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.IdentityActivityStatus = void 0;
|
|
4
|
+
var IdentityActivityStatus;
|
|
5
|
+
(function (IdentityActivityStatus) {
|
|
6
|
+
IdentityActivityStatus[IdentityActivityStatus["unRead"] = 0] = "unRead";
|
|
7
|
+
IdentityActivityStatus[IdentityActivityStatus["read"] = 1] = "read";
|
|
8
|
+
IdentityActivityStatus[IdentityActivityStatus["completed"] = 2] = "completed";
|
|
9
|
+
})(IdentityActivityStatus = exports.IdentityActivityStatus || (exports.IdentityActivityStatus = {}));
|
|
10
|
+
// Usage
|
|
11
|
+
// const activity1: IdentityActivity<SomeRenderState> = {
|
|
12
|
+
// activity: {
|
|
13
|
+
// // Initialize your Activity here
|
|
14
|
+
// },
|
|
15
|
+
// state: {
|
|
16
|
+
// // Initialize your State here
|
|
17
|
+
// },
|
|
18
|
+
// };
|
|
19
|
+
// const activity2: IdentityActivity<SomeRenderState, SomeState> = {
|
|
20
|
+
// activity: {
|
|
21
|
+
// // Initialize your Activity here
|
|
22
|
+
// },
|
|
23
|
+
// state: {
|
|
24
|
+
// // Initialize your State here
|
|
25
|
+
// },
|
|
26
|
+
// };
|
|
27
|
+
// const activity3: IdentityActivityWithJson = {
|
|
28
|
+
// activityId: 22,
|
|
29
|
+
// status: IdentityActivityStatus.unRead,
|
|
30
|
+
// stateJson: "someJson",
|
|
31
|
+
// };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
tslib_1.__exportStar(require("./Activity"), exports);
|
|
5
|
+
tslib_1.__exportStar(require("./IdentityActivity"), exports);
|
|
6
|
+
tslib_1.__exportStar(require("./ActivityRenderer"), exports);
|
|
7
|
+
tslib_1.__exportStar(require("./ActivitySender"), exports);
|
|
8
|
+
tslib_1.__exportStar(require("./ActivityChannel"), exports);
|
|
9
|
+
tslib_1.__exportStar(require("./FeedResult"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./activities";
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export * from "./Equals";
|
|
1
2
|
export * from "./Guid";
|
|
2
3
|
export * from "./Broadcasting";
|
|
3
4
|
export * from "./Topic";
|
|
@@ -11,4 +12,7 @@ export * from "./Tenant";
|
|
|
11
12
|
export * from "./Realtime";
|
|
12
13
|
export * from "./OmniaSharedBootstrapData";
|
|
13
14
|
export * from "./StringExtensions";
|
|
15
|
+
export * from "./DynamicState";
|
|
16
|
+
export * from "./StronglyTypedId";
|
|
14
17
|
export * from "./theming";
|
|
18
|
+
export * from "./hub";
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
//! <omnia-transform-resource path="9a75501c-254b-46d1-9010-7b13681e06f4" />
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
|
+
tslib_1.__exportStar(require("./Equals"), exports);
|
|
5
6
|
tslib_1.__exportStar(require("./Guid"), exports);
|
|
6
7
|
tslib_1.__exportStar(require("./Broadcasting"), exports);
|
|
7
8
|
tslib_1.__exportStar(require("./Topic"), exports);
|
|
@@ -15,4 +16,7 @@ tslib_1.__exportStar(require("./Tenant"), exports);
|
|
|
15
16
|
tslib_1.__exportStar(require("./Realtime"), exports);
|
|
16
17
|
tslib_1.__exportStar(require("./OmniaSharedBootstrapData"), exports);
|
|
17
18
|
tslib_1.__exportStar(require("./StringExtensions"), exports);
|
|
19
|
+
tslib_1.__exportStar(require("./DynamicState"), exports);
|
|
20
|
+
tslib_1.__exportStar(require("./StronglyTypedId"), exports);
|
|
18
21
|
tslib_1.__exportStar(require("./theming"), exports);
|
|
22
|
+
tslib_1.__exportStar(require("./hub"), exports);
|
|
@@ -1,27 +1,63 @@
|
|
|
1
1
|
import { Guid } from "../Guid";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
left: number;
|
|
2
|
+
import { SpacingDefinition, SpacingSettings } from "./SpacingSetting";
|
|
3
|
+
import { ColorSchemaType, ColorSchemaTypes } from "./ThemeDefinitionV2";
|
|
4
|
+
import { TypographyDefinition } from "./TypographyDefinition";
|
|
5
|
+
export interface BoxDimensions extends SpacingSettings {
|
|
7
6
|
}
|
|
8
7
|
export interface BoxBorder extends BoxDimensions {
|
|
9
8
|
color: string;
|
|
10
9
|
}
|
|
11
|
-
export interface
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
10
|
+
export interface BluePrintDefinitions {
|
|
11
|
+
default: BlueprintDefinition;
|
|
12
|
+
variant1: BlueprintDefinition;
|
|
13
|
+
variant2: BlueprintDefinition;
|
|
14
|
+
variant3: BlueprintDefinition;
|
|
15
|
+
}
|
|
16
|
+
export type WebBlueprintDefintionType = "button" | "block" | "typography" | "searchbox" | "layout-spacing" | "inner-spacing";
|
|
17
|
+
export declare enum WebBlueprintDefintionTypes {
|
|
18
|
+
button = "button",
|
|
19
|
+
block = "block",
|
|
20
|
+
typography = "typography",
|
|
21
|
+
searchbox = "searchbox",
|
|
22
|
+
layoutspacing = "layout-spacing",
|
|
23
|
+
innerspacing = "inner-spacing"
|
|
24
|
+
}
|
|
25
|
+
export type VelcronBlueprintDefintionType = "button" | "typography" | "inner-spacing";
|
|
26
|
+
export declare enum VelcronBlueprintDefintionTypes {
|
|
27
|
+
button = "button",
|
|
28
|
+
typography = "typography",
|
|
29
|
+
innerspacing = "inner-spacing"
|
|
30
|
+
}
|
|
31
|
+
export interface BlueprintItemDefinition {
|
|
32
|
+
type: VelcronBlueprintDefintionType | WebBlueprintDefintionType;
|
|
33
|
+
}
|
|
34
|
+
export interface BlockBlueprint extends BlueprintItemDefinition {
|
|
35
|
+
type: "block";
|
|
36
|
+
header?: {
|
|
37
|
+
definitionId: Guid;
|
|
19
38
|
};
|
|
20
|
-
|
|
21
|
-
|
|
39
|
+
colors?: {
|
|
40
|
+
colorSchemaType: ColorSchemaTypes | ColorSchemaType;
|
|
22
41
|
};
|
|
23
|
-
|
|
24
|
-
borderRadius
|
|
25
|
-
|
|
42
|
+
styles?: {
|
|
43
|
+
borderRadius: BoxDimensions;
|
|
44
|
+
border: BoxBorder;
|
|
26
45
|
};
|
|
27
46
|
}
|
|
47
|
+
export interface SpacingBlueprint {
|
|
48
|
+
type: "layout-spacing" | "inner-spacing";
|
|
49
|
+
definition: SpacingDefinition;
|
|
50
|
+
}
|
|
51
|
+
export interface TypographyBlueprint extends BlueprintItemDefinition {
|
|
52
|
+
type: "typography";
|
|
53
|
+
definition: TypographyDefinition;
|
|
54
|
+
}
|
|
55
|
+
export interface SearchBoxBlueprint extends BlueprintItemDefinition {
|
|
56
|
+
type: "searchbox";
|
|
57
|
+
borderRadius?: BoxDimensions;
|
|
58
|
+
variant?: "outlined" | "solo" | "regular" | "plain" | "underlined";
|
|
59
|
+
}
|
|
60
|
+
export interface BlueprintDefinition {
|
|
61
|
+
id: Guid;
|
|
62
|
+
definitions: Array<BlueprintItemDefinition>;
|
|
63
|
+
}
|
|
@@ -1,2 +1,18 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.VelcronBlueprintDefintionTypes = exports.WebBlueprintDefintionTypes = void 0;
|
|
4
|
+
var WebBlueprintDefintionTypes;
|
|
5
|
+
(function (WebBlueprintDefintionTypes) {
|
|
6
|
+
WebBlueprintDefintionTypes["button"] = "button";
|
|
7
|
+
WebBlueprintDefintionTypes["block"] = "block";
|
|
8
|
+
WebBlueprintDefintionTypes["typography"] = "typography";
|
|
9
|
+
WebBlueprintDefintionTypes["searchbox"] = "searchbox";
|
|
10
|
+
WebBlueprintDefintionTypes["layoutspacing"] = "layout-spacing";
|
|
11
|
+
WebBlueprintDefintionTypes["innerspacing"] = "inner-spacing";
|
|
12
|
+
})(WebBlueprintDefintionTypes = exports.WebBlueprintDefintionTypes || (exports.WebBlueprintDefintionTypes = {}));
|
|
13
|
+
var VelcronBlueprintDefintionTypes;
|
|
14
|
+
(function (VelcronBlueprintDefintionTypes) {
|
|
15
|
+
VelcronBlueprintDefintionTypes["button"] = "button";
|
|
16
|
+
VelcronBlueprintDefintionTypes["typography"] = "typography";
|
|
17
|
+
VelcronBlueprintDefintionTypes["innerspacing"] = "inner-spacing";
|
|
18
|
+
})(VelcronBlueprintDefintionTypes = exports.VelcronBlueprintDefintionTypes || (exports.VelcronBlueprintDefintionTypes = {}));
|