@itwin/appui-abstract 4.1.0-dev.4 → 4.1.0-dev.40

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 (194) hide show
  1. package/CHANGELOG.md +20 -1
  2. package/lib/cjs/appui-abstract/BaseUiItemsProvider.d.ts +31 -0
  3. package/lib/cjs/appui-abstract/BaseUiItemsProvider.d.ts.map +1 -0
  4. package/lib/cjs/appui-abstract/BaseUiItemsProvider.js +80 -0
  5. package/lib/cjs/appui-abstract/BaseUiItemsProvider.js.map +1 -0
  6. package/lib/cjs/appui-abstract/UiAdmin.js.map +1 -1
  7. package/lib/cjs/appui-abstract/UiItemsManager.d.ts +114 -0
  8. package/lib/cjs/appui-abstract/UiItemsManager.d.ts.map +1 -0
  9. package/lib/cjs/appui-abstract/UiItemsManager.js +194 -0
  10. package/lib/cjs/appui-abstract/UiItemsManager.js.map +1 -0
  11. package/lib/cjs/appui-abstract/UiItemsProvider.d.ts +30 -0
  12. package/lib/cjs/appui-abstract/UiItemsProvider.d.ts.map +1 -0
  13. package/lib/cjs/appui-abstract/UiItemsProvider.js +10 -0
  14. package/lib/cjs/appui-abstract/UiItemsProvider.js.map +1 -0
  15. package/lib/cjs/appui-abstract/backstage/BackstageItem.d.ts +92 -0
  16. package/lib/cjs/appui-abstract/backstage/BackstageItem.d.ts.map +1 -0
  17. package/lib/cjs/appui-abstract/backstage/BackstageItem.js +71 -0
  18. package/lib/cjs/appui-abstract/backstage/BackstageItem.js.map +1 -0
  19. package/lib/cjs/appui-abstract/backstage/BackstageItemsManager.d.ts +39 -0
  20. package/lib/cjs/appui-abstract/backstage/BackstageItemsManager.d.ts.map +1 -0
  21. package/lib/cjs/appui-abstract/backstage/BackstageItemsManager.js +134 -0
  22. package/lib/cjs/appui-abstract/backstage/BackstageItemsManager.js.map +1 -0
  23. package/lib/cjs/appui-abstract/common/KeyboardKey.js.map +1 -1
  24. package/lib/cjs/appui-abstract/content/ContentLayoutProps.js.map +1 -1
  25. package/lib/cjs/appui-abstract/content/StandardContentLayouts.js.map +1 -1
  26. package/lib/cjs/appui-abstract/dialogs/DialogItem.js.map +1 -1
  27. package/lib/cjs/appui-abstract/dialogs/UiDataProvider.js.map +1 -1
  28. package/lib/cjs/appui-abstract/dialogs/UiLayoutDataProvider.js.map +1 -1
  29. package/lib/cjs/appui-abstract/items/AbstractItemProps.js.map +1 -1
  30. package/lib/cjs/appui-abstract/items/AbstractMenuItemProps.js.map +1 -1
  31. package/lib/cjs/appui-abstract/items/AbstractToolbarProps.js.map +1 -1
  32. package/lib/cjs/appui-abstract/items/BadgeType.js.map +1 -1
  33. package/lib/cjs/appui-abstract/items/ConditionalBooleanValue.js.map +1 -1
  34. package/lib/cjs/appui-abstract/items/ConditionalStringValue.js.map +1 -1
  35. package/lib/cjs/appui-abstract/items/ProvidedItem.d.ts +12 -0
  36. package/lib/cjs/appui-abstract/items/ProvidedItem.d.ts.map +1 -0
  37. package/lib/cjs/appui-abstract/items/ProvidedItem.js +10 -0
  38. package/lib/cjs/appui-abstract/items/ProvidedItem.js.map +1 -0
  39. package/lib/cjs/appui-abstract/items/RelativePosition.js.map +1 -1
  40. package/lib/cjs/appui-abstract/items/StageUsage.d.ts +17 -0
  41. package/lib/cjs/appui-abstract/items/StageUsage.d.ts.map +1 -0
  42. package/lib/cjs/appui-abstract/items/StageUsage.js +25 -0
  43. package/lib/cjs/appui-abstract/items/StageUsage.js.map +1 -0
  44. package/lib/cjs/appui-abstract/notification/MessagePresenter.js.map +1 -1
  45. package/lib/cjs/appui-abstract/notification/MessageSeverity.js.map +1 -1
  46. package/lib/cjs/appui-abstract/properties/Description.js.map +1 -1
  47. package/lib/cjs/appui-abstract/properties/EditorParams.js.map +1 -1
  48. package/lib/cjs/appui-abstract/properties/PrimitiveTypes.js.map +1 -1
  49. package/lib/cjs/appui-abstract/properties/Record.js.map +1 -1
  50. package/lib/cjs/appui-abstract/properties/StandardEditorNames.js.map +1 -1
  51. package/lib/cjs/appui-abstract/properties/StandardTypeNames.js.map +1 -1
  52. package/lib/cjs/appui-abstract/properties/Value.js.map +1 -1
  53. package/lib/cjs/appui-abstract/quantity/BaseQuantityDescription.js.map +1 -1
  54. package/lib/cjs/appui-abstract/statusbar/StatusBarItem.d.ts +129 -0
  55. package/lib/cjs/appui-abstract/statusbar/StatusBarItem.d.ts.map +1 -0
  56. package/lib/cjs/appui-abstract/statusbar/StatusBarItem.js +88 -0
  57. package/lib/cjs/appui-abstract/statusbar/StatusBarItem.js.map +1 -0
  58. package/lib/cjs/appui-abstract/statusbar/StatusBarItemsManager.d.ts +40 -0
  59. package/lib/cjs/appui-abstract/statusbar/StatusBarItemsManager.d.ts.map +1 -0
  60. package/lib/cjs/appui-abstract/statusbar/StatusBarItemsManager.js +136 -0
  61. package/lib/cjs/appui-abstract/statusbar/StatusBarItemsManager.js.map +1 -0
  62. package/lib/cjs/appui-abstract/toolbars/ToolbarItem.d.ts +27 -1
  63. package/lib/cjs/appui-abstract/toolbars/ToolbarItem.d.ts.map +1 -1
  64. package/lib/cjs/appui-abstract/toolbars/ToolbarItem.js +23 -1
  65. package/lib/cjs/appui-abstract/toolbars/ToolbarItem.js.map +1 -1
  66. package/lib/cjs/appui-abstract/toolbars/ToolbarItemsManager.d.ts +46 -0
  67. package/lib/cjs/appui-abstract/toolbars/ToolbarItemsManager.d.ts.map +1 -0
  68. package/lib/cjs/appui-abstract/toolbars/ToolbarItemsManager.js +236 -0
  69. package/lib/cjs/appui-abstract/toolbars/ToolbarItemsManager.js.map +1 -0
  70. package/lib/cjs/appui-abstract/utils/IconSpecUtilities.js.map +1 -1
  71. package/lib/cjs/appui-abstract/utils/PointProps.js.map +1 -1
  72. package/lib/cjs/appui-abstract/utils/UiError.js.map +1 -1
  73. package/lib/cjs/appui-abstract/utils/UiEvent.js.map +1 -1
  74. package/lib/cjs/appui-abstract/utils/UiEventDispatcher.js.map +1 -1
  75. package/lib/cjs/appui-abstract/utils/callbacks.js.map +1 -1
  76. package/lib/cjs/appui-abstract/utils/filter/charCode.js.map +1 -1
  77. package/lib/cjs/appui-abstract/utils/filter/filters.js.map +1 -1
  78. package/lib/cjs/appui-abstract/utils/filter/map.js.map +1 -1
  79. package/lib/cjs/appui-abstract/utils/filter/strings.js.map +1 -1
  80. package/lib/cjs/appui-abstract/utils/isLetter.js.map +1 -1
  81. package/lib/cjs/appui-abstract/utils/misc.js.map +1 -1
  82. package/lib/cjs/appui-abstract/widget/AbstractWidgetProps.d.ts +87 -0
  83. package/lib/cjs/appui-abstract/widget/AbstractWidgetProps.d.ts.map +1 -0
  84. package/lib/cjs/appui-abstract/widget/AbstractWidgetProps.js +10 -0
  85. package/lib/cjs/appui-abstract/widget/AbstractWidgetProps.js.map +1 -0
  86. package/lib/cjs/appui-abstract/widget/StagePanel.d.ts +37 -0
  87. package/lib/cjs/appui-abstract/widget/StagePanel.d.ts.map +1 -0
  88. package/lib/cjs/appui-abstract/widget/StagePanel.js +47 -0
  89. package/lib/cjs/appui-abstract/widget/StagePanel.js.map +1 -0
  90. package/lib/cjs/appui-abstract/widget/WidgetState.d.ts +20 -0
  91. package/lib/cjs/appui-abstract/widget/WidgetState.d.ts.map +1 -0
  92. package/lib/cjs/appui-abstract/widget/WidgetState.js +28 -0
  93. package/lib/cjs/appui-abstract/widget/WidgetState.js.map +1 -0
  94. package/lib/cjs/appui-abstract.d.ts +31 -0
  95. package/lib/cjs/appui-abstract.d.ts.map +1 -1
  96. package/lib/cjs/appui-abstract.js +31 -0
  97. package/lib/cjs/appui-abstract.js.map +1 -1
  98. package/lib/esm/appui-abstract/BaseUiItemsProvider.d.ts +31 -0
  99. package/lib/esm/appui-abstract/BaseUiItemsProvider.d.ts.map +1 -0
  100. package/lib/esm/appui-abstract/BaseUiItemsProvider.js +76 -0
  101. package/lib/esm/appui-abstract/BaseUiItemsProvider.js.map +1 -0
  102. package/lib/esm/appui-abstract/UiAdmin.js.map +1 -1
  103. package/lib/esm/appui-abstract/UiItemsManager.d.ts +114 -0
  104. package/lib/esm/appui-abstract/UiItemsManager.d.ts.map +1 -0
  105. package/lib/esm/appui-abstract/UiItemsManager.js +191 -0
  106. package/lib/esm/appui-abstract/UiItemsManager.js.map +1 -0
  107. package/lib/esm/appui-abstract/UiItemsProvider.d.ts +30 -0
  108. package/lib/esm/appui-abstract/UiItemsProvider.d.ts.map +1 -0
  109. package/lib/esm/appui-abstract/UiItemsProvider.js +9 -0
  110. package/lib/esm/appui-abstract/UiItemsProvider.js.map +1 -0
  111. package/lib/esm/appui-abstract/backstage/BackstageItem.d.ts +92 -0
  112. package/lib/esm/appui-abstract/backstage/BackstageItem.d.ts.map +1 -0
  113. package/lib/esm/appui-abstract/backstage/BackstageItem.js +66 -0
  114. package/lib/esm/appui-abstract/backstage/BackstageItem.js.map +1 -0
  115. package/lib/esm/appui-abstract/backstage/BackstageItemsManager.d.ts +39 -0
  116. package/lib/esm/appui-abstract/backstage/BackstageItemsManager.d.ts.map +1 -0
  117. package/lib/esm/appui-abstract/backstage/BackstageItemsManager.js +130 -0
  118. package/lib/esm/appui-abstract/backstage/BackstageItemsManager.js.map +1 -0
  119. package/lib/esm/appui-abstract/common/KeyboardKey.js.map +1 -1
  120. package/lib/esm/appui-abstract/content/ContentLayoutProps.js.map +1 -1
  121. package/lib/esm/appui-abstract/content/StandardContentLayouts.js.map +1 -1
  122. package/lib/esm/appui-abstract/dialogs/DialogItem.js.map +1 -1
  123. package/lib/esm/appui-abstract/dialogs/UiDataProvider.js.map +1 -1
  124. package/lib/esm/appui-abstract/dialogs/UiLayoutDataProvider.js.map +1 -1
  125. package/lib/esm/appui-abstract/items/AbstractItemProps.js.map +1 -1
  126. package/lib/esm/appui-abstract/items/AbstractMenuItemProps.js.map +1 -1
  127. package/lib/esm/appui-abstract/items/AbstractToolbarProps.js.map +1 -1
  128. package/lib/esm/appui-abstract/items/BadgeType.js.map +1 -1
  129. package/lib/esm/appui-abstract/items/ConditionalBooleanValue.js.map +1 -1
  130. package/lib/esm/appui-abstract/items/ConditionalStringValue.js.map +1 -1
  131. package/lib/esm/appui-abstract/items/ProvidedItem.d.ts +12 -0
  132. package/lib/esm/appui-abstract/items/ProvidedItem.d.ts.map +1 -0
  133. package/lib/esm/appui-abstract/items/ProvidedItem.js +9 -0
  134. package/lib/esm/appui-abstract/items/ProvidedItem.js.map +1 -0
  135. package/lib/esm/appui-abstract/items/RelativePosition.js.map +1 -1
  136. package/lib/esm/appui-abstract/items/StageUsage.d.ts +17 -0
  137. package/lib/esm/appui-abstract/items/StageUsage.d.ts.map +1 -0
  138. package/lib/esm/appui-abstract/items/StageUsage.js +22 -0
  139. package/lib/esm/appui-abstract/items/StageUsage.js.map +1 -0
  140. package/lib/esm/appui-abstract/notification/MessagePresenter.js.map +1 -1
  141. package/lib/esm/appui-abstract/notification/MessageSeverity.js.map +1 -1
  142. package/lib/esm/appui-abstract/properties/Description.js.map +1 -1
  143. package/lib/esm/appui-abstract/properties/EditorParams.js.map +1 -1
  144. package/lib/esm/appui-abstract/properties/PrimitiveTypes.js.map +1 -1
  145. package/lib/esm/appui-abstract/properties/Record.js.map +1 -1
  146. package/lib/esm/appui-abstract/properties/StandardEditorNames.js.map +1 -1
  147. package/lib/esm/appui-abstract/properties/StandardTypeNames.js.map +1 -1
  148. package/lib/esm/appui-abstract/properties/Value.js.map +1 -1
  149. package/lib/esm/appui-abstract/quantity/BaseQuantityDescription.js.map +1 -1
  150. package/lib/esm/appui-abstract/statusbar/StatusBarItem.d.ts +129 -0
  151. package/lib/esm/appui-abstract/statusbar/StatusBarItem.d.ts.map +1 -0
  152. package/lib/esm/appui-abstract/statusbar/StatusBarItem.js +82 -0
  153. package/lib/esm/appui-abstract/statusbar/StatusBarItem.js.map +1 -0
  154. package/lib/esm/appui-abstract/statusbar/StatusBarItemsManager.d.ts +40 -0
  155. package/lib/esm/appui-abstract/statusbar/StatusBarItemsManager.d.ts.map +1 -0
  156. package/lib/esm/appui-abstract/statusbar/StatusBarItemsManager.js +132 -0
  157. package/lib/esm/appui-abstract/statusbar/StatusBarItemsManager.js.map +1 -0
  158. package/lib/esm/appui-abstract/toolbars/ToolbarItem.d.ts +27 -1
  159. package/lib/esm/appui-abstract/toolbars/ToolbarItem.d.ts.map +1 -1
  160. package/lib/esm/appui-abstract/toolbars/ToolbarItem.js +22 -0
  161. package/lib/esm/appui-abstract/toolbars/ToolbarItem.js.map +1 -1
  162. package/lib/esm/appui-abstract/toolbars/ToolbarItemsManager.d.ts +46 -0
  163. package/lib/esm/appui-abstract/toolbars/ToolbarItemsManager.d.ts.map +1 -0
  164. package/lib/esm/appui-abstract/toolbars/ToolbarItemsManager.js +232 -0
  165. package/lib/esm/appui-abstract/toolbars/ToolbarItemsManager.js.map +1 -0
  166. package/lib/esm/appui-abstract/utils/IconSpecUtilities.js.map +1 -1
  167. package/lib/esm/appui-abstract/utils/PointProps.js.map +1 -1
  168. package/lib/esm/appui-abstract/utils/UiError.js.map +1 -1
  169. package/lib/esm/appui-abstract/utils/UiEvent.js.map +1 -1
  170. package/lib/esm/appui-abstract/utils/UiEventDispatcher.js.map +1 -1
  171. package/lib/esm/appui-abstract/utils/callbacks.js.map +1 -1
  172. package/lib/esm/appui-abstract/utils/filter/charCode.js.map +1 -1
  173. package/lib/esm/appui-abstract/utils/filter/filters.js.map +1 -1
  174. package/lib/esm/appui-abstract/utils/filter/map.js.map +1 -1
  175. package/lib/esm/appui-abstract/utils/filter/strings.js.map +1 -1
  176. package/lib/esm/appui-abstract/utils/isLetter.js.map +1 -1
  177. package/lib/esm/appui-abstract/utils/misc.js.map +1 -1
  178. package/lib/esm/appui-abstract/widget/AbstractWidgetProps.d.ts +87 -0
  179. package/lib/esm/appui-abstract/widget/AbstractWidgetProps.d.ts.map +1 -0
  180. package/lib/esm/appui-abstract/widget/AbstractWidgetProps.js +9 -0
  181. package/lib/esm/appui-abstract/widget/AbstractWidgetProps.js.map +1 -0
  182. package/lib/esm/appui-abstract/widget/StagePanel.d.ts +37 -0
  183. package/lib/esm/appui-abstract/widget/StagePanel.d.ts.map +1 -0
  184. package/lib/esm/appui-abstract/widget/StagePanel.js +44 -0
  185. package/lib/esm/appui-abstract/widget/StagePanel.js.map +1 -0
  186. package/lib/esm/appui-abstract/widget/WidgetState.d.ts +20 -0
  187. package/lib/esm/appui-abstract/widget/WidgetState.d.ts.map +1 -0
  188. package/lib/esm/appui-abstract/widget/WidgetState.js +25 -0
  189. package/lib/esm/appui-abstract/widget/WidgetState.js.map +1 -0
  190. package/lib/esm/appui-abstract.d.ts +31 -0
  191. package/lib/esm/appui-abstract.d.ts.map +1 -1
  192. package/lib/esm/appui-abstract.js +31 -0
  193. package/lib/esm/appui-abstract.js.map +1 -1
  194. package/package.json +15 -36
@@ -0,0 +1,236 @@
1
+ "use strict";
2
+ /*---------------------------------------------------------------------------------------------
3
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
4
+ * See LICENSE.md in the project root for license terms and full copyright notice.
5
+ *--------------------------------------------------------------------------------------------*/
6
+ /** @packageDocumentation
7
+ * @module Toolbar
8
+ */
9
+ Object.defineProperty(exports, "__esModule", { value: true });
10
+ exports.ToolbarItemsManager = void 0;
11
+ const core_bentley_1 = require("@itwin/core-bentley");
12
+ const ConditionalBooleanValue_1 = require("../items/ConditionalBooleanValue");
13
+ const ConditionalStringValue_1 = require("../items/ConditionalStringValue");
14
+ const ToolbarItem_1 = require("./ToolbarItem");
15
+ const isInstance = (args) => {
16
+ return !Array.isArray(args);
17
+ };
18
+ /**
19
+ * Controls status bar items.
20
+ * @internal
21
+ */
22
+ class ToolbarItemsManager {
23
+ constructor(items) {
24
+ this._items = [];
25
+ /** Event raised when Toolbar items are changed.
26
+ * @internal
27
+ */
28
+ this.onItemsChanged = new core_bentley_1.BeEvent();
29
+ if (items)
30
+ this.loadItemsInternal(items, true, false);
31
+ }
32
+ loadItemsInternal(items, processConditions, sendItemChanged) {
33
+ if (processConditions && items) {
34
+ const eventIds = ToolbarItemsManager.getSyncIdsOfInterest(items);
35
+ if (0 !== eventIds.length) {
36
+ const { itemsUpdated, updatedItems } = this.internalRefreshAffectedItems(items, new Set(eventIds));
37
+ // istanbul ignore else
38
+ if (itemsUpdated)
39
+ items = updatedItems;
40
+ }
41
+ }
42
+ this._items = items;
43
+ if (sendItemChanged)
44
+ this.onItemsChanged.raiseEvent({ items });
45
+ }
46
+ /** load items but do not fire onItemsChanged
47
+ * @internal
48
+ */
49
+ loadItems(items) {
50
+ this.loadItemsInternal(items, true, false);
51
+ }
52
+ /** Get an array of the Toolbar items */
53
+ get items() {
54
+ return this._items;
55
+ }
56
+ set items(items) {
57
+ // istanbul ignore else
58
+ if (items !== this._items)
59
+ this.loadItemsInternal(items, true, true);
60
+ }
61
+ add(itemOrItems) {
62
+ let itemsToAdd;
63
+ if (isInstance(itemOrItems))
64
+ itemsToAdd = [itemOrItems];
65
+ else {
66
+ itemsToAdd = itemOrItems.filter((itemToAdd, index) => itemOrItems.findIndex((item) => item.id === itemToAdd.id) === index);
67
+ }
68
+ itemsToAdd = itemsToAdd.filter((itemToAdd) => this._items.find((item) => item.id === itemToAdd.id) === undefined);
69
+ if (itemsToAdd.length === 0)
70
+ return;
71
+ const items = [
72
+ ...this._items,
73
+ ...itemsToAdd,
74
+ ];
75
+ this.items = items;
76
+ }
77
+ /** Remove Toolbar items based on id */
78
+ remove(itemIdOrItemIds) {
79
+ const items = this._items.filter((item) => {
80
+ return isInstance(itemIdOrItemIds) ? item.id !== itemIdOrItemIds : !itemIdOrItemIds.find((itemId) => itemId === item.id);
81
+ });
82
+ this.items = items;
83
+ }
84
+ /** @internal */
85
+ removeAll() {
86
+ this._items = [];
87
+ }
88
+ static gatherSyncIds(eventIds, items) {
89
+ for (const item of items) {
90
+ for (const [, entry] of Object.entries(item)) {
91
+ if (entry instanceof ConditionalBooleanValue_1.ConditionalBooleanValue) {
92
+ entry.syncEventIds.forEach((eventId) => eventIds.add(eventId.toLowerCase()));
93
+ }
94
+ else /* istanbul ignore else */ if (entry instanceof ConditionalStringValue_1.ConditionalStringValue) {
95
+ entry.syncEventIds.forEach((eventId) => eventIds.add(eventId.toLowerCase()));
96
+ }
97
+ }
98
+ // istanbul ignore else
99
+ if (ToolbarItem_1.ToolbarItemUtilities.isGroupButton(item)) {
100
+ this.gatherSyncIds(eventIds, item.items);
101
+ }
102
+ }
103
+ }
104
+ static getSyncIdsOfInterest(items) {
105
+ const eventIds = new Set();
106
+ this.gatherSyncIds(eventIds, items);
107
+ return [...eventIds.values()];
108
+ }
109
+ static refreshChildItems(parentItem, eventIds) {
110
+ const updatedItems = [];
111
+ let itemsUpdated = false;
112
+ for (const item of parentItem.items) {
113
+ const updatedItem = { ...item };
114
+ if (ToolbarItem_1.ToolbarItemUtilities.isGroupButton(updatedItem)) {
115
+ const { childrenUpdated, childItems } = this.refreshChildItems(updatedItem, eventIds);
116
+ // istanbul ignore else
117
+ if (childrenUpdated) {
118
+ updatedItem.items = childItems;
119
+ itemsUpdated = true;
120
+ }
121
+ }
122
+ for (const [, entry] of Object.entries(updatedItem)) {
123
+ if (entry instanceof ConditionalBooleanValue_1.ConditionalBooleanValue) {
124
+ // istanbul ignore else
125
+ if (ConditionalBooleanValue_1.ConditionalBooleanValue.refreshValue(entry, eventIds))
126
+ itemsUpdated = true;
127
+ }
128
+ else /* istanbul ignore else */ if (entry instanceof ConditionalStringValue_1.ConditionalStringValue) {
129
+ // istanbul ignore else
130
+ if (ConditionalStringValue_1.ConditionalStringValue.refreshValue(entry, eventIds))
131
+ itemsUpdated = true;
132
+ }
133
+ }
134
+ updatedItems.push(updatedItem);
135
+ }
136
+ return { childrenUpdated: itemsUpdated, childItems: updatedItems };
137
+ }
138
+ internalRefreshAffectedItems(items, eventIds) {
139
+ // istanbul ignore next
140
+ if (0 === eventIds.size)
141
+ return { itemsUpdated: false, updatedItems: [] };
142
+ let updateRequired = false;
143
+ const newItems = [];
144
+ for (const item of items) {
145
+ const updatedItem = { ...item };
146
+ if (ToolbarItem_1.ToolbarItemUtilities.isGroupButton(updatedItem)) {
147
+ const { childrenUpdated, childItems } = ToolbarItemsManager.refreshChildItems(updatedItem, eventIds);
148
+ // istanbul ignore else
149
+ if (childrenUpdated) {
150
+ updatedItem.items = childItems;
151
+ updateRequired = true;
152
+ }
153
+ }
154
+ for (const [, entry] of Object.entries(updatedItem)) {
155
+ if (entry instanceof ConditionalBooleanValue_1.ConditionalBooleanValue) {
156
+ // istanbul ignore else
157
+ if (ConditionalBooleanValue_1.ConditionalBooleanValue.refreshValue(entry, eventIds))
158
+ updateRequired = true;
159
+ }
160
+ else /* istanbul ignore else */ if (entry instanceof ConditionalStringValue_1.ConditionalStringValue) {
161
+ // istanbul ignore else
162
+ if (ConditionalStringValue_1.ConditionalStringValue.refreshValue(entry, eventIds))
163
+ updateRequired = true;
164
+ }
165
+ }
166
+ newItems.push(updatedItem);
167
+ }
168
+ return { itemsUpdated: updateRequired, updatedItems: newItems };
169
+ }
170
+ refreshAffectedItems(eventIds) {
171
+ // istanbul ignore next
172
+ if (0 === eventIds.size)
173
+ return;
174
+ const { itemsUpdated, updatedItems } = this.internalRefreshAffectedItems(this.items, eventIds);
175
+ // istanbul ignore else
176
+ if (itemsUpdated)
177
+ this.loadItemsInternal(updatedItems, false, true);
178
+ }
179
+ static isActiveToolIdRefreshRequiredForChildren(children, toolId) {
180
+ for (const item of children) {
181
+ if (ToolbarItem_1.ToolbarItemUtilities.isGroupButton(item)) {
182
+ if (this.isActiveToolIdRefreshRequiredForChildren(item.items, toolId))
183
+ return true;
184
+ }
185
+ else {
186
+ const isActive = !!item.isActive;
187
+ if ((isActive && item.id !== toolId) || (!isActive && item.id === toolId))
188
+ return true;
189
+ }
190
+ }
191
+ return false;
192
+ }
193
+ isActiveToolIdRefreshRequired(toolId) {
194
+ for (const item of this.items) {
195
+ if (ToolbarItem_1.ToolbarItemUtilities.isGroupButton(item)) {
196
+ if (ToolbarItemsManager.isActiveToolIdRefreshRequiredForChildren(item.items, toolId))
197
+ return true;
198
+ }
199
+ else {
200
+ const isActive = !!item.isActive;
201
+ if ((isActive && item.id !== toolId) || (!isActive && item.id === toolId))
202
+ return true;
203
+ }
204
+ }
205
+ return false;
206
+ }
207
+ static refreshActiveToolIdInChildItems(parentItem, toolId) {
208
+ const newChildren = [];
209
+ for (const item of parentItem.items) {
210
+ const updatedItem = { ...item };
211
+ if (ToolbarItem_1.ToolbarItemUtilities.isGroupButton(updatedItem)) {
212
+ updatedItem.items = ToolbarItemsManager.refreshActiveToolIdInChildItems(updatedItem, toolId);
213
+ }
214
+ updatedItem.isActive = (updatedItem.id === toolId);
215
+ newChildren.push(updatedItem);
216
+ }
217
+ return newChildren;
218
+ }
219
+ setActiveToolId(toolId) {
220
+ // first see if any updates are really necessary
221
+ if (!this.isActiveToolIdRefreshRequired(toolId))
222
+ return;
223
+ const newItems = [];
224
+ for (const item of this.items) {
225
+ const updatedItem = { ...item };
226
+ if (ToolbarItem_1.ToolbarItemUtilities.isGroupButton(updatedItem)) {
227
+ updatedItem.items = ToolbarItemsManager.refreshActiveToolIdInChildItems(updatedItem, toolId);
228
+ }
229
+ updatedItem.isActive = (updatedItem.id === toolId);
230
+ newItems.push(updatedItem);
231
+ }
232
+ this.items = newItems;
233
+ }
234
+ }
235
+ exports.ToolbarItemsManager = ToolbarItemsManager;
236
+ //# sourceMappingURL=ToolbarItemsManager.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ToolbarItemsManager.js","sourceRoot":"","sources":["../../../../src/appui-abstract/toolbars/ToolbarItemsManager.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAA8C;AAC9C,8EAA2E;AAC3E,4EAAyE;AACzE,+CAAkH;AAMlH,MAAM,UAAU,GAAG,CAAI,IAAwB,EAAa,EAAE;IAC5D,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;AAC9B,CAAC,CAAC;AASF;;;GAGG;AACH,MAAa,mBAAmB;IAG9B,YAAY,KAAwC;QAF1C,WAAM,GAAqC,EAAE,C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G,CAAC,WAAW,CAAC,EAAE,KAAK,MAAM,CAAC,CAAC;YACnD,WAAW,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;SAC/B;QACD,OAAO,WAAW,CAAC;IACrB,CAAC;IAEM,eAAe,CAAC,MAAc;QACnC,gDAAgD;QAChD,IAAI,CAAC,IAAI,CAAC,6BAA6B,CAAC,MAAM,CAAC;YAC7C,OAAO;QAET,MAAM,QAAQ,GAAwB,EAAE,CAAC;QACzC,KAAK,MAAM,IAAI,IAAI,IAAI,CAAC,KAAK,EAAE;YAC7B,MAAM,WAAW,GAAG,EAAE,GAAG,IAAI,EAAE,CAAC;YAEhC,IAAI,kCAAoB,CAAC,aAAa,CAAC,WAAW,CAAC,EAAE;gBACnD,WAAW,CAAC,KAAK,GAAG,mBAAmB,CAAC,+BAA+B,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC;aAC9F;YAED,WAAW,CAAC,QAAQ,GAAG,CAAC,WAAW,CAAC,EAAE,KAAK,MAAM,CAAC,CAAC;YACnD,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;SAC5B;QAED,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC;IACxB,CAAC;CAEF;AAzPD,kDAyPC","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 Toolbar\n */\n\nimport { BeEvent } from \"@itwin/core-bentley\";\nimport { ConditionalBooleanValue } from \"../items/ConditionalBooleanValue\";\nimport { ConditionalStringValue } from \"../items/ConditionalStringValue\";\nimport { ActionButton, CommonToolbarItem, GroupButton, ToolbarItemId, ToolbarItemUtilities } from \"./ToolbarItem\";\n\n/* eslint-disable deprecation/deprecation */\n\ntype InstanceOrArray<T> = T | ReadonlyArray<T>;\n\nconst isInstance = <T>(args: InstanceOrArray<T>): args is T => {\n return !Array.isArray(args);\n};\n\n/** Arguments of [[ToolbarItemsManager.onChanged]] event.\n * @internal\n */\nexport interface ToolbarItemsChangedArgs {\n readonly items: ReadonlyArray<CommonToolbarItem>;\n}\n\n/**\n * Controls status bar items.\n * @internal\n */\nexport class ToolbarItemsManager {\n protected _items: ReadonlyArray<CommonToolbarItem> = [];\n\n constructor(items?: ReadonlyArray<CommonToolbarItem>) {\n if (items)\n this.loadItemsInternal(items, true, false);\n }\n\n /** Event raised when Toolbar items are changed.\n * @internal\n */\n public readonly onItemsChanged = new BeEvent<(args: ToolbarItemsChangedArgs) => void>();\n\n private loadItemsInternal(items: ReadonlyArray<CommonToolbarItem>, processConditions: boolean, sendItemChanged: boolean) {\n if (processConditions && items) {\n const eventIds = ToolbarItemsManager.getSyncIdsOfInterest(items);\n if (0 !== eventIds.length) {\n const { itemsUpdated, updatedItems } = this.internalRefreshAffectedItems(items, new Set(eventIds));\n\n // istanbul ignore else\n if (itemsUpdated)\n items = updatedItems;\n }\n }\n\n this._items = items;\n if (sendItemChanged)\n this.onItemsChanged.raiseEvent({ items });\n }\n\n /** load items but do not fire onItemsChanged\n * @internal\n */\n public loadItems(items: ReadonlyArray<CommonToolbarItem>) {\n this.loadItemsInternal(items, true, false);\n }\n\n /** Get an array of the Toolbar items */\n public get items(): ReadonlyArray<CommonToolbarItem> {\n return this._items;\n }\n\n public set items(items: ReadonlyArray<CommonToolbarItem>) {\n // istanbul ignore else\n if (items !== this._items)\n this.loadItemsInternal(items, true, true);\n }\n\n public add(itemOrItems: CommonToolbarItem | ReadonlyArray<CommonToolbarItem>) {\n let itemsToAdd;\n if (isInstance(itemOrItems))\n itemsToAdd = [itemOrItems];\n else {\n itemsToAdd = itemOrItems.filter((itemToAdd, index) => itemOrItems.findIndex((item) => item.id === itemToAdd.id) === index);\n }\n itemsToAdd = itemsToAdd.filter((itemToAdd) => this._items.find((item) => item.id === itemToAdd.id) === undefined);\n if (itemsToAdd.length === 0)\n return;\n const items = [\n ...this._items,\n ...itemsToAdd,\n ];\n this.items = items;\n }\n\n /** Remove Toolbar items based on id */\n public remove(itemIdOrItemIds: ToolbarItemId | ReadonlyArray<ToolbarItemId\n >) {\n const items = this._items.filter((item) => {\n return isInstance(itemIdOrItemIds) ? item.id !== itemIdOrItemIds : !itemIdOrItemIds.find((itemId) => itemId === item.id);\n });\n this.items = items;\n }\n\n /** @internal */\n public removeAll() {\n this._items = [];\n }\n\n private static gatherSyncIds(eventIds: Set<string>, items: readonly CommonToolbarItem[]) {\n for (const item of items) {\n for (const [, entry] of Object.entries(item)) {\n if (entry instanceof ConditionalBooleanValue) {\n entry.syncEventIds.forEach((eventId: string) => eventIds.add(eventId.toLowerCase()));\n } else /* istanbul ignore else */ if (entry instanceof ConditionalStringValue) {\n entry.syncEventIds.forEach((eventId: string) => eventIds.add(eventId.toLowerCase()));\n }\n }\n\n // istanbul ignore else\n if (ToolbarItemUtilities.isGroupButton(item)) {\n this.gatherSyncIds(eventIds, item.items);\n }\n }\n }\n\n public static getSyncIdsOfInterest(items: readonly CommonToolbarItem[]): string[] {\n const eventIds = new Set<string>();\n this.gatherSyncIds(eventIds, items);\n return [...eventIds.values()];\n }\n\n private static refreshChildItems(parentItem: GroupButton, eventIds: Set<string>): { childrenUpdated: boolean, childItems: ReadonlyArray<ActionButton | GroupButton> } {\n const updatedItems: Array<ActionButton | GroupButton> = [];\n let itemsUpdated = false;\n\n for (const item of parentItem.items) {\n const updatedItem = { ...item };\n\n if (ToolbarItemUtilities.isGroupButton(updatedItem)) {\n const { childrenUpdated, childItems } = this.refreshChildItems(updatedItem, eventIds);\n // istanbul ignore else\n if (childrenUpdated) {\n updatedItem.items = childItems;\n itemsUpdated = true;\n }\n }\n\n for (const [, entry] of Object.entries(updatedItem)) {\n if (entry instanceof ConditionalBooleanValue) {\n // istanbul ignore else\n if (ConditionalBooleanValue.refreshValue(entry, eventIds))\n itemsUpdated = true;\n } else /* istanbul ignore else */ if (entry instanceof ConditionalStringValue) {\n // istanbul ignore else\n if (ConditionalStringValue.refreshValue(entry, eventIds))\n itemsUpdated = true;\n }\n }\n\n updatedItems.push(updatedItem);\n }\n return { childrenUpdated: itemsUpdated, childItems: updatedItems };\n }\n\n private internalRefreshAffectedItems(items: readonly CommonToolbarItem[], eventIds: Set<string>): { itemsUpdated: boolean, updatedItems: CommonToolbarItem[] } {\n // istanbul ignore next\n if (0 === eventIds.size)\n return { itemsUpdated: false, updatedItems: [] };\n\n let updateRequired = false;\n\n const newItems: CommonToolbarItem[] = [];\n for (const item of items) {\n const updatedItem = { ...item };\n\n if (ToolbarItemUtilities.isGroupButton(updatedItem)) {\n const { childrenUpdated, childItems } = ToolbarItemsManager.refreshChildItems(updatedItem, eventIds);\n // istanbul ignore else\n if (childrenUpdated) {\n updatedItem.items = childItems;\n updateRequired = true;\n }\n }\n\n for (const [, entry] of Object.entries(updatedItem)) {\n if (entry instanceof ConditionalBooleanValue) {\n // istanbul ignore else\n if (ConditionalBooleanValue.refreshValue(entry, eventIds))\n updateRequired = true;\n } else /* istanbul ignore else */ if (entry instanceof ConditionalStringValue) {\n // istanbul ignore else\n if (ConditionalStringValue.refreshValue(entry, eventIds))\n updateRequired = true;\n }\n }\n\n newItems.push(updatedItem);\n }\n\n return { itemsUpdated: updateRequired, updatedItems: newItems };\n }\n\n public refreshAffectedItems(eventIds: Set<string>) {\n // istanbul ignore next\n if (0 === eventIds.size)\n return;\n\n const { itemsUpdated, updatedItems } = this.internalRefreshAffectedItems(this.items, eventIds);\n\n // istanbul ignore else\n if (itemsUpdated)\n this.loadItemsInternal(updatedItems, false, true);\n }\n\n private static isActiveToolIdRefreshRequiredForChildren(children: ReadonlyArray<ActionButton | GroupButton>, toolId: string): boolean {\n for (const item of children) {\n if (ToolbarItemUtilities.isGroupButton(item)) {\n if (this.isActiveToolIdRefreshRequiredForChildren(item.items, toolId))\n return true;\n } else {\n const isActive = !!item.isActive;\n if ((isActive && item.id !== toolId) || (!isActive && item.id === toolId))\n return true;\n }\n }\n return false;\n }\n\n private isActiveToolIdRefreshRequired(toolId: string): boolean {\n for (const item of this.items) {\n if (ToolbarItemUtilities.isGroupButton(item)) {\n if (ToolbarItemsManager.isActiveToolIdRefreshRequiredForChildren(item.items, toolId))\n return true;\n } else {\n const isActive = !!item.isActive;\n if ((isActive && item.id !== toolId) || (!isActive && item.id === toolId))\n return true;\n }\n }\n\n return false;\n }\n\n private static refreshActiveToolIdInChildItems(parentItem: GroupButton, toolId: string): Array<ActionButton | GroupButton> {\n const newChildren: Array<ActionButton | GroupButton> = [];\n for (const item of parentItem.items) {\n const updatedItem = { ...item };\n\n if (ToolbarItemUtilities.isGroupButton(updatedItem)) {\n updatedItem.items = ToolbarItemsManager.refreshActiveToolIdInChildItems(updatedItem, toolId);\n }\n\n updatedItem.isActive = (updatedItem.id === toolId);\n newChildren.push(updatedItem);\n }\n return newChildren;\n }\n\n public setActiveToolId(toolId: string) {\n // first see if any updates are really necessary\n if (!this.isActiveToolIdRefreshRequired(toolId))\n return;\n\n const newItems: CommonToolbarItem[] = [];\n for (const item of this.items) {\n const updatedItem = { ...item };\n\n if (ToolbarItemUtilities.isGroupButton(updatedItem)) {\n updatedItem.items = ToolbarItemsManager.refreshActiveToolIdInChildItems(updatedItem, toolId);\n }\n\n updatedItem.isActive = (updatedItem.id === toolId);\n newItems.push(updatedItem);\n }\n\n this.items = newItems;\n }\n\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"IconSpecUtilities.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/IconSpecUtilities.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH;;GAEG;AACH,MAAa,iBAAiB;IAK5B;;;MAGE;IACK,MAAM,CAAC,iBAAiB,CAAC,MAAc;QAC5C,OAAO,GAAG,iBAAiB,CAAC,UAAU,GAAG,MAAM,EAAE,CAAC;IACpD,CAAC;IACD;;MAEE;IACK,MAAM,CAAC,0BAA0B,CAAC,SAAiB;QACxD,OAAO,GAAG,iBAAiB,CAAC,oBAAoB,GAAG,SAAS,EAAE,CAAC;IACjE,CAAC;IAED;;;MAGE;IACK,MAAM,CAAC,YAAY,CAAC,QAAgB;QACzC,IAAI,QAAQ,CAAC,UAAU,CAAC,iBAAiB,CAAC,UAAU,CAAC,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE;YAC5E,OAAO,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;SAC1B;QAED,OAAO,SAAS,CAAC;IACnB,CAAC;IACD;;MAEE;IAEK,MAAM,CAAC,qBAAqB,CAAC,QAAgB;QAClD,IAAI,QAAQ,CAAC,UAAU,CAAC,iBAAiB,CAAC,oBAAoB,CAAC,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE;YACtF,OAAO,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;SAC1B;QAED,OAAO,SAAS,CAAC;IAEnB,CAAC;;AAxCD,+DAA+D;AACxC,4BAAU,GAAG,MAAM,CAAC;AACpB,sCAAoB,GAAG,SAAS,CAAC;AAH7C,8CAAiB","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Utilities\r\n */\r\n\r\n/** Creates an IconSpec with an SVG source and gets the SVG source from an IconSpec.\r\n * @public\r\n */\r\nexport class IconSpecUtilities {\r\n /** Prefix for an SVG IconSpec loaded with the Sprite loader */\r\n public static readonly SVG_PREFIX = \"svg:\";\r\n public static readonly WEB_COMPONENT_PREFIX = \"webSvg:\";\r\n\r\n /** Create an IconSpec for an SVG loaded into web component with sprite loader\r\n * This method is deprecated -- use createWebComponentIconSpec()\r\n * @public @deprecated in 3.2. Please avoid using the Sprite loader and use IconSpecUtilities.createWebComponentIconSpec() instead.\r\n */\r\n public static createSvgIconSpec(svgSrc: string): string {\r\n return `${IconSpecUtilities.SVG_PREFIX}${svgSrc}`;\r\n }\r\n /** Create an IconSpec for an SVG loaded into web component with svg-loader\r\n * @public\r\n */\r\n public static createWebComponentIconSpec(srcString: string): string {\r\n return `${IconSpecUtilities.WEB_COMPONENT_PREFIX}${srcString}`;\r\n }\r\n\r\n /** Get the SVG Source from an sprite IconSpec\r\n * This method is deprecated -- use getWebComponentSource()\r\n * @public @deprecated in 3.2. avoid using the Sprite loader and use IconSpecUtilities.getWebComponentSource() instead.\r\n */\r\n public static getSvgSource(iconSpec: string): string | undefined {\r\n if (iconSpec.startsWith(IconSpecUtilities.SVG_PREFIX) && iconSpec.length > 4) {\r\n return iconSpec.slice(4);\r\n }\r\n\r\n return undefined;\r\n }\r\n /** Get the SVG Source from an svg-loader IconSpec\r\n * @public\r\n */\r\n\r\n public static getWebComponentSource(iconSpec: string): string | undefined {\r\n if (iconSpec.startsWith(IconSpecUtilities.WEB_COMPONENT_PREFIX) && iconSpec.length > 7) {\r\n return iconSpec.slice(7);\r\n }\r\n\r\n return undefined;\r\n\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"IconSpecUtilities.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/IconSpecUtilities.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH;;GAEG;AACH,MAAa,iBAAiB;IAK5B;;;MAGE;IACK,MAAM,CAAC,iBAAiB,CAAC,MAAc;QAC5C,OAAO,GAAG,iBAAiB,CAAC,UAAU,GAAG,MAAM,EAAE,CAAC;IACpD,CAAC;IACD;;MAEE;IACK,MAAM,CAAC,0BAA0B,CAAC,SAAiB;QACxD,OAAO,GAAG,iBAAiB,CAAC,oBAAoB,GAAG,SAAS,EAAE,CAAC;IACjE,CAAC;IAED;;;MAGE;IACK,MAAM,CAAC,YAAY,CAAC,QAAgB;QACzC,IAAI,QAAQ,CAAC,UAAU,CAAC,iBAAiB,CAAC,UAAU,CAAC,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE;YAC5E,OAAO,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;SAC1B;QAED,OAAO,SAAS,CAAC;IACnB,CAAC;IACD;;MAEE;IAEK,MAAM,CAAC,qBAAqB,CAAC,QAAgB;QAClD,IAAI,QAAQ,CAAC,UAAU,CAAC,iBAAiB,CAAC,oBAAoB,CAAC,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE;YACtF,OAAO,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;SAC1B;QAED,OAAO,SAAS,CAAC;IAEnB,CAAC;;AAxCD,+DAA+D;AACxC,4BAAU,GAAG,MAAM,CAAC;AACpB,sCAAoB,GAAG,SAAS,CAAC;AAH7C,8CAAiB","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 Utilities\n */\n\n/** Creates an IconSpec with an SVG source and gets the SVG source from an IconSpec.\n * @public\n */\nexport class IconSpecUtilities {\n /** Prefix for an SVG IconSpec loaded with the Sprite loader */\n public static readonly SVG_PREFIX = \"svg:\";\n public static readonly WEB_COMPONENT_PREFIX = \"webSvg:\";\n\n /** Create an IconSpec for an SVG loaded into web component with sprite loader\n * This method is deprecated -- use createWebComponentIconSpec()\n * @public @deprecated in 3.2. Please avoid using the Sprite loader and use IconSpecUtilities.createWebComponentIconSpec() instead.\n */\n public static createSvgIconSpec(svgSrc: string): string {\n return `${IconSpecUtilities.SVG_PREFIX}${svgSrc}`;\n }\n /** Create an IconSpec for an SVG loaded into web component with svg-loader\n * @public\n */\n public static createWebComponentIconSpec(srcString: string): string {\n return `${IconSpecUtilities.WEB_COMPONENT_PREFIX}${srcString}`;\n }\n\n /** Get the SVG Source from an sprite IconSpec\n * This method is deprecated -- use getWebComponentSource()\n * @public @deprecated in 3.2. avoid using the Sprite loader and use IconSpecUtilities.getWebComponentSource() instead.\n */\n public static getSvgSource(iconSpec: string): string | undefined {\n if (iconSpec.startsWith(IconSpecUtilities.SVG_PREFIX) && iconSpec.length > 4) {\n return iconSpec.slice(4);\n }\n\n return undefined;\n }\n /** Get the SVG Source from an svg-loader IconSpec\n * @public\n */\n\n public static getWebComponentSource(iconSpec: string): string | undefined {\n if (iconSpec.startsWith(IconSpecUtilities.WEB_COMPONENT_PREFIX) && iconSpec.length > 7) {\n return iconSpec.slice(7);\n }\n\n return undefined;\n\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"PointProps.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/PointProps.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Utilities\r\n */\r\n\r\n/** Describes 2d points.\r\n * @public\r\n */\r\nexport interface PointProps {\r\n readonly x: number;\r\n readonly y: number;\r\n}\r\n"]}
1
+ {"version":3,"file":"PointProps.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/PointProps.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;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 Utilities\n */\n\n/** Describes 2d points.\n * @public\n */\nexport interface PointProps {\n readonly x: number;\n readonly y: number;\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"UiError.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/UiError.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAAuF;AAEvF;;GAEG;AACH,MAAa,OAAQ,SAAQ,2BAAY;IAEvC,6CAA6C;IAC7C,YAA0B,QAAgB,EAAE,OAAe,EAAE,cAAsB,4BAAa,CAAC,KAAK,EAAE,WAAiC;QACvI,KAAK,CAAC,WAAW,EAAE,OAAO,EAAE,WAAW,CAAC,CAAC;QADjB,aAAQ,GAAR,QAAQ,CAAQ;IAE1C,CAAC;CACF;AAND,0BAMC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Utilities\r\n */\r\n\r\nimport { BentleyError, BentleyStatus, GetMetaDataFunction } from \"@itwin/core-bentley\";\r\n\r\n/** iTwin.js UI UiError class is a subclass of BentleyError. Errors are logged.\r\n * @public\r\n */\r\nexport class UiError extends BentleyError {\r\n\r\n /** Constructs UiError using BentleyError. */\r\n public constructor(public category: string, message: string, errorNumber: number = BentleyStatus.ERROR, getMetaData?: GetMetaDataFunction) {\r\n super(errorNumber, message, getMetaData);\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"UiError.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/UiError.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAAuF;AAEvF;;GAEG;AACH,MAAa,OAAQ,SAAQ,2BAAY;IAEvC,6CAA6C;IAC7C,YAA0B,QAAgB,EAAE,OAAe,EAAE,cAAsB,4BAAa,CAAC,KAAK,EAAE,WAAiC;QACvI,KAAK,CAAC,WAAW,EAAE,OAAO,EAAE,WAAW,CAAC,CAAC;QADjB,aAAQ,GAAR,QAAQ,CAAQ;IAE1C,CAAC;CACF;AAND,0BAMC","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 Utilities\n */\n\nimport { BentleyError, BentleyStatus, GetMetaDataFunction } from \"@itwin/core-bentley\";\n\n/** iTwin.js UI UiError class is a subclass of BentleyError. Errors are logged.\n * @public\n */\nexport class UiError extends BentleyError {\n\n /** Constructs UiError using BentleyError. */\n public constructor(public category: string, message: string, errorNumber: number = BentleyStatus.ERROR, getMetaData?: GetMetaDataFunction) {\n super(errorNumber, message, getMetaData);\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"UiEvent.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/UiEvent.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAAgD;AAEhD;;GAEG;AACH,MAAa,OAAoB,SAAQ,wBAAqB;CAAI;AAAlE,0BAAkE","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Utilities\r\n */\r\n\r\nimport { BeUiEvent } from \"@itwin/core-bentley\";\r\n\r\n/** iTwin.js UI UiEvent class is a subclass of BeEvent with argument type safety.\r\n * @public\r\n */\r\nexport class UiEvent<TEventArgs> extends BeUiEvent<TEventArgs> { }\r\n"]}
1
+ {"version":3,"file":"UiEvent.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/UiEvent.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAAgD;AAEhD;;GAEG;AACH,MAAa,OAAoB,SAAQ,wBAAqB;CAAI;AAAlE,0BAAkE","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 Utilities\n */\n\nimport { BeUiEvent } from \"@itwin/core-bentley\";\n\n/** iTwin.js UI UiEvent class is a subclass of BeEvent with argument type safety.\n * @public\n */\nexport class UiEvent<TEventArgs> extends BeUiEvent<TEventArgs> { }\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"UiEventDispatcher.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/UiEventDispatcher.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,+BAA+B;AAC/B,uCAAoC;AASpC;;GAEG;AACH,MAAa,WAAY,SAAQ,iBAAwB;CAAI;AAA7D,kCAA6D;AAE7D;;;GAGG;AACH,MAAa,iBAAiB;IAQ5B;QACE,IAAI,CAAC,SAAS,GAAG,IAAI,GAAG,EAAU,CAAC;QACnC,IAAI,CAAC,aAAa,GAAG,KAAK,CAAC;QAC3B,IAAI,CAAC,YAAY,GAAG,IAAI,WAAW,EAAE,CAAC;QACtC,IAAI,CAAC,cAAc,GAAG,GAAG,CAAC;QAC1B,IAAI,CAAC,uBAAuB,GAAG,IAAI,CAAC,cAAc,GAAG,CAAC,CAAC;IACzD,CAAC;IAED,wCAAwC;IACxC,0BAA0B;IACnB,gBAAgB,CAAC,MAAc;QACpC,IAAI,CAAC,cAAc,GAAG,MAAM,CAAC;QAC7B,IAAI,CAAC,uBAAuB,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,cAAc,GAAG,CAAC,CAAC,CAAC;QACnE,IAAI,IAAI,CAAC,uBAAuB,GAAG,CAAC;YAClC,IAAI,CAAC,uBAAuB,GAAG,CAAC,CAAC;QACnC,IAAI,IAAI,CAAC,iBAAiB,EAAE;YAC1B,MAAM,CAAC,YAAY,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC;YAC5C,IAAI,CAAC,iBAAiB,GAAG,SAAS,CAAC;SACpC;QACD,IAAI,IAAI,CAAC,SAAS;YAChB,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE,CAAC;QAEzB,IAAI,CAAC,aAAa,GAAG,KAAK,CAAC;IAC7B,CAAC;IAED,iCAAiC;IACj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;QACvB,IAAI,CAAC,iBAAiB,GAAG,MAAM,CAAC,UAAU,CAAC,GAAG,EAAE,GAAE,IAAI,CAAC,qBAAqB,EAAE,CAAC,CAAA,CAAC,EAAE,IAAI,CAAC,uBAAuB,CAAC,CAAC;IAClH,CAAC;IAED,kFAAkF;IAC3E,kBAAkB,CAAC,QAAqB,EAAE,aAAuB;QACtE,0BAA0B;QAC1B,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,CAAC,CAAC,IAAI,aAAa,CAAC,IAAI,CAAC,CAAC,KAAa,EAAW,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC;YACjH,OAAO,IAAI,CAAC;QACd,OAAO,KAAK,CAAC;IACf,CAAC;CACF;AA5HD,8CA4HC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Utilities\r\n */\r\n\r\n// cSpell:ignore configurableui\r\nimport { UiEvent } from \"./UiEvent\";\r\n\r\n/** UiSync Event arguments. Contains a set of lower case event Ids.\r\n * @public\r\n */\r\nexport interface UiSyncEventArgs {\r\n eventIds: Set<string>;\r\n}\r\n\r\n/** UiSync Event class.\r\n * @public\r\n */\r\nexport class UiSyncEvent extends UiEvent<UiSyncEventArgs> { }\r\n\r\n/** This class is used to send eventIds to interested UI components so the component can determine if it needs\r\n * to refresh its display by calling setState on itself.\r\n * @public\r\n */\r\nexport class UiEventDispatcher {\r\n private _syncEventTimerId: number | undefined;\r\n private _eventIds: Set<string>;\r\n private _eventIdAdded;\r\n private _uiSyncEvent: UiSyncEvent;\r\n private _timeoutPeriod;\r\n private _secondaryTimeoutPeriod;\r\n\r\n constructor() {\r\n this._eventIds = new Set<string>();\r\n this._eventIdAdded = false;\r\n this._uiSyncEvent = new UiSyncEvent();\r\n this._timeoutPeriod = 100;\r\n this._secondaryTimeoutPeriod = this._timeoutPeriod / 2;\r\n }\r\n\r\n /** @internal - used for testing only */\r\n /* istanbul ignore next */\r\n public setTimeoutPeriod(period: number): void {\r\n this._timeoutPeriod = period;\r\n this._secondaryTimeoutPeriod = Math.floor(this._timeoutPeriod / 2);\r\n if (this._secondaryTimeoutPeriod < 1)\r\n this._secondaryTimeoutPeriod = 1;\r\n if (this._syncEventTimerId) {\r\n window.clearTimeout(this._syncEventTimerId);\r\n this._syncEventTimerId = undefined;\r\n }\r\n if (this._eventIds)\r\n this._eventIds.clear();\r\n\r\n this._eventIdAdded = false;\r\n }\r\n\r\n /** The current timeout period */\r\n public get timeoutPeriod(): number {\r\n return this._timeoutPeriod;\r\n }\r\n /** Return set of event ids that will be sent to listeners/. */\r\n public get syncEventIds(): Set<string> {\r\n return this._eventIds;\r\n }\r\n\r\n /** Return UiSyncEvent so callers can register an event callback. */\r\n public get onSyncUiEvent(): UiSyncEvent {\r\n return this._uiSyncEvent;\r\n }\r\n\r\n /** Immediately trigger sync event processing. */\r\n public dispatchImmediateSyncUiEvent(eventId: string): void {\r\n const eventIds = new Set<string>();\r\n eventIds.add(eventId.toLowerCase());\r\n this.onSyncUiEvent.emit({ eventIds });\r\n }\r\n\r\n /** Save eventId in Set for processing. */\r\n public dispatchSyncUiEvent(eventId: string): void {\r\n // istanbul ignore if\r\n if (0 === this._timeoutPeriod) {\r\n return;\r\n }\r\n\r\n this.syncEventIds.add(eventId.toLowerCase());\r\n if (!this._syncEventTimerId) { // if there is not a timer active, create one\r\n this._syncEventTimerId = window.setTimeout(() => {this.checkForAdditionalIds();}, this._timeoutPeriod);\r\n } else {\r\n this._eventIdAdded = true;\r\n }\r\n }\r\n\r\n /** Save multiple eventIds in Set for processing. */\r\n public dispatchSyncUiEvents(eventIds: string[]): void {\r\n // istanbul ignore if\r\n if (0 === this._timeoutPeriod) {\r\n return;\r\n }\r\n\r\n eventIds.forEach((id) => this.syncEventIds.add(id.toLowerCase()));\r\n // istanbul ignore else\r\n if (!this._syncEventTimerId) { // if there is not a timer active, create one\r\n this._syncEventTimerId = window.setTimeout(() => {this.checkForAdditionalIds();}, this._timeoutPeriod);\r\n } else {\r\n this._eventIdAdded = true;\r\n }\r\n }\r\n\r\n /** Trigger registered event processing when timer has expired and no addition eventId are added. */\r\n public checkForAdditionalIds() {\r\n /* istanbul ignore else */\r\n if (!this._eventIdAdded) {\r\n // istanbul ignore else\r\n if (this._syncEventTimerId) {\r\n window.clearTimeout(this._syncEventTimerId);\r\n this._syncEventTimerId = undefined;\r\n }\r\n this._eventIdAdded = false;\r\n // istanbul ignore else\r\n if (this.syncEventIds.size > 0) {\r\n const eventIds = new Set<string>();\r\n this.syncEventIds.forEach((value) => eventIds.add(value));\r\n this._eventIds.clear();\r\n this.onSyncUiEvent.emit({ eventIds });\r\n }\r\n return;\r\n }\r\n\r\n // istanbul ignore next\r\n if (this._syncEventTimerId) {\r\n window.clearTimeout(this._syncEventTimerId);\r\n this._syncEventTimerId = undefined;\r\n }\r\n // istanbul ignore next\r\n this._eventIdAdded = false;\r\n // if events have been added before the initial timer expired wait half that time to see if events are still being added.\r\n // istanbul ignore next\r\n this._syncEventTimerId = window.setTimeout(() => {this.checkForAdditionalIds();}, this._secondaryTimeoutPeriod);\r\n }\r\n\r\n /** Checks to see if an eventId of interest is contained in the set of eventIds */\r\n public hasEventOfInterest(eventIds: Set<string>, idsOfInterest: string[]) {\r\n /* istanbul ignore else */\r\n if ((idsOfInterest.length > 0) && idsOfInterest.some((value: string): boolean => eventIds.has(value.toLowerCase())))\r\n return true;\r\n return false;\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"UiEventDispatcher.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/UiEventDispatcher.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,+BAA+B;AAC/B,uCAAoC;AASpC;;GAEG;AACH,MAAa,WAAY,SAAQ,iBAAwB;CAAI;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AAC,IAAI,CAAC,CAAC,KAAa,EAAW,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC;YACjH,OAAO,IAAI,CAAC;QACd,OAAO,KAAK,CAAC;IACf,CAAC;CACF;AA5HD,8CA4HC","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 Utilities\n */\n\n// cSpell:ignore configurableui\nimport { UiEvent } from \"./UiEvent\";\n\n/** UiSync Event arguments. Contains a set of lower case event Ids.\n * @public\n */\nexport interface UiSyncEventArgs {\n eventIds: Set<string>;\n}\n\n/** UiSync Event class.\n * @public\n */\nexport class UiSyncEvent extends UiEvent<UiSyncEventArgs> { }\n\n/** This class is used to send eventIds to interested UI components so the component can determine if it needs\n * to refresh its display by calling setState on itself.\n * @public\n */\nexport class UiEventDispatcher {\n private _syncEventTimerId: number | undefined;\n private _eventIds: Set<string>;\n private _eventIdAdded;\n private _uiSyncEvent: UiSyncEvent;\n private _timeoutPeriod;\n private _secondaryTimeoutPeriod;\n\n constructor() {\n this._eventIds = new Set<string>();\n this._eventIdAdded = false;\n this._uiSyncEvent = new UiSyncEvent();\n this._timeoutPeriod = 100;\n this._secondaryTimeoutPeriod = this._timeoutPeriod / 2;\n }\n\n /** @internal - used for testing only */\n /* istanbul ignore next */\n public setTimeoutPeriod(period: number): void {\n this._timeoutPeriod = period;\n this._secondaryTimeoutPeriod = Math.floor(this._timeoutPeriod / 2);\n if (this._secondaryTimeoutPeriod < 1)\n this._secondaryTimeoutPeriod = 1;\n if (this._syncEventTimerId) {\n window.clearTimeout(this._syncEventTimerId);\n this._syncEventTimerId = undefined;\n }\n if (this._eventIds)\n this._eventIds.clear();\n\n this._eventIdAdded = false;\n }\n\n /** The current timeout period */\n public get timeoutPeriod(): number {\n return this._timeoutPeriod;\n }\n /** Return set of event ids that will be sent to listeners/. */\n public get syncEventIds(): Set<string> {\n return this._eventIds;\n }\n\n /** Return UiSyncEvent so callers can register an event callback. */\n public get onSyncUiEvent(): UiSyncEvent {\n return this._uiSyncEvent;\n }\n\n /** Immediately trigger sync event processing. */\n public dispatchImmediateSyncUiEvent(eventId: string): void {\n const eventIds = new Set<string>();\n eventIds.add(eventId.toLowerCase());\n this.onSyncUiEvent.emit({ eventIds });\n }\n\n /** Save eventId in Set for processing. */\n public dispatchSyncUiEvent(eventId: string): void {\n // istanbul ignore if\n if (0 === this._timeoutPeriod) {\n return;\n }\n\n this.syncEventIds.add(eventId.toLowerCase());\n if (!this._syncEventTimerId) { // if there is not a timer active, create one\n this._syncEventTimerId = window.setTimeout(() => {this.checkForAdditionalIds();}, this._timeoutPeriod);\n } else {\n this._eventIdAdded = true;\n }\n }\n\n /** Save multiple eventIds in Set for processing. */\n public dispatchSyncUiEvents(eventIds: string[]): void {\n // istanbul ignore if\n if (0 === this._timeoutPeriod) {\n return;\n }\n\n eventIds.forEach((id) => this.syncEventIds.add(id.toLowerCase()));\n // istanbul ignore else\n if (!this._syncEventTimerId) { // if there is not a timer active, create one\n this._syncEventTimerId = window.setTimeout(() => {this.checkForAdditionalIds();}, this._timeoutPeriod);\n } else {\n this._eventIdAdded = true;\n }\n }\n\n /** Trigger registered event processing when timer has expired and no addition eventId are added. */\n public checkForAdditionalIds() {\n /* istanbul ignore else */\n if (!this._eventIdAdded) {\n // istanbul ignore else\n if (this._syncEventTimerId) {\n window.clearTimeout(this._syncEventTimerId);\n this._syncEventTimerId = undefined;\n }\n this._eventIdAdded = false;\n // istanbul ignore else\n if (this.syncEventIds.size > 0) {\n const eventIds = new Set<string>();\n this.syncEventIds.forEach((value) => eventIds.add(value));\n this._eventIds.clear();\n this.onSyncUiEvent.emit({ eventIds });\n }\n return;\n }\n\n // istanbul ignore next\n if (this._syncEventTimerId) {\n window.clearTimeout(this._syncEventTimerId);\n this._syncEventTimerId = undefined;\n }\n // istanbul ignore next\n this._eventIdAdded = false;\n // if events have been added before the initial timer expired wait half that time to see if events are still being added.\n // istanbul ignore next\n this._syncEventTimerId = window.setTimeout(() => {this.checkForAdditionalIds();}, this._secondaryTimeoutPeriod);\n }\n\n /** Checks to see if an eventId of interest is contained in the set of eventIds */\n public hasEventOfInterest(eventIds: Set<string>, idsOfInterest: string[]) {\n /* istanbul ignore else */\n if ((idsOfInterest.length > 0) && idsOfInterest.some((value: string): boolean => eventIds.has(value.toLowerCase())))\n return true;\n return false;\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"callbacks.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/callbacks.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Utilities\r\n */\r\n\r\nimport { Primitives } from \"../properties/PrimitiveTypes\";\r\n\r\n/** Signature for number onCommit function.\r\n * @public\r\n */\r\nexport type OnNumberCommitFunc = (value: number) => void;\r\n\r\n/** Signature for value onCommit function.\r\n * @public\r\n */\r\nexport type OnValueCommitFunc = (value: Primitives.Value) => void;\r\n\r\n/** Signature for onCancel function.\r\n * @public\r\n */\r\nexport type OnCancelFunc = () => void;\r\n\r\n/** Signature for onItemExecuted function.\r\n * @public\r\n */\r\nexport type OnItemExecutedFunc = (item: any) => void;\r\n"]}
1
+ {"version":3,"file":"callbacks.js","sourceRoot":"","sources":["../../../../src/appui-abstract/utils/callbacks.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;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 Utilities\n */\n\nimport { Primitives } from \"../properties/PrimitiveTypes\";\n\n/** Signature for number onCommit function.\n * @public\n */\nexport type OnNumberCommitFunc = (value: number) => void;\n\n/** Signature for value onCommit function.\n * @public\n */\nexport type OnValueCommitFunc = (value: Primitives.Value) => void;\n\n/** Signature for onCancel function.\n * @public\n */\nexport type OnCancelFunc = () => void;\n\n/** Signature for onItemExecuted function.\n * @public\n */\nexport type OnItemExecutedFunc = (item: any) => void;\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"charCode.js","sourceRoot":"","sources":["../../../../../src/appui-abstract/utils/filter/charCode.ts"],"names":[],"mappings":";AAAA;;;+FAG+F","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\n// file copied from https://github.com/microsoft/vscode/blob/master/src/vs/base/common/charCode.ts\r\n/* eslint-disable no-restricted-syntax */\r\n\r\n// Names from https://blog.codinghorror.com/ascii-pronunciation-rules-for-programmers/\r\n\r\n/**\r\n * An inlined enum containing useful character codes (to be used with String.charCodeAt).\r\n * Please leave the const keyword such that it gets inlined when compiled to JavaScript!\r\n * @internal\r\n */\r\nexport const enum CharCode {\r\n Null = 0,\r\n /**\r\n * The `\\b` character.\r\n */\r\n Backspace = 8,\r\n /**\r\n * The `\\t` character.\r\n */\r\n Tab = 9,\r\n /**\r\n * The `\\n` character.\r\n */\r\n LineFeed = 10,\r\n /**\r\n * The `\\r` character.\r\n */\r\n CarriageReturn = 13,\r\n Space = 32,\r\n /**\r\n * The `!` character.\r\n */\r\n ExclamationMark = 33,\r\n /**\r\n * The `\"` character.\r\n */\r\n DoubleQuote = 34,\r\n /**\r\n * The `#` character.\r\n */\r\n Hash = 35,\r\n /**\r\n * The `$` character.\r\n */\r\n DollarSign = 36,\r\n /**\r\n * The `%` character.\r\n */\r\n PercentSign = 37,\r\n /**\r\n * The `&` character.\r\n */\r\n Ampersand = 38,\r\n /**\r\n * The `'` character.\r\n */\r\n SingleQuote = 39,\r\n /**\r\n * The `(` character.\r\n */\r\n OpenParen = 40,\r\n /**\r\n * The `)` character.\r\n */\r\n CloseParen = 41,\r\n /**\r\n * The `*` character.\r\n */\r\n Asterisk = 42,\r\n /**\r\n * The `+` character.\r\n */\r\n Plus = 43,\r\n /**\r\n * The `,` character.\r\n */\r\n Comma = 44,\r\n /**\r\n * The `-` character.\r\n */\r\n Dash = 45,\r\n /**\r\n * The `.` character.\r\n */\r\n Period = 46,\r\n /**\r\n * The `/` character.\r\n */\r\n Slash = 47,\r\n\r\n Digit0 = 48,\r\n Digit1 = 49,\r\n Digit2 = 50,\r\n Digit3 = 51,\r\n Digit4 = 52,\r\n Digit5 = 53,\r\n Digit6 = 54,\r\n Digit7 = 55,\r\n Digit8 = 56,\r\n Digit9 = 57,\r\n\r\n /**\r\n * The `:` character.\r\n */\r\n Colon = 58,\r\n /**\r\n * The `;` character.\r\n */\r\n Semicolon = 59,\r\n /**\r\n * The `<` character.\r\n */\r\n LessThan = 60,\r\n /**\r\n * The `=` character.\r\n */\r\n Equals = 61,\r\n /**\r\n * The `>` character.\r\n */\r\n GreaterThan = 62,\r\n /**\r\n * The `?` character.\r\n */\r\n QuestionMark = 63,\r\n /**\r\n * The `@` character.\r\n */\r\n AtSign = 64,\r\n\r\n A = 65,\r\n B = 66,\r\n C = 67,\r\n D = 68,\r\n E = 69,\r\n F = 70,\r\n G = 71,\r\n H = 72,\r\n I = 73,\r\n J = 74,\r\n K = 75,\r\n L = 76,\r\n M = 77,\r\n N = 78,\r\n O = 79,\r\n P = 80,\r\n Q = 81,\r\n R = 82,\r\n S = 83,\r\n T = 84,\r\n U = 85,\r\n V = 86,\r\n W = 87,\r\n X = 88,\r\n Y = 89,\r\n Z = 90,\r\n\r\n /**\r\n * The `[` character.\r\n */\r\n OpenSquareBracket = 91,\r\n /**\r\n * The `\\` character.\r\n */\r\n Backslash = 92,\r\n /**\r\n * The `]` character.\r\n */\r\n CloseSquareBracket = 93,\r\n /**\r\n * The `^` character.\r\n */\r\n Caret = 94,\r\n /**\r\n * The `_` character.\r\n */\r\n Underline = 95,\r\n /**\r\n * The ``(`)`` character.\r\n */\r\n BackTick = 96,\r\n\r\n a = 97,\r\n b = 98,\r\n c = 99,\r\n d = 100,\r\n e = 101,\r\n f = 102,\r\n g = 103,\r\n h = 104,\r\n i = 105,\r\n j = 106,\r\n k = 107,\r\n l = 108,\r\n m = 109,\r\n n = 110,\r\n o = 111,\r\n p = 112,\r\n q = 113,\r\n r = 114,\r\n s = 115,\r\n t = 116,\r\n u = 117,\r\n v = 118,\r\n w = 119,\r\n x = 120,\r\n y = 121,\r\n z = 122,\r\n\r\n /**\r\n * The `{` character.\r\n */\r\n OpenCurlyBrace = 123,\r\n /**\r\n * The `|` character.\r\n */\r\n Pipe = 124,\r\n /**\r\n * The `}` character.\r\n */\r\n CloseCurlyBrace = 125,\r\n /**\r\n * The `~` character.\r\n */\r\n Tilde = 126,\r\n\r\n U_Combining_Grave_Accent = 0x0300,// U+0300Combining Grave Accent\r\n U_Combining_Acute_Accent = 0x0301,// U+0301Combining Acute Accent\r\n U_Combining_Circumflex_Accent = 0x0302,// U+0302Combining Circumflex Accent\r\n U_Combining_Tilde = 0x0303,// U+0303Combining Tilde\r\n U_Combining_Macron = 0x0304,// U+0304Combining Macron\r\n U_Combining_Overline = 0x0305,// U+0305Combining Overline\r\n U_Combining_Breve = 0x0306,// U+0306Combining Breve\r\n U_Combining_Dot_Above = 0x0307,// U+0307Combining Dot Above\r\n U_Combining_Diaeresis = 0x0308,// U+0308Combining Diaeresis\r\n U_Combining_Hook_Above = 0x0309,// U+0309Combining Hook Above\r\n U_Combining_Ring_Above = 0x030A,// U+030ACombining Ring Above\r\n U_Combining_Double_Acute_Accent = 0x030B,// U+030BCombining Double Acute Accent\r\n U_Combining_Caron = 0x030C,// U+030CCombining Caron\r\n U_Combining_Vertical_Line_Above = 0x030D,// U+030DCombining Vertical Line Above\r\n U_Combining_Double_Vertical_Line_Above = 0x030E,// U+030ECombining Double Vertical Line Above\r\n U_Combining_Double_Grave_Accent = 0x030F,// U+030FCombining Double Grave Accent\r\n U_Combining_Candrabindu = 0x0310,// U+0310Combining Candrabindu\r\n U_Combining_Inverted_Breve = 0x0311,// U+0311Combining Inverted Breve\r\n U_Combining_Turned_Comma_Above = 0x0312,// U+0312Combining Turned Comma Above\r\n U_Combining_Comma_Above = 0x0313,// U+0313Combining Comma Above\r\n U_Combining_Reversed_Comma_Above = 0x0314,// U+0314Combining Reversed Comma Above\r\n U_Combining_Comma_Above_Right = 0x0315,// U+0315Combining Comma Above Right\r\n U_Combining_Grave_Accent_Below = 0x0316,// U+0316Combining Grave Accent Below\r\n U_Combining_Acute_Accent_Below = 0x0317,// U+0317Combining Acute Accent Below\r\n U_Combining_Left_Tack_Below = 0x0318,// U+0318Combining Left Tack Below\r\n U_Combining_Right_Tack_Below = 0x0319,// U+0319Combining Right Tack Below\r\n U_Combining_Left_Angle_Above = 0x031A,// U+031ACombining Left Angle Above\r\n U_Combining_Horn = 0x031B,// U+031BCombining Horn\r\n U_Combining_Left_Half_Ring_Below = 0x031C,// U+031CCombining Left Half Ring Below\r\n U_Combining_Up_Tack_Below = 0x031D,// U+031DCombining Up Tack Below\r\n U_Combining_Down_Tack_Below = 0x031E,// U+031ECombining Down Tack Below\r\n U_Combining_Plus_Sign_Below = 0x031F,// U+031FCombining Plus Sign Below\r\n U_Combining_Minus_Sign_Below = 0x0320,// U+0320Combining Minus Sign Below\r\n U_Combining_Palatalized_Hook_Below = 0x0321,// U+0321Combining Palatalized Hook Below\r\n U_Combining_Retroflex_Hook_Below = 0x0322,// U+0322Combining Retroflex Hook Below\r\n U_Combining_Dot_Below = 0x0323,// U+0323Combining Dot Below\r\n U_Combining_Diaeresis_Below = 0x0324,// U+0324Combining Diaeresis Below\r\n U_Combining_Ring_Below = 0x0325,// U+0325Combining Ring Below\r\n U_Combining_Comma_Below = 0x0326,// U+0326Combining Comma Below\r\n U_Combining_Cedilla = 0x0327,// U+0327Combining Cedilla\r\n U_Combining_Ogonek = 0x0328,// U+0328Combining Ogonek\r\n U_Combining_Vertical_Line_Below = 0x0329,// U+0329Combining Vertical Line Below\r\n U_Combining_Bridge_Below = 0x032A,// U+032ACombining Bridge Below\r\n U_Combining_Inverted_Double_Arch_Below = 0x032B,// U+032BCombining Inverted Double Arch Below\r\n U_Combining_Caron_Below = 0x032C,// U+032CCombining Caron Below\r\n U_Combining_Circumflex_Accent_Below = 0x032D,// U+032DCombining Circumflex Accent Below\r\n U_Combining_Breve_Below = 0x032E,// U+032ECombining Breve Below\r\n U_Combining_Inverted_Breve_Below = 0x032F,// U+032FCombining Inverted Breve Below\r\n U_Combining_Tilde_Below = 0x0330,// U+0330Combining Tilde Below\r\n U_Combining_Macron_Below = 0x0331,// U+0331Combining Macron Below\r\n U_Combining_Low_Line = 0x0332,// U+0332Combining Low Line\r\n U_Combining_Double_Low_Line = 0x0333,// U+0333Combining Double Low Line\r\n U_Combining_Tilde_Overlay = 0x0334,// U+0334Combining Tilde Overlay\r\n U_Combining_Short_Stroke_Overlay = 0x0335,// U+0335Combining Short Stroke Overlay\r\n U_Combining_Long_Stroke_Overlay = 0x0336,// U+0336Combining Long Stroke Overlay\r\n U_Combining_Short_Solidus_Overlay = 0x0337,// U+0337Combining Short Solidus Overlay\r\n U_Combining_Long_Solidus_Overlay = 0x0338,// U+0338Combining Long Solidus Overlay\r\n U_Combining_Right_Half_Ring_Below = 0x0339,// U+0339Combining Right Half Ring Below\r\n U_Combining_Inverted_Bridge_Below = 0x033A,// U+033ACombining Inverted Bridge Below\r\n U_Combining_Square_Below = 0x033B,// U+033BCombining Square Below\r\n U_Combining_Seagull_Below = 0x033C,// U+033CCombining Seagull Below\r\n U_Combining_X_Above = 0x033D,// U+033DCombining X Above\r\n U_Combining_Vertical_Tilde = 0x033E,// U+033ECombining Vertical Tilde\r\n U_Combining_Double_Overline = 0x033F,// U+033FCombining Double Overline\r\n U_Combining_Grave_Tone_Mark = 0x0340,// U+0340Combining Grave Tone Mark\r\n U_Combining_Acute_Tone_Mark = 0x0341,// U+0341Combining Acute Tone Mark\r\n U_Combining_Greek_Perispomeni = 0x0342,// U+0342Combining Greek Perispomeni\r\n U_Combining_Greek_Koronis = 0x0343,// U+0343Combining Greek Koronis\r\n U_Combining_Greek_Dialytika_Tonos = 0x0344,// U+0344Combining Greek Dialytika Tonos\r\n U_Combining_Greek_Ypogegrammeni = 0x0345,// U+0345Combining Greek Ypogegrammeni\r\n U_Combining_Bridge_Above = 0x0346,// U+0346Combining Bridge Above\r\n U_Combining_Equals_Sign_Below = 0x0347,// U+0347Combining Equals Sign Below\r\n U_Combining_Double_Vertical_Line_Below = 0x0348,// U+0348Combining Double Vertical Line Below\r\n U_Combining_Left_Angle_Below = 0x0349,// U+0349Combining Left Angle Below\r\n U_Combining_Not_Tilde_Above = 0x034A,// U+034ACombining Not Tilde Above\r\n U_Combining_Homothetic_Above = 0x034B,// U+034BCombining Homothetic Above\r\n U_Combining_Almost_Equal_To_Above = 0x034C,// U+034CCombining Almost Equal To Above\r\n U_Combining_Left_Right_Arrow_Below = 0x034D,// U+034DCombining Left Right Arrow Below\r\n U_Combining_Upwards_Arrow_Below = 0x034E,// U+034ECombining Upwards Arrow Below\r\n U_Combining_Grapheme_Joiner = 0x034F,// U+034FCombining Grapheme Joiner\r\n U_Combining_Right_Arrowhead_Above = 0x0350,// U+0350Combining Right Arrowhead Above\r\n U_Combining_Left_Half_Ring_Above = 0x0351,// U+0351Combining Left Half Ring Above\r\n U_Combining_Fermata = 0x0352,// U+0352Combining Fermata\r\n U_Combining_X_Below = 0x0353,// U+0353Combining X Below\r\n U_Combining_Left_Arrowhead_Below = 0x0354,// U+0354Combining Left Arrowhead Below\r\n U_Combining_Right_Arrowhead_Below = 0x0355,// U+0355Combining Right Arrowhead Below\r\n U_Combining_Right_Arrowhead_And_Up_Arrowhead_Below = 0x0356,// U+0356Combining Right Arrowhead And Up Arrowhead Below\r\n U_Combining_Right_Half_Ring_Above = 0x0357,// U+0357Combining Right Half Ring Above\r\n U_Combining_Dot_Above_Right = 0x0358,// U+0358Combining Dot Above Right\r\n U_Combining_Asterisk_Below = 0x0359,// U+0359Combining Asterisk Below\r\n U_Combining_Double_Ring_Below = 0x035A,// U+035ACombining Double Ring Below\r\n U_Combining_Zigzag_Above = 0x035B,// U+035BCombining Zigzag Above\r\n U_Combining_Double_Breve_Below = 0x035C,// U+035CCombining Double Breve Below\r\n U_Combining_Double_Breve = 0x035D,// U+035DCombining Double Breve\r\n U_Combining_Double_Macron = 0x035E,// U+035ECombining Double Macron\r\n U_Combining_Double_Macron_Below = 0x035F,// U+035FCombining Double Macron Below\r\n U_Combining_Double_Tilde = 0x0360,// U+0360Combining Double Tilde\r\n U_Combining_Double_Inverted_Breve = 0x0361,// U+0361Combining Double Inverted Breve\r\n U_Combining_Double_Rightwards_Arrow_Below = 0x0362,// U+0362Combining Double Rightwards Arrow Below\r\n U_Combining_Latin_Small_Letter_A = 0x0363, // U+0363Combining Latin Small Letter A\r\n U_Combining_Latin_Small_Letter_E = 0x0364, // U+0364Combining Latin Small Letter E\r\n U_Combining_Latin_Small_Letter_I = 0x0365, // U+0365Combining Latin Small Letter I\r\n U_Combining_Latin_Small_Letter_O = 0x0366, // U+0366Combining Latin Small Letter O\r\n U_Combining_Latin_Small_Letter_U = 0x0367, // U+0367Combining Latin Small Letter U\r\n U_Combining_Latin_Small_Letter_C = 0x0368, // U+0368Combining Latin Small Letter C\r\n U_Combining_Latin_Small_Letter_D = 0x0369, // U+0369Combining Latin Small Letter D\r\n U_Combining_Latin_Small_Letter_H = 0x036A, // U+036ACombining Latin Small Letter H\r\n U_Combining_Latin_Small_Letter_M = 0x036B, // U+036BCombining Latin Small Letter M\r\n U_Combining_Latin_Small_Letter_R = 0x036C, // U+036CCombining Latin Small Letter R\r\n U_Combining_Latin_Small_Letter_T = 0x036D, // U+036DCombining Latin Small Letter T\r\n U_Combining_Latin_Small_Letter_V = 0x036E, // U+036ECombining Latin Small Letter V\r\n U_Combining_Latin_Small_Letter_X = 0x036F, // U+036FCombining Latin Small Letter X\r\n\r\n /**\r\n * Unicode Character 'LINE SEPARATOR' (U+2028)\r\n * http://www.fileformat.info/info/unicode/char/2028/index.htm\r\n */\r\n LINE_SEPARATOR = 0x2028,\r\n /**\r\n * Unicode Character 'PARAGRAPH SEPARATOR' (U+2029)\r\n * http://www.fileformat.info/info/unicode/char/2029/index.htm\r\n */\r\n PARAGRAPH_SEPARATOR = 0x2029,\r\n /**\r\n * Unicode Character 'NEXT LINE' (U+0085)\r\n * http://www.fileformat.info/info/unicode/char/0085/index.htm\r\n */\r\n NEXT_LINE = 0x0085,\r\n\r\n // http://www.fileformat.info/info/unicode/category/Sk/list.htm\r\n U_CIRCUMFLEX = 0x005E,// U+005ECIRCUMFLEX\r\n U_GRAVE_ACCENT = 0x0060,// U+0060GRAVE ACCENT\r\n U_DIAERESIS = 0x00A8,// U+00A8DIAERESIS\r\n U_MACRON = 0x00AF,// U+00AFMACRON\r\n U_ACUTE_ACCENT = 0x00B4,// U+00B4ACUTE ACCENT\r\n U_CEDILLA = 0x00B8,// U+00B8CEDILLA\r\n U_MODIFIER_LETTER_LEFT_ARROWHEAD = 0x02C2,// U+02C2MODIFIER LETTER LEFT ARROWHEAD\r\n U_MODIFIER_LETTER_RIGHT_ARROWHEAD = 0x02C3,// U+02C3MODIFIER LETTER RIGHT ARROWHEAD\r\n U_MODIFIER_LETTER_UP_ARROWHEAD = 0x02C4,// U+02C4MODIFIER LETTER UP ARROWHEAD\r\n U_MODIFIER_LETTER_DOWN_ARROWHEAD = 0x02C5,// U+02C5MODIFIER LETTER DOWN ARROWHEAD\r\n U_MODIFIER_LETTER_CENTRED_RIGHT_HALF_RING = 0x02D2,// U+02D2MODIFIER LETTER CENTRED RIGHT HALF RING\r\n U_MODIFIER_LETTER_CENTRED_LEFT_HALF_RING = 0x02D3,// U+02D3MODIFIER LETTER CENTRED LEFT HALF RING\r\n U_MODIFIER_LETTER_UP_TACK = 0x02D4,// U+02D4MODIFIER LETTER UP TACK\r\n U_MODIFIER_LETTER_DOWN_TACK = 0x02D5,// U+02D5MODIFIER LETTER DOWN TACK\r\n U_MODIFIER_LETTER_PLUS_SIGN = 0x02D6,// U+02D6MODIFIER LETTER PLUS SIGN\r\n U_MODIFIER_LETTER_MINUS_SIGN = 0x02D7,// U+02D7MODIFIER LETTER MINUS SIGN\r\n U_BREVE = 0x02D8,// U+02D8BREVE\r\n U_DOT_ABOVE = 0x02D9,// U+02D9DOT ABOVE\r\n U_RING_ABOVE = 0x02DA,// U+02DARING ABOVE\r\n U_OGONEK = 0x02DB,// U+02DBOGONEK\r\n U_SMALL_TILDE = 0x02DC,// U+02DCSMALL TILDE\r\n U_DOUBLE_ACUTE_ACCENT = 0x02DD,// U+02DDDOUBLE ACUTE ACCENT\r\n U_MODIFIER_LETTER_RHOTIC_HOOK = 0x02DE,// U+02DEMODIFIER LETTER RHOTIC HOOK\r\n U_MODIFIER_LETTER_CROSS_ACCENT = 0x02DF,// U+02DFMODIFIER LETTER CROSS ACCENT\r\n U_MODIFIER_LETTER_EXTRA_HIGH_TONE_BAR = 0x02E5,// U+02E5MODIFIER LETTER EXTRA-HIGH TONE BAR\r\n U_MODIFIER_LETTER_HIGH_TONE_BAR = 0x02E6,// U+02E6MODIFIER LETTER HIGH TONE BAR\r\n U_MODIFIER_LETTER_MID_TONE_BAR = 0x02E7,// U+02E7MODIFIER LETTER MID TONE BAR\r\n U_MODIFIER_LETTER_LOW_TONE_BAR = 0x02E8,// U+02E8MODIFIER LETTER LOW TONE BAR\r\n U_MODIFIER_LETTER_EXTRA_LOW_TONE_BAR = 0x02E9,// U+02E9MODIFIER LETTER EXTRA-LOW TONE BAR\r\n U_MODIFIER_LETTER_YIN_DEPARTING_TONE_MARK = 0x02EA,// U+02EAMODIFIER LETTER YIN DEPARTING TONE MARK\r\n U_MODIFIER_LETTER_YANG_DEPARTING_TONE_MARK = 0x02EB,// U+02EBMODIFIER LETTER YANG DEPARTING TONE MARK\r\n U_MODIFIER_LETTER_UNASPIRATED = 0x02ED,// U+02EDMODIFIER LETTER UNASPIRATED\r\n U_MODIFIER_LETTER_LOW_DOWN_ARROWHEAD = 0x02EF,// U+02EFMODIFIER LETTER LOW DOWN ARROWHEAD\r\n U_MODIFIER_LETTER_LOW_UP_ARROWHEAD = 0x02F0,// U+02F0MODIFIER LETTER LOW UP ARROWHEAD\r\n U_MODIFIER_LETTER_LOW_LEFT_ARROWHEAD = 0x02F1,// U+02F1MODIFIER LETTER LOW LEFT ARROWHEAD\r\n U_MODIFIER_LETTER_LOW_RIGHT_ARROWHEAD = 0x02F2,// U+02F2MODIFIER LETTER LOW RIGHT ARROWHEAD\r\n U_MODIFIER_LETTER_LOW_RING = 0x02F3,// U+02F3MODIFIER LETTER LOW RING\r\n U_MODIFIER_LETTER_MIDDLE_GRAVE_ACCENT = 0x02F4,// U+02F4MODIFIER LETTER MIDDLE GRAVE ACCENT\r\n U_MODIFIER_LETTER_MIDDLE_DOUBLE_GRAVE_ACCENT = 0x02F5,// U+02F5MODIFIER LETTER MIDDLE DOUBLE GRAVE ACCENT\r\n U_MODIFIER_LETTER_MIDDLE_DOUBLE_ACUTE_ACCENT = 0x02F6,// U+02F6MODIFIER LETTER MIDDLE DOUBLE ACUTE ACCENT\r\n U_MODIFIER_LETTER_LOW_TILDE = 0x02F7,// U+02F7MODIFIER LETTER LOW TILDE\r\n U_MODIFIER_LETTER_RAISED_COLON = 0x02F8,// U+02F8MODIFIER LETTER RAISED COLON\r\n U_MODIFIER_LETTER_BEGIN_HIGH_TONE = 0x02F9,// U+02F9MODIFIER LETTER BEGIN HIGH TONE\r\n U_MODIFIER_LETTER_END_HIGH_TONE = 0x02FA,// U+02FAMODIFIER LETTER END HIGH TONE\r\n U_MODIFIER_LETTER_BEGIN_LOW_TONE = 0x02FB,// U+02FBMODIFIER LETTER BEGIN LOW TONE\r\n U_MODIFIER_LETTER_END_LOW_TONE = 0x02FC,// U+02FCMODIFIER LETTER END LOW TONE\r\n U_MODIFIER_LETTER_SHELF = 0x02FD,// U+02FDMODIFIER LETTER SHELF\r\n U_MODIFIER_LETTER_OPEN_SHELF = 0x02FE,// U+02FEMODIFIER LETTER OPEN SHELF\r\n U_MODIFIER_LETTER_LOW_LEFT_ARROW = 0x02FF,// U+02FFMODIFIER LETTER LOW LEFT ARROW\r\n U_GREEK_LOWER_NUMERAL_SIGN = 0x0375,// U+0375GREEK LOWER NUMERAL SIGN\r\n U_GREEK_TONOS = 0x0384,// U+0384GREEK TONOS\r\n U_GREEK_DIALYTIKA_TONOS = 0x0385,// U+0385GREEK DIALYTIKA TONOS\r\n U_GREEK_KORONIS = 0x1FBD,// U+1FBDGREEK KORONIS\r\n U_GREEK_PSILI = 0x1FBF,// U+1FBFGREEK PSILI\r\n U_GREEK_PERISPOMENI = 0x1FC0,// U+1FC0GREEK PERISPOMENI\r\n U_GREEK_DIALYTIKA_AND_PERISPOMENI = 0x1FC1,// U+1FC1GREEK DIALYTIKA AND PERISPOMENI\r\n U_GREEK_PSILI_AND_VARIA = 0x1FCD,// U+1FCDGREEK PSILI AND VARIA\r\n U_GREEK_PSILI_AND_OXIA = 0x1FCE,// U+1FCEGREEK PSILI AND OXIA\r\n U_GREEK_PSILI_AND_PERISPOMENI = 0x1FCF,// U+1FCFGREEK PSILI AND PERISPOMENI\r\n U_GREEK_DASIA_AND_VARIA = 0x1FDD,// U+1FDDGREEK DASIA AND VARIA\r\n U_GREEK_DASIA_AND_OXIA = 0x1FDE,// U+1FDEGREEK DASIA AND OXIA\r\n U_GREEK_DASIA_AND_PERISPOMENI = 0x1FDF,// U+1FDFGREEK DASIA AND PERISPOMENI\r\n U_GREEK_DIALYTIKA_AND_VARIA = 0x1FED,// U+1FEDGREEK DIALYTIKA AND VARIA\r\n U_GREEK_DIALYTIKA_AND_OXIA = 0x1FEE,// U+1FEEGREEK DIALYTIKA AND OXIA\r\n U_GREEK_VARIA = 0x1FEF,// U+1FEFGREEK VARIA\r\n U_GREEK_OXIA = 0x1FFD,// U+1FFDGREEK OXIA\r\n U_GREEK_DASIA = 0x1FFE,// U+1FFEGREEK DASIA\r\n\r\n U_OVERLINE = 0x203E, // Unicode Character 'OVERLINE'\r\n\r\n /**\r\n * UTF-8 BOM\r\n * Unicode Character 'ZERO WIDTH NO-BREAK SPACE' (U+FEFF)\r\n * http://www.fileformat.info/info/unicode/char/feff/index.htm\r\n */\r\n UTF8_BOM = 65279\r\n}\r\n"]}
1
+ {"version":3,"file":"charCode.js","sourceRoot":"","sources":["../../../../../src/appui-abstract/utils/filter/charCode.ts"],"names":[],"mappings":";AAAA;;;+FAG+F","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\n// file copied from https://github.com/microsoft/vscode/blob/master/src/vs/base/common/charCode.ts\n/* eslint-disable no-restricted-syntax */\n\n// Names from https://blog.codinghorror.com/ascii-pronunciation-rules-for-programmers/\n\n/**\n * An inlined enum containing useful character codes (to be used with String.charCodeAt).\n * Please leave the const keyword such that it gets inlined when compiled to JavaScript!\n * @internal\n */\nexport const enum CharCode {\n Null = 0,\n /**\n * The `\\b` character.\n */\n Backspace = 8,\n /**\n * The `\\t` character.\n */\n Tab = 9,\n /**\n * The `\\n` character.\n */\n LineFeed = 10,\n /**\n * The `\\r` character.\n */\n CarriageReturn = 13,\n Space = 32,\n /**\n * The `!` character.\n */\n ExclamationMark = 33,\n /**\n * The `\"` character.\n */\n DoubleQuote = 34,\n /**\n * The `#` character.\n */\n Hash = 35,\n /**\n * The `$` character.\n */\n DollarSign = 36,\n /**\n * The `%` character.\n */\n PercentSign = 37,\n /**\n * The `&` character.\n */\n Ampersand = 38,\n /**\n * The `'` character.\n */\n SingleQuote = 39,\n /**\n * The `(` character.\n */\n OpenParen = 40,\n /**\n * The `)` character.\n */\n CloseParen = 41,\n /**\n * The `*` character.\n */\n Asterisk = 42,\n /**\n * The `+` character.\n */\n Plus = 43,\n /**\n * The `,` character.\n */\n Comma = 44,\n /**\n * The `-` character.\n */\n Dash = 45,\n /**\n * The `.` character.\n */\n Period = 46,\n /**\n * The `/` character.\n */\n Slash = 47,\n\n Digit0 = 48,\n Digit1 = 49,\n Digit2 = 50,\n Digit3 = 51,\n Digit4 = 52,\n Digit5 = 53,\n Digit6 = 54,\n Digit7 = 55,\n Digit8 = 56,\n Digit9 = 57,\n\n /**\n * The `:` character.\n */\n Colon = 58,\n /**\n * The `;` character.\n */\n Semicolon = 59,\n /**\n * The `<` character.\n */\n LessThan = 60,\n /**\n * The `=` character.\n */\n Equals = 61,\n /**\n * The `>` character.\n */\n GreaterThan = 62,\n /**\n * The `?` character.\n */\n QuestionMark = 63,\n /**\n * The `@` character.\n */\n AtSign = 64,\n\n A = 65,\n B = 66,\n C = 67,\n D = 68,\n E = 69,\n F = 70,\n G = 71,\n H = 72,\n I = 73,\n J = 74,\n K = 75,\n L = 76,\n M = 77,\n N = 78,\n O = 79,\n P = 80,\n Q = 81,\n R = 82,\n S = 83,\n T = 84,\n U = 85,\n V = 86,\n W = 87,\n X = 88,\n Y = 89,\n Z = 90,\n\n /**\n * The `[` character.\n */\n OpenSquareBracket = 91,\n /**\n * The `\\` character.\n */\n Backslash = 92,\n /**\n * The `]` character.\n */\n CloseSquareBracket = 93,\n /**\n * The `^` character.\n */\n Caret = 94,\n /**\n * The `_` character.\n */\n Underline = 95,\n /**\n * The ``(`)`` character.\n */\n BackTick = 96,\n\n a = 97,\n b = 98,\n c = 99,\n d = 100,\n e = 101,\n f = 102,\n g = 103,\n h = 104,\n i = 105,\n j = 106,\n k = 107,\n l = 108,\n m = 109,\n n = 110,\n o = 111,\n p = 112,\n q = 113,\n r = 114,\n s = 115,\n t = 116,\n u = 117,\n v = 118,\n w = 119,\n x = 120,\n y = 121,\n z = 122,\n\n /**\n * The `{` character.\n */\n OpenCurlyBrace = 123,\n /**\n * The `|` character.\n */\n Pipe = 124,\n /**\n * The `}` character.\n */\n CloseCurlyBrace = 125,\n /**\n * The `~` character.\n */\n Tilde = 126,\n\n U_Combining_Grave_Accent = 0x0300,// U+0300Combining Grave Accent\n U_Combining_Acute_Accent = 0x0301,// U+0301Combining Acute Accent\n U_Combining_Circumflex_Accent = 0x0302,// U+0302Combining Circumflex Accent\n U_Combining_Tilde = 0x0303,// U+0303Combining Tilde\n U_Combining_Macron = 0x0304,// U+0304Combining Macron\n U_Combining_Overline = 0x0305,// U+0305Combining Overline\n U_Combining_Breve = 0x0306,// U+0306Combining Breve\n U_Combining_Dot_Above = 0x0307,// U+0307Combining Dot Above\n U_Combining_Diaeresis = 0x0308,// U+0308Combining Diaeresis\n U_Combining_Hook_Above = 0x0309,// U+0309Combining Hook Above\n U_Combining_Ring_Above = 0x030A,// U+030ACombining Ring Above\n U_Combining_Double_Acute_Accent = 0x030B,// U+030BCombining Double Acute Accent\n U_Combining_Caron = 0x030C,// U+030CCombining Caron\n U_Combining_Vertical_Line_Above = 0x030D,// U+030DCombining Vertical Line Above\n U_Combining_Double_Vertical_Line_Above = 0x030E,// U+030ECombining Double Vertical Line Above\n U_Combining_Double_Grave_Accent = 0x030F,// U+030FCombining Double Grave Accent\n U_Combining_Candrabindu = 0x0310,// U+0310Combining Candrabindu\n U_Combining_Inverted_Breve = 0x0311,// U+0311Combining Inverted Breve\n U_Combining_Turned_Comma_Above = 0x0312,// U+0312Combining Turned Comma Above\n U_Combining_Comma_Above = 0x0313,// U+0313Combining Comma Above\n U_Combining_Reversed_Comma_Above = 0x0314,// U+0314Combining Reversed Comma Above\n U_Combining_Comma_Above_Right = 0x0315,// U+0315Combining Comma Above Right\n U_Combining_Grave_Accent_Below = 0x0316,// U+0316Combining Grave Accent Below\n U_Combining_Acute_Accent_Below = 0x0317,// U+0317Combining Acute Accent Below\n U_Combining_Left_Tack_Below = 0x0318,// U+0318Combining Left Tack Below\n U_Combining_Right_Tack_Below = 0x0319,// U+0319Combining Right Tack Below\n U_Combining_Left_Angle_Above = 0x031A,// U+031ACombining Left Angle Above\n U_Combining_Horn = 0x031B,// U+031BCombining Horn\n U_Combining_Left_Half_Ring_Below = 0x031C,// U+031CCombining Left Half Ring Below\n U_Combining_Up_Tack_Below = 0x031D,// U+031DCombining Up Tack Below\n U_Combining_Down_Tack_Below = 0x031E,// U+031ECombining Down Tack Below\n U_Combining_Plus_Sign_Below = 0x031F,// U+031FCombining Plus Sign Below\n U_Combining_Minus_Sign_Below = 0x0320,// U+0320Combining Minus Sign Below\n U_Combining_Palatalized_Hook_Below = 0x0321,// U+0321Combining Palatalized Hook Below\n U_Combining_Retroflex_Hook_Below = 0x0322,// U+0322Combining Retroflex Hook Below\n U_Combining_Dot_Below = 0x0323,// U+0323Combining Dot Below\n U_Combining_Diaeresis_Below = 0x0324,// U+0324Combining Diaeresis Below\n U_Combining_Ring_Below = 0x0325,// U+0325Combining Ring Below\n U_Combining_Comma_Below = 0x0326,// U+0326Combining Comma Below\n U_Combining_Cedilla = 0x0327,// U+0327Combining Cedilla\n U_Combining_Ogonek = 0x0328,// U+0328Combining Ogonek\n U_Combining_Vertical_Line_Below = 0x0329,// U+0329Combining Vertical Line Below\n U_Combining_Bridge_Below = 0x032A,// U+032ACombining Bridge Below\n U_Combining_Inverted_Double_Arch_Below = 0x032B,// U+032BCombining Inverted Double Arch Below\n U_Combining_Caron_Below = 0x032C,// U+032CCombining Caron Below\n U_Combining_Circumflex_Accent_Below = 0x032D,// U+032DCombining Circumflex Accent Below\n U_Combining_Breve_Below = 0x032E,// U+032ECombining Breve Below\n U_Combining_Inverted_Breve_Below = 0x032F,// U+032FCombining Inverted Breve Below\n U_Combining_Tilde_Below = 0x0330,// U+0330Combining Tilde Below\n U_Combining_Macron_Below = 0x0331,// U+0331Combining Macron Below\n U_Combining_Low_Line = 0x0332,// U+0332Combining Low Line\n U_Combining_Double_Low_Line = 0x0333,// U+0333Combining Double Low Line\n U_Combining_Tilde_Overlay = 0x0334,// U+0334Combining Tilde Overlay\n U_Combining_Short_Stroke_Overlay = 0x0335,// U+0335Combining Short Stroke Overlay\n U_Combining_Long_Stroke_Overlay = 0x0336,// U+0336Combining Long Stroke Overlay\n U_Combining_Short_Solidus_Overlay = 0x0337,// U+0337Combining Short Solidus Overlay\n U_Combining_Long_Solidus_Overlay = 0x0338,// U+0338Combining Long Solidus Overlay\n U_Combining_Right_Half_Ring_Below = 0x0339,// U+0339Combining Right Half Ring Below\n U_Combining_Inverted_Bridge_Below = 0x033A,// U+033ACombining Inverted Bridge Below\n U_Combining_Square_Below = 0x033B,// U+033BCombining Square Below\n U_Combining_Seagull_Below = 0x033C,// U+033CCombining Seagull Below\n U_Combining_X_Above = 0x033D,// U+033DCombining X Above\n U_Combining_Vertical_Tilde = 0x033E,// U+033ECombining Vertical Tilde\n U_Combining_Double_Overline = 0x033F,// U+033FCombining Double Overline\n U_Combining_Grave_Tone_Mark = 0x0340,// U+0340Combining Grave Tone Mark\n U_Combining_Acute_Tone_Mark = 0x0341,// U+0341Combining Acute Tone Mark\n U_Combining_Greek_Perispomeni = 0x0342,// U+0342Combining Greek Perispomeni\n U_Combining_Greek_Koronis = 0x0343,// U+0343Combining Greek Koronis\n U_Combining_Greek_Dialytika_Tonos = 0x0344,// U+0344Combining Greek Dialytika Tonos\n U_Combining_Greek_Ypogegrammeni = 0x0345,// U+0345Combining Greek Ypogegrammeni\n U_Combining_Bridge_Above = 0x0346,// U+0346Combining Bridge Above\n U_Combining_Equals_Sign_Below = 0x0347,// U+0347Combining Equals Sign Below\n U_Combining_Double_Vertical_Line_Below = 0x0348,// U+0348Combining Double Vertical Line Below\n U_Combining_Left_Angle_Below = 0x0349,// U+0349Combining Left Angle Below\n U_Combining_Not_Tilde_Above = 0x034A,// U+034ACombining Not Tilde Above\n U_Combining_Homothetic_Above = 0x034B,// U+034BCombining Homothetic Above\n U_Combining_Almost_Equal_To_Above = 0x034C,// U+034CCombining Almost Equal To Above\n U_Combining_Left_Right_Arrow_Below = 0x034D,// U+034DCombining Left Right Arrow Below\n U_Combining_Upwards_Arrow_Below = 0x034E,// U+034ECombining Upwards Arrow Below\n U_Combining_Grapheme_Joiner = 0x034F,// U+034FCombining Grapheme Joiner\n U_Combining_Right_Arrowhead_Above = 0x0350,// U+0350Combining Right Arrowhead Above\n U_Combining_Left_Half_Ring_Above = 0x0351,// U+0351Combining Left Half Ring Above\n U_Combining_Fermata = 0x0352,// U+0352Combining Fermata\n U_Combining_X_Below = 0x0353,// U+0353Combining X Below\n U_Combining_Left_Arrowhead_Below = 0x0354,// U+0354Combining Left Arrowhead Below\n U_Combining_Right_Arrowhead_Below = 0x0355,// U+0355Combining Right Arrowhead Below\n U_Combining_Right_Arrowhead_And_Up_Arrowhead_Below = 0x0356,// U+0356Combining Right Arrowhead And Up Arrowhead Below\n U_Combining_Right_Half_Ring_Above = 0x0357,// U+0357Combining Right Half Ring Above\n U_Combining_Dot_Above_Right = 0x0358,// U+0358Combining Dot Above Right\n U_Combining_Asterisk_Below = 0x0359,// U+0359Combining Asterisk Below\n U_Combining_Double_Ring_Below = 0x035A,// U+035ACombining Double Ring Below\n U_Combining_Zigzag_Above = 0x035B,// U+035BCombining Zigzag Above\n U_Combining_Double_Breve_Below = 0x035C,// U+035CCombining Double Breve Below\n U_Combining_Double_Breve = 0x035D,// U+035DCombining Double Breve\n U_Combining_Double_Macron = 0x035E,// U+035ECombining Double Macron\n U_Combining_Double_Macron_Below = 0x035F,// U+035FCombining Double Macron Below\n U_Combining_Double_Tilde = 0x0360,// U+0360Combining Double Tilde\n U_Combining_Double_Inverted_Breve = 0x0361,// U+0361Combining Double Inverted Breve\n U_Combining_Double_Rightwards_Arrow_Below = 0x0362,// U+0362Combining Double Rightwards Arrow Below\n U_Combining_Latin_Small_Letter_A = 0x0363, // U+0363Combining Latin Small Letter A\n U_Combining_Latin_Small_Letter_E = 0x0364, // U+0364Combining Latin Small Letter E\n U_Combining_Latin_Small_Letter_I = 0x0365, // U+0365Combining Latin Small Letter I\n U_Combining_Latin_Small_Letter_O = 0x0366, // U+0366Combining Latin Small Letter O\n U_Combining_Latin_Small_Letter_U = 0x0367, // U+0367Combining Latin Small Letter U\n U_Combining_Latin_Small_Letter_C = 0x0368, // U+0368Combining Latin Small Letter C\n U_Combining_Latin_Small_Letter_D = 0x0369, // U+0369Combining Latin Small Letter D\n U_Combining_Latin_Small_Letter_H = 0x036A, // U+036ACombining Latin Small Letter H\n U_Combining_Latin_Small_Letter_M = 0x036B, // U+036BCombining Latin Small Letter M\n U_Combining_Latin_Small_Letter_R = 0x036C, // U+036CCombining Latin Small Letter R\n U_Combining_Latin_Small_Letter_T = 0x036D, // U+036DCombining Latin Small Letter T\n U_Combining_Latin_Small_Letter_V = 0x036E, // U+036ECombining Latin Small Letter V\n U_Combining_Latin_Small_Letter_X = 0x036F, // U+036FCombining Latin Small Letter X\n\n /**\n * Unicode Character 'LINE SEPARATOR' (U+2028)\n * http://www.fileformat.info/info/unicode/char/2028/index.htm\n */\n LINE_SEPARATOR = 0x2028,\n /**\n * Unicode Character 'PARAGRAPH SEPARATOR' (U+2029)\n * http://www.fileformat.info/info/unicode/char/2029/index.htm\n */\n PARAGRAPH_SEPARATOR = 0x2029,\n /**\n * Unicode Character 'NEXT LINE' (U+0085)\n * http://www.fileformat.info/info/unicode/char/0085/index.htm\n */\n NEXT_LINE = 0x0085,\n\n // http://www.fileformat.info/info/unicode/category/Sk/list.htm\n U_CIRCUMFLEX = 0x005E,// U+005ECIRCUMFLEX\n U_GRAVE_ACCENT = 0x0060,// U+0060GRAVE ACCENT\n U_DIAERESIS = 0x00A8,// U+00A8DIAERESIS\n U_MACRON = 0x00AF,// U+00AFMACRON\n U_ACUTE_ACCENT = 0x00B4,// U+00B4ACUTE ACCENT\n U_CEDILLA = 0x00B8,// U+00B8CEDILLA\n U_MODIFIER_LETTER_LEFT_ARROWHEAD = 0x02C2,// U+02C2MODIFIER LETTER LEFT ARROWHEAD\n U_MODIFIER_LETTER_RIGHT_ARROWHEAD = 0x02C3,// U+02C3MODIFIER LETTER RIGHT ARROWHEAD\n U_MODIFIER_LETTER_UP_ARROWHEAD = 0x02C4,// U+02C4MODIFIER LETTER UP ARROWHEAD\n U_MODIFIER_LETTER_DOWN_ARROWHEAD = 0x02C5,// U+02C5MODIFIER LETTER DOWN ARROWHEAD\n U_MODIFIER_LETTER_CENTRED_RIGHT_HALF_RING = 0x02D2,// U+02D2MODIFIER LETTER CENTRED RIGHT HALF RING\n U_MODIFIER_LETTER_CENTRED_LEFT_HALF_RING = 0x02D3,// U+02D3MODIFIER LETTER CENTRED LEFT HALF RING\n U_MODIFIER_LETTER_UP_TACK = 0x02D4,// U+02D4MODIFIER LETTER UP TACK\n U_MODIFIER_LETTER_DOWN_TACK = 0x02D5,// U+02D5MODIFIER LETTER DOWN TACK\n U_MODIFIER_LETTER_PLUS_SIGN = 0x02D6,// U+02D6MODIFIER LETTER PLUS SIGN\n U_MODIFIER_LETTER_MINUS_SIGN = 0x02D7,// U+02D7MODIFIER LETTER MINUS SIGN\n U_BREVE = 0x02D8,// U+02D8BREVE\n U_DOT_ABOVE = 0x02D9,// U+02D9DOT ABOVE\n U_RING_ABOVE = 0x02DA,// U+02DARING ABOVE\n U_OGONEK = 0x02DB,// U+02DBOGONEK\n U_SMALL_TILDE = 0x02DC,// U+02DCSMALL TILDE\n U_DOUBLE_ACUTE_ACCENT = 0x02DD,// U+02DDDOUBLE ACUTE ACCENT\n U_MODIFIER_LETTER_RHOTIC_HOOK = 0x02DE,// U+02DEMODIFIER LETTER RHOTIC HOOK\n U_MODIFIER_LETTER_CROSS_ACCENT = 0x02DF,// U+02DFMODIFIER LETTER CROSS ACCENT\n U_MODIFIER_LETTER_EXTRA_HIGH_TONE_BAR = 0x02E5,// U+02E5MODIFIER LETTER EXTRA-HIGH TONE BAR\n U_MODIFIER_LETTER_HIGH_TONE_BAR = 0x02E6,// U+02E6MODIFIER LETTER HIGH TONE BAR\n U_MODIFIER_LETTER_MID_TONE_BAR = 0x02E7,// U+02E7MODIFIER LETTER MID TONE BAR\n U_MODIFIER_LETTER_LOW_TONE_BAR = 0x02E8,// U+02E8MODIFIER LETTER LOW TONE BAR\n U_MODIFIER_LETTER_EXTRA_LOW_TONE_BAR = 0x02E9,// U+02E9MODIFIER LETTER EXTRA-LOW TONE BAR\n U_MODIFIER_LETTER_YIN_DEPARTING_TONE_MARK = 0x02EA,// U+02EAMODIFIER LETTER YIN DEPARTING TONE MARK\n U_MODIFIER_LETTER_YANG_DEPARTING_TONE_MARK = 0x02EB,// U+02EBMODIFIER LETTER YANG DEPARTING TONE MARK\n U_MODIFIER_LETTER_UNASPIRATED = 0x02ED,// U+02EDMODIFIER LETTER UNASPIRATED\n U_MODIFIER_LETTER_LOW_DOWN_ARROWHEAD = 0x02EF,// U+02EFMODIFIER LETTER LOW DOWN ARROWHEAD\n U_MODIFIER_LETTER_LOW_UP_ARROWHEAD = 0x02F0,// U+02F0MODIFIER LETTER LOW UP ARROWHEAD\n U_MODIFIER_LETTER_LOW_LEFT_ARROWHEAD = 0x02F1,// U+02F1MODIFIER LETTER LOW LEFT ARROWHEAD\n U_MODIFIER_LETTER_LOW_RIGHT_ARROWHEAD = 0x02F2,// U+02F2MODIFIER LETTER LOW RIGHT ARROWHEAD\n U_MODIFIER_LETTER_LOW_RING = 0x02F3,// U+02F3MODIFIER LETTER LOW RING\n U_MODIFIER_LETTER_MIDDLE_GRAVE_ACCENT = 0x02F4,// U+02F4MODIFIER LETTER MIDDLE GRAVE ACCENT\n U_MODIFIER_LETTER_MIDDLE_DOUBLE_GRAVE_ACCENT = 0x02F5,// U+02F5MODIFIER LETTER MIDDLE DOUBLE GRAVE ACCENT\n U_MODIFIER_LETTER_MIDDLE_DOUBLE_ACUTE_ACCENT = 0x02F6,// U+02F6MODIFIER LETTER MIDDLE DOUBLE ACUTE ACCENT\n U_MODIFIER_LETTER_LOW_TILDE = 0x02F7,// U+02F7MODIFIER LETTER LOW TILDE\n U_MODIFIER_LETTER_RAISED_COLON = 0x02F8,// U+02F8MODIFIER LETTER RAISED COLON\n U_MODIFIER_LETTER_BEGIN_HIGH_TONE = 0x02F9,// U+02F9MODIFIER LETTER BEGIN HIGH TONE\n U_MODIFIER_LETTER_END_HIGH_TONE = 0x02FA,// U+02FAMODIFIER LETTER END HIGH TONE\n U_MODIFIER_LETTER_BEGIN_LOW_TONE = 0x02FB,// U+02FBMODIFIER LETTER BEGIN LOW TONE\n U_MODIFIER_LETTER_END_LOW_TONE = 0x02FC,// U+02FCMODIFIER LETTER END LOW TONE\n U_MODIFIER_LETTER_SHELF = 0x02FD,// U+02FDMODIFIER LETTER SHELF\n U_MODIFIER_LETTER_OPEN_SHELF = 0x02FE,// U+02FEMODIFIER LETTER OPEN SHELF\n U_MODIFIER_LETTER_LOW_LEFT_ARROW = 0x02FF,// U+02FFMODIFIER LETTER LOW LEFT ARROW\n U_GREEK_LOWER_NUMERAL_SIGN = 0x0375,// U+0375GREEK LOWER NUMERAL SIGN\n U_GREEK_TONOS = 0x0384,// U+0384GREEK TONOS\n U_GREEK_DIALYTIKA_TONOS = 0x0385,// U+0385GREEK DIALYTIKA TONOS\n U_GREEK_KORONIS = 0x1FBD,// U+1FBDGREEK KORONIS\n U_GREEK_PSILI = 0x1FBF,// U+1FBFGREEK PSILI\n U_GREEK_PERISPOMENI = 0x1FC0,// U+1FC0GREEK PERISPOMENI\n U_GREEK_DIALYTIKA_AND_PERISPOMENI = 0x1FC1,// U+1FC1GREEK DIALYTIKA AND PERISPOMENI\n U_GREEK_PSILI_AND_VARIA = 0x1FCD,// U+1FCDGREEK PSILI AND VARIA\n U_GREEK_PSILI_AND_OXIA = 0x1FCE,// U+1FCEGREEK PSILI AND OXIA\n U_GREEK_PSILI_AND_PERISPOMENI = 0x1FCF,// U+1FCFGREEK PSILI AND PERISPOMENI\n U_GREEK_DASIA_AND_VARIA = 0x1FDD,// U+1FDDGREEK DASIA AND VARIA\n U_GREEK_DASIA_AND_OXIA = 0x1FDE,// U+1FDEGREEK DASIA AND OXIA\n U_GREEK_DASIA_AND_PERISPOMENI = 0x1FDF,// U+1FDFGREEK DASIA AND PERISPOMENI\n U_GREEK_DIALYTIKA_AND_VARIA = 0x1FED,// U+1FEDGREEK DIALYTIKA AND VARIA\n U_GREEK_DIALYTIKA_AND_OXIA = 0x1FEE,// U+1FEEGREEK DIALYTIKA AND OXIA\n U_GREEK_VARIA = 0x1FEF,// U+1FEFGREEK VARIA\n U_GREEK_OXIA = 0x1FFD,// U+1FFDGREEK OXIA\n U_GREEK_DASIA = 0x1FFE,// U+1FFEGREEK DASIA\n\n U_OVERLINE = 0x203E, // Unicode Character 'OVERLINE'\n\n /**\n * UTF-8 BOM\n * Unicode Character 'ZERO WIDTH NO-BREAK SPACE' (U+FEFF)\n * http://www.fileformat.info/info/unicode/char/feff/index.htm\n */\n UTF8_BOM = 65279\n}\n"]}