@budibase/frontend-core 3.27.2 → 3.27.4
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/rows.ts +8 -2
- package/src/components/Chatbox/index.svelte +16 -2
- package/src/constants.ts +4 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@budibase/frontend-core",
|
|
3
|
-
"version": "3.27.
|
|
3
|
+
"version": "3.27.4",
|
|
4
4
|
"description": "Budibase frontend core libraries used in builder and client",
|
|
5
5
|
"author": "Budibase",
|
|
6
6
|
"license": "MPL-2.0",
|
|
@@ -24,5 +24,5 @@
|
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"vitest": "^3.2.4"
|
|
26
26
|
},
|
|
27
|
-
"gitHead": "
|
|
27
|
+
"gitHead": "d0d77e2d7618885095e00c73cefcfefd8ad54877"
|
|
28
28
|
}
|
package/src/api/rows.ts
CHANGED
|
@@ -11,7 +11,11 @@ import {
|
|
|
11
11
|
import { BaseAPIClient } from "./types"
|
|
12
12
|
|
|
13
13
|
export interface RowEndpoints {
|
|
14
|
-
fetchRow: (
|
|
14
|
+
fetchRow: (
|
|
15
|
+
tableId: string,
|
|
16
|
+
rowId: string,
|
|
17
|
+
suppressErrors?: boolean
|
|
18
|
+
) => Promise<FindRowResponse>
|
|
15
19
|
saveRow: (
|
|
16
20
|
row: SaveRowRequest,
|
|
17
21
|
suppressErrors?: boolean
|
|
@@ -34,10 +38,12 @@ export const buildRowEndpoints = (API: BaseAPIClient): RowEndpoints => ({
|
|
|
34
38
|
* Fetches data about a certain row in a data source.
|
|
35
39
|
* @param sourceId the ID of the table or view to fetch from
|
|
36
40
|
* @param rowId the ID of the row to fetch
|
|
41
|
+
* @param suppressErrors whether or not to suppress error notifications
|
|
37
42
|
*/
|
|
38
|
-
fetchRow: async (sourceId, rowId) => {
|
|
43
|
+
fetchRow: async (sourceId, rowId, suppressErrors = false) => {
|
|
39
44
|
return await API.get({
|
|
40
45
|
url: `/api/${sourceId}/rows/${rowId}`,
|
|
46
|
+
suppressErrors,
|
|
41
47
|
})
|
|
42
48
|
},
|
|
43
49
|
|
|
@@ -78,6 +78,9 @@
|
|
|
78
78
|
part => isToolUIPart(part) && part.state === "output-error"
|
|
79
79
|
)
|
|
80
80
|
|
|
81
|
+
const getMessageError = (message: UIMessage<AgentMessageMetadata>) =>
|
|
82
|
+
message.metadata?.error
|
|
83
|
+
|
|
81
84
|
$effect(() => {
|
|
82
85
|
const interval = setInterval(() => {
|
|
83
86
|
let updated = false
|
|
@@ -151,6 +154,7 @@
|
|
|
151
154
|
chatAppId,
|
|
152
155
|
agentId: chat?.agentId,
|
|
153
156
|
transient: !persistConversation,
|
|
157
|
+
isPreview: isAgentPreviewChat,
|
|
154
158
|
title: chat?.title,
|
|
155
159
|
messages,
|
|
156
160
|
},
|
|
@@ -409,9 +413,13 @@
|
|
|
409
413
|
{@const reasoningText = getReasoningText(message)}
|
|
410
414
|
{@const reasoningId = `${message.id}-reasoning`}
|
|
411
415
|
{@const toolError = hasToolError(message)}
|
|
416
|
+
{@const messageError = getMessageError(message)}
|
|
412
417
|
{@const reasoningStreaming = isReasoningStreaming(message)}
|
|
413
418
|
{@const isThinking =
|
|
414
|
-
reasoningStreaming &&
|
|
419
|
+
reasoningStreaming &&
|
|
420
|
+
!toolError &&
|
|
421
|
+
!messageError &&
|
|
422
|
+
!message.metadata?.completedAt}
|
|
415
423
|
<div class="message assistant">
|
|
416
424
|
{#if reasoningText}
|
|
417
425
|
<div class="reasoning-part">
|
|
@@ -487,7 +495,7 @@
|
|
|
487
495
|
<div class="tool-name-wrapper">
|
|
488
496
|
<span class="tool-name">{getToolName(part)}</span>
|
|
489
497
|
</div>
|
|
490
|
-
{#if isRunning || isError}
|
|
498
|
+
{#if isRunning || isError || isSuccess}
|
|
491
499
|
<span class="tool-status">
|
|
492
500
|
{#if isRunning}
|
|
493
501
|
<ProgressCircle size="S" />
|
|
@@ -497,6 +505,12 @@
|
|
|
497
505
|
size="S"
|
|
498
506
|
color="var(--spectrum-global-color-red-600)"
|
|
499
507
|
/>
|
|
508
|
+
{:else if isSuccess}
|
|
509
|
+
<Icon
|
|
510
|
+
name="check"
|
|
511
|
+
size="S"
|
|
512
|
+
color="var(--spectrum-global-color-green-600)"
|
|
513
|
+
/>
|
|
500
514
|
{/if}
|
|
501
515
|
</span>
|
|
502
516
|
{/if}
|
package/src/constants.ts
CHANGED
|
@@ -60,13 +60,14 @@ export const BudibaseRoleOptions = [
|
|
|
60
60
|
{
|
|
61
61
|
label: "Creator",
|
|
62
62
|
value: BudibaseRoles.Creator,
|
|
63
|
-
subtitle:
|
|
63
|
+
subtitle:
|
|
64
|
+
"Builder access. Can create/edit everything within assigned workspace.",
|
|
64
65
|
sortOrder: 2,
|
|
65
66
|
},
|
|
66
67
|
{
|
|
67
|
-
label: "
|
|
68
|
+
label: "End user",
|
|
68
69
|
value: BudibaseRoles.AppUser,
|
|
69
|
-
subtitle: "Can only
|
|
70
|
+
subtitle: "No builder access. Can only access published apps and agents.",
|
|
70
71
|
sortOrder: 3,
|
|
71
72
|
},
|
|
72
73
|
]
|