@budibase/frontend-core 3.12.14 → 3.12.16
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/package.json +2 -2
- package/src/api/app.ts +9 -0
- package/src/components/ConditionField.svelte +1 -4
- package/src/components/CoreFilterBuilder.svelte +5 -5
- package/src/components/FilterField.svelte +1 -8
- package/src/components/grid/cells/DateCell.svelte +1 -1
- package/src/components/grid/cells/GutterCell.svelte +3 -3
- package/src/components/grid/cells/HeaderCell.svelte +25 -23
- package/src/components/grid/cells/OptionsCell.svelte +2 -2
- package/src/components/grid/cells/RelationshipCell.svelte +12 -8
- package/src/components/grid/layout/NewColumnButton.svelte +1 -1
- package/src/components/grid/layout/NewRow.svelte +2 -2
- package/src/components/grid/layout/StickyColumn.svelte +1 -1
- package/src/components/grid/overlays/MenuOverlay.svelte +13 -13
- package/src/constants.ts +20 -20
- package/src/utils/schema.js +4 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@budibase/frontend-core",
|
|
3
|
-
"version": "3.12.
|
|
3
|
+
"version": "3.12.16",
|
|
4
4
|
"description": "Budibase frontend core libraries used in builder and client",
|
|
5
5
|
"author": "Budibase",
|
|
6
6
|
"license": "MPL-2.0",
|
|
@@ -17,5 +17,5 @@
|
|
|
17
17
|
"shortid": "2.2.15",
|
|
18
18
|
"socket.io-client": "^4.7.5"
|
|
19
19
|
},
|
|
20
|
-
"gitHead": "
|
|
20
|
+
"gitHead": "5d84b70e4dbedbe6dd5d323d752e5cc962e592e9"
|
|
21
21
|
}
|
package/src/api/app.ts
CHANGED
|
@@ -12,6 +12,7 @@ import {
|
|
|
12
12
|
FetchAppPackageResponse,
|
|
13
13
|
FetchAppsResponse,
|
|
14
14
|
FetchDeploymentResponse,
|
|
15
|
+
FetchPublishedAppsResponse,
|
|
15
16
|
GetDiagnosticsResponse,
|
|
16
17
|
ImportToUpdateAppRequest,
|
|
17
18
|
ImportToUpdateAppResponse,
|
|
@@ -59,6 +60,7 @@ export interface AppEndpoints {
|
|
|
59
60
|
appId: string
|
|
60
61
|
) => Promise<FetchAppDefinitionResponse>
|
|
61
62
|
addSampleData: (appId: string) => Promise<AddAppSampleDataResponse>
|
|
63
|
+
getPublishedApps: () => Promise<FetchPublishedAppsResponse["apps"]>
|
|
62
64
|
|
|
63
65
|
// Missing request or response types
|
|
64
66
|
importApps: (apps: any) => Promise<any>
|
|
@@ -272,4 +274,11 @@ export const buildAppEndpoints = (API: BaseAPIClient): AppEndpoints => ({
|
|
|
272
274
|
url: `/api/applications/${appId}/sample`,
|
|
273
275
|
})
|
|
274
276
|
},
|
|
277
|
+
|
|
278
|
+
getPublishedApps: async () => {
|
|
279
|
+
const response = await API.get<FetchPublishedAppsResponse>({
|
|
280
|
+
url: `/api/client/applications`,
|
|
281
|
+
})
|
|
282
|
+
return response.apps
|
|
283
|
+
},
|
|
275
284
|
})
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
bindingDrawer.show()
|
|
101
101
|
}}
|
|
102
102
|
>
|
|
103
|
-
<Icon size="S" name="
|
|
103
|
+
<Icon size="S" weight="fill" name="lightning" />
|
|
104
104
|
</div>
|
|
105
105
|
{/if}
|
|
106
106
|
</div>
|
|
@@ -161,9 +161,6 @@
|
|
|
161
161
|
border-color var(--spectrum-global-animation-duration-100, 130ms);
|
|
162
162
|
height: calc(var(--spectrum-alias-item-height-m));
|
|
163
163
|
}
|
|
164
|
-
.binding-control .icon.binding {
|
|
165
|
-
color: var(--yellow);
|
|
166
|
-
}
|
|
167
164
|
|
|
168
165
|
.binding-control .icon:hover {
|
|
169
166
|
cursor: pointer;
|
|
@@ -339,7 +339,7 @@
|
|
|
339
339
|
</div>
|
|
340
340
|
<div class="group-actions">
|
|
341
341
|
<Icon
|
|
342
|
-
name="
|
|
342
|
+
name="plus"
|
|
343
343
|
hoverable
|
|
344
344
|
hoverColor="var(--ink)"
|
|
345
345
|
on:click={() => {
|
|
@@ -350,7 +350,7 @@
|
|
|
350
350
|
}}
|
|
351
351
|
/>
|
|
352
352
|
<Icon
|
|
353
|
-
name="
|
|
353
|
+
name="trash"
|
|
354
354
|
hoverable
|
|
355
355
|
hoverColor="var(--ink)"
|
|
356
356
|
on:click={() => {
|
|
@@ -437,7 +437,7 @@
|
|
|
437
437
|
|
|
438
438
|
<ActionButton
|
|
439
439
|
size="M"
|
|
440
|
-
icon="
|
|
440
|
+
icon="trash"
|
|
441
441
|
on:click={() => {
|
|
442
442
|
handleFilterChange({
|
|
443
443
|
groupIdx,
|
|
@@ -478,7 +478,7 @@
|
|
|
478
478
|
{/if}
|
|
479
479
|
<div class="add-group">
|
|
480
480
|
<Button
|
|
481
|
-
icon="
|
|
481
|
+
icon="plus-circle"
|
|
482
482
|
size="M"
|
|
483
483
|
secondary
|
|
484
484
|
on:click={() => {
|
|
@@ -492,7 +492,7 @@
|
|
|
492
492
|
{#if docsURL}
|
|
493
493
|
<a href={docsURL} target="_blank">
|
|
494
494
|
<Icon
|
|
495
|
-
name="
|
|
495
|
+
name="question"
|
|
496
496
|
color="var(--spectrum-global-color-gray-600)"
|
|
497
497
|
/>
|
|
498
498
|
</a>
|
|
@@ -243,7 +243,7 @@
|
|
|
243
243
|
bindingDrawer.show()
|
|
244
244
|
}}
|
|
245
245
|
>
|
|
246
|
-
<Icon size="S" name="
|
|
246
|
+
<Icon size="S" weight="fill" name="lightning" />
|
|
247
247
|
</div>
|
|
248
248
|
{/if}
|
|
249
249
|
</div>
|
|
@@ -304,9 +304,6 @@
|
|
|
304
304
|
border-color var(--spectrum-global-animation-duration-100, 130ms);
|
|
305
305
|
height: calc(var(--spectrum-alias-item-height-m));
|
|
306
306
|
}
|
|
307
|
-
.binding-control .icon.binding {
|
|
308
|
-
color: var(--yellow);
|
|
309
|
-
}
|
|
310
307
|
|
|
311
308
|
.binding-control .icon:hover {
|
|
312
309
|
cursor: pointer;
|
|
@@ -314,8 +311,4 @@
|
|
|
314
311
|
border-color: var(--spectrum-alias-border-color-hover);
|
|
315
312
|
color: var(--spectrum-alias-text-color-hover);
|
|
316
313
|
}
|
|
317
|
-
|
|
318
|
-
.binding-control .icon.binding:hover {
|
|
319
|
-
color: var(--yellow);
|
|
320
|
-
}
|
|
321
314
|
</style>
|
|
@@ -79,14 +79,14 @@
|
|
|
79
79
|
{#if rowSelected && $config.canDeleteRows}
|
|
80
80
|
<div class="delete" on:click={bulkDelete}>
|
|
81
81
|
<Icon
|
|
82
|
-
name="
|
|
82
|
+
name="trash"
|
|
83
83
|
size="S"
|
|
84
84
|
color="var(--spectrum-global-color-red-400)"
|
|
85
85
|
/>
|
|
86
86
|
</div>
|
|
87
87
|
{:else}
|
|
88
88
|
<div class="expand" class:visible={$config.canExpandRows && expandable}>
|
|
89
|
-
<Icon size="S" name="
|
|
89
|
+
<Icon size="S" name="arrows-out-simple" hoverable on:click={expand} />
|
|
90
90
|
</div>
|
|
91
91
|
{/if}
|
|
92
92
|
</div>
|
|
@@ -131,7 +131,7 @@
|
|
|
131
131
|
.delete:hover {
|
|
132
132
|
cursor: pointer;
|
|
133
133
|
}
|
|
134
|
-
.delete:hover :global(.
|
|
134
|
+
.delete:hover :global(.icon) {
|
|
135
135
|
color: var(--spectrum-global-color-red-600) !important;
|
|
136
136
|
}
|
|
137
137
|
|
|
@@ -305,11 +305,17 @@
|
|
|
305
305
|
|
|
306
306
|
{#if !$config.quiet}
|
|
307
307
|
<div class="column-icon">
|
|
308
|
-
<Icon
|
|
308
|
+
<Icon
|
|
309
|
+
name={getColumnIcon(column)}
|
|
310
|
+
size="M"
|
|
311
|
+
color="var(--spectrum-global-color-gray-600)"
|
|
312
|
+
hoverable
|
|
313
|
+
hoverColor="var(--spectrum-global-color-gray-800)"
|
|
314
|
+
/>
|
|
309
315
|
</div>
|
|
310
316
|
{/if}
|
|
311
317
|
<div class="search-icon" on:click={startSearching}>
|
|
312
|
-
<Icon hoverable size="S" name="
|
|
318
|
+
<Icon hoverable size="S" name="magnifying-glass" />
|
|
313
319
|
</div>
|
|
314
320
|
|
|
315
321
|
<div class="name">
|
|
@@ -318,7 +324,7 @@
|
|
|
318
324
|
|
|
319
325
|
{#if searching}
|
|
320
326
|
<div class="clear-icon" on:click={stopSearching}>
|
|
321
|
-
<Icon hoverable size="S" name="
|
|
327
|
+
<Icon hoverable size="S" name="x" />
|
|
322
328
|
</div>
|
|
323
329
|
{:else}
|
|
324
330
|
{#if sortedBy}
|
|
@@ -327,13 +333,13 @@
|
|
|
327
333
|
hoverable
|
|
328
334
|
size="S"
|
|
329
335
|
name={$sort.order === SortOrder.DESCENDING
|
|
330
|
-
? "
|
|
331
|
-
: "
|
|
336
|
+
? "sort-descending"
|
|
337
|
+
: "sort-ascending"}
|
|
332
338
|
/>
|
|
333
339
|
</div>
|
|
334
340
|
{/if}
|
|
335
341
|
<div class="more-icon" on:click={() => (open = true)}>
|
|
336
|
-
<Icon hoverable size="S" name="
|
|
342
|
+
<Icon hoverable size="S" name="dots-three-vertical" />
|
|
337
343
|
</div>
|
|
338
344
|
{/if}
|
|
339
345
|
</GridCell>
|
|
@@ -353,25 +359,25 @@
|
|
|
353
359
|
</div>
|
|
354
360
|
{:else}
|
|
355
361
|
<Menu>
|
|
356
|
-
<MenuItem icon="
|
|
362
|
+
<MenuItem icon="pencil" on:click={editColumn} disabled={!editable}>
|
|
357
363
|
Edit column
|
|
358
364
|
</MenuItem>
|
|
359
365
|
<MenuItem
|
|
360
|
-
icon="
|
|
366
|
+
icon="copy"
|
|
361
367
|
on:click={duplicateColumn}
|
|
362
368
|
disabled={!$config.canEditColumns}
|
|
363
369
|
>
|
|
364
370
|
Duplicate column
|
|
365
371
|
</MenuItem>
|
|
366
372
|
<MenuItem
|
|
367
|
-
icon="
|
|
373
|
+
icon="tag"
|
|
368
374
|
on:click={makeDisplayColumn}
|
|
369
375
|
disabled={column.primaryDisplay || !canBeDisplayColumn(column.schema)}
|
|
370
376
|
>
|
|
371
377
|
Use as display column
|
|
372
378
|
</MenuItem>
|
|
373
379
|
<MenuItem
|
|
374
|
-
icon="
|
|
380
|
+
icon="sort-ascending"
|
|
375
381
|
on:click={sortAscending}
|
|
376
382
|
disabled={!canBeSortColumn(column.schema) ||
|
|
377
383
|
(column.name === $sort.column &&
|
|
@@ -380,7 +386,7 @@
|
|
|
380
386
|
Sort {sortingLabels.ascending}
|
|
381
387
|
</MenuItem>
|
|
382
388
|
<MenuItem
|
|
383
|
-
icon="
|
|
389
|
+
icon="sort-descending"
|
|
384
390
|
on:click={sortDescending}
|
|
385
391
|
disabled={!canBeSortColumn(column.schema) ||
|
|
386
392
|
(column.name === $sort.column &&
|
|
@@ -388,29 +394,25 @@
|
|
|
388
394
|
>
|
|
389
395
|
Sort {sortingLabels.descending}
|
|
390
396
|
</MenuItem>
|
|
391
|
-
<MenuItem
|
|
392
|
-
disabled={!canMoveLeft}
|
|
393
|
-
icon="ChevronLeft"
|
|
394
|
-
on:click={moveLeft}
|
|
395
|
-
>
|
|
397
|
+
<MenuItem disabled={!canMoveLeft} icon="caret-left" on:click={moveLeft}>
|
|
396
398
|
Move left
|
|
397
399
|
</MenuItem>
|
|
398
400
|
<MenuItem
|
|
399
401
|
disabled={!canMoveRight}
|
|
400
|
-
icon="
|
|
402
|
+
icon="caret-right"
|
|
401
403
|
on:click={moveRight}
|
|
402
404
|
>
|
|
403
405
|
Move right
|
|
404
406
|
</MenuItem>
|
|
405
407
|
<MenuItem
|
|
406
408
|
disabled={column.primaryDisplay}
|
|
407
|
-
icon="
|
|
409
|
+
icon="eye-slash"
|
|
408
410
|
on:click={hideColumn}
|
|
409
411
|
>
|
|
410
412
|
Hide column
|
|
411
413
|
</MenuItem>
|
|
412
414
|
{#if $config.canEditColumns && column.schema.type === "link" && column.schema.tableId === TableNames.USERS && !column.schema.autocolumn}
|
|
413
|
-
<MenuItem icon="
|
|
415
|
+
<MenuItem icon="user" on:click={openMigrationModal}>
|
|
414
416
|
Migrate to user column
|
|
415
417
|
</MenuItem>
|
|
416
418
|
{/if}
|
|
@@ -432,15 +434,15 @@
|
|
|
432
434
|
}
|
|
433
435
|
.header-cell :global(.cell) {
|
|
434
436
|
padding: 0 var(--cell-padding);
|
|
435
|
-
gap: calc(
|
|
437
|
+
gap: calc(1.5 * var(--cell-spacing));
|
|
436
438
|
background: var(--header-cell-background);
|
|
437
439
|
}
|
|
438
440
|
|
|
439
441
|
/* Icon colors */
|
|
440
|
-
.header-cell :global(.
|
|
442
|
+
.header-cell :global(.icon) {
|
|
441
443
|
color: var(--spectrum-global-color-gray-600);
|
|
442
444
|
}
|
|
443
|
-
.header-cell :global(.
|
|
445
|
+
.header-cell :global(.icon.hoverable:hover) {
|
|
444
446
|
color: var(--spectrum-global-color-gray-800) !important;
|
|
445
447
|
cursor: pointer;
|
|
446
448
|
}
|
|
@@ -465,7 +467,7 @@
|
|
|
465
467
|
white-space: nowrap;
|
|
466
468
|
text-overflow: ellipsis;
|
|
467
469
|
overflow: hidden;
|
|
468
|
-
font-weight:
|
|
470
|
+
font-weight: 500;
|
|
469
471
|
}
|
|
470
472
|
.header-cell.searching .name {
|
|
471
473
|
opacity: 0;
|
|
@@ -118,7 +118,7 @@
|
|
|
118
118
|
</div>
|
|
119
119
|
{#if editable}
|
|
120
120
|
<div class="arrow" on:click={open}>
|
|
121
|
-
<Icon name="
|
|
121
|
+
<Icon name="caret-down" />
|
|
122
122
|
</div>
|
|
123
123
|
{/if}
|
|
124
124
|
</div>
|
|
@@ -142,7 +142,7 @@
|
|
|
142
142
|
</span>
|
|
143
143
|
</div>
|
|
144
144
|
{#if values.includes(option)}
|
|
145
|
-
<Icon name="
|
|
145
|
+
<Icon name="check" color="var(--accent-color)" />
|
|
146
146
|
{/if}
|
|
147
147
|
</div>
|
|
148
148
|
{/each}
|
|
@@ -273,10 +273,12 @@
|
|
|
273
273
|
</span>
|
|
274
274
|
{#if editable}
|
|
275
275
|
<Icon
|
|
276
|
-
name="
|
|
276
|
+
name="x"
|
|
277
277
|
size="XS"
|
|
278
278
|
hoverable
|
|
279
279
|
on:click={() => toggleRow(relationship)}
|
|
280
|
+
color="var(--spectrum-global-color-gray-800)"
|
|
281
|
+
weight="bold"
|
|
280
282
|
/>
|
|
281
283
|
{/if}
|
|
282
284
|
</div>
|
|
@@ -284,7 +286,12 @@
|
|
|
284
286
|
{/each}
|
|
285
287
|
{#if editable}
|
|
286
288
|
<div class="add" on:click={open}>
|
|
287
|
-
<Icon
|
|
289
|
+
<Icon
|
|
290
|
+
name="plus"
|
|
291
|
+
size="S"
|
|
292
|
+
color="var(--spectrum-global-color-gray-800)"
|
|
293
|
+
weight="bold"
|
|
294
|
+
/>
|
|
288
295
|
</div>
|
|
289
296
|
{/if}
|
|
290
297
|
</div>
|
|
@@ -329,7 +336,7 @@
|
|
|
329
336
|
</span>
|
|
330
337
|
</div>
|
|
331
338
|
{#if isRowSelected(row)}
|
|
332
|
-
<Icon size="S" name="
|
|
339
|
+
<Icon size="S" name="check" color="var(--accent-color)" />
|
|
333
340
|
{/if}
|
|
334
341
|
</div>
|
|
335
342
|
{/each}
|
|
@@ -440,13 +447,10 @@
|
|
|
440
447
|
|
|
441
448
|
.add {
|
|
442
449
|
background: var(--spectrum-global-color-gray-200);
|
|
443
|
-
padding:
|
|
450
|
+
padding: 3px;
|
|
444
451
|
border-radius: 4px;
|
|
445
452
|
}
|
|
446
|
-
|
|
447
|
-
width: 12px;
|
|
448
|
-
height: 12px;
|
|
449
|
-
}
|
|
453
|
+
|
|
450
454
|
.add:hover {
|
|
451
455
|
background: var(--spectrum-global-color-gray-300);
|
|
452
456
|
cursor: pointer;
|
|
@@ -176,7 +176,7 @@
|
|
|
176
176
|
transition:fade|local={{ duration: 130 }}
|
|
177
177
|
class:offset={!$displayColumn}
|
|
178
178
|
>
|
|
179
|
-
<Icon name="
|
|
179
|
+
<Icon name="plus" size="S" />
|
|
180
180
|
</div>
|
|
181
181
|
{/if}
|
|
182
182
|
</TempTooltip>
|
|
@@ -193,7 +193,7 @@
|
|
|
193
193
|
<div class="sticky-column" transition:fade|local={{ duration: 130 }}>
|
|
194
194
|
<div class="row">
|
|
195
195
|
<GutterCell expandable on:expand={addViaModal} rowHovered>
|
|
196
|
-
<Icon name="
|
|
196
|
+
<Icon name="plus" color="var(--spectrum-global-color-gray-500)" />
|
|
197
197
|
{#if isAdding}
|
|
198
198
|
<div in:fade={{ duration: 130 }} class="loading-overlay" />
|
|
199
199
|
{/if}
|
|
@@ -112,7 +112,7 @@
|
|
|
112
112
|
on:click={() => dispatch("add-row-inline")}
|
|
113
113
|
>
|
|
114
114
|
<GutterCell rowHovered={$hoveredRowId === BlankRowID}>
|
|
115
|
-
<Icon name="
|
|
115
|
+
<Icon name="plus" color="var(--spectrum-global-color-gray-500)" />
|
|
116
116
|
</GutterCell>
|
|
117
117
|
{#if $displayColumn}
|
|
118
118
|
<GridCell
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
<Menu>
|
|
74
74
|
{#if $menu.multiRowMode}
|
|
75
75
|
<MenuItem
|
|
76
|
-
icon="
|
|
76
|
+
icon="copy"
|
|
77
77
|
disabled={!$config.canAddRows || $selectedRowCount > 50}
|
|
78
78
|
on:click={() => dispatch("request-bulk-duplicate")}
|
|
79
79
|
on:click={menu.actions.close}
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
Duplicate {$selectedRowCount} rows
|
|
82
82
|
</MenuItem>
|
|
83
83
|
<MenuItem
|
|
84
|
-
icon="
|
|
84
|
+
icon="trash"
|
|
85
85
|
disabled={!$config.canDeleteRows}
|
|
86
86
|
on:click={() => dispatch("request-bulk-delete")}
|
|
87
87
|
on:click={menu.actions.close}
|
|
@@ -90,7 +90,7 @@
|
|
|
90
90
|
</MenuItem>
|
|
91
91
|
{:else if $menu.multiCellMode}
|
|
92
92
|
<MenuItem
|
|
93
|
-
icon="
|
|
93
|
+
icon="copy"
|
|
94
94
|
disabled={!$copyAllowed}
|
|
95
95
|
on:click={() => dispatch("copy")}
|
|
96
96
|
on:click={menu.actions.close}
|
|
@@ -98,7 +98,7 @@
|
|
|
98
98
|
Copy
|
|
99
99
|
</MenuItem>
|
|
100
100
|
<MenuItem
|
|
101
|
-
icon="
|
|
101
|
+
icon="clipboard-text"
|
|
102
102
|
disabled={!$pasteAllowed}
|
|
103
103
|
on:click={() => dispatch("paste")}
|
|
104
104
|
on:click={menu.actions.close}
|
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
Paste
|
|
107
107
|
</MenuItem>
|
|
108
108
|
<MenuItem
|
|
109
|
-
icon="
|
|
109
|
+
icon="trash"
|
|
110
110
|
disabled={!$config.canEditRows}
|
|
111
111
|
on:click={() => dispatch("request-bulk-delete")}
|
|
112
112
|
>
|
|
@@ -114,7 +114,7 @@
|
|
|
114
114
|
</MenuItem>
|
|
115
115
|
{:else}
|
|
116
116
|
<MenuItem
|
|
117
|
-
icon="
|
|
117
|
+
icon="copy"
|
|
118
118
|
disabled={!$copyAllowed}
|
|
119
119
|
on:click={() => dispatch("copy")}
|
|
120
120
|
on:click={menu.actions.close}
|
|
@@ -122,7 +122,7 @@
|
|
|
122
122
|
Copy
|
|
123
123
|
</MenuItem>
|
|
124
124
|
<MenuItem
|
|
125
|
-
icon="
|
|
125
|
+
icon="clipboard-text"
|
|
126
126
|
disabled={!$pasteAllowed}
|
|
127
127
|
on:click={() => dispatch("paste")}
|
|
128
128
|
on:click={menu.actions.close}
|
|
@@ -130,7 +130,7 @@
|
|
|
130
130
|
Paste
|
|
131
131
|
</MenuItem>
|
|
132
132
|
<MenuItem
|
|
133
|
-
icon="
|
|
133
|
+
icon="arrows-out-simple"
|
|
134
134
|
disabled={isNewRow ||
|
|
135
135
|
!$config.canEditRows ||
|
|
136
136
|
!$config.canExpandRows}
|
|
@@ -140,7 +140,7 @@
|
|
|
140
140
|
Edit row in modal
|
|
141
141
|
</MenuItem>
|
|
142
142
|
<MenuItem
|
|
143
|
-
icon="
|
|
143
|
+
icon="copy"
|
|
144
144
|
disabled={isNewRow || !$focusedRow?._id || !$hasBudibaseIdentifiers}
|
|
145
145
|
on:click={() => copyToClipboard($focusedRow?._id)}
|
|
146
146
|
on:click={menu.actions.close}
|
|
@@ -148,7 +148,7 @@
|
|
|
148
148
|
Copy row _id
|
|
149
149
|
</MenuItem>
|
|
150
150
|
<MenuItem
|
|
151
|
-
icon="
|
|
151
|
+
icon="copy"
|
|
152
152
|
disabled={isNewRow ||
|
|
153
153
|
!$focusedRow?._rev ||
|
|
154
154
|
!$hasBudibaseIdentifiers}
|
|
@@ -158,14 +158,14 @@
|
|
|
158
158
|
Copy row _rev
|
|
159
159
|
</MenuItem>
|
|
160
160
|
<MenuItem
|
|
161
|
-
icon="
|
|
161
|
+
icon="copy"
|
|
162
162
|
disabled={isNewRow || !$config.canAddRows}
|
|
163
163
|
on:click={duplicateRow}
|
|
164
164
|
>
|
|
165
165
|
Duplicate row
|
|
166
166
|
</MenuItem>
|
|
167
167
|
<MenuItem
|
|
168
|
-
icon="
|
|
168
|
+
icon="trash"
|
|
169
169
|
disabled={isNewRow || !$config.canDeleteRows}
|
|
170
170
|
on:click={deleteRow}
|
|
171
171
|
>
|
|
@@ -173,7 +173,7 @@
|
|
|
173
173
|
</MenuItem>
|
|
174
174
|
{#if $config.aiEnabled}
|
|
175
175
|
<MenuItem
|
|
176
|
-
icon="
|
|
176
|
+
icon="magic-wand"
|
|
177
177
|
disabled={isNewRow || !hasAIColumns}
|
|
178
178
|
on:click={generateAIColumns}
|
|
179
179
|
>
|
package/src/constants.ts
CHANGED
|
@@ -118,29 +118,29 @@ export const EventPublishType = {
|
|
|
118
118
|
export { ComponentContextScopes as ContextScopes } from "@budibase/types"
|
|
119
119
|
|
|
120
120
|
export const TypeIconMap = {
|
|
121
|
-
[FieldType.STRING]: "
|
|
122
|
-
[FieldType.OPTIONS]: "
|
|
123
|
-
[FieldType.DATETIME]: "
|
|
124
|
-
[FieldType.BARCODEQR]: "
|
|
125
|
-
[FieldType.SIGNATURE_SINGLE]: "
|
|
126
|
-
[FieldType.LONGFORM]: "
|
|
127
|
-
[FieldType.ARRAY]: "
|
|
128
|
-
[FieldType.NUMBER]: "
|
|
129
|
-
[FieldType.BOOLEAN]: "
|
|
130
|
-
[FieldType.ATTACHMENTS]: "
|
|
131
|
-
[FieldType.ATTACHMENT_SINGLE]: "
|
|
132
|
-
[FieldType.LINK]: "
|
|
133
|
-
[FieldType.FORMULA]: "
|
|
134
|
-
[FieldType.AI]: "
|
|
135
|
-
[FieldType.JSON]: "
|
|
136
|
-
[FieldType.BIGINT]: "
|
|
137
|
-
[FieldType.AUTO]: "
|
|
121
|
+
[FieldType.STRING]: "text-align-left",
|
|
122
|
+
[FieldType.OPTIONS]: "caret-circle-down",
|
|
123
|
+
[FieldType.DATETIME]: "calendar",
|
|
124
|
+
[FieldType.BARCODEQR]: "barcode",
|
|
125
|
+
[FieldType.SIGNATURE_SINGLE]: "pen-nib",
|
|
126
|
+
[FieldType.LONGFORM]: "text-align-left",
|
|
127
|
+
[FieldType.ARRAY]: "list-checks",
|
|
128
|
+
[FieldType.NUMBER]: "hash",
|
|
129
|
+
[FieldType.BOOLEAN]: "toggle-right",
|
|
130
|
+
[FieldType.ATTACHMENTS]: "files",
|
|
131
|
+
[FieldType.ATTACHMENT_SINGLE]: "file",
|
|
132
|
+
[FieldType.LINK]: "arrow-circle-up-right",
|
|
133
|
+
[FieldType.FORMULA]: "calculator",
|
|
134
|
+
[FieldType.AI]: "sparkle",
|
|
135
|
+
[FieldType.JSON]: "brackets-angle",
|
|
136
|
+
[FieldType.BIGINT]: "text-bolder",
|
|
137
|
+
[FieldType.AUTO]: "shapes",
|
|
138
138
|
[FieldType.BB_REFERENCE]: {
|
|
139
|
-
[BBReferenceFieldSubType.USER]: "
|
|
140
|
-
[BBReferenceFieldSubType.USERS]: "
|
|
139
|
+
[BBReferenceFieldSubType.USER]: "users-three",
|
|
140
|
+
[BBReferenceFieldSubType.USERS]: "users-three",
|
|
141
141
|
},
|
|
142
142
|
[FieldType.BB_REFERENCE_SINGLE]: {
|
|
143
|
-
[BBReferenceFieldSubType.USER]: "
|
|
143
|
+
[BBReferenceFieldSubType.USER]: "user",
|
|
144
144
|
},
|
|
145
145
|
}
|
|
146
146
|
|
package/src/utils/schema.js
CHANGED
|
@@ -9,13 +9,13 @@ export const getColumnIcon = column => {
|
|
|
9
9
|
return column.schema.icon
|
|
10
10
|
}
|
|
11
11
|
if (column.calculationType) {
|
|
12
|
-
return "
|
|
12
|
+
return "calculator"
|
|
13
13
|
}
|
|
14
14
|
if (column.schema.autocolumn) {
|
|
15
|
-
return "
|
|
15
|
+
return "shapes"
|
|
16
16
|
}
|
|
17
17
|
if (helpers.schema.isDeprecatedSingleUserColumn(column.schema)) {
|
|
18
|
-
return "
|
|
18
|
+
return "user"
|
|
19
19
|
}
|
|
20
20
|
const { type, subtype } = column.schema
|
|
21
21
|
const result =
|
|
@@ -23,7 +23,7 @@ export const getColumnIcon = column => {
|
|
|
23
23
|
? TypeIconMap[type][subtype]
|
|
24
24
|
: TypeIconMap[type]
|
|
25
25
|
|
|
26
|
-
return result || "
|
|
26
|
+
return result || "article"
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
export const addNestedJSONSchemaFields = schema => {
|