@itwin/presentation-frontend 3.6.0-dev.8 → 3.7.0-dev.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (133) hide show
  1. package/CHANGELOG.md +35 -1
  2. package/LICENSE.md +1 -1
  3. package/lib/cjs/presentation-frontend/ConnectivityInformationProvider.d.ts +29 -29
  4. package/lib/cjs/presentation-frontend/ConnectivityInformationProvider.js +47 -47
  5. package/lib/cjs/presentation-frontend/ConnectivityInformationProvider.js.map +1 -1
  6. package/lib/cjs/presentation-frontend/Diagnostics.d.ts +14 -14
  7. package/lib/cjs/presentation-frontend/Diagnostics.js +61 -61
  8. package/lib/cjs/presentation-frontend/Diagnostics.js.map +1 -1
  9. package/lib/cjs/presentation-frontend/FrontendLoggerCategory.d.ts +12 -12
  10. package/lib/cjs/presentation-frontend/FrontendLoggerCategory.js +20 -20
  11. package/lib/cjs/presentation-frontend/FrontendLoggerCategory.js.map +1 -1
  12. package/lib/cjs/presentation-frontend/IpcRequestsHandler.d.ts +10 -10
  13. package/lib/cjs/presentation-frontend/IpcRequestsHandler.d.ts.map +1 -1
  14. package/lib/cjs/presentation-frontend/IpcRequestsHandler.js +41 -42
  15. package/lib/cjs/presentation-frontend/IpcRequestsHandler.js.map +1 -1
  16. package/lib/cjs/presentation-frontend/LocalizationHelper.d.ts +10 -10
  17. package/lib/cjs/presentation-frontend/LocalizationHelper.js +31 -31
  18. package/lib/cjs/presentation-frontend/LocalizationHelper.js.map +1 -1
  19. package/lib/cjs/presentation-frontend/Presentation.d.ts +75 -75
  20. package/lib/cjs/presentation-frontend/Presentation.js +162 -162
  21. package/lib/cjs/presentation-frontend/Presentation.js.map +1 -1
  22. package/lib/cjs/presentation-frontend/PresentationManager.d.ts +186 -180
  23. package/lib/cjs/presentation-frontend/PresentationManager.d.ts.map +1 -1
  24. package/lib/cjs/presentation-frontend/PresentationManager.js +436 -419
  25. package/lib/cjs/presentation-frontend/PresentationManager.js.map +1 -1
  26. package/lib/cjs/presentation-frontend/RulesetManager.d.ts +63 -60
  27. package/lib/cjs/presentation-frontend/RulesetManager.d.ts.map +1 -1
  28. package/lib/cjs/presentation-frontend/RulesetManager.js +85 -85
  29. package/lib/cjs/presentation-frontend/RulesetManager.js.map +1 -1
  30. package/lib/cjs/presentation-frontend/RulesetVariablesManager.d.ts +143 -143
  31. package/lib/cjs/presentation-frontend/RulesetVariablesManager.js +195 -195
  32. package/lib/cjs/presentation-frontend/RulesetVariablesManager.js.map +1 -1
  33. package/lib/cjs/presentation-frontend/StateTracker.d.ts +38 -23
  34. package/lib/cjs/presentation-frontend/StateTracker.d.ts.map +1 -1
  35. package/lib/cjs/presentation-frontend/StateTracker.js +129 -74
  36. package/lib/cjs/presentation-frontend/StateTracker.js.map +1 -1
  37. package/lib/cjs/presentation-frontend/favorite-properties/FavoritePropertiesManager.d.ts +132 -132
  38. package/lib/cjs/presentation-frontend/favorite-properties/FavoritePropertiesManager.js +525 -525
  39. package/lib/cjs/presentation-frontend/favorite-properties/FavoritePropertiesManager.js.map +1 -1
  40. package/lib/cjs/presentation-frontend/favorite-properties/FavoritePropertiesStorage.d.ts +111 -111
  41. package/lib/cjs/presentation-frontend/favorite-properties/FavoritePropertiesStorage.js +293 -293
  42. package/lib/cjs/presentation-frontend/favorite-properties/FavoritePropertiesStorage.js.map +1 -1
  43. package/lib/cjs/presentation-frontend/selection/HiliteRules.json +172 -172
  44. package/lib/cjs/presentation-frontend/selection/HiliteSetProvider.d.ts +52 -52
  45. package/lib/cjs/presentation-frontend/selection/HiliteSetProvider.js +97 -97
  46. package/lib/cjs/presentation-frontend/selection/HiliteSetProvider.js.map +1 -1
  47. package/lib/cjs/presentation-frontend/selection/ISelectionProvider.d.ts +19 -19
  48. package/lib/cjs/presentation-frontend/selection/ISelectionProvider.js +9 -9
  49. package/lib/cjs/presentation-frontend/selection/ISelectionProvider.js.map +1 -1
  50. package/lib/cjs/presentation-frontend/selection/SelectionChangeEvent.d.ts +52 -52
  51. package/lib/cjs/presentation-frontend/selection/SelectionChangeEvent.js +33 -33
  52. package/lib/cjs/presentation-frontend/selection/SelectionChangeEvent.js.map +1 -1
  53. package/lib/cjs/presentation-frontend/selection/SelectionHandler.d.ts +103 -103
  54. package/lib/cjs/presentation-frontend/selection/SelectionHandler.js +108 -108
  55. package/lib/cjs/presentation-frontend/selection/SelectionHandler.js.map +1 -1
  56. package/lib/cjs/presentation-frontend/selection/SelectionHelper.d.ts +14 -14
  57. package/lib/cjs/presentation-frontend/selection/SelectionHelper.js +37 -37
  58. package/lib/cjs/presentation-frontend/selection/SelectionHelper.js.map +1 -1
  59. package/lib/cjs/presentation-frontend/selection/SelectionManager.d.ts +139 -139
  60. package/lib/cjs/presentation-frontend/selection/SelectionManager.js +414 -414
  61. package/lib/cjs/presentation-frontend/selection/SelectionManager.js.map +1 -1
  62. package/lib/cjs/presentation-frontend/selection/SelectionScopesManager.d.ts +59 -59
  63. package/lib/cjs/presentation-frontend/selection/SelectionScopesManager.js +91 -91
  64. package/lib/cjs/presentation-frontend/selection/SelectionScopesManager.js.map +1 -1
  65. package/lib/cjs/presentation-frontend.d.ts +34 -34
  66. package/lib/cjs/presentation-frontend.js +50 -50
  67. package/lib/cjs/presentation-frontend.js.map +1 -1
  68. package/lib/esm/presentation-frontend/ConnectivityInformationProvider.d.ts +29 -29
  69. package/lib/esm/presentation-frontend/ConnectivityInformationProvider.js +43 -43
  70. package/lib/esm/presentation-frontend/ConnectivityInformationProvider.js.map +1 -1
  71. package/lib/esm/presentation-frontend/Diagnostics.d.ts +14 -14
  72. package/lib/esm/presentation-frontend/Diagnostics.js +56 -56
  73. package/lib/esm/presentation-frontend/Diagnostics.js.map +1 -1
  74. package/lib/esm/presentation-frontend/FrontendLoggerCategory.d.ts +12 -12
  75. package/lib/esm/presentation-frontend/FrontendLoggerCategory.js +17 -17
  76. package/lib/esm/presentation-frontend/FrontendLoggerCategory.js.map +1 -1
  77. package/lib/esm/presentation-frontend/IpcRequestsHandler.d.ts +10 -10
  78. package/lib/esm/presentation-frontend/IpcRequestsHandler.d.ts.map +1 -1
  79. package/lib/esm/presentation-frontend/IpcRequestsHandler.js +37 -38
  80. package/lib/esm/presentation-frontend/IpcRequestsHandler.js.map +1 -1
  81. package/lib/esm/presentation-frontend/LocalizationHelper.d.ts +10 -10
  82. package/lib/esm/presentation-frontend/LocalizationHelper.js +27 -27
  83. package/lib/esm/presentation-frontend/LocalizationHelper.js.map +1 -1
  84. package/lib/esm/presentation-frontend/Presentation.d.ts +75 -75
  85. package/lib/esm/presentation-frontend/Presentation.js +158 -158
  86. package/lib/esm/presentation-frontend/Presentation.js.map +1 -1
  87. package/lib/esm/presentation-frontend/PresentationManager.d.ts +186 -180
  88. package/lib/esm/presentation-frontend/PresentationManager.d.ts.map +1 -1
  89. package/lib/esm/presentation-frontend/PresentationManager.js +431 -414
  90. package/lib/esm/presentation-frontend/PresentationManager.js.map +1 -1
  91. package/lib/esm/presentation-frontend/RulesetManager.d.ts +63 -60
  92. package/lib/esm/presentation-frontend/RulesetManager.d.ts.map +1 -1
  93. package/lib/esm/presentation-frontend/RulesetManager.js +81 -81
  94. package/lib/esm/presentation-frontend/RulesetManager.js.map +1 -1
  95. package/lib/esm/presentation-frontend/RulesetVariablesManager.d.ts +143 -143
  96. package/lib/esm/presentation-frontend/RulesetVariablesManager.js +191 -191
  97. package/lib/esm/presentation-frontend/RulesetVariablesManager.js.map +1 -1
  98. package/lib/esm/presentation-frontend/StateTracker.d.ts +38 -23
  99. package/lib/esm/presentation-frontend/StateTracker.d.ts.map +1 -1
  100. package/lib/esm/presentation-frontend/StateTracker.js +125 -70
  101. package/lib/esm/presentation-frontend/StateTracker.js.map +1 -1
  102. package/lib/esm/presentation-frontend/favorite-properties/FavoritePropertiesManager.d.ts +132 -132
  103. package/lib/esm/presentation-frontend/favorite-properties/FavoritePropertiesManager.js +519 -519
  104. package/lib/esm/presentation-frontend/favorite-properties/FavoritePropertiesManager.js.map +1 -1
  105. package/lib/esm/presentation-frontend/favorite-properties/FavoritePropertiesStorage.d.ts +111 -111
  106. package/lib/esm/presentation-frontend/favorite-properties/FavoritePropertiesStorage.js +285 -285
  107. package/lib/esm/presentation-frontend/favorite-properties/FavoritePropertiesStorage.js.map +1 -1
  108. package/lib/esm/presentation-frontend/selection/HiliteRules.json +172 -172
  109. package/lib/esm/presentation-frontend/selection/HiliteSetProvider.d.ts +52 -52
  110. package/lib/esm/presentation-frontend/selection/HiliteSetProvider.js +93 -93
  111. package/lib/esm/presentation-frontend/selection/HiliteSetProvider.js.map +1 -1
  112. package/lib/esm/presentation-frontend/selection/ISelectionProvider.d.ts +19 -19
  113. package/lib/esm/presentation-frontend/selection/ISelectionProvider.js +8 -8
  114. package/lib/esm/presentation-frontend/selection/ISelectionProvider.js.map +1 -1
  115. package/lib/esm/presentation-frontend/selection/SelectionChangeEvent.d.ts +52 -52
  116. package/lib/esm/presentation-frontend/selection/SelectionChangeEvent.js +29 -29
  117. package/lib/esm/presentation-frontend/selection/SelectionChangeEvent.js.map +1 -1
  118. package/lib/esm/presentation-frontend/selection/SelectionHandler.d.ts +103 -103
  119. package/lib/esm/presentation-frontend/selection/SelectionHandler.js +104 -104
  120. package/lib/esm/presentation-frontend/selection/SelectionHandler.js.map +1 -1
  121. package/lib/esm/presentation-frontend/selection/SelectionHelper.d.ts +14 -14
  122. package/lib/esm/presentation-frontend/selection/SelectionHelper.js +33 -33
  123. package/lib/esm/presentation-frontend/selection/SelectionHelper.js.map +1 -1
  124. package/lib/esm/presentation-frontend/selection/SelectionManager.d.ts +139 -139
  125. package/lib/esm/presentation-frontend/selection/SelectionManager.js +409 -409
  126. package/lib/esm/presentation-frontend/selection/SelectionManager.js.map +1 -1
  127. package/lib/esm/presentation-frontend/selection/SelectionScopesManager.d.ts +59 -59
  128. package/lib/esm/presentation-frontend/selection/SelectionScopesManager.js +85 -85
  129. package/lib/esm/presentation-frontend/selection/SelectionScopesManager.js.map +1 -1
  130. package/lib/esm/presentation-frontend.d.ts +34 -34
  131. package/lib/esm/presentation-frontend.js +38 -38
  132. package/lib/esm/presentation-frontend.js.map +1 -1
  133. package/package.json +14 -14
@@ -1,39 +1,38 @@
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 { IpcApp } from "@itwin/core-frontend";
6
- import { NodeKey, PRESENTATION_IPC_CHANNEL_NAME, RulesetVariable, } from "@itwin/presentation-common";
7
- /** @internal */
8
- export class IpcRequestsHandler {
9
- constructor(clientId) {
10
- this.clientId = clientId;
11
- }
12
- async call(methodName, ...args) {
13
- return IpcApp.callIpcChannel(PRESENTATION_IPC_CHANNEL_NAME, methodName, ...args);
14
- }
15
- async setRulesetVariable(params) {
16
- const jsonParams = {
17
- ...params,
18
- clientId: this.clientId,
19
- variable: RulesetVariable.toJSON(params.variable),
20
- };
21
- return this.call("setRulesetVariable", jsonParams);
22
- }
23
- async unsetRulesetVariable(params) {
24
- const jsonParams = {
25
- ...params,
26
- clientId: this.clientId,
27
- };
28
- return this.call("unsetRulesetVariable", jsonParams);
29
- }
30
- async updateHierarchyState(params) {
31
- const jsonParams = {
32
- ...params,
33
- clientId: this.clientId,
34
- nodeKeys: params.nodeKeys.map(NodeKey.toJSON),
35
- };
36
- return this.call("updateHierarchyState", jsonParams);
37
- }
38
- }
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 { IpcApp } from "@itwin/core-frontend";
6
+ import { PRESENTATION_IPC_CHANNEL_NAME, RulesetVariable, } from "@itwin/presentation-common";
7
+ /** @internal */
8
+ export class IpcRequestsHandler {
9
+ constructor(clientId) {
10
+ this.clientId = clientId;
11
+ }
12
+ async call(methodName, ...args) {
13
+ return IpcApp.callIpcChannel(PRESENTATION_IPC_CHANNEL_NAME, methodName, ...args);
14
+ }
15
+ async setRulesetVariable(params) {
16
+ const jsonParams = {
17
+ ...params,
18
+ clientId: this.clientId,
19
+ variable: RulesetVariable.toJSON(params.variable),
20
+ };
21
+ return this.call("setRulesetVariable", jsonParams);
22
+ }
23
+ async unsetRulesetVariable(params) {
24
+ const jsonParams = {
25
+ ...params,
26
+ clientId: this.clientId,
27
+ };
28
+ return this.call("unsetRulesetVariable", jsonParams);
29
+ }
30
+ async updateHierarchyState(params) {
31
+ const jsonParams = {
32
+ ...params,
33
+ clientId: this.clientId,
34
+ };
35
+ return this.call("updateHierarchyState", jsonParams);
36
+ }
37
+ }
39
38
  //# sourceMappingURL=IpcRequestsHandler.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"IpcRequestsHandler.js","sourceRoot":"","sources":["../../../src/presentation-frontend/IpcRequestsHandler.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAG/F,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EACL,OAAO,EAAe,6BAA6B,EAA4B,eAAe,GAE/F,MAAM,4BAA4B,CAAC;AAEpC,gBAAgB;AAChB,MAAM,OAAO,kBAAkB;IAG7B,YAAY,QAAgB;QAC1B,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;IAC3B,CAAC;IAEO,KAAK,CAAC,IAAI,CAAqD,UAAa,EAAE,GAAG,IAA6C;QACpI,OAAO,MAAM,CAAC,cAAc,CAAC,6BAA6B,EAAE,UAAU,EAAE,GAAG,IAAI,CAAC,CAAC;IACnF,CAAC;IAEM,KAAK,CAAC,kBAAkB,CAAC,MAAmE;QACjG,MAAM,UAAU,GAAkD;YAChE,GAAG,MAAM;YACT,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,QAAQ,EAAE,eAAe,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC;SAClD,CAAC;QACF,OAAO,IAAI,CAAC,IAAI,CAAC,oBAAoB,EAAE,UAAU,CAAC,CAAC;IACrD,CAAC;IAEM,KAAK,CAAC,oBAAoB,CAAC,MAAoD;QACpF,MAAM,UAAU,GAA+B;YAC7C,GAAG,MAAM;YACT,QAAQ,EAAE,IAAI,CAAC,QAAQ;SACxB,CAAC;QACF,OAAO,IAAI,CAAC,IAAI,CAAC,sBAAsB,EAAE,UAAU,CAAC,CAAC;IACvD,CAAC;IAEM,KAAK,CAAC,oBAAoB,CAAC,MAA6D;QAC7F,MAAM,UAAU,GAA4C;YAC1D,GAAG,MAAM;YACT,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,QAAQ,EAAE,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,OAAO,CAAC,MAAM,CAAC;SAC9C,CAAC;QACF,OAAO,IAAI,CAAC,IAAI,CAAC,sBAAsB,EAAE,UAAU,CAAC,CAAC;IACvD,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 { AsyncMethodsOf, PromiseReturnType } from \"@itwin/core-bentley\";\r\nimport { IpcApp } from \"@itwin/core-frontend\";\r\nimport {\r\n NodeKey, NodeKeyJSON, PRESENTATION_IPC_CHANNEL_NAME, PresentationIpcInterface, RulesetVariable, RulesetVariableJSON, SetRulesetVariableParams,\r\n UnsetRulesetVariableParams, UpdateHierarchyStateParams,\r\n} from \"@itwin/presentation-common\";\r\n\r\n/** @internal */\r\nexport class IpcRequestsHandler {\r\n public readonly clientId: string;\r\n\r\n constructor(clientId: string) {\r\n this.clientId = clientId;\r\n }\r\n\r\n private async call<T extends AsyncMethodsOf<PresentationIpcInterface>>(methodName: T, ...args: Parameters<PresentationIpcInterface[T]>): Promise<PromiseReturnType<PresentationIpcInterface[T]>> {\r\n return IpcApp.callIpcChannel(PRESENTATION_IPC_CHANNEL_NAME, methodName, ...args);\r\n }\r\n\r\n public async setRulesetVariable(params: Omit<SetRulesetVariableParams<RulesetVariable>, \"clientId\">) {\r\n const jsonParams: SetRulesetVariableParams<RulesetVariableJSON> = {\r\n ...params,\r\n clientId: this.clientId,\r\n variable: RulesetVariable.toJSON(params.variable),\r\n };\r\n return this.call(\"setRulesetVariable\", jsonParams);\r\n }\r\n\r\n public async unsetRulesetVariable(params: Omit<UnsetRulesetVariableParams, \"clientId\">) {\r\n const jsonParams: UnsetRulesetVariableParams = {\r\n ...params,\r\n clientId: this.clientId,\r\n };\r\n return this.call(\"unsetRulesetVariable\", jsonParams);\r\n }\r\n\r\n public async updateHierarchyState(params: Omit<UpdateHierarchyStateParams<NodeKey>, \"clientId\">) {\r\n const jsonParams: UpdateHierarchyStateParams<NodeKeyJSON> = {\r\n ...params,\r\n clientId: this.clientId,\r\n nodeKeys: params.nodeKeys.map(NodeKey.toJSON),\r\n };\r\n return this.call(\"updateHierarchyState\", jsonParams);\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"IpcRequestsHandler.js","sourceRoot":"","sources":["../../../src/presentation-frontend/IpcRequestsHandler.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAG/F,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EACI,6BAA6B,EAA4B,eAAe,GAElF,MAAM,4BAA4B,CAAC;AAEpC,gBAAgB;AAChB,MAAM,OAAO,kBAAkB;IAG7B,YAAY,QAAgB;QAC1B,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;IAC3B,CAAC;IAEO,KAAK,CAAC,IAAI,CAAqD,UAAa,EAAE,GAAG,IAA6C;QACpI,OAAO,MAAM,CAAC,cAAc,CAAC,6BAA6B,EAAE,UAAU,EAAE,GAAG,IAAI,CAAC,CAAC;IACnF,CAAC;IAEM,KAAK,CAAC,kBAAkB,CAAC,MAAmE;QACjG,MAAM,UAAU,GAAkD;YAChE,GAAG,MAAM;YACT,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,QAAQ,EAAE,eAAe,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC;SAClD,CAAC;QACF,OAAO,IAAI,CAAC,IAAI,CAAC,oBAAoB,EAAE,UAAU,CAAC,CAAC;IACrD,CAAC;IAEM,KAAK,CAAC,oBAAoB,CAAC,MAAoD;QACpF,MAAM,UAAU,GAA+B;YAC7C,GAAG,MAAM;YACT,QAAQ,EAAE,IAAI,CAAC,QAAQ;SACxB,CAAC;QACF,OAAO,IAAI,CAAC,IAAI,CAAC,sBAAsB,EAAE,UAAU,CAAC,CAAC;IACvD,CAAC;IAEM,KAAK,CAAC,oBAAoB,CAAC,MAA6D;QAC7F,MAAM,UAAU,GAAwC;YACtD,GAAG,MAAM;YACT,QAAQ,EAAE,IAAI,CAAC,QAAQ;SACxB,CAAC;QACF,OAAO,IAAI,CAAC,IAAI,CAAC,sBAAsB,EAAE,UAAU,CAAC,CAAC;IACvD,CAAC;CACF","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n\nimport { AsyncMethodsOf, PromiseReturnType } from \"@itwin/core-bentley\";\nimport { IpcApp } from \"@itwin/core-frontend\";\nimport {\n NodeKey, PRESENTATION_IPC_CHANNEL_NAME, PresentationIpcInterface, RulesetVariable, RulesetVariableJSON, SetRulesetVariableParams,\n UnsetRulesetVariableParams, UpdateHierarchyStateParams,\n} from \"@itwin/presentation-common\";\n\n/** @internal */\nexport class IpcRequestsHandler {\n public readonly clientId: string;\n\n constructor(clientId: string) {\n this.clientId = clientId;\n }\n\n private async call<T extends AsyncMethodsOf<PresentationIpcInterface>>(methodName: T, ...args: Parameters<PresentationIpcInterface[T]>): Promise<PromiseReturnType<PresentationIpcInterface[T]>> {\n return IpcApp.callIpcChannel(PRESENTATION_IPC_CHANNEL_NAME, methodName, ...args);\n }\n\n public async setRulesetVariable(params: Omit<SetRulesetVariableParams<RulesetVariable>, \"clientId\">) {\n const jsonParams: SetRulesetVariableParams<RulesetVariableJSON> = {\n ...params,\n clientId: this.clientId,\n variable: RulesetVariable.toJSON(params.variable),\n };\n return this.call(\"setRulesetVariable\", jsonParams);\n }\n\n public async unsetRulesetVariable(params: Omit<UnsetRulesetVariableParams, \"clientId\">) {\n const jsonParams: UnsetRulesetVariableParams = {\n ...params,\n clientId: this.clientId,\n };\n return this.call(\"unsetRulesetVariable\", jsonParams);\n }\n\n public async updateHierarchyState(params: Omit<UpdateHierarchyStateParams<NodeKey>, \"clientId\">) {\n const jsonParams: UpdateHierarchyStateParams<NodeKey> = {\n ...params,\n clientId: this.clientId,\n };\n return this.call(\"updateHierarchyState\", jsonParams);\n }\n}\n"]}
@@ -1,11 +1,11 @@
1
- import { LocalizationHelper } from "@itwin/presentation-common";
2
- /** @internal */
3
- export declare class FrontendLocalizationHelper extends LocalizationHelper {
4
- private _lang;
5
- constructor(lang?: string);
6
- get locale(): string | undefined;
7
- set locale(locale: string | undefined);
8
- static registerNamespaces(): Promise<void>;
9
- static unregisterNamespaces(): void;
10
- }
1
+ import { LocalizationHelper } from "@itwin/presentation-common";
2
+ /** @internal */
3
+ export declare class FrontendLocalizationHelper extends LocalizationHelper {
4
+ private _lang;
5
+ constructor(lang?: string);
6
+ get locale(): string | undefined;
7
+ set locale(locale: string | undefined);
8
+ static registerNamespaces(): Promise<void>;
9
+ static unregisterNamespaces(): void;
10
+ }
11
11
  //# sourceMappingURL=LocalizationHelper.d.ts.map
@@ -1,28 +1,28 @@
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 { LocalizationHelper } from "@itwin/presentation-common";
6
- import { Presentation } from "./Presentation";
7
- const NAMESPACES = ["BisCore", "ECPresentation", "RulesEngine"];
8
- /** @internal */
9
- export class FrontendLocalizationHelper extends LocalizationHelper {
10
- constructor(lang) {
11
- super({ getLocalizedString: (key) => Presentation.localization.getLocalizedString(key, { defaultValue: key, lng: this._lang }) });
12
- this._lang = lang;
13
- }
14
- get locale() {
15
- return this._lang;
16
- }
17
- set locale(locale) {
18
- this._lang = locale;
19
- }
20
- static async registerNamespaces() {
21
- const localizationPromises = NAMESPACES.map(async (namespace) => Presentation.localization.registerNamespace(namespace));
22
- await Promise.all(localizationPromises);
23
- }
24
- static unregisterNamespaces() {
25
- NAMESPACES.map((namespace) => Presentation.localization.unregisterNamespace(namespace));
26
- }
27
- }
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 { LocalizationHelper } from "@itwin/presentation-common";
6
+ import { Presentation } from "./Presentation";
7
+ const NAMESPACES = ["BisCore", "ECPresentation", "RulesEngine"];
8
+ /** @internal */
9
+ export class FrontendLocalizationHelper extends LocalizationHelper {
10
+ constructor(lang) {
11
+ super({ getLocalizedString: (key) => Presentation.localization.getLocalizedString(key, { defaultValue: key, lng: this._lang }) });
12
+ this._lang = lang;
13
+ }
14
+ get locale() {
15
+ return this._lang;
16
+ }
17
+ set locale(locale) {
18
+ this._lang = locale;
19
+ }
20
+ static async registerNamespaces() {
21
+ const localizationPromises = NAMESPACES.map(async (namespace) => Presentation.localization.registerNamespace(namespace));
22
+ await Promise.all(localizationPromises);
23
+ }
24
+ static unregisterNamespaces() {
25
+ NAMESPACES.map((namespace) => Presentation.localization.unregisterNamespace(namespace));
26
+ }
27
+ }
28
28
  //# sourceMappingURL=LocalizationHelper.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"LocalizationHelper.js","sourceRoot":"","sources":["../../../src/presentation-frontend/LocalizationHelper.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,MAAM,UAAU,GAAG,CAAC,SAAS,EAAE,gBAAgB,EAAE,aAAa,CAAC,CAAC;AAEhE,gBAAgB;AAChB,MAAM,OAAO,0BAA2B,SAAQ,kBAAkB;IAEhE,YAAY,IAAa;QACvB,KAAK,CAAC,EAAE,kBAAkB,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,YAAY,CAAC,YAAY,CAAC,kBAAkB,CAAC,GAAG,EAAE,EAAE,YAAY,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,CAAC,KAAK,EAAE,CAAC,EAAE,CAAC,CAAC;QAClI,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC;IACpB,CAAC;IAED,IAAW,MAAM;QACf,OAAO,IAAI,CAAC,KAAK,CAAC;IACpB,CAAC;IACD,IAAW,MAAM,CAAC,MAA0B;QAC1C,IAAI,CAAC,KAAK,GAAG,MAAM,CAAC;IACtB,CAAC;IAEM,MAAM,CAAC,KAAK,CAAC,kBAAkB;QACpC,MAAM,oBAAoB,GAAG,UAAU,CAAC,GAAG,CAAC,KAAK,EAAE,SAAS,EAAE,EAAE,CAAC,YAAY,CAAC,YAAY,CAAC,iBAAiB,CAAC,SAAS,CAAC,CAAC,CAAC;QACzH,MAAM,OAAO,CAAC,GAAG,CAAC,oBAAoB,CAAC,CAAC;IAC1C,CAAC;IAEM,MAAM,CAAC,oBAAoB;QAChC,UAAU,CAAC,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,YAAY,CAAC,YAAY,CAAC,mBAAmB,CAAC,SAAS,CAAC,CAAC,CAAC;IAC1F,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\nimport { LocalizationHelper } from \"@itwin/presentation-common\";\r\nimport { Presentation } from \"./Presentation\";\r\n\r\nconst NAMESPACES = [\"BisCore\", \"ECPresentation\", \"RulesEngine\"];\r\n\r\n/** @internal */\r\nexport class FrontendLocalizationHelper extends LocalizationHelper {\r\n private _lang: string | undefined;\r\n constructor(lang?: string) {\r\n super({ getLocalizedString: (key) => Presentation.localization.getLocalizedString(key, { defaultValue: key, lng: this._lang }) });\r\n this._lang = lang;\r\n }\r\n\r\n public get locale() {\r\n return this._lang;\r\n }\r\n public set locale(locale: string | undefined) {\r\n this._lang = locale;\r\n }\r\n\r\n public static async registerNamespaces() {\r\n const localizationPromises = NAMESPACES.map(async (namespace) => Presentation.localization.registerNamespace(namespace));\r\n await Promise.all(localizationPromises);\r\n }\r\n\r\n public static unregisterNamespaces() {\r\n NAMESPACES.map((namespace) => Presentation.localization.unregisterNamespace(namespace));\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"LocalizationHelper.js","sourceRoot":"","sources":["../../../src/presentation-frontend/LocalizationHelper.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,MAAM,UAAU,GAAG,CAAC,SAAS,EAAE,gBAAgB,EAAE,aAAa,CAAC,CAAC;AAEhE,gBAAgB;AAChB,MAAM,OAAO,0BAA2B,SAAQ,kBAAkB;IAEhE,YAAY,IAAa;QACvB,KAAK,CAAC,EAAE,kBAAkB,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,YAAY,CAAC,YAAY,CAAC,kBAAkB,CAAC,GAAG,EAAE,EAAE,YAAY,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,CAAC,KAAK,EAAE,CAAC,EAAE,CAAC,CAAC;QAClI,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC;IACpB,CAAC;IAED,IAAW,MAAM;QACf,OAAO,IAAI,CAAC,KAAK,CAAC;IACpB,CAAC;IACD,IAAW,MAAM,CAAC,MAA0B;QAC1C,IAAI,CAAC,KAAK,GAAG,MAAM,CAAC;IACtB,CAAC;IAEM,MAAM,CAAC,KAAK,CAAC,kBAAkB;QACpC,MAAM,oBAAoB,GAAG,UAAU,CAAC,GAAG,CAAC,KAAK,EAAE,SAAS,EAAE,EAAE,CAAC,YAAY,CAAC,YAAY,CAAC,iBAAiB,CAAC,SAAS,CAAC,CAAC,CAAC;QACzH,MAAM,OAAO,CAAC,GAAG,CAAC,oBAAoB,CAAC,CAAC;IAC1C,CAAC;IAEM,MAAM,CAAC,oBAAoB;QAChC,UAAU,CAAC,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,YAAY,CAAC,YAAY,CAAC,mBAAmB,CAAC,SAAS,CAAC,CAAC,CAAC;IAC1F,CAAC;CACF","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport { LocalizationHelper } from \"@itwin/presentation-common\";\nimport { Presentation } from \"./Presentation\";\n\nconst NAMESPACES = [\"BisCore\", \"ECPresentation\", \"RulesEngine\"];\n\n/** @internal */\nexport class FrontendLocalizationHelper extends LocalizationHelper {\n private _lang: string | undefined;\n constructor(lang?: string) {\n super({ getLocalizedString: (key) => Presentation.localization.getLocalizedString(key, { defaultValue: key, lng: this._lang }) });\n this._lang = lang;\n }\n\n public get locale() {\n return this._lang;\n }\n public set locale(locale: string | undefined) {\n this._lang = locale;\n }\n\n public static async registerNamespaces() {\n const localizationPromises = NAMESPACES.map(async (namespace) => Presentation.localization.registerNamespace(namespace));\n await Promise.all(localizationPromises);\n }\n\n public static unregisterNamespaces() {\n NAMESPACES.map((namespace) => Presentation.localization.unregisterNamespace(namespace));\n }\n}\n"]}
@@ -1,76 +1,76 @@
1
- /** @packageDocumentation
2
- * @module Core
3
- */
4
- import { Localization } from "@itwin/core-common";
5
- import { FavoritePropertiesManager, FavoritePropertiesManagerProps } from "./favorite-properties/FavoritePropertiesManager";
6
- import { PresentationManager, PresentationManagerProps } from "./PresentationManager";
7
- import { SelectionManager, SelectionManagerProps } from "./selection/SelectionManager";
8
- /**
9
- * Props for initializing [[Presentation]].
10
- * @public
11
- */
12
- export interface PresentationProps {
13
- /** Props for [[PresentationManager]]. */
14
- presentation?: PresentationManagerProps;
15
- /** Props for [[SelectionManager]]. */
16
- selection?: SelectionManagerProps;
17
- /** Props for [[FavoritePropertiesManager]]. */
18
- favorites?: FavoritePropertiesManagerProps;
19
- }
20
- /**
21
- * Static class used to statically set up Presentation library for the frontend.
22
- * Basically what it does is:
23
- * - Create a singleton [[PresentationManager]] instance
24
- * - Create a singleton [[SelectionManager]] instance
25
- * - Create a singleton [[FavoritePropertiesManager]]] instance
26
- *
27
- * @public
28
- */
29
- export declare class Presentation {
30
- private constructor();
31
- /**
32
- * Initializes Presentation library for the frontend.
33
- *
34
- * Example:
35
- * ``` ts
36
- * [[include:Presentation.Frontend.Initialization]]
37
- * ```
38
- *
39
- * The method should be called after a call to [IModelApp.startup]($core-frontend).
40
- */
41
- static initialize(props?: PresentationProps): Promise<void>;
42
- /**
43
- * Terminates Presentation library frontend. This method should be called
44
- * before a call to [IModelApp.shutdown]($core-frontend)
45
- */
46
- static terminate(): void;
47
- /**
48
- * Registers an additional handler which will be invoked during Presentation library frontend
49
- * initialization.
50
- *
51
- * @internal
52
- */
53
- static registerInitializationHandler(handler: () => Promise<() => void>): void;
54
- /** The singleton [[PresentationManager]] */
55
- static get presentation(): PresentationManager;
56
- /** @internal */
57
- static setPresentationManager(value: PresentationManager): void;
58
- /** The singleton [[SelectionManager]] */
59
- static get selection(): SelectionManager;
60
- /** @internal */
61
- static setSelectionManager(value: SelectionManager): void;
62
- /**
63
- * The singleton [[FavoritePropertiesManager]]
64
- * @public
65
- */
66
- static get favoriteProperties(): FavoritePropertiesManager;
67
- /** @internal */
68
- static setFavoritePropertiesManager(value: FavoritePropertiesManager): void;
69
- /**
70
- * The localization manager used by Presentation frontend. Returns the result of `IModelApp.i18n`.
71
- */
72
- static get localization(): Localization;
73
- /** @internal */
74
- static setLocalization(value: Localization): void;
75
- }
1
+ /** @packageDocumentation
2
+ * @module Core
3
+ */
4
+ import { Localization } from "@itwin/core-common";
5
+ import { FavoritePropertiesManager, FavoritePropertiesManagerProps } from "./favorite-properties/FavoritePropertiesManager";
6
+ import { PresentationManager, PresentationManagerProps } from "./PresentationManager";
7
+ import { SelectionManager, SelectionManagerProps } from "./selection/SelectionManager";
8
+ /**
9
+ * Props for initializing [[Presentation]].
10
+ * @public
11
+ */
12
+ export interface PresentationProps {
13
+ /** Props for [[PresentationManager]]. */
14
+ presentation?: PresentationManagerProps;
15
+ /** Props for [[SelectionManager]]. */
16
+ selection?: SelectionManagerProps;
17
+ /** Props for [[FavoritePropertiesManager]]. */
18
+ favorites?: FavoritePropertiesManagerProps;
19
+ }
20
+ /**
21
+ * Static class used to statically set up Presentation library for the frontend.
22
+ * Basically what it does is:
23
+ * - Create a singleton [[PresentationManager]] instance
24
+ * - Create a singleton [[SelectionManager]] instance
25
+ * - Create a singleton [[FavoritePropertiesManager]]] instance
26
+ *
27
+ * @public
28
+ */
29
+ export declare class Presentation {
30
+ private constructor();
31
+ /**
32
+ * Initializes Presentation library for the frontend.
33
+ *
34
+ * Example:
35
+ * ``` ts
36
+ * [[include:Presentation.Frontend.Initialization]]
37
+ * ```
38
+ *
39
+ * The method should be called after a call to [IModelApp.startup]($core-frontend).
40
+ */
41
+ static initialize(props?: PresentationProps): Promise<void>;
42
+ /**
43
+ * Terminates Presentation library frontend. This method should be called
44
+ * before a call to [IModelApp.shutdown]($core-frontend)
45
+ */
46
+ static terminate(): void;
47
+ /**
48
+ * Registers an additional handler which will be invoked during Presentation library frontend
49
+ * initialization.
50
+ *
51
+ * @internal
52
+ */
53
+ static registerInitializationHandler(handler: () => Promise<() => void>): void;
54
+ /** The singleton [[PresentationManager]] */
55
+ static get presentation(): PresentationManager;
56
+ /** @internal */
57
+ static setPresentationManager(value: PresentationManager): void;
58
+ /** The singleton [[SelectionManager]] */
59
+ static get selection(): SelectionManager;
60
+ /** @internal */
61
+ static setSelectionManager(value: SelectionManager): void;
62
+ /**
63
+ * The singleton [[FavoritePropertiesManager]]
64
+ * @public
65
+ */
66
+ static get favoriteProperties(): FavoritePropertiesManager;
67
+ /** @internal */
68
+ static setFavoritePropertiesManager(value: FavoritePropertiesManager): void;
69
+ /**
70
+ * The localization manager used by Presentation frontend. Returns the result of `IModelApp.i18n`.
71
+ */
72
+ static get localization(): Localization;
73
+ /** @internal */
74
+ static setLocalization(value: Localization): void;
75
+ }
76
76
  //# sourceMappingURL=Presentation.d.ts.map