@stackable-labs/sdk-extension-contracts 1.101.0 → 1.102.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +45 -4
- package/dist/index.js +51 -24
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -51,12 +51,14 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
51
51
|
readonly icon: "square";
|
|
52
52
|
readonly category: "layout";
|
|
53
53
|
readonly attributes: readonly ["className"];
|
|
54
|
+
readonly childOnly: true;
|
|
54
55
|
};
|
|
55
56
|
readonly 'ui-card-header': {
|
|
56
57
|
readonly description: "Header area within a Card";
|
|
57
58
|
readonly icon: "square";
|
|
58
59
|
readonly category: "layout";
|
|
59
60
|
readonly attributes: readonly ["className"];
|
|
61
|
+
readonly childOnly: true;
|
|
60
62
|
};
|
|
61
63
|
readonly 'ui-button': {
|
|
62
64
|
readonly description: "Interactive button with variant and size options";
|
|
@@ -102,12 +104,14 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
102
104
|
readonly icon: "text-cursor-input";
|
|
103
105
|
readonly category: "input";
|
|
104
106
|
readonly attributes: readonly ["type", "placeholder", "value", "onChange", "disabled", "className", "id"];
|
|
107
|
+
readonly selfClosing: true;
|
|
105
108
|
};
|
|
106
109
|
readonly 'ui-textarea': {
|
|
107
110
|
readonly description: "Multi-line text input field";
|
|
108
111
|
readonly icon: "text";
|
|
109
112
|
readonly category: "input";
|
|
110
113
|
readonly attributes: readonly ["placeholder", "value", "onChange", "disabled", "rows", "className", "id"];
|
|
114
|
+
readonly selfClosing: true;
|
|
111
115
|
};
|
|
112
116
|
readonly 'ui-select': {
|
|
113
117
|
readonly description: "Dropdown select with options";
|
|
@@ -121,12 +125,14 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
121
125
|
readonly icon: "chevrons-up-down";
|
|
122
126
|
readonly category: "input";
|
|
123
127
|
readonly attributes: readonly ["value", "disabled", "className"];
|
|
128
|
+
readonly childOnly: true;
|
|
124
129
|
};
|
|
125
130
|
readonly 'ui-checkbox': {
|
|
126
131
|
readonly description: "Checkbox toggle for boolean values";
|
|
127
132
|
readonly icon: "square-check";
|
|
128
133
|
readonly category: "input";
|
|
129
134
|
readonly attributes: readonly ["checked", "onChange", "disabled", "className", "id"];
|
|
135
|
+
readonly selfClosing: true;
|
|
130
136
|
};
|
|
131
137
|
readonly 'ui-switch': {
|
|
132
138
|
readonly description: "Toggle switch for on/off states";
|
|
@@ -136,6 +142,7 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
136
142
|
readonly attributeValues: {
|
|
137
143
|
readonly size: readonly ["sm", "default"];
|
|
138
144
|
};
|
|
145
|
+
readonly selfClosing: true;
|
|
139
146
|
};
|
|
140
147
|
readonly 'ui-label': {
|
|
141
148
|
readonly description: "Form label associated with an input";
|
|
@@ -155,6 +162,7 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
155
162
|
readonly icon: "circle-dot";
|
|
156
163
|
readonly category: "input";
|
|
157
164
|
readonly attributes: readonly ["value", "disabled", "className", "id"];
|
|
165
|
+
readonly childOnly: true;
|
|
158
166
|
};
|
|
159
167
|
readonly 'ui-stack': {
|
|
160
168
|
readonly description: "Vertical or horizontal flex container with gap";
|
|
@@ -180,6 +188,7 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
180
188
|
readonly icon: "minus";
|
|
181
189
|
readonly category: "layout";
|
|
182
190
|
readonly attributes: readonly ["className"];
|
|
191
|
+
readonly selfClosing: true;
|
|
183
192
|
};
|
|
184
193
|
readonly 'ui-tabs': {
|
|
185
194
|
readonly description: "Tabbed content container";
|
|
@@ -194,18 +203,21 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
194
203
|
readonly category: "navigation";
|
|
195
204
|
readonly attributes: readonly ["className"];
|
|
196
205
|
readonly children: readonly ["ui-tabs-trigger"];
|
|
206
|
+
readonly childOnly: true;
|
|
197
207
|
};
|
|
198
208
|
readonly 'ui-tabs-trigger': {
|
|
199
209
|
readonly description: "Clickable tab label within TabsList";
|
|
200
210
|
readonly icon: "panel-top";
|
|
201
211
|
readonly category: "navigation";
|
|
202
212
|
readonly attributes: readonly ["value", "className"];
|
|
213
|
+
readonly childOnly: true;
|
|
203
214
|
};
|
|
204
215
|
readonly 'ui-tabs-content': {
|
|
205
216
|
readonly description: "Content panel shown when its tab is active";
|
|
206
217
|
readonly icon: "panel-top";
|
|
207
218
|
readonly category: "navigation";
|
|
208
219
|
readonly attributes: readonly ["value", "className"];
|
|
220
|
+
readonly childOnly: true;
|
|
209
221
|
};
|
|
210
222
|
readonly 'ui-scroll-area': {
|
|
211
223
|
readonly description: "Scrollable content container";
|
|
@@ -218,6 +230,7 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
218
230
|
readonly icon: "circle-user";
|
|
219
231
|
readonly category: "composite";
|
|
220
232
|
readonly attributes: readonly ["src", "alt", "className"];
|
|
233
|
+
readonly selfClosing: true;
|
|
221
234
|
};
|
|
222
235
|
readonly 'ui-icon': {
|
|
223
236
|
readonly description: "Icon from the allowed icon set";
|
|
@@ -227,6 +240,7 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
227
240
|
readonly attributeValues: {
|
|
228
241
|
readonly size: readonly ["sm", "md", "lg"];
|
|
229
242
|
};
|
|
243
|
+
readonly selfClosing: true;
|
|
230
244
|
};
|
|
231
245
|
readonly 'ui-qr-code': {
|
|
232
246
|
readonly description: "QR code rendered from a string payload";
|
|
@@ -234,10 +248,11 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
234
248
|
readonly category: "composite";
|
|
235
249
|
readonly attributes: readonly ["value", "size", "variant", "level", "alt", "className"];
|
|
236
250
|
readonly attributeValues: {
|
|
237
|
-
readonly size: readonly ["
|
|
251
|
+
readonly size: readonly ["md", "sm", "lg"];
|
|
238
252
|
readonly variant: readonly ["default", "inverted"];
|
|
239
|
-
readonly level: readonly ["
|
|
253
|
+
readonly level: readonly ["medium", "low", "quartile", "high"];
|
|
240
254
|
};
|
|
255
|
+
readonly selfClosing: true;
|
|
241
256
|
};
|
|
242
257
|
readonly 'ui-link': {
|
|
243
258
|
readonly description: "Hyperlink element";
|
|
@@ -257,12 +272,14 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
257
272
|
readonly icon: "menu";
|
|
258
273
|
readonly category: "navigation";
|
|
259
274
|
readonly attributes: readonly ["icon", "label", "description", "onClick", "className"];
|
|
275
|
+
readonly childOnly: true;
|
|
260
276
|
};
|
|
261
277
|
readonly 'ui-skeleton': {
|
|
262
278
|
readonly description: "Loading placeholder with shimmer effect";
|
|
263
279
|
readonly icon: "loader";
|
|
264
280
|
readonly category: "feedback";
|
|
265
281
|
readonly attributes: readonly ["width", "height", "className"];
|
|
282
|
+
readonly selfClosing: true;
|
|
266
283
|
};
|
|
267
284
|
readonly 'ui-tooltip': {
|
|
268
285
|
readonly description: "Hover tooltip with text content";
|
|
@@ -275,6 +292,7 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
275
292
|
readonly icon: "bar-chart";
|
|
276
293
|
readonly category: "feedback";
|
|
277
294
|
readonly attributes: readonly ["value", "className"];
|
|
295
|
+
readonly selfClosing: true;
|
|
278
296
|
};
|
|
279
297
|
readonly 'ui-alert': {
|
|
280
298
|
readonly description: "Alert banner with icon and optional title";
|
|
@@ -297,12 +315,14 @@ declare const UI_TAG_DEFINITIONS: {
|
|
|
297
315
|
readonly icon: "chevrons-down-up";
|
|
298
316
|
readonly category: "composite";
|
|
299
317
|
readonly attributes: readonly ["className"];
|
|
318
|
+
readonly childOnly: true;
|
|
300
319
|
};
|
|
301
320
|
readonly 'ui-collapsible-content': {
|
|
302
321
|
readonly description: "Content revealed when Collapsible is open";
|
|
303
322
|
readonly icon: "chevrons-down-up";
|
|
304
323
|
readonly category: "composite";
|
|
305
324
|
readonly attributes: readonly ["className"];
|
|
325
|
+
readonly childOnly: true;
|
|
306
326
|
};
|
|
307
327
|
};
|
|
308
328
|
/** Union type of all valid UI tag names */
|
|
@@ -331,14 +351,35 @@ declare const UI_TAG_CHILDREN: Partial<Record<UITag, readonly UITag[]>>;
|
|
|
331
351
|
* `<ui.X {...args}/>` template and a source-as-render template.
|
|
332
352
|
*/
|
|
333
353
|
declare const UI_TAG_COMPOUND: Partial<Record<UITag, readonly UITag[]>>;
|
|
354
|
+
/**
|
|
355
|
+
* Tags that render with no children (self-closing in JSX).
|
|
356
|
+
* Driven by the `selfClosing` flag in UI_TAG_DEFINITIONS.
|
|
357
|
+
* Used by codegen to choose between `<ui.X {...args} />` and
|
|
358
|
+
* `<ui.X {...args}>{children}</ui.X>` templates.
|
|
359
|
+
*/
|
|
360
|
+
declare const UI_TAG_SELF_CLOSING: ReadonlySet<UITag>;
|
|
361
|
+
/**
|
|
362
|
+
* Tags that exist only as structural children of compound parents.
|
|
363
|
+
* Driven by the `childOnly` flag in UI_TAG_DEFINITIONS.
|
|
364
|
+
* Used by codegen to skip standalone stories/palette entries for these tags.
|
|
365
|
+
*/
|
|
366
|
+
declare const UI_TAG_CHILD_ONLY: ReadonlySet<UITag>;
|
|
334
367
|
/** Category for each UI tag — used for grouping in stories and palettes. */
|
|
335
368
|
declare const UI_TAG_CATEGORIES: Record<UITag, UITagCategory>;
|
|
336
369
|
declare const tagToComponentName: (tag: UITag) => string;
|
|
337
370
|
/**
|
|
338
371
|
* Supported icon names (subset of lucide-react).
|
|
339
372
|
* Extensions reference icons by name; host renders the actual icon component.
|
|
373
|
+
*
|
|
374
|
+
* ICON REGISTRY — manual update spots (keep in lockstep):
|
|
375
|
+
* 1. packages/sdk/extension/contracts/src/components.ts → ALLOWED_ICONS (this list)
|
|
376
|
+
* 2. packages/embeddables/src/lib/hostComponents.tsx → ICON_MAP (+ lucide-react import)
|
|
377
|
+
* Auto-generated from ALLOWED_ICONS (no edits needed):
|
|
378
|
+
* • SKILL.md icon catalogs (ai-docs generators/components.ts → generate-skills.ts)
|
|
379
|
+
* • storybook stories, site-developers content, dist/index.d.ts, studio bundle
|
|
380
|
+
* Grep `ICON REGISTRY` to find every spot.
|
|
340
381
|
*/
|
|
341
|
-
declare const ALLOWED_ICONS: readonly ["arrow-left", "calendar", "check-circle-2", "chevron-left", "chevron-right", "clock", "credit-card", "external-link", "help-circle", "info", "loader-2", "mail", "map-pin", "message-circle", "message-square", "package", "phone", "search", "shopping-bag", "sparkles", "truck", "user", "x-circle", "alert-circle", "book-open", "qr-code"];
|
|
382
|
+
declare const ALLOWED_ICONS: readonly ["arrow-left", "calendar", "check-circle-2", "chevron-left", "chevron-right", "clock", "credit-card", "external-link", "help-circle", "info", "loader-2", "mail", "map-pin", "message-circle", "message-square", "package", "phone", "search", "shopping-bag", "sparkles", "truck", "user", "x-circle", "alert-circle", "book-open", "qr-code", "image-off"];
|
|
342
383
|
type AllowedIconName = (typeof ALLOWED_ICONS)[number];
|
|
343
384
|
|
|
344
385
|
/**
|
|
@@ -1007,4 +1048,4 @@ interface Order {
|
|
|
1007
1048
|
display_status?: OrderStatus;
|
|
1008
1049
|
}
|
|
1009
1050
|
|
|
1010
|
-
export { ACTIVITY_EVENT, ALLOWED_ICONS, type ActionInvokePayload, type ActionPayloadMap, type ActivityEvent, type ActivityEventHandler, type ActivityEventType, type Address, type AllowedIconName, type ApiError, type ApiRequest, type ApiResponse, CAPABILITY_PERMISSION_MAP, type Capability, type CapabilityCall, type CapabilityRequest, type CapabilityResponse, type CapabilityType, type ContextData, type ConversationField, type ConversationTags, type Customer, type DataField, type DataFieldType, type EncryptedPayload, type EventDomain, type EventType, type ExtendIdentityHandler, type ExtendIdentityRequest, type ExtendIdentityResponse, type ExtensionManifest, type ExtensionRegistryEntry, type FetchRequest, type FetchRequestInit, type FetchResponse, type HostToSandboxMessage, IDENTITY_EVENT, INVOKE_ACTION, type IdentityBaseClaims, type IdentityEvent, type IdentityEventType, type IdentityState, type InstanceConfig, type InstanceOption, type InvokeAction, type MarketplaceExtension, type MessagingContext, type MessagingEvent, type MessagingEventHandler, type MessagingEventType, type MessagingPostbackEvent, type MessengerCommand, type NamedEntity, type NewConversationPayload, type Order, type OrderAction, type OrderItem, type OrderStatus, type OrderStatuses, PERMISSIONS, type Permission, type Price, RESERVED_CONTEXT_KEYS, type ReservedContextKey, SURFACE_TARGET, type SandboxToHostMessage, type Shipment, type SurfaceContext, type SurfaceLifecycleMessage, type SurfaceTarget, type Target, type Theme, type ToastPayload, type UITag, type UITagCategory, UI_TAGS, UI_TAG_ATTRIBUTES, UI_TAG_ATTRIBUTE_VALUES, UI_TAG_CATEGORIES, UI_TAG_CHILDREN, UI_TAG_COMPOUND, UI_TAG_DEFINITIONS, type UserIdentity, type WellKnownActivityEvent, type WidgetAction, tagToComponentName };
|
|
1051
|
+
export { ACTIVITY_EVENT, ALLOWED_ICONS, type ActionInvokePayload, type ActionPayloadMap, type ActivityEvent, type ActivityEventHandler, type ActivityEventType, type Address, type AllowedIconName, type ApiError, type ApiRequest, type ApiResponse, CAPABILITY_PERMISSION_MAP, type Capability, type CapabilityCall, type CapabilityRequest, type CapabilityResponse, type CapabilityType, type ContextData, type ConversationField, type ConversationTags, type Customer, type DataField, type DataFieldType, type EncryptedPayload, type EventDomain, type EventType, type ExtendIdentityHandler, type ExtendIdentityRequest, type ExtendIdentityResponse, type ExtensionManifest, type ExtensionRegistryEntry, type FetchRequest, type FetchRequestInit, type FetchResponse, type HostToSandboxMessage, IDENTITY_EVENT, INVOKE_ACTION, type IdentityBaseClaims, type IdentityEvent, type IdentityEventType, type IdentityState, type InstanceConfig, type InstanceOption, type InvokeAction, type MarketplaceExtension, type MessagingContext, type MessagingEvent, type MessagingEventHandler, type MessagingEventType, type MessagingPostbackEvent, type MessengerCommand, type NamedEntity, type NewConversationPayload, type Order, type OrderAction, type OrderItem, type OrderStatus, type OrderStatuses, PERMISSIONS, type Permission, type Price, RESERVED_CONTEXT_KEYS, type ReservedContextKey, SURFACE_TARGET, type SandboxToHostMessage, type Shipment, type SurfaceContext, type SurfaceLifecycleMessage, type SurfaceTarget, type Target, type Theme, type ToastPayload, type UITag, type UITagCategory, UI_TAGS, UI_TAG_ATTRIBUTES, UI_TAG_ATTRIBUTE_VALUES, UI_TAG_CATEGORIES, UI_TAG_CHILDREN, UI_TAG_CHILD_ONLY, UI_TAG_COMPOUND, UI_TAG_DEFINITIONS, UI_TAG_SELF_CLOSING, type UserIdentity, type WellKnownActivityEvent, type WidgetAction, tagToComponentName };
|
package/dist/index.js
CHANGED
|
@@ -36,13 +36,15 @@ var UI_TAG_DEFINITIONS = {
|
|
|
36
36
|
description: "Content area within a Card",
|
|
37
37
|
icon: "square",
|
|
38
38
|
category: "layout",
|
|
39
|
-
attributes: ["className"]
|
|
39
|
+
attributes: ["className"],
|
|
40
|
+
childOnly: true
|
|
40
41
|
},
|
|
41
42
|
"ui-card-header": {
|
|
42
43
|
description: "Header area within a Card",
|
|
43
44
|
icon: "square",
|
|
44
45
|
category: "layout",
|
|
45
|
-
attributes: ["className"]
|
|
46
|
+
attributes: ["className"],
|
|
47
|
+
childOnly: true
|
|
46
48
|
},
|
|
47
49
|
"ui-button": {
|
|
48
50
|
description: "Interactive button with variant and size options",
|
|
@@ -87,13 +89,15 @@ var UI_TAG_DEFINITIONS = {
|
|
|
87
89
|
description: "Single-line text input field",
|
|
88
90
|
icon: "text-cursor-input",
|
|
89
91
|
category: "input",
|
|
90
|
-
attributes: ["type", "placeholder", "value", "onChange", "disabled", "className", "id"]
|
|
92
|
+
attributes: ["type", "placeholder", "value", "onChange", "disabled", "className", "id"],
|
|
93
|
+
selfClosing: true
|
|
91
94
|
},
|
|
92
95
|
"ui-textarea": {
|
|
93
96
|
description: "Multi-line text input field",
|
|
94
97
|
icon: "text",
|
|
95
98
|
category: "input",
|
|
96
|
-
attributes: ["placeholder", "value", "onChange", "disabled", "rows", "className", "id"]
|
|
99
|
+
attributes: ["placeholder", "value", "onChange", "disabled", "rows", "className", "id"],
|
|
100
|
+
selfClosing: true
|
|
97
101
|
},
|
|
98
102
|
"ui-select": {
|
|
99
103
|
description: "Dropdown select with options",
|
|
@@ -106,13 +110,15 @@ var UI_TAG_DEFINITIONS = {
|
|
|
106
110
|
description: "Option within a Select dropdown",
|
|
107
111
|
icon: "chevrons-up-down",
|
|
108
112
|
category: "input",
|
|
109
|
-
attributes: ["value", "disabled", "className"]
|
|
113
|
+
attributes: ["value", "disabled", "className"],
|
|
114
|
+
childOnly: true
|
|
110
115
|
},
|
|
111
116
|
"ui-checkbox": {
|
|
112
117
|
description: "Checkbox toggle for boolean values",
|
|
113
118
|
icon: "square-check",
|
|
114
119
|
category: "input",
|
|
115
|
-
attributes: ["checked", "onChange", "disabled", "className", "id"]
|
|
120
|
+
attributes: ["checked", "onChange", "disabled", "className", "id"],
|
|
121
|
+
selfClosing: true
|
|
116
122
|
},
|
|
117
123
|
"ui-switch": {
|
|
118
124
|
description: "Toggle switch for on/off states",
|
|
@@ -121,7 +127,8 @@ var UI_TAG_DEFINITIONS = {
|
|
|
121
127
|
attributes: ["checked", "onChange", "disabled", "size", "className", "id"],
|
|
122
128
|
attributeValues: {
|
|
123
129
|
size: ["sm", "default"]
|
|
124
|
-
}
|
|
130
|
+
},
|
|
131
|
+
selfClosing: true
|
|
125
132
|
},
|
|
126
133
|
"ui-label": {
|
|
127
134
|
description: "Form label associated with an input",
|
|
@@ -140,7 +147,8 @@ var UI_TAG_DEFINITIONS = {
|
|
|
140
147
|
description: "Individual radio button within a RadioGroup",
|
|
141
148
|
icon: "circle-dot",
|
|
142
149
|
category: "input",
|
|
143
|
-
attributes: ["value", "disabled", "className", "id"]
|
|
150
|
+
attributes: ["value", "disabled", "className", "id"],
|
|
151
|
+
childOnly: true
|
|
144
152
|
},
|
|
145
153
|
"ui-stack": {
|
|
146
154
|
// TODO: explore adding `align` attribute (e.g., 'start', 'center', 'end') — needs host implementation in hostComponents.tsx
|
|
@@ -167,7 +175,8 @@ var UI_TAG_DEFINITIONS = {
|
|
|
167
175
|
description: "Horizontal divider line",
|
|
168
176
|
icon: "minus",
|
|
169
177
|
category: "layout",
|
|
170
|
-
attributes: ["className"]
|
|
178
|
+
attributes: ["className"],
|
|
179
|
+
selfClosing: true
|
|
171
180
|
},
|
|
172
181
|
"ui-tabs": {
|
|
173
182
|
description: "Tabbed content container",
|
|
@@ -181,19 +190,22 @@ var UI_TAG_DEFINITIONS = {
|
|
|
181
190
|
icon: "panel-top",
|
|
182
191
|
category: "navigation",
|
|
183
192
|
attributes: ["className"],
|
|
184
|
-
children: ["ui-tabs-trigger"]
|
|
193
|
+
children: ["ui-tabs-trigger"],
|
|
194
|
+
childOnly: true
|
|
185
195
|
},
|
|
186
196
|
"ui-tabs-trigger": {
|
|
187
197
|
description: "Clickable tab label within TabsList",
|
|
188
198
|
icon: "panel-top",
|
|
189
199
|
category: "navigation",
|
|
190
|
-
attributes: ["value", "className"]
|
|
200
|
+
attributes: ["value", "className"],
|
|
201
|
+
childOnly: true
|
|
191
202
|
},
|
|
192
203
|
"ui-tabs-content": {
|
|
193
204
|
description: "Content panel shown when its tab is active",
|
|
194
205
|
icon: "panel-top",
|
|
195
206
|
category: "navigation",
|
|
196
|
-
attributes: ["value", "className"]
|
|
207
|
+
attributes: ["value", "className"],
|
|
208
|
+
childOnly: true
|
|
197
209
|
},
|
|
198
210
|
"ui-scroll-area": {
|
|
199
211
|
description: "Scrollable content container",
|
|
@@ -205,7 +217,8 @@ var UI_TAG_DEFINITIONS = {
|
|
|
205
217
|
description: "User avatar with image and initials fallback",
|
|
206
218
|
icon: "circle-user",
|
|
207
219
|
category: "composite",
|
|
208
|
-
attributes: ["src", "alt", "className"]
|
|
220
|
+
attributes: ["src", "alt", "className"],
|
|
221
|
+
selfClosing: true
|
|
209
222
|
},
|
|
210
223
|
"ui-icon": {
|
|
211
224
|
description: "Icon from the allowed icon set",
|
|
@@ -214,7 +227,8 @@ var UI_TAG_DEFINITIONS = {
|
|
|
214
227
|
attributes: ["name", "size", "className"],
|
|
215
228
|
attributeValues: {
|
|
216
229
|
size: ["sm", "md", "lg"]
|
|
217
|
-
}
|
|
230
|
+
},
|
|
231
|
+
selfClosing: true
|
|
218
232
|
},
|
|
219
233
|
"ui-qr-code": {
|
|
220
234
|
description: "QR code rendered from a string payload",
|
|
@@ -222,10 +236,11 @@ var UI_TAG_DEFINITIONS = {
|
|
|
222
236
|
category: "composite",
|
|
223
237
|
attributes: ["value", "size", "variant", "level", "alt", "className"],
|
|
224
238
|
attributeValues: {
|
|
225
|
-
size: ["
|
|
239
|
+
size: ["md", "sm", "lg"],
|
|
226
240
|
variant: ["default", "inverted"],
|
|
227
|
-
level: ["
|
|
228
|
-
}
|
|
241
|
+
level: ["medium", "low", "quartile", "high"]
|
|
242
|
+
},
|
|
243
|
+
selfClosing: true
|
|
229
244
|
},
|
|
230
245
|
"ui-link": {
|
|
231
246
|
description: "Hyperlink element",
|
|
@@ -244,13 +259,15 @@ var UI_TAG_DEFINITIONS = {
|
|
|
244
259
|
description: "Clickable item within a Menu",
|
|
245
260
|
icon: "menu",
|
|
246
261
|
category: "navigation",
|
|
247
|
-
attributes: ["icon", "label", "description", "onClick", "className"]
|
|
262
|
+
attributes: ["icon", "label", "description", "onClick", "className"],
|
|
263
|
+
childOnly: true
|
|
248
264
|
},
|
|
249
265
|
"ui-skeleton": {
|
|
250
266
|
description: "Loading placeholder with shimmer effect",
|
|
251
267
|
icon: "loader",
|
|
252
268
|
category: "feedback",
|
|
253
|
-
attributes: ["width", "height", "className"]
|
|
269
|
+
attributes: ["width", "height", "className"],
|
|
270
|
+
selfClosing: true
|
|
254
271
|
},
|
|
255
272
|
"ui-tooltip": {
|
|
256
273
|
description: "Hover tooltip with text content",
|
|
@@ -262,7 +279,8 @@ var UI_TAG_DEFINITIONS = {
|
|
|
262
279
|
description: "Progress bar with percentage value",
|
|
263
280
|
icon: "bar-chart",
|
|
264
281
|
category: "feedback",
|
|
265
|
-
attributes: ["value", "className"]
|
|
282
|
+
attributes: ["value", "className"],
|
|
283
|
+
selfClosing: true
|
|
266
284
|
},
|
|
267
285
|
"ui-alert": {
|
|
268
286
|
description: "Alert banner with icon and optional title",
|
|
@@ -284,13 +302,15 @@ var UI_TAG_DEFINITIONS = {
|
|
|
284
302
|
description: "Clickable trigger to toggle Collapsible",
|
|
285
303
|
icon: "chevrons-down-up",
|
|
286
304
|
category: "composite",
|
|
287
|
-
attributes: ["className"]
|
|
305
|
+
attributes: ["className"],
|
|
306
|
+
childOnly: true
|
|
288
307
|
},
|
|
289
308
|
"ui-collapsible-content": {
|
|
290
309
|
description: "Content revealed when Collapsible is open",
|
|
291
310
|
icon: "chevrons-down-up",
|
|
292
311
|
category: "composite",
|
|
293
|
-
attributes: ["className"]
|
|
312
|
+
attributes: ["className"],
|
|
313
|
+
childOnly: true
|
|
294
314
|
}
|
|
295
315
|
};
|
|
296
316
|
var defs = UI_TAG_DEFINITIONS;
|
|
@@ -308,6 +328,12 @@ var UI_TAG_COMPOUND = {
|
|
|
308
328
|
...UI_TAG_CHILDREN,
|
|
309
329
|
"ui-tooltip": ["ui-button"]
|
|
310
330
|
};
|
|
331
|
+
var UI_TAG_SELF_CLOSING = new Set(
|
|
332
|
+
UI_TAGS.filter((tag) => defs[tag].selfClosing === true)
|
|
333
|
+
);
|
|
334
|
+
var UI_TAG_CHILD_ONLY = new Set(
|
|
335
|
+
UI_TAGS.filter((tag) => defs[tag].childOnly === true)
|
|
336
|
+
);
|
|
311
337
|
var UI_TAG_CATEGORIES = Object.fromEntries(
|
|
312
338
|
UI_TAGS.map((tag) => [tag, defs[tag].category])
|
|
313
339
|
);
|
|
@@ -341,7 +367,8 @@ var ALLOWED_ICONS = [
|
|
|
341
367
|
"x-circle",
|
|
342
368
|
"alert-circle",
|
|
343
369
|
"book-open",
|
|
344
|
-
"qr-code"
|
|
370
|
+
"qr-code",
|
|
371
|
+
"image-off"
|
|
345
372
|
];
|
|
346
373
|
|
|
347
374
|
// src/capabilities.ts
|
|
@@ -400,4 +427,4 @@ var SURFACE_TARGET = {
|
|
|
400
427
|
FOOTER_LINKS: "slot.footer-links"
|
|
401
428
|
};
|
|
402
429
|
|
|
403
|
-
export { ACTIVITY_EVENT, ALLOWED_ICONS, CAPABILITY_PERMISSION_MAP, EXTENSION_CATEGORY, EXTENSION_VISIBILITY, IDENTITY_EVENT, INVOKE_ACTION, PERMISSIONS, RESERVED_CONTEXT_KEYS, SURFACE_TARGET, UI_TAGS, UI_TAG_ATTRIBUTES, UI_TAG_ATTRIBUTE_VALUES, UI_TAG_CATEGORIES, UI_TAG_CHILDREN, UI_TAG_COMPOUND, UI_TAG_DEFINITIONS, asClerkOrgId, asClerkUserId, asISOTimestamp, tagToComponentName };
|
|
430
|
+
export { ACTIVITY_EVENT, ALLOWED_ICONS, CAPABILITY_PERMISSION_MAP, EXTENSION_CATEGORY, EXTENSION_VISIBILITY, IDENTITY_EVENT, INVOKE_ACTION, PERMISSIONS, RESERVED_CONTEXT_KEYS, SURFACE_TARGET, UI_TAGS, UI_TAG_ATTRIBUTES, UI_TAG_ATTRIBUTE_VALUES, UI_TAG_CATEGORIES, UI_TAG_CHILDREN, UI_TAG_CHILD_ONLY, UI_TAG_COMPOUND, UI_TAG_DEFINITIONS, UI_TAG_SELF_CLOSING, asClerkOrgId, asClerkUserId, asISOTimestamp, tagToComponentName };
|