@wallarm-org/design-system 4.8.0-rc-feat-parser.1 → 4.8.0-rc-fix-claude-code.2

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 (176) hide show
  1. package/README.md +4 -2
  2. package/dist/components/BulkBar/index.d.ts +5 -0
  3. package/dist/components/Drawer/classes.js +1 -1
  4. package/dist/components/DropdownMenu/DropdownMenu.d.ts +0 -2
  5. package/dist/components/DropdownMenu/DropdownMenu.js +71 -84
  6. package/dist/components/DropdownMenu/DropdownMenuItemDescription.js +1 -1
  7. package/dist/components/FilterInput/hooks/useFilterInputAutocomplete/useFilterInputAutocomplete.js +1 -1
  8. package/dist/components/NotificationCenter/NotificationCenter.d.ts +20 -0
  9. package/dist/components/NotificationCenter/NotificationCenter.js +65 -0
  10. package/dist/components/NotificationCenter/NotificationCenterBody.d.ts +18 -0
  11. package/dist/components/NotificationCenter/NotificationCenterBody.js +202 -0
  12. package/dist/components/NotificationCenter/NotificationCenterContent.d.ts +5 -0
  13. package/dist/components/NotificationCenter/NotificationCenterContent.js +42 -0
  14. package/dist/components/NotificationCenter/NotificationCenterHeader.d.ts +20 -0
  15. package/dist/components/NotificationCenter/NotificationCenterHeader.js +202 -0
  16. package/dist/components/NotificationCenter/NotificationCenterItem.d.ts +26 -0
  17. package/dist/components/NotificationCenter/NotificationCenterItem.js +211 -0
  18. package/dist/components/NotificationCenter/NotificationCenterItemTime.d.ts +9 -0
  19. package/dist/components/NotificationCenter/NotificationCenterItemTime.js +148 -0
  20. package/dist/components/NotificationCenter/NotificationCenterItemTitle.d.ts +14 -0
  21. package/dist/components/NotificationCenter/NotificationCenterItemTitle.js +115 -0
  22. package/dist/components/NotificationCenter/NotificationCenterTabs.d.ts +10 -0
  23. package/dist/components/NotificationCenter/NotificationCenterTabs.js +77 -0
  24. package/dist/components/NotificationCenter/NotificationCenterTrigger.d.ts +13 -0
  25. package/dist/components/NotificationCenter/NotificationCenterTrigger.js +138 -0
  26. package/dist/components/NotificationCenter/index.d.ts +9 -0
  27. package/dist/components/NotificationCenter/index.js +9 -0
  28. package/dist/components/Overlay/Overlay.js +1 -1
  29. package/dist/components/SearchInput/SearchInput.d.ts +7 -5
  30. package/dist/components/SearchInput/SearchInput.js +119 -101
  31. package/dist/components/Select/SelectSearchInput.d.ts +1 -1
  32. package/dist/components/Table/types.d.ts +1 -1
  33. package/dist/components/Tabs/Tabs.d.ts +1 -0
  34. package/dist/components/Tabs/Tabs.js +30 -28
  35. package/dist/components/Tabs/TabsList/index.d.ts +1 -1
  36. package/dist/components/Tabs/index.d.ts +2 -2
  37. package/dist/components/Tour/TourPositioner.d.ts +3 -0
  38. package/dist/components/Tour/TourPositioner.js +4 -4
  39. package/dist/guidelines/foundations/color.md +157 -0
  40. package/dist/guidelines/foundations/focus.md +122 -0
  41. package/dist/guidelines/foundations/layering.md +131 -0
  42. package/dist/guidelines/foundations/radius-elevation.md +111 -0
  43. package/dist/guidelines/foundations/spacing.md +117 -0
  44. package/dist/guidelines/foundations/typography.md +114 -0
  45. package/dist/guidelines/patterns/app-layout.md +1567 -0
  46. package/dist/guidelines/patterns/auth-page.md +668 -0
  47. package/dist/guidelines/patterns/confirmation-dialogs.md +605 -0
  48. package/dist/guidelines/patterns/create-edit-forms.md +768 -0
  49. package/dist/guidelines/patterns/detail-drawer.md +868 -0
  50. package/dist/guidelines/patterns/empty-states.md +461 -0
  51. package/dist/guidelines/patterns/entity-table.md +533 -0
  52. package/dist/guidelines/patterns/feedback-toasts.md +493 -0
  53. package/dist/guidelines/patterns/filtering.md +630 -0
  54. package/dist/guidelines/patterns/resource-list-page.md +558 -0
  55. package/dist/guidelines/patterns/settings-page.md +752 -0
  56. package/dist/guidelines/rules.md +25 -0
  57. package/dist/index.d.ts +2 -3
  58. package/dist/index.js +1 -2
  59. package/dist/metadata/components.json +12431 -9208
  60. package/dist/metadata/guidelines.json +1705 -0
  61. package/dist/theme/typography.css +5 -0
  62. package/dist/utils/formatDateTime.d.ts +6 -0
  63. package/dist/utils/formatDateTime.js +13 -1
  64. package/package.json +6 -4
  65. package/dist/components/Rules/PointSelector/KeyboardShortcutsDialog.d.ts +0 -14
  66. package/dist/components/Rules/PointSelector/KeyboardShortcutsDialog.js +0 -209
  67. package/dist/components/Rules/PointSelector/MatchStep.d.ts +0 -15
  68. package/dist/components/Rules/PointSelector/MatchStep.js +0 -186
  69. package/dist/components/Rules/PointSelector/MenuFooterHints.d.ts +0 -16
  70. package/dist/components/Rules/PointSelector/MenuFooterHints.js +0 -177
  71. package/dist/components/Rules/PointSelector/PointPreview.d.ts +0 -10
  72. package/dist/components/Rules/PointSelector/PointPreview.js +0 -88
  73. package/dist/components/Rules/PointSelector/PointSelector.d.ts +0 -17
  74. package/dist/components/Rules/PointSelector/PointSelector.js +0 -937
  75. package/dist/components/Rules/PointSelector/PointSelectorEmptyState.d.ts +0 -12
  76. package/dist/components/Rules/PointSelector/PointSelectorEmptyState.js +0 -173
  77. package/dist/components/Rules/PointSelector/PointSelectorError.d.ts +0 -31
  78. package/dist/components/Rules/PointSelector/PointSelectorError.js +0 -275
  79. package/dist/components/Rules/PointSelector/PointSelectorInput.d.ts +0 -20
  80. package/dist/components/Rules/PointSelector/PointSelectorInput.js +0 -130
  81. package/dist/components/Rules/PointSelector/PointSelectorMenu.d.ts +0 -31
  82. package/dist/components/Rules/PointSelector/PointSelectorMenu.js +0 -317
  83. package/dist/components/Rules/PointSelector/PointSelectorSkeleton.d.ts +0 -8
  84. package/dist/components/Rules/PointSelector/PointSelectorSkeleton.js +0 -73
  85. package/dist/components/Rules/PointSelector/SampleRequest.d.ts +0 -14
  86. package/dist/components/Rules/PointSelector/SampleRequest.js +0 -116
  87. package/dist/components/Rules/PointSelector/StepMenu.d.ts +0 -40
  88. package/dist/components/Rules/PointSelector/StepMenu.js +0 -210
  89. package/dist/components/Rules/PointSelector/VersionWarning.d.ts +0 -26
  90. package/dist/components/Rules/PointSelector/VersionWarning.js +0 -231
  91. package/dist/components/Rules/PointSelector/WhereBar.d.ts +0 -48
  92. package/dist/components/Rules/PointSelector/WhereBar.js +0 -263
  93. package/dist/components/Rules/PointSelector/classes.d.ts +0 -28
  94. package/dist/components/Rules/PointSelector/classes.js +0 -22
  95. package/dist/components/Rules/PointSelector/index.d.ts +0 -20
  96. package/dist/components/Rules/PointSelector/index.js +0 -18
  97. package/dist/components/Rules/PointSelector/liftLayer.d.ts +0 -8
  98. package/dist/components/Rules/PointSelector/liftLayer.js +0 -4
  99. package/dist/components/Rules/PointSelector/sampleValue.d.ts +0 -6
  100. package/dist/components/Rules/PointSelector/sampleValue.js +0 -51
  101. package/dist/components/Rules/PointSelector/sdkBridge.d.ts +0 -508
  102. package/dist/components/Rules/PointSelector/sdkBridge.js +0 -339
  103. package/dist/components/Rules/PointSelector/types.d.ts +0 -304
  104. package/dist/components/Rules/PointSelector/types.js +0 -0
  105. package/dist/components/Rules/PointSelector/usePointSelector.d.ts +0 -161
  106. package/dist/components/Rules/PointSelector/usePointSelector.js +0 -1088
  107. package/dist/components/Rules/RuleBuilder/ActionEditor/ActionEditor.d.ts +0 -28
  108. package/dist/components/Rules/RuleBuilder/ActionEditor/ActionEditor.js +0 -208
  109. package/dist/components/Rules/RuleBuilder/ActionEditor/ActionFields.d.ts +0 -23
  110. package/dist/components/Rules/RuleBuilder/ActionEditor/ActionFields.js +0 -950
  111. package/dist/components/Rules/RuleBuilder/ActionEditor/ActionTargetPicker.d.ts +0 -21
  112. package/dist/components/Rules/RuleBuilder/ActionEditor/ActionTargetPicker.js +0 -110
  113. package/dist/components/Rules/RuleBuilder/ActionEditor/ActionTypeSelect.d.ts +0 -20
  114. package/dist/components/Rules/RuleBuilder/ActionEditor/ActionTypeSelect.js +0 -31
  115. package/dist/components/Rules/RuleBuilder/ActionEditor/AttackTypeField.d.ts +0 -23
  116. package/dist/components/Rules/RuleBuilder/ActionEditor/AttackTypeField.js +0 -131
  117. package/dist/components/Rules/RuleBuilder/ActionEditor/classes.d.ts +0 -17
  118. package/dist/components/Rules/RuleBuilder/ActionEditor/classes.js +0 -14
  119. package/dist/components/Rules/RuleBuilder/ActionEditor/index.d.ts +0 -6
  120. package/dist/components/Rules/RuleBuilder/ActionEditor/index.js +0 -6
  121. package/dist/components/Rules/RuleBuilder/ConditionTree/AddConditionMenu.d.ts +0 -24
  122. package/dist/components/Rules/RuleBuilder/ConditionTree/AddConditionMenu.js +0 -245
  123. package/dist/components/Rules/RuleBuilder/ConditionTree/AttackCondition.d.ts +0 -15
  124. package/dist/components/Rules/RuleBuilder/ConditionTree/AttackCondition.js +0 -691
  125. package/dist/components/Rules/RuleBuilder/ConditionTree/ConditionCard.d.ts +0 -19
  126. package/dist/components/Rules/RuleBuilder/ConditionTree/ConditionCard.js +0 -72
  127. package/dist/components/Rules/RuleBuilder/ConditionTree/ConditionTree.d.ts +0 -27
  128. package/dist/components/Rules/RuleBuilder/ConditionTree/ConditionTree.js +0 -407
  129. package/dist/components/Rules/RuleBuilder/ConditionTree/FieldCondition.d.ts +0 -14
  130. package/dist/components/Rules/RuleBuilder/ConditionTree/FieldCondition.js +0 -269
  131. package/dist/components/Rules/RuleBuilder/ConditionTree/GroupCondition.d.ts +0 -25
  132. package/dist/components/Rules/RuleBuilder/ConditionTree/GroupCondition.js +0 -99
  133. package/dist/components/Rules/RuleBuilder/ConditionTree/SampleCondition.d.ts +0 -14
  134. package/dist/components/Rules/RuleBuilder/ConditionTree/SampleCondition.js +0 -118
  135. package/dist/components/Rules/RuleBuilder/ConditionTree/SignalCondition.d.ts +0 -14
  136. package/dist/components/Rules/RuleBuilder/ConditionTree/SignalCondition.js +0 -446
  137. package/dist/components/Rules/RuleBuilder/ConditionTree/TagCondition.d.ts +0 -14
  138. package/dist/components/Rules/RuleBuilder/ConditionTree/TagCondition.js +0 -266
  139. package/dist/components/Rules/RuleBuilder/ConditionTree/classes.d.ts +0 -35
  140. package/dist/components/Rules/RuleBuilder/ConditionTree/classes.js +0 -57
  141. package/dist/components/Rules/RuleBuilder/ConditionTree/index.d.ts +0 -15
  142. package/dist/components/Rules/RuleBuilder/ConditionTree/index.js +0 -10
  143. package/dist/components/Rules/RuleBuilder/RuleBuilder.d.ts +0 -67
  144. package/dist/components/Rules/RuleBuilder/RuleBuilder.js +0 -366
  145. package/dist/components/Rules/RuleBuilder/Summary/ActionSummary.d.ts +0 -32
  146. package/dist/components/Rules/RuleBuilder/Summary/ActionSummary.js +0 -420
  147. package/dist/components/Rules/RuleBuilder/Summary/ConditionSummary.d.ts +0 -27
  148. package/dist/components/Rules/RuleBuilder/Summary/ConditionSummary.js +0 -446
  149. package/dist/components/Rules/RuleBuilder/Summary/index.d.ts +0 -7
  150. package/dist/components/Rules/RuleBuilder/Summary/index.js +0 -2
  151. package/dist/components/Rules/RuleBuilder/classes.d.ts +0 -19
  152. package/dist/components/Rules/RuleBuilder/classes.js +0 -18
  153. package/dist/components/Rules/RuleBuilder/index.d.ts +0 -55
  154. package/dist/components/Rules/RuleBuilder/index.js +0 -11
  155. package/dist/components/Rules/RuleBuilder/models/actionModel.d.ts +0 -31
  156. package/dist/components/Rules/RuleBuilder/models/actionModel.js +0 -276
  157. package/dist/components/Rules/RuleBuilder/models/conditionModel.d.ts +0 -95
  158. package/dist/components/Rules/RuleBuilder/models/conditionModel.js +0 -418
  159. package/dist/components/Rules/RuleBuilder/models/index.d.ts +0 -3
  160. package/dist/components/Rules/RuleBuilder/models/index.js +0 -3
  161. package/dist/components/Rules/RuleBuilder/models/validation.d.ts +0 -176
  162. package/dist/components/Rules/RuleBuilder/models/validation.js +0 -242
  163. package/dist/components/Rules/RuleBuilder/shared/ChoiceSelect.d.ts +0 -27
  164. package/dist/components/Rules/RuleBuilder/shared/ChoiceSelect.js +0 -92
  165. package/dist/components/Rules/RuleBuilder/shared/index.d.ts +0 -1
  166. package/dist/components/Rules/RuleBuilder/shared/index.js +0 -1
  167. package/dist/components/Rules/RuleBuilder/types.d.ts +0 -384
  168. package/dist/components/Rules/RuleBuilder/types.js +0 -0
  169. package/dist/components/Rules/RuleBuilder/utils/constants.d.ts +0 -65
  170. package/dist/components/Rules/RuleBuilder/utils/constants.js +0 -356
  171. package/dist/components/Rules/RuleBuilder/utils/extractBindings.d.ts +0 -48
  172. package/dist/components/Rules/RuleBuilder/utils/extractBindings.js +0 -42
  173. package/dist/components/Rules/RuleBuilder/utils/helpers.d.ts +0 -92
  174. package/dist/components/Rules/RuleBuilder/utils/helpers.js +0 -54
  175. package/dist/components/Rules/RuleBuilder/utils/index.d.ts +0 -2
  176. package/dist/components/Rules/RuleBuilder/utils/index.js +0 -2
@@ -1,317 +0,0 @@
1
- import { jsx, jsxs } from "react/jsx-runtime";
2
- import { c } from "react/compiler-runtime";
3
- import { useTestId } from "../../../utils/testId.js";
4
- import { DropdownMenu, DropdownMenuContent, DropdownMenuFooter, DropdownMenuGroup, DropdownMenuItem, DropdownMenuItemContent, DropdownMenuItemDescription, DropdownMenuItemText, DropdownMenuLabel, DropdownMenuShortcut } from "../../DropdownMenu/index.js";
5
- import { Kbd } from "../../Kbd/index.js";
6
- import { MenuFooterHints } from "./MenuFooterHints.js";
7
- const PointSelectorMenu = (t0)=>{
8
- const $ = c(81);
9
- let anchorRef;
10
- let contentId;
11
- let highlightedId;
12
- let items;
13
- let onClose;
14
- let onHighlight;
15
- let onSelect;
16
- let open;
17
- let props;
18
- let t1;
19
- if ($[0] !== t0) {
20
- const { open: t2, contentId: t3, anchorRef: t4, focusRef, items: t5, highlightedId: t6, onSelect: t7, onHighlight: t8, onClose: t9, isNameMode: t10, ...t11 } = t0;
21
- open = t2;
22
- contentId = t3;
23
- anchorRef = t4;
24
- items = t5;
25
- highlightedId = t6;
26
- onSelect = t7;
27
- onHighlight = t8;
28
- onClose = t9;
29
- t1 = t10;
30
- props = t11;
31
- $[0] = t0;
32
- $[1] = anchorRef;
33
- $[2] = contentId;
34
- $[3] = highlightedId;
35
- $[4] = items;
36
- $[5] = onClose;
37
- $[6] = onHighlight;
38
- $[7] = onSelect;
39
- $[8] = open;
40
- $[9] = props;
41
- $[10] = t1;
42
- } else {
43
- anchorRef = $[1];
44
- contentId = $[2];
45
- highlightedId = $[3];
46
- items = $[4];
47
- onClose = $[5];
48
- onHighlight = $[6];
49
- onSelect = $[7];
50
- open = $[8];
51
- props = $[9];
52
- t1 = $[10];
53
- }
54
- const isNameMode = void 0 === t1 ? false : t1;
55
- const testId = useTestId("menu");
56
- let T0;
57
- let T1;
58
- let T2;
59
- let t10;
60
- let t11;
61
- let t12;
62
- let t13;
63
- let t14;
64
- let t15;
65
- let t16;
66
- let t17;
67
- let t18;
68
- let t19;
69
- let t2;
70
- let t3;
71
- let t4;
72
- let t5;
73
- let t6;
74
- let t7;
75
- let t8;
76
- let t9;
77
- if ($[11] !== anchorRef || $[12] !== contentId || $[13] !== highlightedId || $[14] !== items || $[15] !== onClose || $[16] !== onHighlight || $[17] !== onSelect || $[18] !== open || $[19] !== props || $[20] !== testId) {
78
- const grouped = items.reduce(_temp, {});
79
- items.slice(0, 9);
80
- T2 = DropdownMenu;
81
- t12 = open;
82
- if ($[42] !== contentId) {
83
- t13 = contentId ? {
84
- content: contentId
85
- } : void 0;
86
- $[42] = contentId;
87
- $[43] = t13;
88
- } else t13 = $[43];
89
- if ($[44] !== onClose) {
90
- t14 = (next)=>!next && onClose?.();
91
- $[44] = onClose;
92
- $[45] = t14;
93
- } else t14 = $[45];
94
- t15 = false;
95
- t16 = false;
96
- t17 = highlightedId ?? void 0;
97
- if ($[46] !== onHighlight) {
98
- t18 = (d)=>d.highlightedValue && onHighlight?.(d.highlightedValue);
99
- $[46] = onHighlight;
100
- $[47] = t18;
101
- } else t18 = $[47];
102
- if ($[48] !== anchorRef) {
103
- t19 = {
104
- placement: "bottom-start",
105
- flip: false,
106
- gutter: 6,
107
- getAnchorRect: ()=>anchorRef?.current?.getBoundingClientRect() ?? null
108
- };
109
- $[48] = anchorRef;
110
- $[49] = t19;
111
- } else t19 = $[49];
112
- T1 = DropdownMenuContent;
113
- t4 = props;
114
- t5 = "point-selector-menu";
115
- t6 = testId;
116
- t7 = "listbox";
117
- t8 = contentId;
118
- t9 = "w-[460px]";
119
- if ($[50] === Symbol.for("react.memo_cache_sentinel")) {
120
- t10 = {
121
- maxHeight: "min(460px, var(--available-height))"
122
- };
123
- t11 = /*#__PURE__*/ jsx(DropdownMenuLabel, {
124
- children: "Choose next step"
125
- });
126
- $[50] = t10;
127
- $[51] = t11;
128
- } else {
129
- t10 = $[50];
130
- t11 = $[51];
131
- }
132
- T0 = DropdownMenuGroup;
133
- t2 = "flex flex-col gap-1";
134
- t3 = Object.entries(grouped).map((t20)=>{
135
- const [category, categoryItems] = t20;
136
- const relevantItems = categoryItems.filter(_temp2);
137
- if (0 === relevantItems.length) return null;
138
- return /*#__PURE__*/ jsx("div", {
139
- children: categoryItems.map((t21)=>{
140
- const { item: item_0, index: index_1 } = t21;
141
- if (index_1 >= 9) return null;
142
- const displayNumber = index_1 + 1;
143
- const itemId = `item-${index_1}`;
144
- return /*#__PURE__*/ jsxs(DropdownMenuItem, {
145
- value: itemId,
146
- role: "option",
147
- "aria-selected": itemId === highlightedId,
148
- onSelect: ()=>onSelect(item_0),
149
- children: [
150
- /*#__PURE__*/ jsxs(DropdownMenuItemContent, {
151
- children: [
152
- /*#__PURE__*/ jsx(DropdownMenuItemText, {
153
- children: item_0.label
154
- }),
155
- item_0.detail && /*#__PURE__*/ jsx(DropdownMenuItemDescription, {
156
- children: item_0.detail
157
- })
158
- ]
159
- }),
160
- /*#__PURE__*/ jsx(DropdownMenuShortcut, {
161
- children: /*#__PURE__*/ jsx(Kbd, {
162
- size: "small",
163
- children: displayNumber
164
- })
165
- })
166
- ]
167
- }, itemId);
168
- })
169
- }, category);
170
- });
171
- $[11] = anchorRef;
172
- $[12] = contentId;
173
- $[13] = highlightedId;
174
- $[14] = items;
175
- $[15] = onClose;
176
- $[16] = onHighlight;
177
- $[17] = onSelect;
178
- $[18] = open;
179
- $[19] = props;
180
- $[20] = testId;
181
- $[21] = T0;
182
- $[22] = T1;
183
- $[23] = T2;
184
- $[24] = t10;
185
- $[25] = t11;
186
- $[26] = t12;
187
- $[27] = t13;
188
- $[28] = t14;
189
- $[29] = t15;
190
- $[30] = t16;
191
- $[31] = t17;
192
- $[32] = t18;
193
- $[33] = t19;
194
- $[34] = t2;
195
- $[35] = t3;
196
- $[36] = t4;
197
- $[37] = t5;
198
- $[38] = t6;
199
- $[39] = t7;
200
- $[40] = t8;
201
- $[41] = t9;
202
- } else {
203
- T0 = $[21];
204
- T1 = $[22];
205
- T2 = $[23];
206
- t10 = $[24];
207
- t11 = $[25];
208
- t12 = $[26];
209
- t13 = $[27];
210
- t14 = $[28];
211
- t15 = $[29];
212
- t16 = $[30];
213
- t17 = $[31];
214
- t18 = $[32];
215
- t19 = $[33];
216
- t2 = $[34];
217
- t3 = $[35];
218
- t4 = $[36];
219
- t5 = $[37];
220
- t6 = $[38];
221
- t7 = $[39];
222
- t8 = $[40];
223
- t9 = $[41];
224
- }
225
- let t20;
226
- if ($[52] !== T0 || $[53] !== t2 || $[54] !== t3) {
227
- t20 = /*#__PURE__*/ jsx(T0, {
228
- className: t2,
229
- children: t3
230
- });
231
- $[52] = T0;
232
- $[53] = t2;
233
- $[54] = t3;
234
- $[55] = t20;
235
- } else t20 = $[55];
236
- const t21 = isNameMode ? "name" : "list";
237
- let t22;
238
- if ($[56] !== t21) {
239
- t22 = /*#__PURE__*/ jsx(DropdownMenuFooter, {
240
- children: /*#__PURE__*/ jsx(MenuFooterHints, {
241
- variant: t21,
242
- escLabel: "to close"
243
- })
244
- });
245
- $[56] = t21;
246
- $[57] = t22;
247
- } else t22 = $[57];
248
- let t23;
249
- if ($[58] !== T1 || $[59] !== t10 || $[60] !== t11 || $[61] !== t20 || $[62] !== t22 || $[63] !== t4 || $[64] !== t5 || $[65] !== t6 || $[66] !== t7 || $[67] !== t8 || $[68] !== t9) {
250
- t23 = /*#__PURE__*/ jsxs(T1, {
251
- ...t4,
252
- "data-slot": t5,
253
- "data-testid": t6,
254
- role: t7,
255
- id: t8,
256
- className: t9,
257
- style: t10,
258
- children: [
259
- t11,
260
- t20,
261
- t22
262
- ]
263
- });
264
- $[58] = T1;
265
- $[59] = t10;
266
- $[60] = t11;
267
- $[61] = t20;
268
- $[62] = t22;
269
- $[63] = t4;
270
- $[64] = t5;
271
- $[65] = t6;
272
- $[66] = t7;
273
- $[67] = t8;
274
- $[68] = t9;
275
- $[69] = t23;
276
- } else t23 = $[69];
277
- let t24;
278
- if ($[70] !== T2 || $[71] !== t12 || $[72] !== t13 || $[73] !== t14 || $[74] !== t15 || $[75] !== t16 || $[76] !== t17 || $[77] !== t18 || $[78] !== t19 || $[79] !== t23) {
279
- t24 = /*#__PURE__*/ jsx(T2, {
280
- open: t12,
281
- ids: t13,
282
- onOpenChange: t14,
283
- closeOnSelect: t15,
284
- closeOnInteractOutside: t16,
285
- highlightedValue: t17,
286
- onHighlightChange: t18,
287
- positioning: t19,
288
- children: t23
289
- });
290
- $[70] = T2;
291
- $[71] = t12;
292
- $[72] = t13;
293
- $[73] = t14;
294
- $[74] = t15;
295
- $[75] = t16;
296
- $[76] = t17;
297
- $[77] = t18;
298
- $[78] = t19;
299
- $[79] = t23;
300
- $[80] = t24;
301
- } else t24 = $[80];
302
- return t24;
303
- };
304
- PointSelectorMenu.displayName = "PointSelectorMenu";
305
- function _temp(acc, item, index) {
306
- if (!acc[item.category]) acc[item.category] = [];
307
- acc[item.category]?.push({
308
- item,
309
- index
310
- });
311
- return acc;
312
- }
313
- function _temp2(t0) {
314
- const { index: index_0 } = t0;
315
- return index_0 < 9;
316
- }
317
- export { PointSelectorMenu };
@@ -1,8 +0,0 @@
1
- import type { FC } from 'react';
2
- /**
3
- * PointSelectorSkeleton Component
4
- *
5
- * Loading skeleton shown while SDK initializes.
6
- * Matches PointSelector layout with placeholder shapes.
7
- */
8
- export declare const PointSelectorSkeleton: FC;
@@ -1,73 +0,0 @@
1
- import { jsx, jsxs } from "react/jsx-runtime";
2
- import { c } from "react/compiler-runtime";
3
- import { Skeleton } from "../../Skeleton/index.js";
4
- import { Text } from "../../Text/index.js";
5
- const PointSelectorSkeleton = ()=>{
6
- const $ = c(3);
7
- let t0;
8
- if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
9
- t0 = /*#__PURE__*/ jsxs("div", {
10
- className: "flex items-center justify-between gap-12",
11
- children: [
12
- /*#__PURE__*/ jsx(Skeleton, {
13
- width: "200px",
14
- height: "20px",
15
- rounded: 4
16
- }),
17
- /*#__PURE__*/ jsx(Skeleton, {
18
- width: "160px",
19
- height: "36px",
20
- rounded: 8
21
- })
22
- ]
23
- });
24
- $[0] = t0;
25
- } else t0 = $[0];
26
- let t1;
27
- if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
28
- t1 = /*#__PURE__*/ jsxs("div", {
29
- className: "flex flex-col gap-8 rounded-12 border border-border-primary-light bg-bg-surface-1 p-12",
30
- children: [
31
- t0,
32
- /*#__PURE__*/ jsxs("div", {
33
- className: "flex flex-col gap-8",
34
- children: [
35
- /*#__PURE__*/ jsx(Skeleton, {
36
- width: "100%",
37
- height: "40px",
38
- rounded: 8
39
- }),
40
- /*#__PURE__*/ jsx(Skeleton, {
41
- width: "180px",
42
- height: "16px",
43
- rounded: 4
44
- })
45
- ]
46
- })
47
- ]
48
- });
49
- $[1] = t1;
50
- } else t1 = $[1];
51
- let t2;
52
- if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
53
- t2 = /*#__PURE__*/ jsxs("div", {
54
- "data-slot": "point-selector-skeleton",
55
- className: "flex flex-col gap-12",
56
- children: [
57
- t1,
58
- /*#__PURE__*/ jsx("div", {
59
- className: "flex items-center justify-center py-8",
60
- children: /*#__PURE__*/ jsx(Text, {
61
- size: "sm",
62
- color: "secondary",
63
- children: "Loading SDK..."
64
- })
65
- })
66
- ]
67
- });
68
- $[2] = t2;
69
- } else t2 = $[2];
70
- return t2;
71
- };
72
- PointSelectorSkeleton.displayName = "PointSelectorSkeleton";
73
- export { PointSelectorSkeleton };
@@ -1,14 +0,0 @@
1
- import type { FC } from 'react';
2
- import { type RuleContext, type SampleValue, type Segment } from '@wallarm-org/rules-lib';
3
- export interface SampleRequestProps {
4
- segments: readonly Segment[];
5
- context: RuleContext;
6
- /** What the condition looks for; absent: the value as a placeholder. */
7
- value?: SampleValue;
8
- }
9
- /**
10
- * Where the value sits in a message, drawn as a sample request (or response):
11
- * only what the point names is written out, the rest are ‹placeholders›, and
12
- * the value the condition looks at is highlighted. Styled as a DS code snippet.
13
- */
14
- export declare const SampleRequest: FC<SampleRequestProps>;
@@ -1,116 +0,0 @@
1
- import { jsx, jsxs } from "react/jsx-runtime";
2
- import { c } from "react/compiler-runtime";
3
- import { sampleMessage } from "@wallarm-org/rules-lib";
4
- import { useTestId } from "../../../utils/testId.js";
5
- const ROLE_CLASS = {
6
- "": "",
7
- ph: "italic text-syntax-comment",
8
- str: "text-syntax-string",
9
- key: "text-syntax-property",
10
- fn: "text-syntax-function",
11
- hname: "text-syntax-attr-name"
12
- };
13
- const tokenClass = (t)=>2 === t.highlight ? "rounded-4 bg-syntax-highlight-brand-highlight px-2 text-syntax-highlight-brand-code" : ROLE_CLASS[t.role];
14
- const SampleRequest = (t0)=>{
15
- const $ = c(23);
16
- const { segments, context, value } = t0;
17
- const testId = useTestId("sample");
18
- let t1;
19
- let t2;
20
- let t3;
21
- let t4;
22
- let t5;
23
- let t6;
24
- let t7;
25
- if ($[0] !== context || $[1] !== segments || $[2] !== testId || $[3] !== value) {
26
- const lines = sampleMessage(segments, context, value);
27
- const title = "http_response" === context ? "Sample response" : "Sample request";
28
- t3 = "sample-request";
29
- t4 = testId;
30
- t5 = "code-snippet-bg m-0 flex flex-col overflow-hidden rounded-8 font-mono text-syntax-no-syntax";
31
- t6 = title;
32
- if ($[11] !== title) {
33
- t7 = /*#__PURE__*/ jsx("figcaption", {
34
- className: "border-b border-border-primary-light px-12 py-6 font-sans text-text-secondary text-xs",
35
- children: title
36
- });
37
- $[11] = title;
38
- $[12] = t7;
39
- } else t7 = $[12];
40
- t1 = "overflow-x-auto py-8 text-xs";
41
- t2 = lines.map(_temp2);
42
- $[0] = context;
43
- $[1] = segments;
44
- $[2] = testId;
45
- $[3] = value;
46
- $[4] = t1;
47
- $[5] = t2;
48
- $[6] = t3;
49
- $[7] = t4;
50
- $[8] = t5;
51
- $[9] = t6;
52
- $[10] = t7;
53
- } else {
54
- t1 = $[4];
55
- t2 = $[5];
56
- t3 = $[6];
57
- t4 = $[7];
58
- t5 = $[8];
59
- t6 = $[9];
60
- t7 = $[10];
61
- }
62
- let t8;
63
- if ($[13] !== t1 || $[14] !== t2) {
64
- t8 = /*#__PURE__*/ jsx("div", {
65
- className: t1,
66
- children: t2
67
- });
68
- $[13] = t1;
69
- $[14] = t2;
70
- $[15] = t8;
71
- } else t8 = $[15];
72
- let t9;
73
- if ($[16] !== t3 || $[17] !== t4 || $[18] !== t5 || $[19] !== t6 || $[20] !== t7 || $[21] !== t8) {
74
- t9 = /*#__PURE__*/ jsxs("figure", {
75
- "data-slot": t3,
76
- "data-testid": t4,
77
- className: t5,
78
- "aria-label": t6,
79
- children: [
80
- t7,
81
- t8
82
- ]
83
- });
84
- $[16] = t3;
85
- $[17] = t4;
86
- $[18] = t5;
87
- $[19] = t6;
88
- $[20] = t7;
89
- $[21] = t8;
90
- $[22] = t9;
91
- } else t9 = $[22];
92
- return t9;
93
- };
94
- SampleRequest.displayName = "SampleRequest";
95
- function _temp(t, k) {
96
- return /*#__PURE__*/ jsx("span", {
97
- className: tokenClass(t),
98
- children: t.text
99
- }, k);
100
- }
101
- function _temp2(line, i) {
102
- return /*#__PURE__*/ jsxs("div", {
103
- className: "flex min-h-20 items-center",
104
- children: [
105
- /*#__PURE__*/ jsx("span", {
106
- className: "w-32 shrink-0 select-none pr-12 text-right text-syntax-comment",
107
- children: i + 1
108
- }),
109
- /*#__PURE__*/ jsx("span", {
110
- className: "whitespace-pre pr-12",
111
- children: line.map(_temp)
112
- })
113
- ]
114
- }, i);
115
- }
116
- export { SampleRequest };
@@ -1,40 +0,0 @@
1
- import type { FC, ReactNode, RefObject } from 'react';
2
- import type { MenuFooter, MenuRow } from './types.js';
3
- interface Props {
4
- open: boolean;
5
- /** The menu's id. The anchor names it in `aria-controls`: a modal drawer's
6
- * focus trap lets focus into the portaled menu only when an expanded
7
- * element inside the drawer controls it. */
8
- contentId: string;
9
- /** The element the menu hangs under (the query bar). */
10
- anchorRef: RefObject<HTMLElement | null>;
11
- /** The input the user types in; keeps keyboard focus while the menu is open. */
12
- focusRef: RefObject<HTMLInputElement | null>;
13
- title: string;
14
- rows: MenuRow[];
15
- highlightedId: string | null;
16
- status?: string;
17
- footer: MenuFooter;
18
- escLabel: string;
19
- /** Content above the rows: the name input of a name step. */
20
- header?: ReactNode;
21
- applyLabel?: string;
22
- /** Nothing is ticked yet: the apply button is shown but inactive. */
23
- applyDisabled?: boolean;
24
- onApply?: () => void;
25
- onHighlight: (id: string) => void;
26
- onChoose: (id: string) => void;
27
- onClose: () => void;
28
- /** Show examples when no segments chosen */
29
- showExamples?: boolean;
30
- /** Called when example is clicked */
31
- onSelectExample?: (point: string) => void;
32
- }
33
- /**
34
- * A design-system dropdown menu anchored to the query bar, like the
35
- * FilterInput menu: a question, rows with a muted second line, the option's
36
- * number on the right, ticks for a multi-select, keyboard hints in the footer.
37
- * Keyboard focus stays in `focusRef`; the highlight is controlled.
38
- */
39
- export declare const StepMenu: FC<Props>;
40
- export {};