@itwin/core-frontend 3.0.0-dev.97 → 3.0.0-extension.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 (73) hide show
  1. package/lib/cjs/IModelApp.d.ts +7 -1
  2. package/lib/cjs/IModelApp.d.ts.map +1 -1
  3. package/lib/cjs/IModelApp.js +10 -2
  4. package/lib/cjs/IModelApp.js.map +1 -1
  5. package/lib/cjs/core-frontend.d.ts +7 -6
  6. package/lib/cjs/core-frontend.d.ts.map +1 -1
  7. package/lib/cjs/core-frontend.js +7 -6
  8. package/lib/cjs/core-frontend.js.map +1 -1
  9. package/lib/cjs/extension/Extension.d.ts +39 -0
  10. package/lib/cjs/extension/Extension.d.ts.map +1 -0
  11. package/lib/cjs/extension/Extension.js +39 -0
  12. package/lib/cjs/extension/Extension.js.map +1 -0
  13. package/lib/cjs/extension/ExtensionAdmin.d.ts +70 -0
  14. package/lib/cjs/extension/ExtensionAdmin.d.ts.map +1 -0
  15. package/lib/cjs/extension/ExtensionAdmin.js +105 -0
  16. package/lib/cjs/extension/ExtensionAdmin.js.map +1 -0
  17. package/lib/cjs/extension/ExtensionHost.d.ts +20 -0
  18. package/lib/cjs/extension/ExtensionHost.d.ts.map +1 -0
  19. package/lib/cjs/extension/ExtensionHost.js +19 -0
  20. package/lib/cjs/extension/ExtensionHost.js.map +1 -0
  21. package/lib/cjs/extension/ExtensionImpl.d.ts +16 -0
  22. package/lib/cjs/extension/ExtensionImpl.d.ts.map +1 -0
  23. package/lib/cjs/extension/ExtensionImpl.js +40 -0
  24. package/lib/cjs/extension/ExtensionImpl.js.map +1 -0
  25. package/lib/cjs/extension/ExtensionLoader.d.ts +20 -0
  26. package/lib/cjs/extension/ExtensionLoader.d.ts.map +1 -0
  27. package/lib/cjs/extension/ExtensionLoader.js +11 -0
  28. package/lib/cjs/extension/ExtensionLoader.js.map +1 -0
  29. package/lib/cjs/extension/ExtensionRuntime.d.ts +2 -0
  30. package/lib/cjs/extension/ExtensionRuntime.d.ts.map +1 -0
  31. package/lib/cjs/extension/ExtensionRuntime.js +60 -0
  32. package/lib/cjs/extension/ExtensionRuntime.js.map +1 -0
  33. package/lib/cjs/extension/extensions.d.ts +18 -0
  34. package/lib/cjs/extension/extensions.d.ts.map +1 -0
  35. package/lib/cjs/extension/extensions.js +35 -0
  36. package/lib/cjs/extension/extensions.js.map +1 -0
  37. package/lib/esm/IModelApp.d.ts +7 -1
  38. package/lib/esm/IModelApp.d.ts.map +1 -1
  39. package/lib/esm/IModelApp.js +10 -2
  40. package/lib/esm/IModelApp.js.map +1 -1
  41. package/lib/esm/core-frontend.d.ts +7 -6
  42. package/lib/esm/core-frontend.d.ts.map +1 -1
  43. package/lib/esm/core-frontend.js +7 -6
  44. package/lib/esm/core-frontend.js.map +1 -1
  45. package/lib/esm/extension/Extension.d.ts +39 -0
  46. package/lib/esm/extension/Extension.d.ts.map +1 -0
  47. package/lib/esm/extension/Extension.js +38 -0
  48. package/lib/esm/extension/Extension.js.map +1 -0
  49. package/lib/esm/extension/ExtensionAdmin.d.ts +70 -0
  50. package/lib/esm/extension/ExtensionAdmin.d.ts.map +1 -0
  51. package/lib/esm/extension/ExtensionAdmin.js +101 -0
  52. package/lib/esm/extension/ExtensionAdmin.js.map +1 -0
  53. package/lib/esm/extension/ExtensionHost.d.ts +20 -0
  54. package/lib/esm/extension/ExtensionHost.d.ts.map +1 -0
  55. package/lib/esm/extension/ExtensionHost.js +15 -0
  56. package/lib/esm/extension/ExtensionHost.js.map +1 -0
  57. package/lib/esm/extension/ExtensionImpl.d.ts +16 -0
  58. package/lib/esm/extension/ExtensionImpl.d.ts.map +1 -0
  59. package/lib/esm/extension/ExtensionImpl.js +35 -0
  60. package/lib/esm/extension/ExtensionImpl.js.map +1 -0
  61. package/lib/esm/extension/ExtensionLoader.d.ts +20 -0
  62. package/lib/esm/extension/ExtensionLoader.d.ts.map +1 -0
  63. package/lib/esm/extension/ExtensionLoader.js +10 -0
  64. package/lib/esm/extension/ExtensionLoader.js.map +1 -0
  65. package/lib/esm/extension/ExtensionRuntime.d.ts +2 -0
  66. package/lib/esm/extension/ExtensionRuntime.d.ts.map +1 -0
  67. package/lib/esm/extension/ExtensionRuntime.js +58 -0
  68. package/lib/esm/extension/ExtensionRuntime.js.map +1 -0
  69. package/lib/esm/extension/extensions.d.ts +18 -0
  70. package/lib/esm/extension/extensions.d.ts.map +1 -0
  71. package/lib/esm/extension/extensions.js +23 -0
  72. package/lib/esm/extension/extensions.js.map +1 -0
  73. package/package.json +24 -24
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Extension.js","sourceRoot":"","sources":["../../../src/extension/Extension.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;;AA0CH;;IAEI;AACJ,kCAAkC;AAClC,yDAAyD;AACzD,uDAAuD;AACvD,kDAAkD;AAElD,8GAA8G;AAC9G,4DAA4D;AAC5D,MAAM;AAEN,gEAAgE;AAChE,8BAA8B;AAC9B,4BAA4B;AAE5B,6DAA6D;AAC7D,iBAAiB;AACjB,oDAAoD;AAEpD,wHAAwH;AACxH,2GAA2G;AAC3G,8DAA8D;AAE9D,wDAAwD;AAExD,kCAAkC;AAClC,4CAA4C;AAC5C,wDAAwD;AACxD,MAAM;AAEN,yCAAyC;AACzC,4CAA4C;AAC5C,wHAAwH;AACxH,MAAM;AACN,IAAI","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Extensions\r\n */\r\n\r\ntype ResolveFunc = (() => Promise<any>);\r\n\r\n/** Defines the format of an Extension manifest */\r\nexport interface ExtensionManifest {\r\n readonly name: string;\r\n readonly displayName?: string;\r\n readonly version: string;\r\n readonly description?: string;\r\n /** The main module file to load. This should be a path to the javascript file\r\n * e.g \"./lib/main.js\"\r\n */\r\n readonly main?: string;\r\n /** The version of iTwin.js Core. */\r\n readonly engines?: { itwinjs: string };\r\n /** List of activation events this Extension supports. */\r\n readonly activationEvents?: string[];\r\n readonly enableProposedApi?: boolean;\r\n}\r\n\r\nexport interface BuildExtensionManifest extends ExtensionManifest {\r\n /** Only valid when the Extension is loaded at build-time.\r\n *\r\n * Defines how to load the Extension manifest and\r\n */\r\n readonly module?: string;\r\n}\r\n\r\n/** Describes an Extension that has already been downloaded and has a location files can be easily executed. */\r\nexport interface LocalExtensionProps {\r\n readonly manifest: ExtensionManifest;\r\n readonly mainFunc?: ResolveFunc;\r\n /** Identifies a location of the Extension that it can be loaded.\r\n *\r\n * WIP:\r\n * - Could be a URL to the location of the Extension\r\n * - Could be a file path to an installed location locally.\r\n */\r\n // readonly location: string;\r\n}\r\n\r\n/** Represents an Extension that we are attempting to load.\r\n * @beta\r\n */\r\n// export class PendingExtension {\r\n// public resolve: ResolveFunc | undefined = undefined;\r\n// public reject: RejectFunc | undefined = undefined;\r\n// public promise: Promise<LocalExtensionProps>;\r\n\r\n// public constructor(private _tarFileUrl: string, public loader: ExtensionLoader, public args?: string[]) {\r\n// this.promise = new Promise(this.executor.bind(this));\r\n// }\r\n\r\n// public executor(resolve: ResolveFunc, reject: RejectFunc) {\r\n// this.resolve = resolve;\r\n// this.reject = reject;\r\n\r\n// const head = document.getElementsByTagName(\"head\")[0];\r\n// if (!head)\r\n// reject(new Error(\"no head element found\"));\r\n\r\n// // create the script element. We handle onerror and resolve a ExtensionLoadResult failure in the onerror handler,\r\n// // but we don't resolve success until the loaded extension calls \"register\" (see Extension.register)\r\n// const scriptElement = document.createElement(\"script\");\r\n\r\n// scriptElement.onerror = this.cantLoad.bind(this);\r\n\r\n// scriptElement.async = true;\r\n// scriptElement.src = this._tarFileUrl;\r\n// head.insertBefore(scriptElement, head.lastChild);\r\n// }\r\n\r\n// // called when we can't load the URL\r\n// private cantLoad(_ev: string | Event) {\r\n// this.resolve!(IModelApp.i18n.translate(\"iModelJs:ExtensionErrors.CantFind\", { extensionUrl: this._tarFileUrl }));\r\n// }\r\n// }\r\n"]}
@@ -0,0 +1,70 @@
1
+ /** @packageDocumentation
2
+ * @module Extensions
3
+ */
4
+ import { ExtensionLoader } from "./ExtensionLoader";
5
+ /** The Extensions loading system has 3 goals:
6
+ * 1. Only fetch what is needed when it is required
7
+ * 1. Load a manifest file
8
+ * 2. Load the the main module when necessary
9
+ * 2. Download the needed files from
10
+ *
11
+ * 3 ways to load an Extension into the system:
12
+ *
13
+ * 1. At build-time provide the function to load both the Extension Manifest and import the main module of the extension.
14
+ * The main module must contain the activate() function.
15
+ * 2. A minimum set of ExtensionLoaderProps that provide enough information to get the manifest
16
+ *
17
+ * An Extension can be in 3 different states:
18
+ * - Known
19
+ * - The Extension Admin has the minimal information needed to fetch the manifest for the Extension.
20
+ * knows the Extension exists but has not yet loaded the manifest
21
+ * - Installed
22
+ * - The Extension has the full manifest loaded and can be executed on the activation events
23
+ * - Disabled
24
+ * - The Extension has the full manifest but is not currently enabled and will not be executed based on the
25
+ * activation events.
26
+ */
27
+ declare type ResolveFunc = (() => Promise<any>);
28
+ /** The Extension Admin controls the list of currently known, loaded and executing an Extension.
29
+ * Handles the loading of Extensions and maintains a list of the currently loaded Extensions.
30
+ *
31
+ * On application startup, an initial list of Extensions is gathered by searching in known locations for
32
+ *
33
+ * @alpha
34
+ */
35
+ export declare class ExtensionAdmin {
36
+ /** The list of places to download an Extension. */
37
+ private _extensionLoaders;
38
+ /** Defines the set of extensions that are currently known and can be invoked during activation events. */
39
+ private _installedExtensions;
40
+ /**
41
+ * Fired when an Extension has been added or removed.
42
+ */
43
+ onStartup: () => Promise<void>;
44
+ constructor();
45
+ /** Adds an ExtensionLoader to the front of the list of extension loaders in use. Extension loaders will be invoked front to back.
46
+ * By default, the list consists of public Extension Service context, unless disabled via props.
47
+ * @param extensionLoader Extension loader to add
48
+ */
49
+ addExtensionLoaderFront(extensionLoader: ExtensionLoader): void;
50
+ /** Adds an ExtensionLoader to the list of extension loaders in use.
51
+ * By default, the list consists of public Extension Service context, unless disabled via props.
52
+ * @param extensionLoader Extension loader to add
53
+ */
54
+ addExtensionLoader(extensionLoader: ExtensionLoader): void;
55
+ /** Add an Extension to be bundled during compilation.
56
+ * @param manifestLoader A function that loads the manifest file.
57
+ * @param mainFunc The main function to be executed upon
58
+ */
59
+ addBuildExtension(manifestPromise: Promise<any>, mainFunc?: ResolveFunc): Promise<void>;
60
+ /** Loops over all enabled Extensions and triggers each one if the provided event is defined. */
61
+ private activateExtensionEvents;
62
+ /** Resolves an import function provided for build-time Extensions that should return a valid
63
+ * Extension Manifest.
64
+ */
65
+ private getManifest;
66
+ private parseManifest;
67
+ private execute;
68
+ }
69
+ export {};
70
+ //# sourceMappingURL=ExtensionAdmin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionAdmin.d.ts","sourceRoot":"","sources":["../../../src/extension/ExtensionAdmin.ts"],"names":[],"mappings":"AAIA;;GAEG;AAKH,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,aAAK,WAAW,GAAG,CAAC,MAAM,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC;AAOxC;;;;;;GAMG;AACH,qBAAa,cAAc;IACzB,oDAAoD;IACpD,OAAO,CAAC,iBAAiB,CAAyB;IAElD,2GAA2G;IAC3G,OAAO,CAAC,oBAAoB,CAA4E;IAExG;;QAEI;IAGG,SAAS,sBAEd;;IAMF;;;OAGG;IACI,uBAAuB,CAAC,eAAe,EAAE,eAAe;IAI/D;;;QAGI;IACG,kBAAkB,CAAC,eAAe,EAAE,eAAe;IAI1D;;;OAGG;IACU,iBAAiB,CAAC,eAAe,EAAE,OAAO,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC;IAKpG,gGAAgG;YAClF,uBAAuB;IAYrC;;OAEG;YACW,WAAW;YAMX,aAAa;YAiBb,OAAO;CAKtB"}
@@ -0,0 +1,101 @@
1
+ /*---------------------------------------------------------------------------------------------
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
+ /** @packageDocumentation
6
+ * @module Extensions
7
+ */
8
+ // import { Extension, ExtensionLoader, ExtensionManifest, LocalExtensionProps, PendingExtension } from "./Extension";
9
+ import { IModelApp } from "../IModelApp";
10
+ // type RejectFunc = ((arg: Error) => void);
11
+ var ActivationEvents;
12
+ (function (ActivationEvents) {
13
+ ActivationEvents["onStartupApp"] = "onStartupApp";
14
+ })(ActivationEvents || (ActivationEvents = {}));
15
+ /** The Extension Admin controls the list of currently known, loaded and executing an Extension.
16
+ * Handles the loading of Extensions and maintains a list of the currently loaded Extensions.
17
+ *
18
+ * On application startup, an initial list of Extensions is gathered by searching in known locations for
19
+ *
20
+ * @alpha
21
+ */
22
+ export class ExtensionAdmin {
23
+ constructor() {
24
+ /** The list of places to download an Extension. */
25
+ this._extensionLoaders = [];
26
+ /** Defines the set of extensions that are currently known and can be invoked during activation events. */
27
+ this._installedExtensions = new Map();
28
+ /**
29
+ * Fired when an Extension has been added or removed.
30
+ */
31
+ // public readonly onInstallExtension = new BeEvent<(added: readonly ExtensionProps[], removed: readonly ExtensionProps[]) => void>();
32
+ this.onStartup = async () => {
33
+ await this.activateExtensionEvents(ActivationEvents.onStartupApp);
34
+ };
35
+ IModelApp.onBeforeStartup.addListener(this.onStartup);
36
+ }
37
+ /** Adds an ExtensionLoader to the front of the list of extension loaders in use. Extension loaders will be invoked front to back.
38
+ * By default, the list consists of public Extension Service context, unless disabled via props.
39
+ * @param extensionLoader Extension loader to add
40
+ */
41
+ addExtensionLoaderFront(extensionLoader) {
42
+ this._extensionLoaders.unshift(extensionLoader);
43
+ }
44
+ /** Adds an ExtensionLoader to the list of extension loaders in use.
45
+ * By default, the list consists of public Extension Service context, unless disabled via props.
46
+ * @param extensionLoader Extension loader to add
47
+ */
48
+ addExtensionLoader(extensionLoader) {
49
+ this._extensionLoaders.push(extensionLoader);
50
+ }
51
+ /** Add an Extension to be bundled during compilation.
52
+ * @param manifestLoader A function that loads the manifest file.
53
+ * @param mainFunc The main function to be executed upon
54
+ */
55
+ async addBuildExtension(manifestPromise, mainFunc) {
56
+ const manifest = await this.getManifest(manifestPromise);
57
+ this._installedExtensions.set(manifest.name, { manifest, mainFunc });
58
+ }
59
+ /** Loops over all enabled Extensions and triggers each one if the provided event is defined. */
60
+ async activateExtensionEvents(event) {
61
+ for (const extension of this._installedExtensions.values()) {
62
+ if (!extension.manifest.activationEvents)
63
+ continue;
64
+ for (const activationEvent of extension.manifest.activationEvents) {
65
+ if (activationEvent === event) {
66
+ this.execute(extension); // eslint-disable-line @typescript-eslint/no-floating-promises
67
+ }
68
+ }
69
+ }
70
+ }
71
+ /** Resolves an import function provided for build-time Extensions that should return a valid
72
+ * Extension Manifest.
73
+ */
74
+ async getManifest(loader) {
75
+ const raw = await loader;
76
+ const manifest = this.parseManifest(raw);
77
+ return manifest;
78
+ }
79
+ async parseManifest(raw) {
80
+ try {
81
+ if ("object" === typeof (raw))
82
+ return raw;
83
+ if ("string" === typeof (raw))
84
+ return JSON.parse(raw);
85
+ }
86
+ catch (err) { }
87
+ throw new Error("Extension is invalid: package.json is not JSON.");
88
+ }
89
+ // Important: The Function constructor is used here to isolate the context in which the Extension javascript has access.
90
+ // By using the Function constructor to create and then execute the extension it will only have access to two scopes:
91
+ // 1. It's own function scope
92
+ // 2. The global scope
93
+ //
94
+ // The global scope is important for an Extension as that is where the reference to the Extension Implementation is supplied
95
+ // from the application side.
96
+ async execute(extension) {
97
+ if (extension.mainFunc)
98
+ return extension.mainFunc();
99
+ }
100
+ }
101
+ //# sourceMappingURL=ExtensionAdmin.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionAdmin.js","sourceRoot":"","sources":["../../../src/extension/ExtensionAdmin.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAEH,sHAAsH;AACtH,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AA4BzC,4CAA4C;AAE5C,IAAK,gBAEJ;AAFD,WAAK,gBAAgB;IACnB,iDAA6B,CAAA;AAC/B,CAAC,EAFI,gBAAgB,KAAhB,gBAAgB,QAEpB;AAED;;;;;;GAMG;AACH,MAAM,OAAO,cAAc;IAgBzB;QAfA,oDAAoD;QAC5C,sBAAiB,GAAsB,EAAE,CAAC;QAElD,2GAA2G;QACnG,yBAAoB,GAAqC,IAAI,GAAG,EAA+B,CAAC;QAExG;;YAEI;QACJ,sIAAsI;QAE/H,cAAS,GAAG,KAAK,IAAI,EAAE;YAC5B,MAAM,IAAI,CAAC,uBAAuB,CAAC,gBAAgB,CAAC,YAAY,CAAC,CAAC;QACpE,CAAC,CAAC;QAGA,SAAS,CAAC,eAAe,CAAC,WAAW,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;IACxD,CAAC;IAED;;;OAGG;IACI,uBAAuB,CAAC,eAAgC;QAC7D,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;IAClD,CAAC;IAED;;;QAGI;IACG,kBAAkB,CAAC,eAAgC;QACxD,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;IAC/C,CAAC;IAED;;;OAGG;IACI,KAAK,CAAC,iBAAiB,CAAC,eAA6B,EAAE,QAAsB;QAClF,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,WAAW,CAAC,eAAe,CAAC,CAAC;QACzD,IAAI,CAAC,oBAAoB,CAAC,GAAG,CAAC,QAAQ,CAAC,IAAI,EAAE,EAAE,QAAQ,EAAE,QAAQ,EAAE,CAAC,CAAC;IACvE,CAAC;IAED,gGAAgG;IACxF,KAAK,CAAC,uBAAuB,CAAC,KAAa;QACjD,KAAK,MAAM,SAAS,IAAI,IAAI,CAAC,oBAAoB,CAAC,MAAM,EAAE,EAAE;YAC1D,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,gBAAgB;gBACtC,SAAS;YACX,KAAK,MAAM,eAAe,IAAI,SAAS,CAAC,QAAQ,CAAC,gBAAgB,EAAE;gBACjE,IAAI,eAAe,KAAK,KAAK,EAAE;oBAC7B,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,8DAA8D;iBACxF;aACF;SACF;IACH,CAAC;IAED;;OAEG;IACK,KAAK,CAAC,WAAW,CAAC,MAAoB;QAC5C,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC;QACzB,MAAM,QAAQ,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;QACzC,OAAO,QAAQ,CAAC;IAClB,CAAC;IAEO,KAAK,CAAC,aAAa,CAAC,GAAY;QACtC,IAAI;YACF,IAAI,QAAQ,KAAK,OAAO,CAAC,GAAG,CAAC;gBAC3B,OAAO,GAAwB,CAAC;YAClC,IAAI,QAAQ,KAAK,OAAO,CAAC,GAAG,CAAC;gBAC3B,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAsB,CAAC;SAC/C;QAAC,OAAO,GAAQ,EAAE,GAAG;QACtB,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;IACrE,CAAC;IAED,wHAAwH;IACxH,qHAAqH;IACrH,8BAA8B;IAC9B,uBAAuB;IACvB,EAAE;IACF,4HAA4H;IAC5H,6BAA6B;IACrB,KAAK,CAAC,OAAO,CAAC,SAA8B;QAClD,IAAI,SAAS,CAAC,QAAQ;YACpB,OAAO,SAAS,CAAC,QAAQ,EAAE,CAAC;IAChC,CAAC;CAEF","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Extensions\r\n */\r\n\r\n// import { Extension, ExtensionLoader, ExtensionManifest, LocalExtensionProps, PendingExtension } from \"./Extension\";\r\nimport { IModelApp } from \"../IModelApp\";\r\nimport { ExtensionManifest, LocalExtensionProps } from \"./Extension\";\r\nimport { ExtensionLoader } from \"./ExtensionLoader\";\r\n\r\n/** The Extensions loading system has 3 goals:\r\n * 1. Only fetch what is needed when it is required\r\n * 1. Load a manifest file\r\n * 2. Load the the main module when necessary\r\n * 2. Download the needed files from\r\n *\r\n * 3 ways to load an Extension into the system:\r\n *\r\n * 1. At build-time provide the function to load both the Extension Manifest and import the main module of the extension.\r\n * The main module must contain the activate() function.\r\n * 2. A minimum set of ExtensionLoaderProps that provide enough information to get the manifest\r\n *\r\n * An Extension can be in 3 different states:\r\n * - Known\r\n * - The Extension Admin has the minimal information needed to fetch the manifest for the Extension.\r\n * knows the Extension exists but has not yet loaded the manifest\r\n * - Installed\r\n * - The Extension has the full manifest loaded and can be executed on the activation events\r\n * - Disabled\r\n * - The Extension has the full manifest but is not currently enabled and will not be executed based on the\r\n * activation events.\r\n */\r\n\r\ntype ResolveFunc = (() => Promise<any>);\r\n// type RejectFunc = ((arg: Error) => void);\r\n\r\nenum ActivationEvents {\r\n onStartupApp = \"onStartupApp\",\r\n}\r\n\r\n/** The Extension Admin controls the list of currently known, loaded and executing an Extension.\r\n * Handles the loading of Extensions and maintains a list of the currently loaded Extensions.\r\n *\r\n * On application startup, an initial list of Extensions is gathered by searching in known locations for\r\n *\r\n * @alpha\r\n */\r\nexport class ExtensionAdmin {\r\n /** The list of places to download an Extension. */\r\n private _extensionLoaders: ExtensionLoader[] = [];\r\n\r\n /** Defines the set of extensions that are currently known and can be invoked during activation events. */\r\n private _installedExtensions: Map<string, LocalExtensionProps> = new Map<string, LocalExtensionProps>();\r\n\r\n /**\r\n * Fired when an Extension has been added or removed.\r\n */\r\n // public readonly onInstallExtension = new BeEvent<(added: readonly ExtensionProps[], removed: readonly ExtensionProps[]) => void>();\r\n\r\n public onStartup = async () => {\r\n await this.activateExtensionEvents(ActivationEvents.onStartupApp);\r\n };\r\n\r\n public constructor() {\r\n IModelApp.onBeforeStartup.addListener(this.onStartup);\r\n }\r\n\r\n /** Adds an ExtensionLoader to the front of the list of extension loaders in use. Extension loaders will be invoked front to back.\r\n * By default, the list consists of public Extension Service context, unless disabled via props.\r\n * @param extensionLoader Extension loader to add\r\n */\r\n public addExtensionLoaderFront(extensionLoader: ExtensionLoader) {\r\n this._extensionLoaders.unshift(extensionLoader);\r\n }\r\n\r\n /** Adds an ExtensionLoader to the list of extension loaders in use.\r\n * By default, the list consists of public Extension Service context, unless disabled via props.\r\n * @param extensionLoader Extension loader to add\r\n */\r\n public addExtensionLoader(extensionLoader: ExtensionLoader) {\r\n this._extensionLoaders.push(extensionLoader);\r\n }\r\n\r\n /** Add an Extension to be bundled during compilation.\r\n * @param manifestLoader A function that loads the manifest file.\r\n * @param mainFunc The main function to be executed upon\r\n */\r\n public async addBuildExtension(manifestPromise: Promise<any>, mainFunc?: ResolveFunc): Promise<void> {\r\n const manifest = await this.getManifest(manifestPromise);\r\n this._installedExtensions.set(manifest.name, { manifest, mainFunc });\r\n }\r\n\r\n /** Loops over all enabled Extensions and triggers each one if the provided event is defined. */\r\n private async activateExtensionEvents(event: string) {\r\n for (const extension of this._installedExtensions.values()) {\r\n if (!extension.manifest.activationEvents)\r\n continue;\r\n for (const activationEvent of extension.manifest.activationEvents) {\r\n if (activationEvent === event) {\r\n this.execute(extension); // eslint-disable-line @typescript-eslint/no-floating-promises\r\n }\r\n }\r\n }\r\n }\r\n\r\n /** Resolves an import function provided for build-time Extensions that should return a valid\r\n * Extension Manifest.\r\n */\r\n private async getManifest(loader: Promise<any>): Promise<ExtensionManifest> {\r\n const raw = await loader;\r\n const manifest = this.parseManifest(raw);\r\n return manifest;\r\n }\r\n\r\n private async parseManifest(raw: unknown): Promise<ExtensionManifest> {\r\n try {\r\n if (\"object\" === typeof (raw))\r\n return raw as ExtensionManifest;\r\n if (\"string\" === typeof (raw))\r\n return JSON.parse(raw) as ExtensionManifest;\r\n } catch (err: any) { }\r\n throw new Error(\"Extension is invalid: package.json is not JSON.\");\r\n }\r\n\r\n // Important: The Function constructor is used here to isolate the context in which the Extension javascript has access.\r\n // By using the Function constructor to create and then execute the extension it will only have access to two scopes:\r\n // 1. It's own function scope\r\n // 2. The global scope\r\n //\r\n // The global scope is important for an Extension as that is where the reference to the Extension Implementation is supplied\r\n // from the application side.\r\n private async execute(extension: LocalExtensionProps): Promise<void> {\r\n if (extension.mainFunc)\r\n return extension.mainFunc();\r\n }\r\n\r\n}\r\n"]}
@@ -0,0 +1,20 @@
1
+ import type { ToolAdmin } from "../tools/ToolAdmin";
2
+ import type { AccuSnap } from "../AccuSnap";
3
+ import type { NotificationManager } from "../NotificationManager";
4
+ import type { ViewManager } from "../ViewManager";
5
+ import type { ElementLocateManager } from "../ElementLocateManager";
6
+ import type { Localization } from "@itwin/core-common";
7
+ /**
8
+ * Subset of IModelApp exposed to Extensions
9
+ * @beta
10
+ */
11
+ export declare class ExtensionHost {
12
+ protected constructor();
13
+ static get toolAdmin(): ToolAdmin;
14
+ static get notifications(): NotificationManager;
15
+ static get viewManager(): ViewManager;
16
+ static get locateManager(): ElementLocateManager;
17
+ static get accuSnap(): AccuSnap;
18
+ static get localization(): Localization;
19
+ }
20
+ //# sourceMappingURL=ExtensionHost.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionHost.d.ts","sourceRoot":"","sources":["../../../src/extension/ExtensionHost.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAClE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AACpE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAEvD;;;GAGG;AACH,qBAAa,aAAa;IACxB,SAAS;IAET,WAAkB,SAAS,IAAI,SAAS,CAAgC;IACxE,WAAkB,aAAa,IAAI,mBAAmB,CAAoC;IAC1F,WAAkB,WAAW,IAAI,WAAW,CAAkC;IAC9E,WAAkB,aAAa,IAAI,oBAAoB,CAAoC;IAC3F,WAAkB,QAAQ,IAAI,QAAQ,CAA+B;IACrE,WAAkB,YAAY,IAAI,YAAY,CAAmC;CAClF"}
@@ -0,0 +1,15 @@
1
+ import { IModelApp } from "../IModelApp";
2
+ /**
3
+ * Subset of IModelApp exposed to Extensions
4
+ * @beta
5
+ */
6
+ export class ExtensionHost {
7
+ constructor() { }
8
+ static get toolAdmin() { return IModelApp.toolAdmin; }
9
+ static get notifications() { return IModelApp.notifications; }
10
+ static get viewManager() { return IModelApp.viewManager; }
11
+ static get locateManager() { return IModelApp.locateManager; } // internal ?
12
+ static get accuSnap() { return IModelApp.accuSnap; }
13
+ static get localization() { return IModelApp.localization; } // re think this, should be contribution point
14
+ }
15
+ //# sourceMappingURL=ExtensionHost.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionHost.js","sourceRoot":"","sources":["../../../src/extension/ExtensionHost.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAQzC;;;GAGG;AACH,MAAM,OAAO,aAAa;IACxB,gBAA0B,CAAC;IAEpB,MAAM,KAAK,SAAS,KAAgB,OAAO,SAAS,CAAC,SAAS,CAAC,CAAC,CAAC;IACjE,MAAM,KAAK,aAAa,KAA0B,OAAO,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC;IACnF,MAAM,KAAK,WAAW,KAAkB,OAAO,SAAS,CAAC,WAAW,CAAC,CAAC,CAAC;IACvE,MAAM,KAAK,aAAa,KAA2B,OAAO,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,aAAa;IAClG,MAAM,KAAK,QAAQ,KAAe,OAAO,SAAS,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC9D,MAAM,KAAK,YAAY,KAAmB,OAAO,SAAS,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,8CAA8C;CACjI","sourcesContent":["import { IModelApp } from \"../IModelApp\";\r\nimport type { ToolAdmin } from \"../tools/ToolAdmin\";\r\nimport type { AccuSnap } from \"../AccuSnap\";\r\nimport type { NotificationManager } from \"../NotificationManager\";\r\nimport type { ViewManager } from \"../ViewManager\";\r\nimport type { ElementLocateManager } from \"../ElementLocateManager\";\r\nimport type { Localization } from \"@itwin/core-common\";\r\n\r\n/**\r\n * Subset of IModelApp exposed to Extensions\r\n * @beta\r\n */\r\nexport class ExtensionHost {\r\n protected constructor() { }\r\n\r\n public static get toolAdmin(): ToolAdmin { return IModelApp.toolAdmin; }\r\n public static get notifications(): NotificationManager { return IModelApp.notifications; }\r\n public static get viewManager(): ViewManager { return IModelApp.viewManager; }\r\n public static get locateManager(): ElementLocateManager { return IModelApp.locateManager; } // internal ?\r\n public static get accuSnap(): AccuSnap { return IModelApp.accuSnap; }\r\n public static get localization(): Localization { return IModelApp.localization; } // re think this, should be contribution point\r\n}\r\n"]}
@@ -0,0 +1,16 @@
1
+ import { ToolType } from "../tools/Tool";
2
+ import { CommonToolbarItem, ToolbarOrientation, ToolbarUsage, UiItemsProvider } from "@itwin/appui-abstract";
3
+ export declare class ToolProvider implements UiItemsProvider {
4
+ readonly id: string;
5
+ private _toolId;
6
+ private _toolIcon;
7
+ private _toolLabel;
8
+ constructor(tool: ToolType);
9
+ provideToolbarButtonItems(_stageId: string, stageUsage: string, toolbarUsage: ToolbarUsage, toolbarOrientation: ToolbarOrientation): CommonToolbarItem[];
10
+ }
11
+ export declare class ExtensionImpl {
12
+ private _id;
13
+ constructor(_id: string);
14
+ registerTool(tool: ToolType, onRegistered?: () => any): Promise<void>;
15
+ }
16
+ //# sourceMappingURL=ExtensionImpl.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionImpl.d.ts","sourceRoot":"","sources":["../../../src/extension/ExtensionImpl.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAEzC,OAAO,EAAE,iBAAiB,EAAoC,kBAAkB,EAAE,YAAY,EAAkB,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE/J,qBAAa,YAAa,YAAW,eAAe;IAClD,SAAgB,EAAE,SAAC;IACnB,OAAO,CAAC,OAAO,CAAM;IACrB,OAAO,CAAC,SAAS,CAAC;IAClB,OAAO,CAAC,UAAU,CAAC;gBAEA,IAAI,EAAE,QAAQ;IAO1B,yBAAyB,CAAC,QAAQ,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,YAAY,EAAE,YAAY,EAAE,kBAAkB,EAAE,kBAAkB,GAAG,iBAAiB,EAAE;CAIhK;AAED,qBAAa,aAAa;IACZ,OAAO,CAAC,GAAG;gBAAH,GAAG,EAAE,MAAM;IAElB,YAAY,CAAC,IAAI,EAAE,QAAQ,EAAE,YAAY,CAAC,EAAE,MAAM,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC;CASnF"}
@@ -0,0 +1,35 @@
1
+ /*---------------------------------------------------------------------------------------------
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
+ import { IModelApp } from "../IModelApp";
6
+ import { StageUsage, ToolbarItemUtilities, ToolbarOrientation, ToolbarUsage, UiItemsManager } from "@itwin/appui-abstract";
7
+ export class ToolProvider {
8
+ constructor(tool) {
9
+ this._toolId = "";
10
+ this.id = `ToolProvider:${tool.toolId}`;
11
+ this._toolId = tool.toolId;
12
+ this._toolIcon = tool.iconSpec;
13
+ this._toolLabel = tool.description;
14
+ }
15
+ provideToolbarButtonItems(_stageId, stageUsage, toolbarUsage, toolbarOrientation) {
16
+ const toolbarItem = ToolbarItemUtilities.createActionButton(this._toolId, 0, this._toolIcon, this._toolLabel, async () => { await IModelApp.tools.run(this._toolId); });
17
+ return stageUsage === StageUsage.General && toolbarUsage === ToolbarUsage.ContentManipulation && toolbarOrientation === ToolbarOrientation.Horizontal ? [toolbarItem] : [];
18
+ }
19
+ }
20
+ export class ExtensionImpl {
21
+ constructor(_id) {
22
+ this._id = _id;
23
+ }
24
+ async registerTool(tool, onRegistered) {
25
+ try {
26
+ IModelApp.tools.register(tool);
27
+ UiItemsManager.register(new ToolProvider(tool));
28
+ onRegistered === null || onRegistered === void 0 ? void 0 : onRegistered();
29
+ }
30
+ catch (e) {
31
+ console.log(`Error registering tool: ${e}`); // eslint-disable-line
32
+ }
33
+ }
34
+ }
35
+ //# sourceMappingURL=ExtensionImpl.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionImpl.js","sourceRoot":"","sources":["../../../src/extension/ExtensionImpl.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAG/F,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAqB,UAAU,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,YAAY,EAAE,cAAc,EAAmB,MAAM,uBAAuB,CAAC;AAE/J,MAAM,OAAO,YAAY;IAMvB,YAAmB,IAAc;QAJzB,YAAO,GAAG,EAAE,CAAC;QAKnB,IAAI,CAAC,EAAE,GAAG,gBAAgB,IAAI,CAAC,MAAM,EAAE,CAAC;QACxC,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,MAAM,CAAC;QAC3B,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,QAAQ,CAAC;QAC/B,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,WAAW,CAAC;IACrC,CAAC;IAEM,yBAAyB,CAAC,QAAgB,EAAE,UAAkB,EAAE,YAA0B,EAAE,kBAAsC;QACvI,MAAM,WAAW,GAAG,oBAAoB,CAAC,kBAAkB,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,EAAE,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,UAAU,EAAE,KAAK,IAAI,EAAE,GAAG,MAAM,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QACxK,OAAO,UAAU,KAAK,UAAU,CAAC,OAAO,IAAI,YAAY,KAAK,YAAY,CAAC,mBAAmB,IAAI,kBAAkB,KAAK,kBAAkB,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IAC7K,CAAC;CACF;AAED,MAAM,OAAO,aAAa;IACxB,YAAoB,GAAW;QAAX,QAAG,GAAH,GAAG,CAAQ;IAAI,CAAC;IAE7B,KAAK,CAAC,YAAY,CAAC,IAAc,EAAE,YAAwB;QAChE,IAAI;YACF,SAAS,CAAC,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;YAC/B,cAAc,CAAC,QAAQ,CAAC,IAAI,YAAY,CAAC,IAAI,CAAC,CAAC,CAAC;YAChD,YAAY,aAAZ,YAAY,uBAAZ,YAAY,EAAI,CAAC;SAClB;QAAC,OAAO,CAAM,EAAE;YACf,OAAO,CAAC,GAAG,CAAC,2BAA2B,CAAC,EAAE,CAAC,CAAC,CAAC,sBAAsB;SACpE;IACH,CAAC;CACF","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\nimport { ToolType } from \"../tools/Tool\";\r\nimport { IModelApp } from \"../IModelApp\";\r\nimport { CommonToolbarItem, StageUsage, ToolbarItemUtilities, ToolbarOrientation, ToolbarUsage, UiItemsManager, UiItemsProvider } from \"@itwin/appui-abstract\";\r\n\r\nexport class ToolProvider implements UiItemsProvider {\r\n public readonly id;\r\n private _toolId = \"\";\r\n private _toolIcon;\r\n private _toolLabel;\r\n\r\n public constructor(tool: ToolType) {\r\n this.id = `ToolProvider:${tool.toolId}`;\r\n this._toolId = tool.toolId;\r\n this._toolIcon = tool.iconSpec;\r\n this._toolLabel = tool.description;\r\n }\r\n\r\n public provideToolbarButtonItems(_stageId: string, stageUsage: string, toolbarUsage: ToolbarUsage, toolbarOrientation: ToolbarOrientation): CommonToolbarItem[] {\r\n const toolbarItem = ToolbarItemUtilities.createActionButton(this._toolId, 0, this._toolIcon, this._toolLabel, async () => { await IModelApp.tools.run(this._toolId); });\r\n return stageUsage === StageUsage.General && toolbarUsage === ToolbarUsage.ContentManipulation && toolbarOrientation === ToolbarOrientation.Horizontal ? [toolbarItem] : [];\r\n }\r\n}\r\n\r\nexport class ExtensionImpl {\r\n constructor(private _id: string) { }\r\n\r\n public async registerTool(tool: ToolType, onRegistered?: () => any): Promise<void> {\r\n try {\r\n IModelApp.tools.register(tool);\r\n UiItemsManager.register(new ToolProvider(tool));\r\n onRegistered?.();\r\n } catch (e: any) {\r\n console.log(`Error registering tool: ${e}`); // eslint-disable-line\r\n }\r\n }\r\n}\r\n"]}
@@ -0,0 +1,20 @@
1
+ import { ExtensionManifest, LocalExtensionProps } from "./Extension";
2
+ /** THe minimum information required to download an Extension */
3
+ export interface ExtensionLoaderProps {
4
+ name: string;
5
+ version: string;
6
+ }
7
+ export interface BuiltInExtensionLoaderProps {
8
+ manifest: Promise<any>;
9
+ loader: (() => Promise<any>);
10
+ }
11
+ /** Describes what is needed in order to write an Extension Loader.
12
+ * @alpha
13
+ */
14
+ export interface ExtensionLoader {
15
+ /** Retrieves an Extension manifest for the provided Extension identifier */
16
+ getManifest(arg: ExtensionLoaderProps): Promise<ExtensionManifest>;
17
+ /** Downloads an Extension provided the name of the Extension */
18
+ downloadExtension(arg: ExtensionLoaderProps): Promise<LocalExtensionProps>;
19
+ }
20
+ //# sourceMappingURL=ExtensionLoader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionLoader.d.ts","sourceRoot":"","sources":["../../../src/extension/ExtensionLoader.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAErE,gEAAgE;AAChE,MAAM,WAAW,oBAAoB;IACnC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,2BAA2B;IAC1C,QAAQ,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC;IACvB,MAAM,EAAE,CAAC,MAAM,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC;CAC9B;AAED;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,4EAA4E;IAC5E,WAAW,CAAC,GAAG,EAAE,oBAAoB,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;IACnE,gEAAgE;IAChE,iBAAiB,CAAC,GAAG,EAAE,oBAAoB,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAAC;CAC5E"}
@@ -0,0 +1,10 @@
1
+ /*---------------------------------------------------------------------------------------------
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
+ export {};
6
+ // export class BuiltInExtensionLoader {
7
+ // public async getManifest(name: string): Promise<ExtensionManifest> {
8
+ // }
9
+ // }
10
+ //# sourceMappingURL=ExtensionLoader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionLoader.js","sourceRoot":"","sources":["../../../src/extension/ExtensionLoader.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;;AAyB/F,wCAAwC;AACxC,yEAAyE;AAEzE,MAAM;AACN,IAAI","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\nimport { ExtensionManifest, LocalExtensionProps } from \"./Extension\";\r\n\r\n/** THe minimum information required to download an Extension */\r\nexport interface ExtensionLoaderProps {\r\n name: string;\r\n version: string;\r\n}\r\n\r\nexport interface BuiltInExtensionLoaderProps {\r\n manifest: Promise<any>;\r\n loader: (() => Promise<any>);\r\n}\r\n\r\n/** Describes what is needed in order to write an Extension Loader.\r\n * @alpha\r\n */\r\nexport interface ExtensionLoader {\r\n /** Retrieves an Extension manifest for the provided Extension identifier */\r\n getManifest(arg: ExtensionLoaderProps): Promise<ExtensionManifest>;\r\n /** Downloads an Extension provided the name of the Extension */\r\n downloadExtension(arg: ExtensionLoaderProps): Promise<LocalExtensionProps>;\r\n}\r\n\r\n// export class BuiltInExtensionLoader {\r\n// public async getManifest(name: string): Promise<ExtensionManifest> {\r\n\r\n// }\r\n// }\r\n"]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=ExtensionRuntime.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionRuntime.d.ts","sourceRoot":"","sources":["../../../src/extension/ExtensionRuntime.ts"],"names":[],"mappings":""}
@@ -0,0 +1,58 @@
1
+ /*---------------------------------------------------------------------------------------------
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
+ /* eslint-disable @typescript-eslint/naming-convention */
6
+ import { ContextRotationId } from "../AccuDraw";
7
+ import { ACSDisplayOptions, ACSType } from "../AuxCoordSys";
8
+ import { CoordSystem } from "../CoordSystem";
9
+ import { LocateAction, LocateFilterStatus, LocateResponse, SnapStatus } from "../ElementLocateManager";
10
+ import { FlashMode } from "../FlashSettings";
11
+ import { FrontendLoggerCategory } from "../FrontendLoggerCategory";
12
+ import { HitDetailType, HitGeomType, HitParentGeomType, HitPriority, HitSource, SnapHeat, SnapMode } from "../HitDetail";
13
+ import { ActivityMessageEndReason, MessageBoxIconType, MessageBoxType, MessageBoxValue, OutputMessageAlert, OutputMessagePriority, OutputMessageType } from "../NotificationManager";
14
+ import { SelectionSetEventType } from "../SelectionSet";
15
+ import { StandardViewId } from "../StandardView";
16
+ import { ViewRect } from "../ViewRect";
17
+ import { ViewStatus } from "../ViewStatus";
18
+ import { DepthPointSource, ViewUndoEvent } from "../Viewport";
19
+ import { GraphicType } from "../render/GraphicBuilder";
20
+ import { Pixel } from "../render/Pixel";
21
+ import { TextureTransparency } from "../render/RenderTexture";
22
+ import { UniformType, VaryingType } from "../render/ScreenSpaceEffectBuilder";
23
+ import { TileBoundingBoxes, TileGraphicType, TileLoadPriority, TileLoadStatus, TileTreeLoadStatus, TileVisibility } from "../tile/internal";
24
+ import { ClipEventType } from "../tools/ClipViewTool";
25
+ import { PrimitiveTool } from "../tools/PrimitiveTool";
26
+ import { SelectionMethod, SelectionMode, SelectionProcessing } from "../tools/SelectTool";
27
+ import { BeButton, BeButtonEvent, BeModifierKeys, CoordinateLockOverrides, CoordSource, EventHandled, InputSource, InteractiveTool, KeyinParseError, ParseAndRunResult, Tool } from "../tools/Tool";
28
+ import { ManipulatorToolEvent, StartOrResume } from "../tools/ToolAdmin";
29
+ import { ToolAssistance, ToolAssistanceImage, ToolAssistanceInputMethod } from "../tools/ToolAssistance";
30
+ import { ViewTool } from "../tools/ViewTool";
31
+ import { ColorDef } from "@itwin/core-common";
32
+ import { ExtensionImpl } from "./ExtensionImpl";
33
+ import { ExtensionHost } from "./ExtensionHost";
34
+ const globalSymbol = Symbol.for("itwin.core.frontend.globals");
35
+ if (globalThis[globalSymbol])
36
+ throw new Error("Multiple @itwin/core-frontend imports detected!");
37
+ const getExtensionApi = (id) => {
38
+ return {
39
+ exports: {
40
+ InteractiveTool, PrimitiveTool, ViewTool, Tool,
41
+ ToolAssistance, BeButtonEvent, ViewRect, Pixel, LocateResponse,
42
+ ColorDef,
43
+ ExtensionHost,
44
+ ACSDisplayOptions, ACSType, ActivityMessageEndReason, BeButton, BeModifierKeys, ClipEventType, ContextRotationId, CoordinateLockOverrides,
45
+ CoordSource, CoordSystem, DepthPointSource, EventHandled, FlashMode, FrontendLoggerCategory, GraphicType, HitDetailType, HitGeomType,
46
+ HitParentGeomType, HitPriority, HitSource, InputSource, KeyinParseError, LocateAction, LocateFilterStatus, ManipulatorToolEvent,
47
+ MessageBoxIconType, MessageBoxType, MessageBoxValue, OutputMessageAlert, OutputMessagePriority, OutputMessageType, ParseAndRunResult,
48
+ SelectionMethod, SelectionMode, SelectionProcessing, SelectionSetEventType, SnapHeat, SnapMode, SnapStatus, StandardViewId, StartOrResume,
49
+ TextureTransparency, TileBoundingBoxes, TileGraphicType, TileLoadPriority, TileLoadStatus, TileTreeLoadStatus, TileVisibility,
50
+ ToolAssistanceImage, ToolAssistanceInputMethod, UniformType, VaryingType, ViewStatus, ViewUndoEvent,
51
+ },
52
+ api: new ExtensionImpl(id),
53
+ };
54
+ };
55
+ globalThis[globalSymbol] = {
56
+ getExtensionApi,
57
+ };
58
+ //# sourceMappingURL=ExtensionRuntime.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExtensionRuntime.js","sourceRoot":"","sources":["../../../src/extension/ExtensionRuntime.ts"],"names":[],"mappings":"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","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\n/* eslint-disable @typescript-eslint/naming-convention */\r\n\r\nimport { ContextRotationId } from \"../AccuDraw\";\r\nimport { ACSDisplayOptions, ACSType } from \"../AuxCoordSys\";\r\nimport { CoordSystem } from \"../CoordSystem\";\r\nimport { LocateAction, LocateFilterStatus, LocateResponse, SnapStatus } from \"../ElementLocateManager\";\r\nimport { FlashMode } from \"../FlashSettings\";\r\nimport { FrontendLoggerCategory } from \"../FrontendLoggerCategory\";\r\nimport { HitDetailType, HitGeomType, HitParentGeomType, HitPriority, HitSource, SnapHeat, SnapMode } from \"../HitDetail\";\r\nimport { ActivityMessageEndReason, MessageBoxIconType, MessageBoxType, MessageBoxValue, OutputMessageAlert, OutputMessagePriority, OutputMessageType } from \"../NotificationManager\";\r\nimport { SelectionSetEventType } from \"../SelectionSet\";\r\nimport { StandardViewId } from \"../StandardView\";\r\nimport { ViewRect } from \"../ViewRect\";\r\nimport { ViewStatus } from \"../ViewStatus\";\r\nimport { DepthPointSource, ViewUndoEvent } from \"../Viewport\";\r\nimport { GraphicType } from \"../render/GraphicBuilder\";\r\nimport { Pixel } from \"../render/Pixel\";\r\nimport { TextureTransparency } from \"../render/RenderTexture\";\r\nimport { UniformType, VaryingType } from \"../render/ScreenSpaceEffectBuilder\";\r\nimport { TileBoundingBoxes, TileGraphicType, TileLoadPriority, TileLoadStatus, TileTreeLoadStatus, TileVisibility } from \"../tile/internal\";\r\nimport { ClipEventType } from \"../tools/ClipViewTool\";\r\nimport { PrimitiveTool } from \"../tools/PrimitiveTool\";\r\nimport { SelectionMethod, SelectionMode, SelectionProcessing } from \"../tools/SelectTool\";\r\nimport { BeButton, BeButtonEvent, BeModifierKeys, CoordinateLockOverrides, CoordSource, EventHandled, InputSource, InteractiveTool, KeyinParseError, ParseAndRunResult, Tool } from \"../tools/Tool\";\r\nimport { ManipulatorToolEvent, StartOrResume } from \"../tools/ToolAdmin\";\r\nimport { ToolAssistance, ToolAssistanceImage, ToolAssistanceInputMethod } from \"../tools/ToolAssistance\";\r\nimport { ViewTool } from \"../tools/ViewTool\";\r\n\r\nimport { ColorDef } from \"@itwin/core-common\";\r\nimport { ExtensionImpl } from \"./ExtensionImpl\";\r\nimport { ExtensionHost } from \"./ExtensionHost\";\r\n\r\nconst globalSymbol = Symbol.for(\"itwin.core.frontend.globals\");\r\nif ((globalThis as any)[globalSymbol])\r\n throw new Error(\"Multiple @itwin/core-frontend imports detected!\");\r\n\r\nconst getExtensionApi = (id: string) => {\r\n return {\r\n exports: {\r\n InteractiveTool, PrimitiveTool, ViewTool, Tool,\r\n\r\n ToolAssistance, BeButtonEvent, ViewRect, Pixel, LocateResponse,\r\n\r\n ColorDef,\r\n\r\n ExtensionHost,\r\n\r\n ACSDisplayOptions, ACSType, ActivityMessageEndReason, BeButton, BeModifierKeys, ClipEventType, ContextRotationId, CoordinateLockOverrides,\r\n CoordSource, CoordSystem, DepthPointSource, EventHandled, FlashMode, FrontendLoggerCategory, GraphicType, HitDetailType, HitGeomType,\r\n HitParentGeomType, HitPriority, HitSource, InputSource, KeyinParseError, LocateAction, LocateFilterStatus, ManipulatorToolEvent,\r\n MessageBoxIconType, MessageBoxType, MessageBoxValue, OutputMessageAlert, OutputMessagePriority, OutputMessageType, ParseAndRunResult,\r\n SelectionMethod, SelectionMode, SelectionProcessing, SelectionSetEventType, SnapHeat, SnapMode, SnapStatus, StandardViewId, StartOrResume,\r\n TextureTransparency, TileBoundingBoxes, TileGraphicType, TileLoadPriority, TileLoadStatus, TileTreeLoadStatus, TileVisibility,\r\n ToolAssistanceImage, ToolAssistanceInputMethod, UniformType, VaryingType, ViewStatus, ViewUndoEvent,\r\n },\r\n api: new ExtensionImpl(id),\r\n };\r\n};\r\n\r\n(globalThis as any)[globalSymbol] = {\r\n getExtensionApi,\r\n};\r\n"]}
@@ -0,0 +1,18 @@
1
+ /**
2
+ * The Extension framework is made up of multiple pieces:
3
+ *
4
+ * - Extension Impl
5
+ * - Extension API
6
+ * - The Extension API defines all of the types and API that can be used by an Extension.
7
+ * - Extension Admin loading
8
+ * - Handles the
9
+ * - Extension Hooks
10
+ * - Defines the
11
+ */
12
+ export * from "./Extension";
13
+ export * from "./ExtensionAdmin";
14
+ export * from "./ExtensionImpl";
15
+ export * from "./ExtensionLoader";
16
+ export * from "./ExtensionHost";
17
+ import "./ExtensionRuntime";
18
+ //# sourceMappingURL=extensions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"extensions.d.ts","sourceRoot":"","sources":["../../../src/extension/extensions.ts"],"names":[],"mappings":"AAOA;;;;;;;;;;GAUG;AAEH,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,OAAO,oBAAoB,CAAC"}
@@ -0,0 +1,23 @@
1
+ /*---------------------------------------------------------------------------------------------
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
+ // Barrel file for all extension related files.
6
+ /**
7
+ * The Extension framework is made up of multiple pieces:
8
+ *
9
+ * - Extension Impl
10
+ * - Extension API
11
+ * - The Extension API defines all of the types and API that can be used by an Extension.
12
+ * - Extension Admin loading
13
+ * - Handles the
14
+ * - Extension Hooks
15
+ * - Defines the
16
+ */
17
+ export * from "./Extension";
18
+ export * from "./ExtensionAdmin";
19
+ export * from "./ExtensionImpl";
20
+ export * from "./ExtensionLoader";
21
+ export * from "./ExtensionHost";
22
+ import "./ExtensionRuntime";
23
+ //# sourceMappingURL=extensions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"extensions.js","sourceRoot":"","sources":["../../../src/extension/extensions.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAE/F,+CAA+C;AAE/C;;;;;;;;;;GAUG;AAEH,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,OAAO,oBAAoB,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\n// Barrel file for all extension related files.\r\n\r\n/**\r\n * The Extension framework is made up of multiple pieces:\r\n *\r\n * - Extension Impl\r\n * - Extension API\r\n * - The Extension API defines all of the types and API that can be used by an Extension.\r\n * - Extension Admin loading\r\n * - Handles the\r\n * - Extension Hooks\r\n * - Defines the\r\n */\r\n\r\nexport * from \"./Extension\";\r\nexport * from \"./ExtensionAdmin\";\r\nexport * from \"./ExtensionImpl\";\r\nexport * from \"./ExtensionLoader\";\r\nexport * from \"./ExtensionHost\";\r\nimport \"./ExtensionRuntime\";\r\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@itwin/core-frontend",
3
- "version": "3.0.0-dev.97",
3
+ "version": "3.0.0-extension.0",
4
4
  "description": "iTwin.js frontend components",
5
5
  "main": "lib/cjs/core-frontend.js",
6
6
  "module": "lib/esm/core-frontend.js",
@@ -23,33 +23,33 @@
23
23
  "url": "http://www.bentley.com"
24
24
  },
25
25
  "peerDependencies": {
26
- "@itwin/core-bentley": "^3.0.0-dev.97",
27
- "@itwin/core-geometry": "^3.0.0-dev.97",
28
- "@itwin/core-common": "^3.0.0-dev.97",
29
- "@itwin/core-quantity": "^3.0.0-dev.97",
30
- "@bentley/itwin-client": "^3.0.0-dev.97",
31
- "@itwin/core-orbitgt": "^3.0.0-dev.97",
32
- "@bentley/product-settings-client": "^3.0.0-dev.97",
33
- "@itwin/appui-abstract": "^3.0.0-dev.97",
34
- "@itwin/webgl-compatibility": "^3.0.0-dev.97"
26
+ "@bentley/itwin-client": "^3.0.0-extension.0",
27
+ "@bentley/product-settings-client": "^3.0.0-extension.0",
28
+ "@itwin/appui-abstract": "^3.0.0-extension.0",
29
+ "@itwin/core-bentley": "^3.0.0-extension.0",
30
+ "@itwin/core-common": "^3.0.0-extension.0",
31
+ "@itwin/core-geometry": "^3.0.0-extension.0",
32
+ "@itwin/core-quantity": "^3.0.0-extension.0",
33
+ "@itwin/core-orbitgt": "^3.0.0-extension.0",
34
+ "@itwin/webgl-compatibility": "^3.0.0-extension.0"
35
35
  },
36
36
  "//devDependencies": [
37
37
  "NOTE: All peerDependencies should also be listed as devDependencies since peerDependencies are not considered by npm install",
38
38
  "NOTE: All tools used by scripts in this package must be listed as devDependencies"
39
39
  ],
40
40
  "devDependencies": {
41
- "@itwin/core-bentley": "3.0.0-dev.97",
42
- "@itwin/build-tools": "3.0.0-dev.97",
43
- "@itwin/certa": "3.0.0-dev.97",
44
- "@itwin/eslint-plugin": "3.0.0-dev.97",
45
- "@itwin/core-geometry": "3.0.0-dev.97",
46
- "@itwin/core-common": "3.0.0-dev.97",
47
- "@itwin/core-quantity": "3.0.0-dev.97",
48
- "@bentley/itwin-client": "3.0.0-dev.97",
49
- "@itwin/core-orbitgt": "3.0.0-dev.97",
50
- "@bentley/product-settings-client": "3.0.0-dev.97",
51
- "@itwin/appui-abstract": "3.0.0-dev.97",
52
- "@itwin/webgl-compatibility": "3.0.0-dev.97",
41
+ "@itwin/core-bentley": "3.0.0-extension.0",
42
+ "@itwin/build-tools": "3.0.0-extension.0",
43
+ "@itwin/certa": "3.0.0-extension.0",
44
+ "@itwin/eslint-plugin": "3.0.0-extension.0",
45
+ "@itwin/core-geometry": "3.0.0-extension.0",
46
+ "@itwin/core-common": "3.0.0-extension.0",
47
+ "@itwin/core-quantity": "3.0.0-extension.0",
48
+ "@bentley/itwin-client": "3.0.0-extension.0",
49
+ "@itwin/core-orbitgt": "3.0.0-extension.0",
50
+ "@bentley/product-settings-client": "3.0.0-extension.0",
51
+ "@itwin/appui-abstract": "3.0.0-extension.0",
52
+ "@itwin/webgl-compatibility": "3.0.0-extension.0",
53
53
  "@types/chai": "^4.1.4",
54
54
  "@types/chai-as-promised": "^7",
55
55
  "@types/mocha": "^8.2.2",
@@ -74,8 +74,8 @@
74
74
  "NOTE: core-frontend should remain UI technology agnostic, so no react/angular dependencies are allowed"
75
75
  ],
76
76
  "dependencies": {
77
- "@bentley/telemetry-client": "3.0.0-dev.97",
78
- "@itwin/core-i18n": "3.0.0-dev.97",
77
+ "@bentley/telemetry-client": "3.0.0-extension.0",
78
+ "@itwin/core-i18n": "3.0.0-extension.0",
79
79
  "fuse.js": "^3.3.0",
80
80
  "semver": "^5.5.0",
81
81
  "wms-capabilities": "0.4.0",