@itwin/presentation-common 5.0.0-dev.56 → 5.0.0-dev.58

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 (250) hide show
  1. package/Ruleset.schema.json +3 -258
  2. package/lib/cjs/presentation-common/AsyncTasks.js +1 -3
  3. package/lib/cjs/presentation-common/AsyncTasks.js.map +1 -1
  4. package/lib/cjs/presentation-common/EC.d.ts +5 -80
  5. package/lib/cjs/presentation-common/EC.d.ts.map +1 -1
  6. package/lib/cjs/presentation-common/EC.js +1 -97
  7. package/lib/cjs/presentation-common/EC.js.map +1 -1
  8. package/lib/cjs/presentation-common/ElementProperties.js +16 -9
  9. package/lib/cjs/presentation-common/ElementProperties.js.map +1 -1
  10. package/lib/cjs/presentation-common/KeySet.d.ts +2 -2
  11. package/lib/cjs/presentation-common/KeySet.d.ts.map +1 -1
  12. package/lib/cjs/presentation-common/KeySet.js +9 -11
  13. package/lib/cjs/presentation-common/KeySet.js.map +1 -1
  14. package/lib/cjs/presentation-common/KoqPropertyValueFormatter.js +3 -0
  15. package/lib/cjs/presentation-common/KoqPropertyValueFormatter.js.map +1 -1
  16. package/lib/cjs/presentation-common/LabelDefinition.d.ts +0 -48
  17. package/lib/cjs/presentation-common/LabelDefinition.d.ts.map +1 -1
  18. package/lib/cjs/presentation-common/LabelDefinition.js +1 -44
  19. package/lib/cjs/presentation-common/LabelDefinition.js.map +1 -1
  20. package/lib/cjs/presentation-common/LocalizationHelper.js +1 -0
  21. package/lib/cjs/presentation-common/LocalizationHelper.js.map +1 -1
  22. package/lib/cjs/presentation-common/PresentationRpcInterface.d.ts +7 -9
  23. package/lib/cjs/presentation-common/PresentationRpcInterface.d.ts.map +1 -1
  24. package/lib/cjs/presentation-common/PresentationRpcInterface.js +21 -17
  25. package/lib/cjs/presentation-common/PresentationRpcInterface.js.map +1 -1
  26. package/lib/cjs/presentation-common/RegisteredRuleset.js +3 -0
  27. package/lib/cjs/presentation-common/RegisteredRuleset.js.map +1 -1
  28. package/lib/cjs/presentation-common/RpcRequestsHandler.d.ts +7 -7
  29. package/lib/cjs/presentation-common/RpcRequestsHandler.d.ts.map +1 -1
  30. package/lib/cjs/presentation-common/RpcRequestsHandler.js +6 -1
  31. package/lib/cjs/presentation-common/RpcRequestsHandler.js.map +1 -1
  32. package/lib/cjs/presentation-common/RulesetVariables.d.ts +1 -46
  33. package/lib/cjs/presentation-common/RulesetVariables.d.ts.map +1 -1
  34. package/lib/cjs/presentation-common/RulesetVariables.js.map +1 -1
  35. package/lib/cjs/presentation-common/Update.d.ts +2 -79
  36. package/lib/cjs/presentation-common/Update.d.ts.map +1 -1
  37. package/lib/cjs/presentation-common/Update.js +1 -104
  38. package/lib/cjs/presentation-common/Update.js.map +1 -1
  39. package/lib/cjs/presentation-common/Utils.d.ts +7 -0
  40. package/lib/cjs/presentation-common/Utils.d.ts.map +1 -1
  41. package/lib/cjs/presentation-common/Utils.js +23 -0
  42. package/lib/cjs/presentation-common/Utils.js.map +1 -1
  43. package/lib/cjs/presentation-common/content/Content.d.ts +0 -7
  44. package/lib/cjs/presentation-common/content/Content.d.ts.map +1 -1
  45. package/lib/cjs/presentation-common/content/Content.js +5 -10
  46. package/lib/cjs/presentation-common/content/Content.js.map +1 -1
  47. package/lib/cjs/presentation-common/content/ContentTraverser.js +20 -12
  48. package/lib/cjs/presentation-common/content/ContentTraverser.js.map +1 -1
  49. package/lib/cjs/presentation-common/content/Descriptor.d.ts +2 -31
  50. package/lib/cjs/presentation-common/content/Descriptor.d.ts.map +1 -1
  51. package/lib/cjs/presentation-common/content/Descriptor.js +50 -15
  52. package/lib/cjs/presentation-common/content/Descriptor.js.map +1 -1
  53. package/lib/cjs/presentation-common/content/Fields.d.ts +4 -10
  54. package/lib/cjs/presentation-common/content/Fields.d.ts.map +1 -1
  55. package/lib/cjs/presentation-common/content/Fields.js +77 -35
  56. package/lib/cjs/presentation-common/content/Fields.js.map +1 -1
  57. package/lib/cjs/presentation-common/content/Item.d.ts +5 -31
  58. package/lib/cjs/presentation-common/content/Item.d.ts.map +1 -1
  59. package/lib/cjs/presentation-common/content/Item.js +24 -48
  60. package/lib/cjs/presentation-common/content/Item.js.map +1 -1
  61. package/lib/cjs/presentation-common/content/Property.d.ts +2 -12
  62. package/lib/cjs/presentation-common/content/Property.d.ts.map +1 -1
  63. package/lib/cjs/presentation-common/content/Property.js +0 -18
  64. package/lib/cjs/presentation-common/content/Property.js.map +1 -1
  65. package/lib/cjs/presentation-common/content/PropertyValueFormatter.js +3 -0
  66. package/lib/cjs/presentation-common/content/PropertyValueFormatter.js.map +1 -1
  67. package/lib/cjs/presentation-common/content/Value.d.ts +0 -106
  68. package/lib/cjs/presentation-common/content/Value.d.ts.map +1 -1
  69. package/lib/cjs/presentation-common/content/Value.js +1 -215
  70. package/lib/cjs/presentation-common/content/Value.js.map +1 -1
  71. package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.d.ts +1 -22
  72. package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.d.ts.map +1 -1
  73. package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.js +0 -23
  74. package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.js.map +1 -1
  75. package/lib/cjs/presentation-common/hierarchy/Key.d.ts +0 -83
  76. package/lib/cjs/presentation-common/hierarchy/Key.d.ts.map +1 -1
  77. package/lib/cjs/presentation-common/hierarchy/Key.js +6 -24
  78. package/lib/cjs/presentation-common/hierarchy/Key.js.map +1 -1
  79. package/lib/cjs/presentation-common/hierarchy/Node.d.ts +2 -106
  80. package/lib/cjs/presentation-common/hierarchy/Node.d.ts.map +1 -1
  81. package/lib/cjs/presentation-common/hierarchy/Node.js +0 -99
  82. package/lib/cjs/presentation-common/hierarchy/Node.js.map +1 -1
  83. package/lib/cjs/presentation-common/hierarchy/NodePathElement.d.ts +1 -67
  84. package/lib/cjs/presentation-common/hierarchy/NodePathElement.d.ts.map +1 -1
  85. package/lib/cjs/presentation-common/hierarchy/NodePathElement.js +0 -117
  86. package/lib/cjs/presentation-common/hierarchy/NodePathElement.js.map +1 -1
  87. package/lib/cjs/presentation-common/rules/Rule.d.ts +0 -14
  88. package/lib/cjs/presentation-common/rules/Rule.d.ts.map +1 -1
  89. package/lib/cjs/presentation-common/rules/Rule.js.map +1 -1
  90. package/lib/cjs/presentation-common/rules/content/ContentSpecification.d.ts +0 -7
  91. package/lib/cjs/presentation-common/rules/content/ContentSpecification.d.ts.map +1 -1
  92. package/lib/cjs/presentation-common/rules/content/ContentSpecification.js.map +1 -1
  93. package/lib/cjs/presentation-common/rules/customization/CustomizationRule.d.ts +1 -5
  94. package/lib/cjs/presentation-common/rules/customization/CustomizationRule.d.ts.map +1 -1
  95. package/lib/cjs/presentation-common/rules/customization/CustomizationRule.js.map +1 -1
  96. package/lib/cjs/presentation-common/rules/customization/GroupingRule.d.ts +2 -28
  97. package/lib/cjs/presentation-common/rules/customization/GroupingRule.d.ts.map +1 -1
  98. package/lib/cjs/presentation-common/rules/customization/GroupingRule.js +1 -15
  99. package/lib/cjs/presentation-common/rules/customization/GroupingRule.js.map +1 -1
  100. package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts +2 -0
  101. package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts.map +1 -1
  102. package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.js.map +1 -1
  103. package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts +0 -9
  104. package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts.map +1 -1
  105. package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js.map +1 -1
  106. package/lib/cjs/presentation-common.d.ts +1 -5
  107. package/lib/cjs/presentation-common.d.ts.map +1 -1
  108. package/lib/cjs/presentation-common.js +2 -5
  109. package/lib/cjs/presentation-common.js.map +1 -1
  110. package/lib/esm/presentation-common/AsyncTasks.js +1 -3
  111. package/lib/esm/presentation-common/AsyncTasks.js.map +1 -1
  112. package/lib/esm/presentation-common/EC.d.ts +5 -80
  113. package/lib/esm/presentation-common/EC.d.ts.map +1 -1
  114. package/lib/esm/presentation-common/EC.js +0 -96
  115. package/lib/esm/presentation-common/EC.js.map +1 -1
  116. package/lib/esm/presentation-common/ElementProperties.js +16 -9
  117. package/lib/esm/presentation-common/ElementProperties.js.map +1 -1
  118. package/lib/esm/presentation-common/KeySet.d.ts +2 -2
  119. package/lib/esm/presentation-common/KeySet.d.ts.map +1 -1
  120. package/lib/esm/presentation-common/KeySet.js +9 -11
  121. package/lib/esm/presentation-common/KeySet.js.map +1 -1
  122. package/lib/esm/presentation-common/KoqPropertyValueFormatter.js +3 -0
  123. package/lib/esm/presentation-common/KoqPropertyValueFormatter.js.map +1 -1
  124. package/lib/esm/presentation-common/LabelDefinition.d.ts +0 -48
  125. package/lib/esm/presentation-common/LabelDefinition.d.ts.map +1 -1
  126. package/lib/esm/presentation-common/LabelDefinition.js +0 -43
  127. package/lib/esm/presentation-common/LabelDefinition.js.map +1 -1
  128. package/lib/esm/presentation-common/LocalizationHelper.js +1 -0
  129. package/lib/esm/presentation-common/LocalizationHelper.js.map +1 -1
  130. package/lib/esm/presentation-common/PresentationRpcInterface.d.ts +7 -9
  131. package/lib/esm/presentation-common/PresentationRpcInterface.d.ts.map +1 -1
  132. package/lib/esm/presentation-common/PresentationRpcInterface.js +21 -17
  133. package/lib/esm/presentation-common/PresentationRpcInterface.js.map +1 -1
  134. package/lib/esm/presentation-common/RegisteredRuleset.js +3 -0
  135. package/lib/esm/presentation-common/RegisteredRuleset.js.map +1 -1
  136. package/lib/esm/presentation-common/RpcRequestsHandler.d.ts +7 -7
  137. package/lib/esm/presentation-common/RpcRequestsHandler.d.ts.map +1 -1
  138. package/lib/esm/presentation-common/RpcRequestsHandler.js +6 -1
  139. package/lib/esm/presentation-common/RpcRequestsHandler.js.map +1 -1
  140. package/lib/esm/presentation-common/RulesetVariables.d.ts +1 -46
  141. package/lib/esm/presentation-common/RulesetVariables.d.ts.map +1 -1
  142. package/lib/esm/presentation-common/RulesetVariables.js.map +1 -1
  143. package/lib/esm/presentation-common/Update.d.ts +2 -79
  144. package/lib/esm/presentation-common/Update.d.ts.map +1 -1
  145. package/lib/esm/presentation-common/Update.js +0 -103
  146. package/lib/esm/presentation-common/Update.js.map +1 -1
  147. package/lib/esm/presentation-common/Utils.d.ts +7 -0
  148. package/lib/esm/presentation-common/Utils.d.ts.map +1 -1
  149. package/lib/esm/presentation-common/Utils.js +22 -0
  150. package/lib/esm/presentation-common/Utils.js.map +1 -1
  151. package/lib/esm/presentation-common/content/Content.d.ts +0 -7
  152. package/lib/esm/presentation-common/content/Content.d.ts.map +1 -1
  153. package/lib/esm/presentation-common/content/Content.js +5 -10
  154. package/lib/esm/presentation-common/content/Content.js.map +1 -1
  155. package/lib/esm/presentation-common/content/ContentTraverser.js +20 -12
  156. package/lib/esm/presentation-common/content/ContentTraverser.js.map +1 -1
  157. package/lib/esm/presentation-common/content/Descriptor.d.ts +2 -31
  158. package/lib/esm/presentation-common/content/Descriptor.d.ts.map +1 -1
  159. package/lib/esm/presentation-common/content/Descriptor.js +50 -15
  160. package/lib/esm/presentation-common/content/Descriptor.js.map +1 -1
  161. package/lib/esm/presentation-common/content/Fields.d.ts +4 -10
  162. package/lib/esm/presentation-common/content/Fields.d.ts.map +1 -1
  163. package/lib/esm/presentation-common/content/Fields.js +77 -35
  164. package/lib/esm/presentation-common/content/Fields.js.map +1 -1
  165. package/lib/esm/presentation-common/content/Item.d.ts +5 -31
  166. package/lib/esm/presentation-common/content/Item.d.ts.map +1 -1
  167. package/lib/esm/presentation-common/content/Item.js +24 -48
  168. package/lib/esm/presentation-common/content/Item.js.map +1 -1
  169. package/lib/esm/presentation-common/content/Property.d.ts +2 -12
  170. package/lib/esm/presentation-common/content/Property.d.ts.map +1 -1
  171. package/lib/esm/presentation-common/content/Property.js +0 -18
  172. package/lib/esm/presentation-common/content/Property.js.map +1 -1
  173. package/lib/esm/presentation-common/content/PropertyValueFormatter.js +3 -0
  174. package/lib/esm/presentation-common/content/PropertyValueFormatter.js.map +1 -1
  175. package/lib/esm/presentation-common/content/Value.d.ts +0 -106
  176. package/lib/esm/presentation-common/content/Value.d.ts.map +1 -1
  177. package/lib/esm/presentation-common/content/Value.js +0 -214
  178. package/lib/esm/presentation-common/content/Value.js.map +1 -1
  179. package/lib/esm/presentation-common/hierarchy/HierarchyLevel.d.ts +1 -22
  180. package/lib/esm/presentation-common/hierarchy/HierarchyLevel.d.ts.map +1 -1
  181. package/lib/esm/presentation-common/hierarchy/HierarchyLevel.js +1 -22
  182. package/lib/esm/presentation-common/hierarchy/HierarchyLevel.js.map +1 -1
  183. package/lib/esm/presentation-common/hierarchy/Key.d.ts +0 -83
  184. package/lib/esm/presentation-common/hierarchy/Key.d.ts.map +1 -1
  185. package/lib/esm/presentation-common/hierarchy/Key.js +6 -24
  186. package/lib/esm/presentation-common/hierarchy/Key.js.map +1 -1
  187. package/lib/esm/presentation-common/hierarchy/Node.d.ts +2 -106
  188. package/lib/esm/presentation-common/hierarchy/Node.d.ts.map +1 -1
  189. package/lib/esm/presentation-common/hierarchy/Node.js +1 -98
  190. package/lib/esm/presentation-common/hierarchy/Node.js.map +1 -1
  191. package/lib/esm/presentation-common/hierarchy/NodePathElement.d.ts +1 -67
  192. package/lib/esm/presentation-common/hierarchy/NodePathElement.d.ts.map +1 -1
  193. package/lib/esm/presentation-common/hierarchy/NodePathElement.js +1 -116
  194. package/lib/esm/presentation-common/hierarchy/NodePathElement.js.map +1 -1
  195. package/lib/esm/presentation-common/rules/Rule.d.ts +0 -14
  196. package/lib/esm/presentation-common/rules/Rule.d.ts.map +1 -1
  197. package/lib/esm/presentation-common/rules/Rule.js.map +1 -1
  198. package/lib/esm/presentation-common/rules/content/ContentSpecification.d.ts +0 -7
  199. package/lib/esm/presentation-common/rules/content/ContentSpecification.d.ts.map +1 -1
  200. package/lib/esm/presentation-common/rules/content/ContentSpecification.js.map +1 -1
  201. package/lib/esm/presentation-common/rules/customization/CustomizationRule.d.ts +1 -5
  202. package/lib/esm/presentation-common/rules/customization/CustomizationRule.d.ts.map +1 -1
  203. package/lib/esm/presentation-common/rules/customization/CustomizationRule.js.map +1 -1
  204. package/lib/esm/presentation-common/rules/customization/GroupingRule.d.ts +2 -28
  205. package/lib/esm/presentation-common/rules/customization/GroupingRule.d.ts.map +1 -1
  206. package/lib/esm/presentation-common/rules/customization/GroupingRule.js +0 -14
  207. package/lib/esm/presentation-common/rules/customization/GroupingRule.js.map +1 -1
  208. package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts +2 -0
  209. package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts.map +1 -1
  210. package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.js.map +1 -1
  211. package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts +0 -9
  212. package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts.map +1 -1
  213. package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js.map +1 -1
  214. package/lib/esm/presentation-common.d.ts +1 -5
  215. package/lib/esm/presentation-common.d.ts.map +1 -1
  216. package/lib/esm/presentation-common.js +1 -5
  217. package/lib/esm/presentation-common.js.map +1 -1
  218. package/package.json +10 -10
  219. package/lib/cjs/presentation-common/rules/customization/CheckBoxRule.d.ts +0 -45
  220. package/lib/cjs/presentation-common/rules/customization/CheckBoxRule.d.ts.map +0 -1
  221. package/lib/cjs/presentation-common/rules/customization/CheckBoxRule.js +0 -10
  222. package/lib/cjs/presentation-common/rules/customization/CheckBoxRule.js.map +0 -1
  223. package/lib/cjs/presentation-common/rules/customization/ImageIdOverride.d.ts +0 -30
  224. package/lib/cjs/presentation-common/rules/customization/ImageIdOverride.d.ts.map +0 -1
  225. package/lib/cjs/presentation-common/rules/customization/ImageIdOverride.js +0 -10
  226. package/lib/cjs/presentation-common/rules/customization/ImageIdOverride.js.map +0 -1
  227. package/lib/cjs/presentation-common/rules/customization/LabelOverride.d.ts +0 -41
  228. package/lib/cjs/presentation-common/rules/customization/LabelOverride.d.ts.map +0 -1
  229. package/lib/cjs/presentation-common/rules/customization/LabelOverride.js +0 -10
  230. package/lib/cjs/presentation-common/rules/customization/LabelOverride.js.map +0 -1
  231. package/lib/cjs/presentation-common/rules/customization/StyleOverride.d.ts +0 -49
  232. package/lib/cjs/presentation-common/rules/customization/StyleOverride.d.ts.map +0 -1
  233. package/lib/cjs/presentation-common/rules/customization/StyleOverride.js +0 -10
  234. package/lib/cjs/presentation-common/rules/customization/StyleOverride.js.map +0 -1
  235. package/lib/esm/presentation-common/rules/customization/CheckBoxRule.d.ts +0 -45
  236. package/lib/esm/presentation-common/rules/customization/CheckBoxRule.d.ts.map +0 -1
  237. package/lib/esm/presentation-common/rules/customization/CheckBoxRule.js +0 -9
  238. package/lib/esm/presentation-common/rules/customization/CheckBoxRule.js.map +0 -1
  239. package/lib/esm/presentation-common/rules/customization/ImageIdOverride.d.ts +0 -30
  240. package/lib/esm/presentation-common/rules/customization/ImageIdOverride.d.ts.map +0 -1
  241. package/lib/esm/presentation-common/rules/customization/ImageIdOverride.js +0 -9
  242. package/lib/esm/presentation-common/rules/customization/ImageIdOverride.js.map +0 -1
  243. package/lib/esm/presentation-common/rules/customization/LabelOverride.d.ts +0 -41
  244. package/lib/esm/presentation-common/rules/customization/LabelOverride.d.ts.map +0 -1
  245. package/lib/esm/presentation-common/rules/customization/LabelOverride.js +0 -9
  246. package/lib/esm/presentation-common/rules/customization/LabelOverride.js.map +0 -1
  247. package/lib/esm/presentation-common/rules/customization/StyleOverride.d.ts +0 -49
  248. package/lib/esm/presentation-common/rules/customization/StyleOverride.d.ts.map +0 -1
  249. package/lib/esm/presentation-common/rules/customization/StyleOverride.js +0 -9
  250. package/lib/esm/presentation-common/rules/customization/StyleOverride.js.map +0 -1
@@ -37,50 +37,6 @@ export var Value;
37
37
  value.label !== undefined);
38
38
  }
39
39
  Value.isNavigationValue = isNavigationValue;
40
- /**
41
- * Serialize [[Value]] to JSON
42
- * @deprecated in 3.x. Use [[Value]]
43
- */
44
- // eslint-disable-next-line @typescript-eslint/no-deprecated
45
- function fromJSON(json) {
46
- if (json === null) {
47
- return undefined;
48
- }
49
- if (isNestedContentValue(json)) {
50
- // eslint-disable-next-line @typescript-eslint/no-deprecated
51
- return json.map(NestedContentValue.fromJSON);
52
- }
53
- if (isArrayValue(json)) {
54
- return valuesArrayFromJSON(json);
55
- }
56
- if (isMapValue(json)) {
57
- return valuesMapFromJSON(json);
58
- }
59
- return json;
60
- }
61
- Value.fromJSON = fromJSON;
62
- /**
63
- * Deserialize [[Value]] from JSON
64
- * @deprecated in 3.x. Use [[Value]]
65
- */
66
- // eslint-disable-next-line @typescript-eslint/no-deprecated
67
- function toJSON(value) {
68
- if (undefined === value) {
69
- return null;
70
- }
71
- if (isNestedContentValue(value)) {
72
- // eslint-disable-next-line @typescript-eslint/no-deprecated
73
- return value.map(NestedContentValue.toJSON);
74
- }
75
- if (isArrayValue(value)) {
76
- return valuesArrayToJSON(value);
77
- }
78
- if (isMapValue(value)) {
79
- return valuesMapToJSON(value);
80
- }
81
- return value;
82
- }
83
- Value.toJSON = toJSON;
84
40
  })(Value || (Value = {}));
85
41
  /** @public */
86
42
  // eslint-disable-next-line @typescript-eslint/no-redeclare
@@ -101,106 +57,7 @@ export var DisplayValue;
101
57
  return isMapValue(value);
102
58
  }
103
59
  DisplayValue.isMap = isMap;
104
- /**
105
- * Serialize [[DisplayValue]] to JSON
106
- * @deprecated in 3.x. Use [[DisplayValue]]
107
- */
108
- // eslint-disable-next-line @typescript-eslint/no-deprecated
109
- function fromJSON(json) {
110
- if (json === null) {
111
- return undefined;
112
- }
113
- if (isArrayValue(json)) {
114
- return displayValuesArrayFromJSON(json);
115
- }
116
- if (isMapValue(json)) {
117
- return displayValuesMapFromJSON(json);
118
- }
119
- return json;
120
- }
121
- DisplayValue.fromJSON = fromJSON;
122
- /**
123
- * Deserialize [[DisplayValue]] from JSON
124
- * @deprecated in 3.x. Use [[DisplayValue]]
125
- */
126
- // eslint-disable-next-line @typescript-eslint/no-deprecated
127
- function toJSON(value) {
128
- if (undefined === value) {
129
- return null;
130
- }
131
- if (isArrayValue(value)) {
132
- return displayValuesArrayToJSON(value);
133
- }
134
- if (isMapValue(value)) {
135
- return displayValuesMapToJSON(value);
136
- }
137
- return value;
138
- }
139
- DisplayValue.toJSON = toJSON;
140
60
  })(DisplayValue || (DisplayValue = {}));
141
- /** @public */
142
- export var NestedContentValue;
143
- (function (NestedContentValue) {
144
- /**
145
- * Serialize [[NestedContentValue]] to JSON
146
- * @deprecated in 3.x. Use [[NestedContentValue]]
147
- */
148
- // eslint-disable-next-line @typescript-eslint/no-deprecated
149
- function toJSON(value) {
150
- return {
151
- ...value,
152
- values: valuesMapToJSON(value.values),
153
- displayValues: displayValuesMapToJSON(value.displayValues),
154
- };
155
- }
156
- NestedContentValue.toJSON = toJSON;
157
- /**
158
- * Deserialize [[NestedContentValue]] from JSON
159
- * @deprecated in 3.x. Use [[NestedContentValue]]
160
- */
161
- // eslint-disable-next-line @typescript-eslint/no-deprecated
162
- function fromJSON(json) {
163
- return {
164
- ...json,
165
- values: valuesMapFromJSON(json.values),
166
- displayValues: displayValuesMapFromJSON(json.displayValues),
167
- };
168
- }
169
- NestedContentValue.fromJSON = fromJSON;
170
- })(NestedContentValue || (NestedContentValue = {}));
171
- /** @public */
172
- export var DisplayValueGroup;
173
- (function (DisplayValueGroup) {
174
- /**
175
- * Serialize [[DisplayValueGroup]] to JSON
176
- * @deprecated in 3.x. Use [[DisplayValueGroup]]
177
- */
178
- // eslint-disable-next-line @typescript-eslint/no-deprecated
179
- function toJSON(group) {
180
- return {
181
- // eslint-disable-next-line @typescript-eslint/no-deprecated
182
- displayValue: DisplayValue.toJSON(group.displayValue),
183
- // eslint-disable-next-line @typescript-eslint/no-deprecated
184
- groupedRawValues: group.groupedRawValues.map(Value.toJSON),
185
- };
186
- }
187
- DisplayValueGroup.toJSON = toJSON;
188
- /**
189
- * Deserialize [[DisplayValueGroup]] from JSON
190
- * @deprecated in 3.x. Use [[DisplayValueGroup]]
191
- */
192
- // eslint-disable-next-line @typescript-eslint/no-deprecated
193
- function fromJSON(json) {
194
- return {
195
- // eslint-disable-next-line @typescript-eslint/no-deprecated
196
- displayValue: DisplayValue.fromJSON(json.displayValue),
197
- // eslint-disable-next-line @typescript-eslint/no-deprecated
198
- groupedRawValues: json.groupedRawValues.map(Value.fromJSON),
199
- };
200
- }
201
- DisplayValueGroup.fromJSON = fromJSON;
202
- })(DisplayValueGroup || (DisplayValueGroup = {}));
203
- // eslint-disable-next-line @typescript-eslint/no-deprecated
204
61
  function isNestedContentValue(v) {
205
62
  return (v !== undefined &&
206
63
  Array.isArray(v) &&
@@ -216,81 +73,10 @@ function isArrayValue(v) {
216
73
  // we have other means to determine the type of value.
217
74
  return v !== undefined && Array.isArray(v);
218
75
  }
219
- // eslint-disable-next-line @typescript-eslint/no-deprecated
220
76
  function isMapValue(v) {
221
77
  return v !== undefined && typeof v === "object" && !Array.isArray(v);
222
78
  }
223
79
  function isPrimitiveValue(v) {
224
80
  return !isArrayValue(v) && !isMapValue(v);
225
81
  }
226
- // eslint-disable-next-line @typescript-eslint/no-deprecated
227
- function valuesArrayFromJSON(json) {
228
- // eslint-disable-next-line @typescript-eslint/no-deprecated
229
- return json.map(Value.fromJSON);
230
- }
231
- // eslint-disable-next-line @typescript-eslint/no-deprecated
232
- function valuesArrayToJSON(values) {
233
- // eslint-disable-next-line @typescript-eslint/no-deprecated
234
- return values.map(Value.toJSON);
235
- }
236
- // eslint-disable-next-line @typescript-eslint/no-deprecated
237
- function valuesMapFromJSON(json) {
238
- const map = {};
239
- for (const key in json) {
240
- /* istanbul ignore else */
241
- if (json.hasOwnProperty(key)) {
242
- // eslint-disable-next-line @typescript-eslint/no-deprecated
243
- map[key] = Value.fromJSON(json[key]);
244
- }
245
- }
246
- return map;
247
- }
248
- // eslint-disable-next-line @typescript-eslint/no-deprecated
249
- function valuesMapToJSON(values) {
250
- // eslint-disable-next-line @typescript-eslint/no-deprecated
251
- const map = {};
252
- for (const key in values) {
253
- /* istanbul ignore else */
254
- if (values.hasOwnProperty(key)) {
255
- // eslint-disable-next-line @typescript-eslint/no-deprecated
256
- map[key] = Value.toJSON(values[key]);
257
- }
258
- }
259
- return map;
260
- }
261
- // eslint-disable-next-line @typescript-eslint/no-deprecated
262
- function displayValuesArrayFromJSON(json) {
263
- // eslint-disable-next-line @typescript-eslint/no-deprecated
264
- return json.map(DisplayValue.fromJSON);
265
- }
266
- // eslint-disable-next-line @typescript-eslint/no-deprecated
267
- function displayValuesArrayToJSON(values) {
268
- // eslint-disable-next-line @typescript-eslint/no-deprecated
269
- return values.map(DisplayValue.toJSON);
270
- }
271
- // eslint-disable-next-line @typescript-eslint/no-deprecated
272
- function displayValuesMapFromJSON(json) {
273
- const map = {};
274
- for (const key in json) {
275
- /* istanbul ignore else */
276
- if (json.hasOwnProperty(key)) {
277
- // eslint-disable-next-line @typescript-eslint/no-deprecated
278
- map[key] = DisplayValue.fromJSON(json[key]);
279
- }
280
- }
281
- return map;
282
- }
283
- // eslint-disable-next-line @typescript-eslint/no-deprecated
284
- function displayValuesMapToJSON(values) {
285
- // eslint-disable-next-line @typescript-eslint/no-deprecated
286
- const map = {};
287
- for (const key in values) {
288
- /* istanbul ignore else */
289
- if (values.hasOwnProperty(key)) {
290
- // eslint-disable-next-line @typescript-eslint/no-deprecated
291
- map[key] = DisplayValue.toJSON(values[key]);
292
- }
293
- }
294
- return map;
295
- }
296
82
  //# sourceMappingURL=Value.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Value.js","sourceRoot":"","sources":["../../../../src/presentation-common/content/Value.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG;;GAEG;AAYH,cAAc;AACd,2DAA2D;AAC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AAG,GAAyB,EAAE,CAAC;IACrC,KAAK,MAAM,GAAG,IAAI,MAAM,EAAE,CAAC;QACzB,0BAA0B;QAC1B,IAAI,MAAM,CAAC,cAAc,CAAC,GAAG,CAAC,EAAE,CAAC;YAC/B,4DAA4D;YAC5D,GAAG,CAAC,GAAG,CAAC,GAAG,YAAY,CAAC,MAAM,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC;QAC9C,CAAC;IACH,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC","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/** @packageDocumentation\n * @module Content\n */\n\nimport { InstanceId, InstanceKey } from \"../EC\";\nimport { LabelDefinition } from \"../LabelDefinition\";\nimport { ValuesDictionary } from \"../Utils\";\n\n/**\n * Raw value type\n * @public\n */\nexport type Value = string | number | boolean | undefined | ValuesMap | ValuesArray | NavigationPropertyValue | NestedContentValue[];\n\n/** @public */\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport namespace Value {\n /** Is the value a primitive */\n export function isPrimitive(value: Value): value is string | number | boolean | undefined {\n return isPrimitiveValue(value);\n }\n\n /** Is the value an array */\n export function isArray(value: Value): value is ValuesArray {\n return isArrayValue(value);\n }\n\n /** Is the value a map / struct */\n export function isMap(value: Value): value is ValuesMap {\n return isMapValue(value);\n }\n\n /** Is the value a nested content value */\n export function isNestedContent(value: Value): value is NestedContentValue[] {\n return isNestedContentValue(value);\n }\n\n /** Is the value a navigation value */\n export function isNavigationValue(value: Value): value is NavigationPropertyValue {\n return (\n value !== undefined &&\n (value as NavigationPropertyValue).id !== undefined &&\n (value as NavigationPropertyValue).className !== undefined &&\n (value as NavigationPropertyValue).label !== undefined\n );\n }\n\n /**\n * Serialize [[Value]] to JSON\n * @deprecated in 3.x. Use [[Value]]\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function fromJSON(json: ValueJSON): Value {\n if (json === null) {\n return undefined;\n }\n if (isNestedContentValue(json)) {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n return json.map(NestedContentValue.fromJSON);\n }\n if (isArrayValue(json)) {\n return valuesArrayFromJSON(json);\n }\n if (isMapValue(json)) {\n return valuesMapFromJSON(json);\n }\n return json;\n }\n\n /**\n * Deserialize [[Value]] from JSON\n * @deprecated in 3.x. Use [[Value]]\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function toJSON(value: Value): ValueJSON {\n if (undefined === value) {\n return null;\n }\n if (isNestedContentValue(value)) {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n return value.map(NestedContentValue.toJSON);\n }\n if (isArrayValue(value)) {\n return valuesArrayToJSON(value);\n }\n if (isMapValue(value)) {\n return valuesMapToJSON(value);\n }\n return value;\n }\n}\n\n/**\n * A map of raw values\n * @public\n */\nexport interface ValuesMap extends ValuesDictionary<Value> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * An array of raw values\n * @public\n */\nexport interface ValuesArray extends Array<Value> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * Display value type.\n * @public\n */\nexport type DisplayValue = string | undefined | DisplayValuesMap | DisplayValuesArray;\n\n/** @public */\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport namespace DisplayValue {\n /** Is the value a primitive */\n export function isPrimitive(value: DisplayValue): value is string | undefined {\n return isPrimitiveValue(value);\n }\n\n /** Is the value an array */\n export function isArray(value: DisplayValue): value is DisplayValuesArray {\n return isArrayValue(value);\n }\n\n /** Is the value a map / struct */\n export function isMap(value: DisplayValue): value is DisplayValuesMap {\n return isMapValue(value);\n }\n\n /**\n * Serialize [[DisplayValue]] to JSON\n * @deprecated in 3.x. Use [[DisplayValue]]\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function fromJSON(json: DisplayValueJSON): DisplayValue {\n if (json === null) {\n return undefined;\n }\n if (isArrayValue(json)) {\n return displayValuesArrayFromJSON(json);\n }\n if (isMapValue(json)) {\n return displayValuesMapFromJSON(json);\n }\n return json;\n }\n\n /**\n * Deserialize [[DisplayValue]] from JSON\n * @deprecated in 3.x. Use [[DisplayValue]]\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function toJSON(value: DisplayValue): DisplayValueJSON {\n if (undefined === value) {\n return null;\n }\n if (isArrayValue(value)) {\n return displayValuesArrayToJSON(value);\n }\n if (isMapValue(value)) {\n return displayValuesMapToJSON(value);\n }\n return value;\n }\n}\n\n/**\n * A map of display values\n * @public\n */\nexport interface DisplayValuesMap extends ValuesDictionary<DisplayValue> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * An array of display values\n * @public\n */\nexport interface DisplayValuesArray extends Array<DisplayValue> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * Data structure that describes nested content value.\n * @public\n */\nexport interface NestedContentValue {\n /** Keys of instances whose content is contained in this value */\n primaryKeys: InstanceKey[];\n /** Content values map */\n values: ValuesDictionary<Value>;\n /** Content display values map */\n displayValues: ValuesDictionary<DisplayValue>;\n /** Names of fields whose values are merged */\n mergedFieldNames: string[];\n /** Label of the ECInstance that this `NestedContentValue` is based on. */\n labelDefinition?: LabelDefinition;\n}\n\n/**\n * Data structure that describes value of the navigation property.\n * @public\n */\nexport interface NavigationPropertyValue {\n /** Label of target instance. */\n label: LabelDefinition;\n /** Full class name of target instance in format `SchemaName:ClassName` */\n className: string;\n /** Id of target instance. */\n id: InstanceId;\n}\n\n/** @public */\nexport namespace NestedContentValue {\n /**\n * Serialize [[NestedContentValue]] to JSON\n * @deprecated in 3.x. Use [[NestedContentValue]]\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function toJSON(value: NestedContentValue): NestedContentValueJSON {\n return {\n ...value,\n values: valuesMapToJSON(value.values),\n displayValues: displayValuesMapToJSON(value.displayValues),\n };\n }\n\n /**\n * Deserialize [[NestedContentValue]] from JSON\n * @deprecated in 3.x. Use [[NestedContentValue]]\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function fromJSON(json: NestedContentValueJSON): NestedContentValue {\n return {\n ...json,\n values: valuesMapFromJSON(json.values),\n displayValues: displayValuesMapFromJSON(json.displayValues),\n };\n }\n}\n\n/**\n * JSON representation of [[Value]]\n * @public\n * @deprecated in 3.x. Use [[Value]]\n */\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nexport type ValueJSON = string | number | boolean | null | ValuesMapJSON | ValuesArrayJSON | NavigationPropertyValue | NestedContentValueJSON[];\n/**\n * JSON representation of [[ValuesMap]]\n * @public\n * @deprecated in 3.x. Use [[ValuesMap]]\n */\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nexport interface ValuesMapJSON extends ValuesDictionary<ValueJSON> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * JSON representation of [[ValuesArray]]\n * @public\n * @deprecated in 3.x. Use [[ValuesArray]]\n */\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nexport interface ValuesArrayJSON extends Array<ValueJSON> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * JSON representation of [[DisplayValue]]\n * @public\n * @deprecated in 3.x. Use [[DisplayValue]]\n */\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nexport type DisplayValueJSON = string | null | DisplayValuesMapJSON | DisplayValuesArrayJSON;\n\n/**\n * JSON representation of [[DisplayValuesMap]]\n * @public\n * @deprecated in 3.x. Use [[DisplayValuesMap]]\n */\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nexport interface DisplayValuesMapJSON extends ValuesDictionary<DisplayValueJSON> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * JSON representation of [[DisplayValuesArray]]\n * @public\n * @deprecated in 3.x. Use [[DisplayValuesArray]]\n */\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nexport interface DisplayValuesArrayJSON extends Array<DisplayValueJSON> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * JSON representation of [[NestedContentValue]]\n * @public\n * @deprecated in 3.x. Use [[NestedContentValue]]\n */\nexport interface NestedContentValueJSON {\n primaryKeys: InstanceKey[];\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n values: ValuesDictionary<ValueJSON>;\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n displayValues: ValuesDictionary<DisplayValueJSON>;\n mergedFieldNames: string[];\n}\n\n/**\n * A group of raw values and their common display value.\n * @public\n */\nexport interface DisplayValueGroup {\n /** Common display value for all grouped raw values */\n displayValue: DisplayValue;\n /** A list of grouped raw values */\n groupedRawValues: Value[];\n}\n\n/**\n * JSON representation of [[DisplayValueGroup]].\n * @public\n * @deprecated in 3.x. Use [[DisplayValueGroup]]\n */\nexport interface DisplayValueGroupJSON {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n displayValue: DisplayValueJSON;\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n groupedRawValues: ValueJSON[];\n}\n\n/** @public */\nexport namespace DisplayValueGroup {\n /**\n * Serialize [[DisplayValueGroup]] to JSON\n * @deprecated in 3.x. Use [[DisplayValueGroup]]\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function toJSON(group: DisplayValueGroup): DisplayValueGroupJSON {\n return {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n displayValue: DisplayValue.toJSON(group.displayValue),\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n groupedRawValues: group.groupedRawValues.map(Value.toJSON),\n };\n }\n\n /**\n * Deserialize [[DisplayValueGroup]] from JSON\n * @deprecated in 3.x. Use [[DisplayValueGroup]]\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function fromJSON(json: DisplayValueGroupJSON): DisplayValueGroup {\n return {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n displayValue: DisplayValue.fromJSON(json.displayValue),\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n groupedRawValues: json.groupedRawValues.map(Value.fromJSON),\n };\n }\n}\n\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction isNestedContentValue(v: Value | ValueJSON): v is NestedContentValue[] | NestedContentValueJSON[] {\n return (\n v !== undefined &&\n Array.isArray(v) &&\n (v.length === 0 ||\n (!!v[0] &&\n (v[0] as NestedContentValue).primaryKeys !== undefined &&\n (v[0] as NestedContentValue).values !== undefined &&\n (v[0] as NestedContentValue).displayValues !== undefined &&\n (v[0] as NestedContentValue).mergedFieldNames !== undefined))\n );\n}\n\nfunction isArrayValue(\n v: Value | ValueJSON | DisplayValue | DisplayValueJSON, // eslint-disable-line @typescript-eslint/no-deprecated\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n): v is ValuesArray | ValuesArrayJSON | DisplayValuesArray | DisplayValuesArrayJSON {\n // note: we don't guarantee by 100% that v is ValuesArray | DisplayValuesArray, but merely make compiler happy.\n // we have other means to determine the type of value.\n return v !== undefined && Array.isArray(v);\n}\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction isMapValue(v: Value | ValueJSON | DisplayValue | DisplayValueJSON): v is ValuesMap | ValuesMapJSON | DisplayValuesMap | DisplayValuesMapJSON {\n return v !== undefined && typeof v === \"object\" && !Array.isArray(v);\n}\nfunction isPrimitiveValue(v: Value | DisplayValue): v is string | number | boolean | undefined {\n return !isArrayValue(v) && !isMapValue(v);\n}\n\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction valuesArrayFromJSON(json: ValuesArrayJSON): ValuesArray {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n return json.map(Value.fromJSON);\n}\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction valuesArrayToJSON(values: ValuesArray): ValuesArrayJSON {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n return values.map(Value.toJSON);\n}\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction valuesMapFromJSON(json: ValuesMapJSON): ValuesMap {\n const map: ValuesMap = {};\n for (const key in json) {\n /* istanbul ignore else */\n if (json.hasOwnProperty(key)) {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n map[key] = Value.fromJSON(json[key]);\n }\n }\n return map;\n}\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction valuesMapToJSON(values: ValuesMap): ValuesMapJSON {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n const map: ValuesMapJSON = {};\n for (const key in values) {\n /* istanbul ignore else */\n if (values.hasOwnProperty(key)) {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n map[key] = Value.toJSON(values[key]);\n }\n }\n return map;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction displayValuesArrayFromJSON(json: DisplayValuesArrayJSON): DisplayValuesArray {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n return json.map(DisplayValue.fromJSON);\n}\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction displayValuesArrayToJSON(values: DisplayValuesArray): DisplayValuesArrayJSON {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n return values.map(DisplayValue.toJSON);\n}\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction displayValuesMapFromJSON(json: DisplayValuesMapJSON): DisplayValuesMap {\n const map: DisplayValuesMap = {};\n for (const key in json) {\n /* istanbul ignore else */\n if (json.hasOwnProperty(key)) {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n map[key] = DisplayValue.fromJSON(json[key]);\n }\n }\n return map;\n}\n// eslint-disable-next-line @typescript-eslint/no-deprecated\nfunction displayValuesMapToJSON(values: DisplayValuesMap): DisplayValuesMapJSON {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n const map: DisplayValuesMapJSON = {};\n for (const key in values) {\n /* istanbul ignore else */\n if (values.hasOwnProperty(key)) {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n map[key] = DisplayValue.toJSON(values[key]);\n }\n }\n return map;\n}\n"]}
1
+ {"version":3,"file":"Value.js","sourceRoot":"","sources":["../../../../src/presentation-common/content/Value.ts"],"names":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,CAAC;IAFe,oBAAO,UAEtB,CAAA;IAED,kCAAkC;IAClC,SAAgB,KAAK,CAAC,KAAmB;QACvC,OAAO,UAAU,CAAC,KAAK,CAAC,CAAC;IAC3B,CAAC;IAFe,kBAAK,QAEpB,CAAA;AACH,CAAC,EAfgB,YAAY,KAAZ,YAAY,QAe5B;AAuDD,SAAS,oBAAoB,CAAC,CAAQ;IACpC,OAAO,CACL,CAAC,KAAK,SAAS;QACf,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC;QAChB,CAAC,CAAC,CAAC,MAAM,KAAK,CAAC;YACb,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;gBACJ,CAAC,CAAC,CAAC,CAAwB,CAAC,WAAW,KAAK,SAAS;gBACrD,CAAC,CAAC,CAAC,CAAwB,CAAC,MAAM,KAAK,SAAS;gBAChD,CAAC,CAAC,CAAC,CAAwB,CAAC,aAAa,KAAK,SAAS;gBACvD,CAAC,CAAC,CAAC,CAAwB,CAAC,gBAAgB,KAAK,SAAS,CAAC,CAAC,CAClE,CAAC;AACJ,CAAC;AAED,SAAS,YAAY,CAAC,CAAuB;IAC3C,+GAA+G;IAC/G,sDAAsD;IACtD,OAAO,CAAC,KAAK,SAAS,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AAC7C,CAAC;AACD,SAAS,UAAU,CAAC,CAAuB;IACzC,OAAO,CAAC,KAAK,SAAS,IAAI,OAAO,CAAC,KAAK,QAAQ,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AACvE,CAAC;AACD,SAAS,gBAAgB,CAAC,CAAuB;IAC/C,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;AAC5C,CAAC","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/** @packageDocumentation\n * @module Content\n */\n\nimport { InstanceId, InstanceKey } from \"../EC\";\nimport { LabelDefinition } from \"../LabelDefinition\";\nimport { ValuesDictionary } from \"../Utils\";\n\n/**\n * Raw value type\n * @public\n */\nexport type Value = string | number | boolean | undefined | ValuesMap | ValuesArray | NavigationPropertyValue | NestedContentValue[];\n\n/** @public */\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport namespace Value {\n /** Is the value a primitive */\n export function isPrimitive(value: Value): value is string | number | boolean | undefined {\n return isPrimitiveValue(value);\n }\n\n /** Is the value an array */\n export function isArray(value: Value): value is ValuesArray {\n return isArrayValue(value);\n }\n\n /** Is the value a map / struct */\n export function isMap(value: Value): value is ValuesMap {\n return isMapValue(value);\n }\n\n /** Is the value a nested content value */\n export function isNestedContent(value: Value): value is NestedContentValue[] {\n return isNestedContentValue(value);\n }\n\n /** Is the value a navigation value */\n export function isNavigationValue(value: Value): value is NavigationPropertyValue {\n return (\n value !== undefined &&\n (value as NavigationPropertyValue).id !== undefined &&\n (value as NavigationPropertyValue).className !== undefined &&\n (value as NavigationPropertyValue).label !== undefined\n );\n }\n}\n\n/**\n * A map of raw values\n * @public\n */\nexport interface ValuesMap extends ValuesDictionary<Value> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * An array of raw values\n * @public\n */\nexport interface ValuesArray extends Array<Value> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * Display value type.\n * @public\n */\nexport type DisplayValue = string | undefined | DisplayValuesMap | DisplayValuesArray;\n\n/** @public */\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport namespace DisplayValue {\n /** Is the value a primitive */\n export function isPrimitive(value: DisplayValue): value is string | undefined {\n return isPrimitiveValue(value);\n }\n\n /** Is the value an array */\n export function isArray(value: DisplayValue): value is DisplayValuesArray {\n return isArrayValue(value);\n }\n\n /** Is the value a map / struct */\n export function isMap(value: DisplayValue): value is DisplayValuesMap {\n return isMapValue(value);\n }\n}\n\n/**\n * A map of display values\n * @public\n */\nexport interface DisplayValuesMap extends ValuesDictionary<DisplayValue> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * An array of display values\n * @public\n */\nexport interface DisplayValuesArray extends Array<DisplayValue> {} // eslint-disable-line @typescript-eslint/no-empty-object-type\n\n/**\n * Data structure that describes nested content value.\n * @public\n */\nexport interface NestedContentValue {\n /** Keys of instances whose content is contained in this value */\n primaryKeys: InstanceKey[];\n /** Content values map */\n values: ValuesDictionary<Value>;\n /** Content display values map */\n displayValues: ValuesDictionary<DisplayValue>;\n /** Names of fields whose values are merged */\n mergedFieldNames: string[];\n /** Label of the ECInstance that this `NestedContentValue` is based on. */\n labelDefinition?: LabelDefinition;\n}\n\n/**\n * Data structure that describes value of the navigation property.\n * @public\n */\nexport interface NavigationPropertyValue {\n /** Label of target instance. */\n label: LabelDefinition;\n /** Full class name of target instance in format `SchemaName:ClassName` */\n className: string;\n /** Id of target instance. */\n id: InstanceId;\n}\n\n/**\n * A group of raw values and their common display value.\n * @public\n */\nexport interface DisplayValueGroup {\n /** Common display value for all grouped raw values */\n displayValue: DisplayValue;\n /** A list of grouped raw values */\n groupedRawValues: Value[];\n}\n\nfunction isNestedContentValue(v: Value): v is NestedContentValue[] {\n return (\n v !== undefined &&\n Array.isArray(v) &&\n (v.length === 0 ||\n (!!v[0] &&\n (v[0] as NestedContentValue).primaryKeys !== undefined &&\n (v[0] as NestedContentValue).values !== undefined &&\n (v[0] as NestedContentValue).displayValues !== undefined &&\n (v[0] as NestedContentValue).mergedFieldNames !== undefined))\n );\n}\n\nfunction isArrayValue(v: Value | DisplayValue): v is ValuesArray | DisplayValuesArray {\n // note: we don't guarantee by 100% that v is ValuesArray | DisplayValuesArray, but merely make compiler happy.\n // we have other means to determine the type of value.\n return v !== undefined && Array.isArray(v);\n}\nfunction isMapValue(v: Value | DisplayValue): v is ValuesMap | DisplayValuesMap {\n return v !== undefined && typeof v === \"object\" && !Array.isArray(v);\n}\nfunction isPrimitiveValue(v: Value | DisplayValue): v is string | number | boolean | undefined {\n return !isArrayValue(v) && !isMapValue(v);\n}\n"]}
@@ -1,7 +1,7 @@
1
1
  /** @packageDocumentation
2
2
  * @module Hierarchies
3
3
  */
4
- import { Node, NodeJSON } from "./Node";
4
+ import { Node } from "./Node";
5
5
  /**
6
6
  * Defines a hierarchy level that consists of an array of nodes and possibly other information.
7
7
  * @public
@@ -15,25 +15,4 @@ export interface HierarchyLevel {
15
15
  */
16
16
  supportsFiltering?: boolean;
17
17
  }
18
- /**
19
- * JSON representation of [[HierarchyLevel]].
20
- * @beta
21
- * @deprecated in 3.x. Use [[HierarchyLevel]]
22
- */
23
- export interface HierarchyLevelJSON {
24
- nodes: NodeJSON[];
25
- supportsFiltering?: boolean;
26
- }
27
- /**
28
- * Contains helper functions for working with objects of [[HierarchyLevel]] type.
29
- * @public
30
- */
31
- export declare namespace HierarchyLevel {
32
- /**
33
- * Deserialize [[HierarchyLevel]] from JSON
34
- * @beta
35
- * @deprecated in 3.x. Use [[HierarchyLevel]].
36
- */
37
- function fromJSON(json: HierarchyLevelJSON): HierarchyLevel;
38
- }
39
18
  //# sourceMappingURL=HierarchyLevel.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"HierarchyLevel.d.ts","sourceRoot":"","sources":["../../../../src/presentation-common/hierarchy/HierarchyLevel.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,QAAQ,CAAC;AAExC;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,4CAA4C;IAC5C,KAAK,EAAE,IAAI,EAAE,CAAC;IACd;;;OAGG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAED;;;;GAIG;AACH,MAAM,WAAW,kBAAkB;IAEjC,KAAK,EAAE,QAAQ,EAAE,CAAC;IAClB,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAED;;;GAGG;AACH,yBAAiB,cAAc,CAAC;IAC9B;;;;OAIG;IAEH,SAAgB,QAAQ,CAAC,IAAI,EAAE,kBAAkB,GAAG,cAAc,CAMjE;CACF"}
1
+ {"version":3,"file":"HierarchyLevel.d.ts","sourceRoot":"","sources":["../../../../src/presentation-common/hierarchy/HierarchyLevel.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAE9B;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,4CAA4C;IAC5C,KAAK,EAAE,IAAI,EAAE,CAAC;IACd;;;OAGG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B"}
@@ -5,26 +5,5 @@
5
5
  /** @packageDocumentation
6
6
  * @module Hierarchies
7
7
  */
8
- import { Node } from "./Node";
9
- /**
10
- * Contains helper functions for working with objects of [[HierarchyLevel]] type.
11
- * @public
12
- */
13
- export var HierarchyLevel;
14
- (function (HierarchyLevel) {
15
- /**
16
- * Deserialize [[HierarchyLevel]] from JSON
17
- * @beta
18
- * @deprecated in 3.x. Use [[HierarchyLevel]].
19
- */
20
- // eslint-disable-next-line @typescript-eslint/no-deprecated
21
- function fromJSON(json) {
22
- return {
23
- ...json,
24
- // eslint-disable-next-line @typescript-eslint/no-deprecated
25
- nodes: json.nodes.map(Node.fromJSON),
26
- };
27
- }
28
- HierarchyLevel.fromJSON = fromJSON;
29
- })(HierarchyLevel || (HierarchyLevel = {}));
8
+ export {};
30
9
  //# sourceMappingURL=HierarchyLevel.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"HierarchyLevel.js","sourceRoot":"","sources":["../../../../src/presentation-common/hierarchy/HierarchyLevel.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG;;GAEG;AAEH,OAAO,EAAE,IAAI,EAAY,MAAM,QAAQ,CAAC;AA2BxC;;;GAGG;AACH,MAAM,KAAW,cAAc,CAc9B;AAdD,WAAiB,cAAc;IAC7B;;;;OAIG;IACH,4DAA4D;IAC5D,SAAgB,QAAQ,CAAC,IAAwB;QAC/C,OAAO;YACL,GAAG,IAAI;YACP,4DAA4D;YAC5D,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC;SACrC,CAAC;IACJ,CAAC;IANe,uBAAQ,WAMvB,CAAA;AACH,CAAC,EAdgB,cAAc,KAAd,cAAc,QAc9B","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/** @packageDocumentation\n * @module Hierarchies\n */\n\nimport { Node, NodeJSON } from \"./Node\";\n\n/**\n * Defines a hierarchy level that consists of an array of nodes and possibly other information.\n * @public\n */\nexport interface HierarchyLevel {\n /** A list of nodes in a hierarchy level. */\n nodes: Node[];\n /**\n * Identifies whether the hierarchy level supports filtering. If not, requesting either a hierarchy level descriptor or\n * a hierarchy level with [[HierarchyRequestOptions.instanceFilter]] will throw an error with [[PresentationStatus.InvalidArgument]] status.\n */\n supportsFiltering?: boolean;\n}\n\n/**\n * JSON representation of [[HierarchyLevel]].\n * @beta\n * @deprecated in 3.x. Use [[HierarchyLevel]]\n */\nexport interface HierarchyLevelJSON {\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n nodes: NodeJSON[];\n supportsFiltering?: boolean;\n}\n\n/**\n * Contains helper functions for working with objects of [[HierarchyLevel]] type.\n * @public\n */\nexport namespace HierarchyLevel {\n /**\n * Deserialize [[HierarchyLevel]] from JSON\n * @beta\n * @deprecated in 3.x. Use [[HierarchyLevel]].\n */\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n export function fromJSON(json: HierarchyLevelJSON): HierarchyLevel {\n return {\n ...json,\n // eslint-disable-next-line @typescript-eslint/no-deprecated\n nodes: json.nodes.map(Node.fromJSON),\n };\n }\n}\n"]}
1
+ {"version":3,"file":"HierarchyLevel.js","sourceRoot":"","sources":["../../../../src/presentation-common/hierarchy/HierarchyLevel.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG;;GAEG","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/** @packageDocumentation\n * @module Hierarchies\n */\n\nimport { Node } from \"./Node\";\n\n/**\n * Defines a hierarchy level that consists of an array of nodes and possibly other information.\n * @public\n */\nexport interface HierarchyLevel {\n /** A list of nodes in a hierarchy level. */\n nodes: Node[];\n /**\n * Identifies whether the hierarchy level supports filtering. If not, requesting either a hierarchy level descriptor or\n * a hierarchy level with [[HierarchyRequestOptions.instanceFilter]] will throw an error with [[PresentationStatus.InvalidArgument]] status.\n */\n supportsFiltering?: boolean;\n}\n"]}
@@ -20,36 +20,16 @@ export declare enum StandardNodeTypes {
20
20
  export type NodeKey = BaseNodeKey | ECInstancesNodeKey | ECClassGroupingNodeKey | ECPropertyGroupingNodeKey | LabelGroupingNodeKey;
21
21
  /** @public */
22
22
  export declare namespace NodeKey {
23
- /**
24
- * Serialize given [[NodeKey]] to JSON
25
- * @deprecated in 3.x. Use [[NodeKey]].
26
- */
27
- function toJSON(key: NodeKey): NodeKeyJSON;
28
- /**
29
- * Deserialize node key from JSON
30
- * @deprecated in 3.x. Use [[NodeKey]].
31
- */
32
- function fromJSON(json: NodeKeyJSON): NodeKey;
33
23
  /** Checks if the supplied key is an [[ECInstancesNodeKey]] */
34
24
  function isInstancesNodeKey(key: NodeKey): key is ECInstancesNodeKey;
35
- /** Checks if the supplied key is an [[ECInstancesNodeKey]]. @deprecated in 3.x. Use an override for [[NodeKey]]. */
36
- function isInstancesNodeKey(key: NodeKeyJSON): key is ECInstancesNodeKeyJSON;
37
25
  /** Checks if the supplied key is an [[ECClassGroupingNodeKey]] */
38
26
  function isClassGroupingNodeKey(key: NodeKey): key is ECClassGroupingNodeKey;
39
- /** Checks if the supplied key is an [[ECClassGroupingNodeKey]]. @deprecated in 3.x. Use an override for [[NodeKey]]. */
40
- function isClassGroupingNodeKey(key: NodeKeyJSON): key is ECClassGroupingNodeKeyJSON;
41
27
  /** Checks if the supplied key is an [[ECPropertyGroupingNodeKey]] */
42
28
  function isPropertyGroupingNodeKey(key: NodeKey): key is ECPropertyGroupingNodeKey;
43
- /** Checks if the supplied key is an [[ECPropertyGroupingNodeKey]]. @deprecated in 3.x. Use an override for [[NodeKey]]. */
44
- function isPropertyGroupingNodeKey(key: NodeKeyJSON): key is ECPropertyGroupingNodeKeyJSON;
45
29
  /** Checks if the supplied key is a [[LabelGroupingNodeKey]] */
46
30
  function isLabelGroupingNodeKey(key: NodeKey): key is LabelGroupingNodeKey;
47
- /** Checks if the supplied key is a [[LabelGroupingNodeKey]]. @deprecated in 3.x. Use an override for [[NodeKey]]. */
48
- function isLabelGroupingNodeKey(key: NodeKeyJSON): key is LabelGroupingNodeKeyJSON;
49
31
  /** Checks if the supplied key is a grouping node key */
50
32
  function isGroupingNodeKey(key: NodeKey): key is GroupingNodeKey;
51
- /** Checks if the supplied key is a grouping node key. @deprecated in 3.x. Use an override for [[NodeKey]]. */
52
- function isGroupingNodeKey(key: NodeKeyJSON): key is GroupingNodeKeyJSON;
53
33
  /**
54
34
  * Checks if two given node keys are equal, taking their versions into account.
55
35
  *
@@ -83,17 +63,6 @@ export interface BaseNodeKey {
83
63
  /** Query that returns all selected instance keys */
84
64
  instanceKeysSelectQuery?: PresentationQuery;
85
65
  }
86
- /**
87
- * Serialized [[BaseNodeKey]] JSON representation.
88
- * @public
89
- * @deprecated in 3.x. Use [[BaseNodeKey]].
90
- */
91
- export interface BaseNodeKeyJSON {
92
- type: string;
93
- version?: number;
94
- pathFromRoot: string[];
95
- instanceKeysSelectQuery?: PresentationQuery;
96
- }
97
66
  /**
98
67
  * Data structure that describes a node ECInstance node key
99
68
  * @public
@@ -103,15 +72,6 @@ export interface ECInstancesNodeKey extends BaseNodeKey {
103
72
  /** List of [[InstanceKey]] objects of ECInstances represented by the node */
104
73
  instanceKeys: InstanceKey[];
105
74
  }
106
- /**
107
- * Serialized [[ECInstancesNodeKey]] JSON representation.
108
- * @public
109
- * @deprecated in 3.x. Use [[ECInstancesNodeKey]].
110
- */
111
- export interface ECInstancesNodeKeyJSON extends BaseNodeKey {
112
- type: StandardNodeTypes.ECInstancesNode;
113
- instanceKeys: InstanceKey[];
114
- }
115
75
  /**
116
76
  * Data structure that describes a grouping node key
117
77
  * @public
@@ -126,14 +86,6 @@ export interface GroupingNodeKey extends BaseNodeKey {
126
86
  */
127
87
  groupedInstancesCount: number;
128
88
  }
129
- /**
130
- * Serialized [[GroupingNodeKey]] JSON representation.
131
- * @public
132
- * @deprecated in 3.x. Use [[GroupingNodeKey]].
133
- */
134
- export interface GroupingNodeKeyJSON extends BaseNodeKey {
135
- groupedInstancesCount: number;
136
- }
137
89
  /**
138
90
  * Data structure that describes an ECClass grouping node key
139
91
  * @public
@@ -143,15 +95,6 @@ export interface ECClassGroupingNodeKey extends GroupingNodeKey {
143
95
  /** Full name of the grouping ECClass */
144
96
  className: string;
145
97
  }
146
- /**
147
- * Serialized [[ECClassGroupingNodeKey]] JSON representation.
148
- * @public
149
- * @deprecated in 3.x. Use [[ECClassGroupingNodeKey]].
150
- */
151
- export interface ECClassGroupingNodeKeyJSON extends GroupingNodeKey {
152
- type: StandardNodeTypes.ECClassGroupingNode;
153
- className: string;
154
- }
155
98
  /**
156
99
  * Data structure that describes an ECProperty grouping node key
157
100
  * @public
@@ -165,17 +108,6 @@ export interface ECPropertyGroupingNodeKey extends GroupingNodeKey {
165
108
  /** Raw grouping values */
166
109
  groupingValues: any[];
167
110
  }
168
- /**
169
- * Serialized [[ECPropertyGroupingNodeKey]] JSON representation.
170
- * @public
171
- * @deprecated in 3.x. Use [[ECPropertyGroupingNodeKey]].
172
- */
173
- export interface ECPropertyGroupingNodeKeyJSON extends GroupingNodeKey {
174
- type: StandardNodeTypes.ECPropertyGroupingNode;
175
- className: string;
176
- propertyName: string;
177
- groupingValues: any[];
178
- }
179
111
  /**
180
112
  * Data structure that describes a display label grouping node key
181
113
  * @public
@@ -185,21 +117,6 @@ export interface LabelGroupingNodeKey extends GroupingNodeKey {
185
117
  /** Grouping display label */
186
118
  label: string;
187
119
  }
188
- /**
189
- * Serialized [[LabelGroupingNodeKey]] JSON representation.
190
- * @public
191
- * @deprecated in 3.x. Use [[LabelGroupingNodeKey]].
192
- */
193
- export interface LabelGroupingNodeKeyJSON extends GroupingNodeKey {
194
- type: StandardNodeTypes.DisplayLabelGroupingNode;
195
- label: string;
196
- }
197
- /**
198
- * One of the serialized node key types
199
- * @public
200
- * @deprecated in 3.x. Use [[NodeKey]].
201
- */
202
- export type NodeKeyJSON = BaseNodeKeyJSON | ECInstancesNodeKeyJSON | ECClassGroupingNodeKeyJSON | ECPropertyGroupingNodeKeyJSON | LabelGroupingNodeKeyJSON;
203
120
  /**
204
121
  * Data structure that describes a presentation query
205
122
  * @public
@@ -1 +1 @@
1
- {"version":3,"file":"Key.d.ts","sourceRoot":"","sources":["../../../../src/presentation-common/hierarchy/Key.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAU,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACzD,OAAO,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAEpC;;;GAGG;AACH,oBAAY,iBAAiB;IAC3B,eAAe,oBAAoB;IACnC,mBAAmB,wBAAwB;IAC3C,sBAAsB,2BAA2B;IACjD,wBAAwB,6BAA6B;CACtD;AAED;;;GAGG;AACH,MAAM,MAAM,OAAO,GAAG,WAAW,GAAG,kBAAkB,GAAG,sBAAsB,GAAG,yBAAyB,GAAG,oBAAoB,CAAC;AACnI,cAAc;AAEd,yBAAiB,OAAO,CAAC;IACvB;;;OAGG;IAEH,SAAgB,MAAM,CAAC,GAAG,EAAE,OAAO,GAAG,WAAW,CAEhD;IAED;;;OAGG;IAEH,SAAgB,QAAQ,CAAC,IAAI,E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AAK,EAAE,MAAM,CAAC;CACf;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IAChC,kBAAkB;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,yBAAyB;IACzB,QAAQ,CAAC,EAAE,wBAAwB,EAAE,CAAC;CACvC;AAED;;;GAGG;AACH,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,IAAI,CAAC;IACX,KAAK,EAAE,UAAU,CAAC;CACnB;AAED;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,OAAO,CAAC;IACd,KAAK,EAAE,UAAU,EAAE,CAAC;CACrB;AAED;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,SAAS,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,KAAK,EAAE,GAAG,CAAC;CACZ;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,UAAU,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,KAAK,EAAE,GAAG,EAAE,CAAC;CACd;AAED;;;GAGG;AACH,MAAM,MAAM,wBAAwB,GAAG,SAAS,GAAG,YAAY,GAAG,cAAc,GAAG,iBAAiB,CAAC"}
@@ -22,47 +22,29 @@ export var StandardNodeTypes;
22
22
  // eslint-disable-next-line @typescript-eslint/no-redeclare
23
23
  export var NodeKey;
24
24
  (function (NodeKey) {
25
- /**
26
- * Serialize given [[NodeKey]] to JSON
27
- * @deprecated in 3.x. Use [[NodeKey]].
28
- */
29
- // eslint-disable-next-line @typescript-eslint/no-deprecated
30
- function toJSON(key) {
31
- return { ...key };
32
- }
33
- NodeKey.toJSON = toJSON;
34
- /**
35
- * Deserialize node key from JSON
36
- * @deprecated in 3.x. Use [[NodeKey]].
37
- */
38
- // eslint-disable-next-line @typescript-eslint/no-deprecated
39
- function fromJSON(json) {
40
- return { version: 1, ...json };
41
- }
42
- NodeKey.fromJSON = fromJSON;
43
- // eslint-disable-next-line @typescript-eslint/no-deprecated
25
+ /** Checks if the supplied key is an [[ECInstancesNodeKey]] */
44
26
  function isInstancesNodeKey(key) {
45
27
  return key.type === StandardNodeTypes.ECInstancesNode;
46
28
  }
47
29
  NodeKey.isInstancesNodeKey = isInstancesNodeKey;
48
- // eslint-disable-next-line @typescript-eslint/no-deprecated
30
+ /** Checks if the supplied key is an [[ECClassGroupingNodeKey]] */
49
31
  function isClassGroupingNodeKey(key) {
50
32
  return key.type === StandardNodeTypes.ECClassGroupingNode;
51
33
  }
52
34
  NodeKey.isClassGroupingNodeKey = isClassGroupingNodeKey;
53
- // eslint-disable-next-line @typescript-eslint/no-deprecated
35
+ /** Checks if the supplied key is an [[ECPropertyGroupingNodeKey]] */
54
36
  function isPropertyGroupingNodeKey(key) {
55
37
  return key.type === StandardNodeTypes.ECPropertyGroupingNode;
56
38
  }
57
39
  NodeKey.isPropertyGroupingNodeKey = isPropertyGroupingNodeKey;
58
- // eslint-disable-next-line @typescript-eslint/no-deprecated
40
+ /** Checks if the supplied key is a [[LabelGroupingNodeKey]] */
59
41
  function isLabelGroupingNodeKey(key) {
60
42
  return key.type === StandardNodeTypes.DisplayLabelGroupingNode;
61
43
  }
62
44
  NodeKey.isLabelGroupingNodeKey = isLabelGroupingNodeKey;
63
- // eslint-disable-next-line @typescript-eslint/no-deprecated
45
+ /** Checks if the supplied key is a grouping node key */
64
46
  function isGroupingNodeKey(key) {
65
- return isClassGroupingNodeKey(key) || isPropertyGroupingNodeKey(key) || isLabelGroupingNodeKey(key); // eslint-disable-line @typescript-eslint/no-deprecated
47
+ return isClassGroupingNodeKey(key) || isPropertyGroupingNodeKey(key) || isLabelGroupingNodeKey(key);
66
48
  }
67
49
  NodeKey.isGroupingNodeKey = isGroupingNodeKey;
68
50
  /**