@vived/host 3.4.0 → 3.6.0

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 (65) hide show
  1. package/lib/Components/Dispatcher/UCs/DispatchThemeUC.d.ts +52 -1
  2. package/lib/Components/Dispatcher/UCs/DispatchThemeUC.js +7 -2
  3. package/lib/Components/Events/Types/EventTypes.d.ts +13 -0
  4. package/lib/Components/Events/Types/EventTypes.js +17 -0
  5. package/lib/Components/Events/Types/PayloadTypes.d.ts +59 -0
  6. package/lib/Components/Events/Types/PayloadTypes.js +2 -0
  7. package/lib/Components/Events/Types/index.d.ts +2 -0
  8. package/lib/Components/Events/Types/index.js +14 -0
  9. package/lib/Components/Events/index.d.ts +1 -0
  10. package/lib/Components/Events/index.js +13 -0
  11. package/lib/Components/ThemeColors/Adapter/index.d.ts +1 -0
  12. package/lib/Components/ThemeColors/Adapter/index.js +13 -0
  13. package/lib/Components/ThemeColors/Adapter/themeColorAdapter.d.ts +3 -0
  14. package/lib/Components/ThemeColors/Adapter/themeColorAdapter.js +23 -0
  15. package/lib/Components/ThemeColors/Controllers/getOnPrimaryColor.d.ts +3 -0
  16. package/lib/Components/ThemeColors/Controllers/getOnPrimaryColor.js +16 -0
  17. package/lib/Components/ThemeColors/Controllers/getOnSurfaceColor.d.ts +3 -0
  18. package/lib/Components/ThemeColors/Controllers/getOnSurfaceColor.js +16 -0
  19. package/lib/Components/ThemeColors/Controllers/getPrimaryColor.d.ts +3 -0
  20. package/lib/Components/ThemeColors/Controllers/getPrimaryColor.js +16 -0
  21. package/lib/Components/ThemeColors/Controllers/getSurfaceColor.d.ts +3 -0
  22. package/lib/Components/ThemeColors/Controllers/getSurfaceColor.js +16 -0
  23. package/lib/Components/ThemeColors/Controllers/getSurfaceContainerColor.d.ts +3 -0
  24. package/lib/Components/ThemeColors/Controllers/getSurfaceContainerColor.js +16 -0
  25. package/lib/Components/ThemeColors/Controllers/index.d.ts +5 -0
  26. package/lib/Components/ThemeColors/Controllers/index.js +17 -0
  27. package/lib/Components/ThemeColors/Data/index.d.ts +2 -0
  28. package/lib/Components/ThemeColors/Data/index.js +10 -0
  29. package/lib/Components/ThemeColors/Data/vivedDarkTheme.json +51 -0
  30. package/lib/Components/ThemeColors/Data/vivedLightTheme.json +51 -0
  31. package/lib/Components/ThemeColors/Entities/HostThemeEntity.d.ts +127 -0
  32. package/lib/Components/ThemeColors/Entities/HostThemeEntity.js +166 -0
  33. package/lib/Components/ThemeColors/Entities/index.d.ts +1 -0
  34. package/lib/Components/ThemeColors/Entities/index.js +13 -0
  35. package/lib/Components/ThemeColors/Mocks/MockThemeColorPM.d.ts +8 -0
  36. package/lib/Components/ThemeColors/Mocks/MockThemeColorPM.js +15 -0
  37. package/lib/Components/ThemeColors/Mocks/index.d.ts +1 -0
  38. package/lib/Components/ThemeColors/Mocks/index.js +13 -0
  39. package/lib/Components/ThemeColors/PM/ThemeColorsPM.d.ts +12 -0
  40. package/lib/Components/ThemeColors/PM/ThemeColorsPM.js +46 -0
  41. package/lib/Components/ThemeColors/PM/index.d.ts +1 -0
  42. package/lib/Components/ThemeColors/PM/index.js +13 -0
  43. package/lib/Components/ThemeColors/UCs/SetThemeUC.d.ts +10 -0
  44. package/lib/Components/ThemeColors/UCs/SetThemeUC.js +43 -0
  45. package/lib/Components/ThemeColors/UCs/index.d.ts +1 -0
  46. package/lib/Components/ThemeColors/UCs/index.js +13 -0
  47. package/lib/Components/ThemeColors/index.d.ts +7 -0
  48. package/lib/Components/ThemeColors/index.js +19 -0
  49. package/lib/Components/index.d.ts +2 -0
  50. package/lib/Components/index.js +2 -0
  51. package/lib/Entities/MemoizedColor.d.ts +9 -0
  52. package/lib/Entities/MemoizedColor.js +23 -0
  53. package/lib/Entities/index.d.ts +1 -0
  54. package/lib/Entities/index.js +1 -0
  55. package/lib/Utilities/addAlphaToHex.d.ts +1 -0
  56. package/lib/Utilities/addAlphaToHex.js +16 -0
  57. package/lib/Utilities/alphaToHex.d.ts +2 -0
  58. package/lib/Utilities/alphaToHex.js +21 -0
  59. package/lib/Utilities/index.d.ts +2 -0
  60. package/lib/Utilities/index.js +2 -0
  61. package/lib/ValueObjects/Color.d.ts +82 -0
  62. package/lib/ValueObjects/Color.js +858 -0
  63. package/lib/ValueObjects/index.d.ts +2 -1
  64. package/lib/ValueObjects/index.js +1 -0
  65. package/package.json +1 -1
@@ -2,8 +2,59 @@ import { HostAppObject, HostAppObjectRepo, HostAppObjectUC } from "../../../Host
2
2
  export declare abstract class DispatchThemeUC extends HostAppObjectUC {
3
3
  static readonly type = "DispatchThemeUC";
4
4
  readonly requestType = "SET_THEME_COLORS";
5
- abstract doDispatch(colors: object): void;
5
+ abstract doDispatch(): void;
6
6
  static get(appObject: HostAppObject): DispatchThemeUC | undefined;
7
7
  static getByID(id: string, appObjects: HostAppObjectRepo): DispatchThemeUC | undefined;
8
8
  }
9
9
  export declare function makeDispatchThemeUC(appObject: HostAppObject): DispatchThemeUC;
10
+ export interface ColorSchemeV1 {
11
+ primary: string;
12
+ onPrimary: string;
13
+ primaryContainer: string;
14
+ onPrimaryContainer: string;
15
+ primaryFixed: string;
16
+ onPrimaryFixed: string;
17
+ primaryFixedDim: string;
18
+ onPrimaryFixedVariant: string;
19
+ secondary: string;
20
+ onSecondary: string;
21
+ secondaryContainer: string;
22
+ onSecondaryContainer: string;
23
+ secondaryFixed: string;
24
+ onSecondaryFixed: string;
25
+ secondaryFixedDim: string;
26
+ onSecondaryFixedVariant: string;
27
+ tertiary: string;
28
+ onTertiary: string;
29
+ tertiaryContainer: string;
30
+ onTertiaryContainer: string;
31
+ tertiaryFixed: string;
32
+ onTertiaryFixed: string;
33
+ tertiaryFixedDim: string;
34
+ onTertiaryFixedVariant: string;
35
+ error: string;
36
+ onError: string;
37
+ errorContainer: string;
38
+ onErrorContainer: string;
39
+ outline: string;
40
+ background: string;
41
+ onBackground: string;
42
+ surface: string;
43
+ onSurface: string;
44
+ surfaceVariant: string;
45
+ onSurfaceVariant: string;
46
+ inverseSurface: string;
47
+ inverseOnSurface: string;
48
+ inversePrimary: string;
49
+ shadow: string;
50
+ surfaceTint: string;
51
+ outlineVariant: string;
52
+ scrim: string;
53
+ surfaceContainerHighest: string;
54
+ surfaceContainerHigh: string;
55
+ surfaceContainer: string;
56
+ surfaceContainerLow: string;
57
+ surfaceContainerLowest: string;
58
+ surfaceBright: string;
59
+ surfaceDim: string;
60
+ }
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.makeDispatchThemeUC = exports.DispatchThemeUC = void 0;
4
4
  const HostAppObject_1 = require("../../../HostAppObject");
5
+ const ThemeColors_1 = require("../../ThemeColors");
5
6
  const Entities_1 = require("../Entities");
6
7
  class DispatchThemeUC extends HostAppObject_1.HostAppObjectUC {
7
8
  constructor() {
@@ -40,9 +41,13 @@ class DispatchThemeUCImp extends DispatchThemeUC {
40
41
  this.dispose();
41
42
  }
42
43
  }
43
- doDispatch(colors) {
44
- if (!this.dispatcher)
44
+ get theme() {
45
+ return this.getCachedSingleton(ThemeColors_1.HostThemeEntity.type);
46
+ }
47
+ doDispatch() {
48
+ if (!this.dispatcher || !this.theme)
45
49
  return;
50
+ const colors = Object.assign({}, this.theme.activeScheme);
46
51
  const payload = {
47
52
  colors
48
53
  };
@@ -0,0 +1,13 @@
1
+ export declare enum EventType {
2
+ MOUNT_PLAYER = "MOUNT_PLAYER",
3
+ UNMOUNT_PLAYER = "UNMOUNT_PLAYER",
4
+ APP_REQUESTED = "APP_REQUESTED",
5
+ APP_READY = "APP_READY",
6
+ ASSET_REQUESTED = "ASSET_REQUESTED",
7
+ ASSET_RECEIVED = "ASSET_RECEIVED",
8
+ SLIDE_START = "SLIDE_START",
9
+ SLIDE_STOP = "SLIDE_STOP",
10
+ START_ACTIVITY = "START_ACTIVITY",
11
+ ACTIVITY_COMPLETED = "ACTIVITY_COMPLETED",
12
+ ACTIVITY_PUBLISHED = "ACTIVITY_PUBLISHED"
13
+ }
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.EventType = void 0;
4
+ var EventType;
5
+ (function (EventType) {
6
+ EventType["MOUNT_PLAYER"] = "MOUNT_PLAYER";
7
+ EventType["UNMOUNT_PLAYER"] = "UNMOUNT_PLAYER";
8
+ EventType["APP_REQUESTED"] = "APP_REQUESTED";
9
+ EventType["APP_READY"] = "APP_READY";
10
+ EventType["ASSET_REQUESTED"] = "ASSET_REQUESTED";
11
+ EventType["ASSET_RECEIVED"] = "ASSET_RECEIVED";
12
+ EventType["SLIDE_START"] = "SLIDE_START";
13
+ EventType["SLIDE_STOP"] = "SLIDE_STOP";
14
+ EventType["START_ACTIVITY"] = "START_ACTIVITY";
15
+ EventType["ACTIVITY_COMPLETED"] = "ACTIVITY_COMPLETED";
16
+ EventType["ACTIVITY_PUBLISHED"] = "ACTIVITY_PUBLISHED";
17
+ })(EventType = exports.EventType || (exports.EventType = {}));
@@ -0,0 +1,59 @@
1
+ export interface StartActivityEventPayload {
2
+ channelID: string;
3
+ activityID: string;
4
+ slides: {
5
+ id: string;
6
+ name: string;
7
+ appID: string;
8
+ }[];
9
+ name: string;
10
+ }
11
+ export interface CompleteActivityEventPayload {
12
+ channelID: string;
13
+ activityID: string;
14
+ completedAllSlides: boolean;
15
+ }
16
+ export interface PublishActivityEventPayload {
17
+ channelID: string;
18
+ activityID: string;
19
+ }
20
+ export interface StopSlideEventPayload {
21
+ channelID: string;
22
+ activityID: string;
23
+ appID: string;
24
+ slideID: string;
25
+ }
26
+ export interface StartSlideEventPayload {
27
+ channelID: string;
28
+ activityID: string;
29
+ appID: string;
30
+ slideID: string;
31
+ }
32
+ export interface MountPlayerEventPayload {
33
+ channelID: string;
34
+ activityID: string;
35
+ }
36
+ export interface UnmountPlayerEventPayload {
37
+ channelID: string;
38
+ activityID: string;
39
+ }
40
+ export interface AppRequestedEventPayload {
41
+ channelID: string;
42
+ activityID: string;
43
+ appID: string;
44
+ }
45
+ export interface AppReadyEventPayload {
46
+ channelID: string;
47
+ activityID: string;
48
+ appID: string;
49
+ }
50
+ export interface AssetRequestedEventPayload {
51
+ channelID: string;
52
+ activityID: string;
53
+ assetID: string;
54
+ }
55
+ export interface AssetReceivedEventPayload {
56
+ channelID: string;
57
+ activityID: string;
58
+ assetID: string;
59
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,2 @@
1
+ export * from "./EventTypes";
2
+ export * from "./PayloadTypes";
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
+ }) : (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ o[k2] = m[k];
8
+ }));
9
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
10
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
11
+ };
12
+ Object.defineProperty(exports, "__esModule", { value: true });
13
+ __exportStar(require("./EventTypes"), exports);
14
+ __exportStar(require("./PayloadTypes"), exports);
@@ -0,0 +1 @@
1
+ export * from "./Types";
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
+ }) : (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ o[k2] = m[k];
8
+ }));
9
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
10
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
11
+ };
12
+ Object.defineProperty(exports, "__esModule", { value: true });
13
+ __exportStar(require("./Types"), exports);
@@ -0,0 +1 @@
1
+ export * from "./themeColorAdapter";
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
+ }) : (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ o[k2] = m[k];
8
+ }));
9
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
10
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
11
+ };
12
+ Object.defineProperty(exports, "__esModule", { value: true });
13
+ __exportStar(require("./themeColorAdapter"), exports);
@@ -0,0 +1,3 @@
1
+ import { SingletonPmAdapter } from "../../../Types";
2
+ import { ThemeColorsVM } from "../PM";
3
+ export declare const themeColorAdapter: SingletonPmAdapter<ThemeColorsVM>;
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.themeColorAdapter = void 0;
4
+ const PM_1 = require("../PM");
5
+ exports.themeColorAdapter = {
6
+ defaultVM: PM_1.defaultThemeColorsVM,
7
+ subscribe: (appObjects, setVM) => {
8
+ const pm = PM_1.ThemeColorsPM.get(appObjects);
9
+ if (!pm) {
10
+ appObjects.submitError("themeColorAdapter", "Unable to find ThemeColorsPM");
11
+ return;
12
+ }
13
+ pm.addView(setVM);
14
+ },
15
+ unsubscribe: (appObjects, setVM) => {
16
+ const pm = PM_1.ThemeColorsPM.get(appObjects);
17
+ if (!pm) {
18
+ appObjects.submitError("themeColorAdapter", "Unable to find ThemeColorsPM");
19
+ return;
20
+ }
21
+ pm.removeView(setVM);
22
+ }
23
+ };
@@ -0,0 +1,3 @@
1
+ import { HostAppObjectRepo } from "../../../HostAppObject";
2
+ import { Color } from "../../../ValueObjects";
3
+ export declare function getOnPrimaryColor(appObjects: HostAppObjectRepo): Color;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getOnPrimaryColor = void 0;
4
+ const ValueObjects_1 = require("../../../ValueObjects");
5
+ const Entities_1 = require("../Entities");
6
+ function getOnPrimaryColor(appObjects) {
7
+ const theme = Entities_1.HostThemeEntity.get(appObjects);
8
+ if (theme) {
9
+ return theme.getColorForType(Entities_1.ThemeColorType.onPrimary);
10
+ }
11
+ else {
12
+ appObjects.submitError("getOnPrimaryColor", "Unable to find ThemeColors");
13
+ return ValueObjects_1.Color.RGB(0, 0, 0);
14
+ }
15
+ }
16
+ exports.getOnPrimaryColor = getOnPrimaryColor;
@@ -0,0 +1,3 @@
1
+ import { HostAppObjectRepo } from "../../../HostAppObject";
2
+ import { Color } from "../../../ValueObjects";
3
+ export declare function getOnSurfaceColor(appObjects: HostAppObjectRepo): Color;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getOnSurfaceColor = void 0;
4
+ const ValueObjects_1 = require("../../../ValueObjects");
5
+ const Entities_1 = require("../Entities");
6
+ function getOnSurfaceColor(appObjects) {
7
+ const theme = Entities_1.HostThemeEntity.get(appObjects);
8
+ if (theme) {
9
+ return theme.getColorForType(Entities_1.ThemeColorType.onSurface);
10
+ }
11
+ else {
12
+ appObjects.submitError("getOnSurfaceColor", "Unable to find ThemeColors");
13
+ return ValueObjects_1.Color.RGB(0, 0, 0);
14
+ }
15
+ }
16
+ exports.getOnSurfaceColor = getOnSurfaceColor;
@@ -0,0 +1,3 @@
1
+ import { HostAppObjectRepo } from "../../../HostAppObject";
2
+ import { Color } from "../../../ValueObjects";
3
+ export declare function getPrimaryColor(appObjects: HostAppObjectRepo): Color;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getPrimaryColor = void 0;
4
+ const ValueObjects_1 = require("../../../ValueObjects");
5
+ const Entities_1 = require("../Entities");
6
+ function getPrimaryColor(appObjects) {
7
+ const theme = Entities_1.HostThemeEntity.get(appObjects);
8
+ if (theme) {
9
+ return theme.getColorForType(Entities_1.ThemeColorType.primary);
10
+ }
11
+ else {
12
+ appObjects.submitError("getPrimaryColor", "Unable to find ThemeColors");
13
+ return ValueObjects_1.Color.RGB(0, 0, 0);
14
+ }
15
+ }
16
+ exports.getPrimaryColor = getPrimaryColor;
@@ -0,0 +1,3 @@
1
+ import { HostAppObjectRepo } from "../../../HostAppObject";
2
+ import { Color } from "../../../ValueObjects";
3
+ export declare function getSurfaceColor(appObjects: HostAppObjectRepo): Color;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getSurfaceColor = void 0;
4
+ const ValueObjects_1 = require("../../../ValueObjects");
5
+ const Entities_1 = require("../Entities");
6
+ function getSurfaceColor(appObjects) {
7
+ const theme = Entities_1.HostThemeEntity.get(appObjects);
8
+ if (theme) {
9
+ return theme.getColorForType(Entities_1.ThemeColorType.surface);
10
+ }
11
+ else {
12
+ appObjects.submitError("getSurfaceColor", "Unable to find ThemeColors");
13
+ return ValueObjects_1.Color.RGB(0, 0, 0);
14
+ }
15
+ }
16
+ exports.getSurfaceColor = getSurfaceColor;
@@ -0,0 +1,3 @@
1
+ import { HostAppObjectRepo } from "../../../HostAppObject";
2
+ import { Color } from "../../../ValueObjects";
3
+ export declare function getSurfaceContainerColor(appObjects: HostAppObjectRepo): Color;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getSurfaceContainerColor = void 0;
4
+ const ValueObjects_1 = require("../../../ValueObjects");
5
+ const Entities_1 = require("../Entities");
6
+ function getSurfaceContainerColor(appObjects) {
7
+ const theme = Entities_1.HostThemeEntity.get(appObjects);
8
+ if (theme) {
9
+ return theme.getColorForType(Entities_1.ThemeColorType.surfaceContainer);
10
+ }
11
+ else {
12
+ appObjects.submitError("getSurfaceColor", "Unable to find ThemeColors");
13
+ return ValueObjects_1.Color.RGB(0, 0, 0);
14
+ }
15
+ }
16
+ exports.getSurfaceContainerColor = getSurfaceContainerColor;
@@ -0,0 +1,5 @@
1
+ export * from "./getOnPrimaryColor";
2
+ export * from "./getOnSurfaceColor";
3
+ export * from "./getPrimaryColor";
4
+ export * from "./getSurfaceColor";
5
+ export * from "./getSurfaceContainerColor";
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
+ }) : (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ o[k2] = m[k];
8
+ }));
9
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
10
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
11
+ };
12
+ Object.defineProperty(exports, "__esModule", { value: true });
13
+ __exportStar(require("./getOnPrimaryColor"), exports);
14
+ __exportStar(require("./getOnSurfaceColor"), exports);
15
+ __exportStar(require("./getPrimaryColor"), exports);
16
+ __exportStar(require("./getSurfaceColor"), exports);
17
+ __exportStar(require("./getSurfaceContainerColor"), exports);
@@ -0,0 +1,2 @@
1
+ export { default as vivedDarkThemeData } from "./vivedDarkTheme.json";
2
+ export { default as vivedLightThemeData } from "./vivedLightTheme.json";
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.vivedLightThemeData = exports.vivedDarkThemeData = void 0;
7
+ var vivedDarkTheme_json_1 = require("./vivedDarkTheme.json");
8
+ Object.defineProperty(exports, "vivedDarkThemeData", { enumerable: true, get: function () { return __importDefault(vivedDarkTheme_json_1).default; } });
9
+ var vivedLightTheme_json_1 = require("./vivedLightTheme.json");
10
+ Object.defineProperty(exports, "vivedLightThemeData", { enumerable: true, get: function () { return __importDefault(vivedLightTheme_json_1).default; } });
@@ -0,0 +1,51 @@
1
+ {
2
+ "primary": "#7BD0FF",
3
+ "onPrimary": "#003549",
4
+ "primaryContainer": "#004C69",
5
+ "onPrimaryContainer": "#C4E7FF",
6
+ "primaryFixed": "#C4E7FF",
7
+ "onPrimaryFixed": "#001E2C",
8
+ "primaryFixedDim": "#7BD0FF",
9
+ "onPrimaryFixedVariant": "#004C69",
10
+ "secondary": "#B5C9D7",
11
+ "onSecondary": "#20333E",
12
+ "secondaryContainer": "#374955",
13
+ "onSecondaryContainer": "#D1E5F4",
14
+ "secondaryFixed": "#D1E5F4",
15
+ "onSecondaryFixed": "#0A1E28",
16
+ "secondaryFixedDim": "#B5C9D7",
17
+ "onSecondaryFixedVariant": "#374955",
18
+ "tertiary": "#CAC1E9",
19
+ "onTertiary": "#322C4C",
20
+ "tertiaryContainer": "#484264",
21
+ "onTertiaryContainer": "#E6DEFF",
22
+ "tertiaryFixed": "#E6DEFF",
23
+ "onTertiaryFixed": "#1D1736",
24
+ "tertiaryFixedDim": "#CAC1E9",
25
+ "onTertiaryFixedVariant": "#484264",
26
+ "error": "#FFB4AB",
27
+ "onError": "#690005",
28
+ "errorContainer": "#93000A",
29
+ "onErrorContainer": "#FFDAD6",
30
+ "outline": "#8B9297",
31
+ "background": "#191C1E",
32
+ "onBackground": "#E1E2E5",
33
+ "surface": "#111416",
34
+ "onSurface": "#C5C6C9",
35
+ "surfaceVariant": "#41484D",
36
+ "onSurfaceVariant": "#C0C7CD",
37
+ "inverseSurface": "#E1E2E5",
38
+ "inverseOnSurface": "#191C1E",
39
+ "inversePrimary": "#00668A",
40
+ "shadow": "#000000",
41
+ "surfaceTint": "#7BD0FF",
42
+ "outlineVariant": "#41484D",
43
+ "scrim": "#000000",
44
+ "surfaceContainerHighest": "#333537",
45
+ "surfaceContainerHigh": "#282A2C",
46
+ "surfaceContainer": "#1D2022",
47
+ "surfaceContainerLow": "#191C1E",
48
+ "surfaceContainerLowest": "#0C0F10",
49
+ "surfaceBright": "#37393C",
50
+ "surfaceDim": "#111416"
51
+ }
@@ -0,0 +1,51 @@
1
+ {
2
+ "primary": "#00668A",
3
+ "onPrimary": "#FFFFFF",
4
+ "primaryContainer": "#C4E7FF",
5
+ "onPrimaryContainer": "#001E2C",
6
+ "primaryFixed": "#C4E7FF",
7
+ "onPrimaryFixed": "#001E2C",
8
+ "primaryFixedDim": "#7BD0FF",
9
+ "onPrimaryFixedVariant": "#004C69",
10
+ "secondary": "#4E616D",
11
+ "onSecondary": "#FFFFFF",
12
+ "secondaryContainer": "#D1E5F4",
13
+ "onSecondaryContainer": "#0A1E28",
14
+ "secondaryFixed": "#D1E5F4",
15
+ "onSecondaryFixed": "#0A1E28",
16
+ "secondaryFixedDim": "#B5C9D7",
17
+ "onSecondaryFixedVariant": "#374955",
18
+ "tertiary": "#605A7D",
19
+ "onTertiary": "#FFFFFF",
20
+ "tertiaryContainer": "#E6DEFF",
21
+ "onTertiaryContainer": "#1D1736",
22
+ "tertiaryFixed": "#E6DEFF",
23
+ "onTertiaryFixed": "#1D1736",
24
+ "tertiaryFixedDim": "#CAC1E9",
25
+ "onTertiaryFixedVariant": "#484264",
26
+ "error": "#BA1A1A",
27
+ "onError": "#FFFFFF",
28
+ "errorContainer": "#FFDAD6",
29
+ "onErrorContainer": "#410002",
30
+ "outline": "#71787D",
31
+ "background": "#FBFCFF",
32
+ "onBackground": "#191C1E",
33
+ "surface": "#F8F9FC",
34
+ "onSurface": "#191C1E",
35
+ "surfaceVariant": "#DCE3E9",
36
+ "onSurfaceVariant": "#41484D",
37
+ "inverseSurface": "#2E3133",
38
+ "inverseOnSurface": "#F0F1F3",
39
+ "inversePrimary": "#7BD0FF",
40
+ "shadow": "#000000",
41
+ "surfaceTint": "#00668A",
42
+ "outlineVariant": "#C0C7CD",
43
+ "scrim": "#000000",
44
+ "surfaceContainerHighest": "#E1E2E5",
45
+ "surfaceContainerHigh": "#E7E8EA",
46
+ "surfaceContainer": "#EDEEF0",
47
+ "surfaceContainerLow": "#F3F3F6",
48
+ "surfaceContainerLowest": "#FFFFFF",
49
+ "surfaceBright": "#F8F9FC",
50
+ "surfaceDim": "#D9DADC"
51
+ }
@@ -0,0 +1,127 @@
1
+ import { HostAppObject, HostAppObjectEntity, HostAppObjectRepo } from "../../../HostAppObject";
2
+ import { Color } from "../../../ValueObjects";
3
+ export declare enum ThemeColorType {
4
+ primary = "primary",
5
+ onPrimary = "onPrimary",
6
+ primaryContainer = "primaryContainer",
7
+ onPrimaryContainer = "onPrimaryContainer",
8
+ primaryFixed = "primaryFixed",
9
+ onPrimaryFixed = "onPrimaryFixed",
10
+ primaryFixedDim = "primaryFixedDim",
11
+ onPrimaryFixedVariant = "onPrimaryFixedVariant",
12
+ secondary = "secondary",
13
+ onSecondary = "onSecondary",
14
+ secondaryContainer = "secondaryContainer",
15
+ onSecondaryContainer = "onSecondaryContainer",
16
+ secondaryFixed = "secondaryFixed",
17
+ onSecondaryFixed = "onSecondaryFixed",
18
+ secondaryFixedDim = "secondaryFixedDim",
19
+ onSecondaryFixedVariant = "onSecondaryFixedVariant",
20
+ tertiary = "tertiary",
21
+ onTertiary = "onTertiary",
22
+ tertiaryContainer = "tertiaryContainer",
23
+ onTertiaryContainer = "onTertiaryContainer",
24
+ tertiaryFixed = "tertiaryFixed",
25
+ onTertiaryFixed = "onTertiaryFixed",
26
+ tertiaryFixedDim = "tertiaryFixedDim",
27
+ onTertiaryFixedVariant = "onTertiaryFixedVariant",
28
+ error = "error",
29
+ onError = "onError",
30
+ errorContainer = "errorContainer",
31
+ onErrorContainer = "onErrorContainer",
32
+ outline = "outline",
33
+ background = "background",
34
+ onBackground = "onBackground",
35
+ surface = "surface",
36
+ onSurface = "onSurface",
37
+ surfaceVariant = "surfaceVariant",
38
+ onSurfaceVariant = "onSurfaceVariant",
39
+ inverseSurface = "inverseSurface",
40
+ inverseOnSurface = "inverseOnSurface",
41
+ inversePrimary = "inversePrimary",
42
+ shadow = "shadow",
43
+ surfaceTint = "surfaceTint",
44
+ outlineVariant = "outlineVariant",
45
+ scrim = "scrim",
46
+ surfaceContainerHighest = "surfaceContainerHighest",
47
+ surfaceContainerHigh = "surfaceContainerHigh",
48
+ surfaceContainer = "surfaceContainer",
49
+ surfaceContainerLow = "surfaceContainerLow",
50
+ surfaceContainerLowest = "surfaceContainerLowest",
51
+ surfaceBright = "surfaceBright",
52
+ surfaceDim = "surfaceDim"
53
+ }
54
+ export interface ColorScheme {
55
+ primary: string;
56
+ onPrimary: string;
57
+ primaryContainer: string;
58
+ onPrimaryContainer: string;
59
+ primaryFixed: string;
60
+ onPrimaryFixed: string;
61
+ primaryFixedDim: string;
62
+ onPrimaryFixedVariant: string;
63
+ secondary: string;
64
+ onSecondary: string;
65
+ secondaryContainer: string;
66
+ onSecondaryContainer: string;
67
+ secondaryFixed: string;
68
+ onSecondaryFixed: string;
69
+ secondaryFixedDim: string;
70
+ onSecondaryFixedVariant: string;
71
+ tertiary: string;
72
+ onTertiary: string;
73
+ tertiaryContainer: string;
74
+ onTertiaryContainer: string;
75
+ tertiaryFixed: string;
76
+ onTertiaryFixed: string;
77
+ tertiaryFixedDim: string;
78
+ onTertiaryFixedVariant: string;
79
+ error: string;
80
+ onError: string;
81
+ errorContainer: string;
82
+ onErrorContainer: string;
83
+ outline: string;
84
+ background: string;
85
+ onBackground: string;
86
+ surface: string;
87
+ onSurface: string;
88
+ surfaceVariant: string;
89
+ onSurfaceVariant: string;
90
+ inverseSurface: string;
91
+ inverseOnSurface: string;
92
+ inversePrimary: string;
93
+ shadow: string;
94
+ surfaceTint: string;
95
+ outlineVariant: string;
96
+ scrim: string;
97
+ surfaceContainerHighest: string;
98
+ surfaceContainerHigh: string;
99
+ surfaceContainer: string;
100
+ surfaceContainerLow: string;
101
+ surfaceContainerLowest: string;
102
+ surfaceBright: string;
103
+ surfaceDim: string;
104
+ }
105
+ export declare abstract class HostThemeEntity extends HostAppObjectEntity {
106
+ static readonly type = "HostThemeEntity";
107
+ abstract submitScheme(name: string, scheme: ColorScheme): void;
108
+ abstract activeSchemeName: string;
109
+ abstract get activeScheme(): ColorScheme;
110
+ abstract getColorForType(type: ThemeColorType): Color;
111
+ abstract getHexForType(type: ThemeColorType): string;
112
+ static get: (appObjects: HostAppObjectRepo) => HostThemeEntity | undefined;
113
+ }
114
+ export declare function makeHostThemeEntity(appObject: HostAppObject): HostThemeEntityImp;
115
+ declare class HostThemeEntityImp extends HostThemeEntity {
116
+ private schemeLookup;
117
+ get activeScheme(): ColorScheme;
118
+ submitScheme: (name: string, scheme: ColorScheme) => void;
119
+ getHexForType(type: ThemeColorType): string;
120
+ private memoizedActiveScheme;
121
+ get activeSchemeName(): string;
122
+ set activeSchemeName(val: string);
123
+ constructor(appObject: HostAppObject);
124
+ getColorForType: (type: ThemeColorType) => Color;
125
+ }
126
+ export declare const defaultScheme: ColorScheme;
127
+ export {};