@rippling/pebble-sdui-web 0.19.2 → 0.21.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/catalogs/custom-apps/catalog.d.ts +1 -1
- package/dist/catalogs/custom-apps/component-events.d.ts +2 -0
- package/dist/catalogs/custom-apps/component-props.d.ts +19 -3
- package/dist/catalogs/custom-apps/components.d.ts +5 -3
- package/dist/catalogs/custom-apps/function-params.d.ts +19 -0
- package/dist/catalogs/custom-apps/functions.d.ts +17 -1
- package/dist/catalogs/custom-apps/index.cjs +2 -2
- package/dist/catalogs/custom-apps/index.cjs.map +1 -1
- package/dist/catalogs/custom-apps/index.d.ts +5 -5
- package/dist/catalogs/custom-apps/index.js +408 -198
- package/dist/catalogs/custom-apps/index.js.map +1 -1
- package/dist/docs/typescript/web/catalogs/custom-apps/components.md +53 -4
- package/dist/docs/typescript/web/catalogs/custom-apps/computed-functions.md +90 -0
- package/dist/docs/typescript/web/catalogs/custom-apps/definitions.md +48 -0
- package/dist/docs/typescript/web/catalogs/custom-apps/readme.md +1 -1
- package/dist/docs/typescript/web/catalogs/custom-apps/types.md +2 -2
- package/package.json +1 -1
|
@@ -1310,7 +1310,7 @@ No additional properties.
|
|
|
1310
1310
|
|
|
1311
1311
|
A reorderable drag-and-drop list for dynamically rearranging items. Supports vertical and horizontal layouts; use when item order flexibility is crucial to the user experience.
|
|
1312
1312
|
|
|
1313
|
-
The list prop should be bound to state. When items are reordered or removed, the updated list array is written back to state. The update event fires after reorder; the remove event fires after an item is removed.
|
|
1313
|
+
The list prop should be bound to state. When items are reordered or removed, the updated list array is written back to state. The update event fires after reorder; the remove event fires after an item is removed. Chip mode is used when no slots.item template is provided: labelKey and tip apply only there. Custom item mode is opt-in through slots.item; the first item slot element is repeated once per row with $item, $index, and $bindItem support. Use DraggableListHandle to mark where dragging may start and DraggableListRemove to remove the current row. Every item must resolve to a unique stable id via idKey (default: id).
|
|
1314
1314
|
|
|
1315
1315
|
Catalog key: `DraggableList`
|
|
1316
1316
|
Builder: `DraggableList`
|
|
@@ -1324,18 +1324,67 @@ Events: `update`, `remove`, `dragStart`, `dragEnd`
|
|
|
1324
1324
|
|---|---:|---|---|
|
|
1325
1325
|
| `dragContainerMinHeight` | no | number | Minimum height of drag container in pixels. Default: 0 |
|
|
1326
1326
|
| `groupName` | no | string | List group identifier for dragging among multiple lists. Default: "group" |
|
|
1327
|
+
| `idKey` | no | string | Key name or nested path used to resolve the stable item identifier. Default: id |
|
|
1327
1328
|
| `isDragDisabled` | no | boolean | Disable drag functionality. Default: false |
|
|
1328
1329
|
| `isHorizontal` | no | boolean | Display the list horizontally. Default: false |
|
|
1329
1330
|
| `isRemovable` | no | boolean | Allow elements of the list to be removed. Default: false |
|
|
1330
|
-
| `labelKey` |
|
|
1331
|
+
| `labelKey` | no | string | Key name in each item used to generate the default chip label. Required in chip mode only |
|
|
1331
1332
|
| `limitDragToDragIcon` | no | boolean | Restrict dragging to only the drag icon. Only works when showDragIcon is true. Default: false |
|
|
1332
|
-
| `list` | yes | [DraggableListList](./types.md#draggablelistlist)[] | Array of draggable items. Each item must
|
|
1333
|
+
| `list` | yes | [DraggableListList](./types.md#draggablelistlist)[] | Array of draggable items. Each item must resolve to a unique stable identifier via idKey (default: id). Additional keys are allowed. |
|
|
1333
1334
|
| `showDragIcon` | no | boolean | Show drag icon for each item. Default: false |
|
|
1334
|
-
| `tip` | no | [DraggableListTip](./types.md#draggablelisttip) | Tooltip configuration for the default chip renderer |
|
|
1335
|
+
| `tip` | no | [DraggableListTip](./types.md#draggablelisttip) | Tooltip configuration for the default chip renderer in chip mode |
|
|
1335
1336
|
| `width` | no | string | Width of the list. Default: 100% |
|
|
1336
1337
|
|
|
1337
1338
|
No additional properties.
|
|
1338
1339
|
|
|
1340
|
+
## DraggableListHandle
|
|
1341
|
+
|
|
1342
|
+
A custom-row drag handle for SDUI DraggableList item templates.
|
|
1343
|
+
|
|
1344
|
+
Use inside DraggableList slots.item to mark where dragging may start in custom item mode. If the parent DraggableList has isDragDisabled=true, this helper renders nothing. Outside DraggableList it simply renders its children.
|
|
1345
|
+
|
|
1346
|
+
Catalog key: `DraggableListHandle`
|
|
1347
|
+
Builder: `DraggableListHandle`
|
|
1348
|
+
Props type: `DraggableListHandleProps`
|
|
1349
|
+
Accepts children: yes
|
|
1350
|
+
Events: _none_
|
|
1351
|
+
|
|
1352
|
+
### Props
|
|
1353
|
+
|
|
1354
|
+
_No fields._
|
|
1355
|
+
|
|
1356
|
+
No additional properties.
|
|
1357
|
+
|
|
1358
|
+
## DraggableListRemove
|
|
1359
|
+
|
|
1360
|
+
A row-scoped remove action for custom SDUI DraggableList item templates.
|
|
1361
|
+
|
|
1362
|
+
Use inside DraggableList slots.item to remove the current row in custom item mode. This helper intentionally exposes only a small Button-like prop surface for remove actions. The parent DraggableList still controls whether removal is allowed: if isRemovable=false, this helper renders nothing. Children take precedence over the label prop. Outside DraggableList it renders as a passive Button-like control.
|
|
1363
|
+
|
|
1364
|
+
Catalog key: `DraggableListRemove`
|
|
1365
|
+
Builder: `DraggableListRemove`
|
|
1366
|
+
Props type: `DraggableListRemoveProps`
|
|
1367
|
+
Accepts children: yes
|
|
1368
|
+
Events: _none_
|
|
1369
|
+
|
|
1370
|
+
### Props
|
|
1371
|
+
|
|
1372
|
+
| Name | Required | Type | Description |
|
|
1373
|
+
|---|---:|---|---|
|
|
1374
|
+
| `appearance` | no | [ButtonAppearance](./definitions.md#buttonappearance) | Visual style variant. Default: PRIMARY |
|
|
1375
|
+
| `aria-describedby` | no | string | ID of element that describes this button |
|
|
1376
|
+
| `aria-label` | no | string | Accessibility label for the button |
|
|
1377
|
+
| `aria-labelledby` | no | string | ID of element that labels this button |
|
|
1378
|
+
| `icon` | no | string | Icon to show in the remove action (for example "TRASH_OUTLINE") |
|
|
1379
|
+
| `id` | no | string | DOM id selector for the button element |
|
|
1380
|
+
| `isDisabled` | no | boolean | Disables the remove action. Default: false |
|
|
1381
|
+
| `label` | no | string | Button text content |
|
|
1382
|
+
| `size` | no | [ButtonSize](./definitions.md#buttonsize) | Button size. Default: M |
|
|
1383
|
+
| `tabIndex` | no | number | Tab order index for keyboard navigation |
|
|
1384
|
+
| `variant` | no | [ButtonVariant](./definitions.md#buttonvariant) | Button variant type. Default: NORMAL |
|
|
1385
|
+
|
|
1386
|
+
No additional properties.
|
|
1387
|
+
|
|
1339
1388
|
## Drawer
|
|
1340
1389
|
|
|
1341
1390
|
A sliding panel that appears from the edge of the screen, allowing users to access additional information or complete secondary tasks like forms without losing context of their primary workflow. Use instead of Modal when preserving the user's place on the page is important.
|
|
@@ -98,3 +98,93 @@ Params type: `ArraySomeParams`
|
|
|
98
98
|
| `where` | yes | unknown | |
|
|
99
99
|
|
|
100
100
|
No additional properties.
|
|
101
|
+
|
|
102
|
+
## formatDate
|
|
103
|
+
|
|
104
|
+
Formats a date using the viewer locale and timezone configured in the client.
|
|
105
|
+
|
|
106
|
+
Use inside any dynamically resolved component prop.
|
|
107
|
+
Example: { "$computed": "format_date", "args": { "value": { "$state": "/createdAt" } } }
|
|
108
|
+
Uses the viewer's configured locale, timezone, and date order.
|
|
109
|
+
Invalid date values return an empty string.
|
|
110
|
+
|
|
111
|
+
Catalog key: `format_date`
|
|
112
|
+
Helper: `formatDate`
|
|
113
|
+
Params type: `FormatDateParams`
|
|
114
|
+
|
|
115
|
+
### Params
|
|
116
|
+
|
|
117
|
+
| Name | Required | Type | Description |
|
|
118
|
+
|---|---:|---|---|
|
|
119
|
+
| `style` | no | [formatDateStyle](./definitions.md#formatdatestyle) | Date display style. Defaults to medium. |
|
|
120
|
+
| `timeZone` | no | string | Optional IANA timezone override, for example America/Los_Angeles. Defaults to the viewer timezone configured in the client. |
|
|
121
|
+
| `value` | yes | string | ISO date or date-time string to format. |
|
|
122
|
+
|
|
123
|
+
No additional properties.
|
|
124
|
+
|
|
125
|
+
## formatDateTime
|
|
126
|
+
|
|
127
|
+
Formats a date and time using the viewer locale and timezone configured in the client.
|
|
128
|
+
|
|
129
|
+
Use inside any dynamically resolved component prop.
|
|
130
|
+
Example: { "$computed": "format_date_time", "args": { "value": { "$state": "/createdAt" } } }
|
|
131
|
+
Uses the viewer's configured locale, timezone, date order, and 12/24-hour preference.
|
|
132
|
+
Invalid date values return an empty string.
|
|
133
|
+
|
|
134
|
+
Catalog key: `format_date_time`
|
|
135
|
+
Helper: `formatDateTime`
|
|
136
|
+
Params type: `FormatDateTimeParams`
|
|
137
|
+
|
|
138
|
+
### Params
|
|
139
|
+
|
|
140
|
+
| Name | Required | Type | Description |
|
|
141
|
+
|---|---:|---|---|
|
|
142
|
+
| `dateStyle` | no | [formatDateStyle](./definitions.md#formatdatestyle) | Date display style. Defaults to medium. |
|
|
143
|
+
| `timeStyle` | no | [formatDateTimeTimeStyle](./definitions.md#formatdatetimetimestyle) | Time display style. Defaults to short. |
|
|
144
|
+
| `timeZone` | no | string | Optional IANA timezone override, for example America/Los_Angeles. Defaults to the viewer timezone configured in the client. |
|
|
145
|
+
| `value` | yes | string | ISO date or date-time string to format. |
|
|
146
|
+
|
|
147
|
+
No additional properties.
|
|
148
|
+
|
|
149
|
+
## formatRelativeTime
|
|
150
|
+
|
|
151
|
+
Formats a date as relative time using the viewer locale configured in the client.
|
|
152
|
+
|
|
153
|
+
Use inside any dynamically resolved component prop.
|
|
154
|
+
Example: { "$computed": "format_relative_time", "args": { "value": { "$state": "/createdAt" } } }
|
|
155
|
+
Invalid date values return an empty string.
|
|
156
|
+
|
|
157
|
+
Catalog key: `format_relative_time`
|
|
158
|
+
Helper: `formatRelativeTime`
|
|
159
|
+
Params type: `FormatRelativeTimeParams`
|
|
160
|
+
|
|
161
|
+
### Params
|
|
162
|
+
|
|
163
|
+
| Name | Required | Type | Description |
|
|
164
|
+
|---|---:|---|---|
|
|
165
|
+
| `value` | yes | string | ISO date or date-time string to format. |
|
|
166
|
+
|
|
167
|
+
No additional properties.
|
|
168
|
+
|
|
169
|
+
## formatTime
|
|
170
|
+
|
|
171
|
+
Formats a time using the viewer locale and timezone configured in the client.
|
|
172
|
+
|
|
173
|
+
Use inside any dynamically resolved component prop.
|
|
174
|
+
Example: { "$computed": "format_time", "args": { "value": { "$state": "/createdAt" } } }
|
|
175
|
+
Uses the viewer's configured locale, timezone, and 12/24-hour preference.
|
|
176
|
+
Invalid date values return an empty string.
|
|
177
|
+
|
|
178
|
+
Catalog key: `format_time`
|
|
179
|
+
Helper: `formatTime`
|
|
180
|
+
Params type: `FormatTimeParams`
|
|
181
|
+
|
|
182
|
+
### Params
|
|
183
|
+
|
|
184
|
+
| Name | Required | Type | Description |
|
|
185
|
+
|---|---:|---|---|
|
|
186
|
+
| `style` | no | [formatDateTimeTimeStyle](./definitions.md#formatdatetimetimestyle) | Time display style. Defaults to short. |
|
|
187
|
+
| `timeZone` | no | string | Optional IANA timezone override, for example America/Los_Angeles. Defaults to the viewer timezone configured in the client. |
|
|
188
|
+
| `value` | yes | string | ISO date or date-time string to format. |
|
|
189
|
+
|
|
190
|
+
No additional properties.
|
|
@@ -1189,6 +1189,7 @@ Referenced by:
|
|
|
1189
1189
|
| Kind | Entity | Field |
|
|
1190
1190
|
|---|---|---|
|
|
1191
1191
|
| component | `Button` | `appearance` |
|
|
1192
|
+
| component | `DraggableListRemove` | `appearance` |
|
|
1192
1193
|
|
|
1193
1194
|
## ButtonAriaHaspopup
|
|
1194
1195
|
|
|
@@ -1373,6 +1374,7 @@ Referenced by:
|
|
|
1373
1374
|
| Kind | Entity | Field |
|
|
1374
1375
|
|---|---|---|
|
|
1375
1376
|
| component | `Button` | `size` |
|
|
1377
|
+
| component | `DraggableListRemove` | `size` |
|
|
1376
1378
|
| component | `ModalCloseButton` | `size` |
|
|
1377
1379
|
| component | `SplitButton` | `size` |
|
|
1378
1380
|
| type | `AppNavBarAction` | `size` |
|
|
@@ -1463,6 +1465,7 @@ Referenced by:
|
|
|
1463
1465
|
| Kind | Entity | Field |
|
|
1464
1466
|
|---|---|---|
|
|
1465
1467
|
| component | `Button` | `variant` |
|
|
1468
|
+
| component | `DraggableListRemove` | `variant` |
|
|
1466
1469
|
| type | `PageHeaderAction` | `variant` |
|
|
1467
1470
|
|
|
1468
1471
|
## CalendarFormat
|
|
@@ -2243,6 +2246,51 @@ Referenced by:
|
|
|
2243
2246
|
| component | `FloatingButton` | `type` |
|
|
2244
2247
|
| component | `IconButton` | `type` |
|
|
2245
2248
|
|
|
2249
|
+
## formatDateStyle
|
|
2250
|
+
|
|
2251
|
+
TypeScript type:
|
|
2252
|
+
|
|
2253
|
+
```ts
|
|
2254
|
+
"short" | "medium" | "long"
|
|
2255
|
+
```
|
|
2256
|
+
|
|
2257
|
+
Allowed values:
|
|
2258
|
+
|
|
2259
|
+
| Value |
|
|
2260
|
+
|---|
|
|
2261
|
+
| `short` |
|
|
2262
|
+
| `medium` |
|
|
2263
|
+
| `long` |
|
|
2264
|
+
|
|
2265
|
+
Referenced by:
|
|
2266
|
+
|
|
2267
|
+
| Kind | Entity | Field |
|
|
2268
|
+
|---|---|---|
|
|
2269
|
+
| computed function | `formatDate` | `style` |
|
|
2270
|
+
| computed function | `formatDateTime` | `dateStyle` |
|
|
2271
|
+
|
|
2272
|
+
## formatDateTimeTimeStyle
|
|
2273
|
+
|
|
2274
|
+
TypeScript type:
|
|
2275
|
+
|
|
2276
|
+
```ts
|
|
2277
|
+
"short" | "long"
|
|
2278
|
+
```
|
|
2279
|
+
|
|
2280
|
+
Allowed values:
|
|
2281
|
+
|
|
2282
|
+
| Value |
|
|
2283
|
+
|---|
|
|
2284
|
+
| `short` |
|
|
2285
|
+
| `long` |
|
|
2286
|
+
|
|
2287
|
+
Referenced by:
|
|
2288
|
+
|
|
2289
|
+
| Kind | Entity | Field |
|
|
2290
|
+
|---|---|---|
|
|
2291
|
+
| computed function | `formatDateTime` | `timeStyle` |
|
|
2292
|
+
| computed function | `formatTime` | `style` |
|
|
2293
|
+
|
|
2246
2294
|
## FormInputGroupInputType
|
|
2247
2295
|
|
|
2248
2296
|
TypeScript type:
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
# custom-apps Catalog
|
|
3
3
|
|
|
4
4
|
Catalog: `custom-apps`
|
|
5
|
-
Version: `1.
|
|
5
|
+
Version: `1.12.0`
|
|
6
6
|
SDK language: `typescript`
|
|
7
7
|
|
|
8
8
|
Use this catalog index after you have chosen this catalog for the spec. Do not mix components, actions, computed functions, or render helpers from another catalog unless that catalog explicitly documents compatibility.
|
|
@@ -1052,14 +1052,14 @@ No additional properties.
|
|
|
1052
1052
|
|
|
1053
1053
|
| Name | Required | Type | Description |
|
|
1054
1054
|
|---|---:|---|---|
|
|
1055
|
-
| `id` |
|
|
1055
|
+
| `id` | no | string \| number | Unique identifier for the item |
|
|
1056
1056
|
| `label` | no | string | Display label for the item |
|
|
1057
1057
|
|
|
1058
1058
|
Additional properties: unknown.
|
|
1059
1059
|
|
|
1060
1060
|
## DraggableListTip
|
|
1061
1061
|
|
|
1062
|
-
Tooltip configuration for the default chip renderer
|
|
1062
|
+
Tooltip configuration for the default chip renderer in chip mode
|
|
1063
1063
|
|
|
1064
1064
|
### Fields
|
|
1065
1065
|
|