@mcp-b/react-components 0.10.0 → 0.12.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/{AgentChat-B9LD_WF1.d.ts → AgentChat-CRmsKg9B.d.ts} +10 -6
- package/dist/{BrowserLiveView-ZktFZiMD.d.ts → BrowserLiveView-BV5qgFgI.d.ts} +11 -10
- package/dist/{BrowserReplay-6G-mnwcn.d.ts → BrowserReplay-xWvRjRAC.d.ts} +2 -1
- package/dist/{Menu-B5vDqZe_.d.ts → Menu-BLhnNnRK.d.ts} +3 -0
- package/dist/{ModelSelector-DXtpcRmT.js → ModelSelector-BB-xB-Es.js} +16 -13
- package/dist/{PromptInput-D6-G24p7.d.ts → PromptInput-IyM6ZETj.d.ts} +13 -45
- package/dist/ThinkChat-B3wYahor.js +190 -0
- package/dist/{ThinkChatActivity-B2UD95My.d.ts → ThinkChatActivity-F4KFPcJA.d.ts} +4 -4
- package/dist/ThinkChatContext-C3Eb1Xpi.d.ts +16 -0
- package/dist/{ThinkChatToolParts-DnUiZgCC.d.ts → ThinkChatToolParts-Cv4o7j6F.d.ts} +13 -5
- package/dist/components/AgentChat.d.ts +1 -1
- package/dist/components/AgentChat.js +57 -23
- package/dist/components/AgentConnection.d.ts +3 -14
- package/dist/components/AgentConnection.js +7 -111
- package/dist/components/Badge.js +1 -15
- package/dist/components/BrowserLiveView.d.ts +1 -1
- package/dist/components/BrowserLiveView.js +14 -10
- package/dist/components/BrowserReplay.d.ts +1 -1
- package/dist/components/BrowserRunPanel.d.ts +46 -0
- package/dist/components/BrowserRunPanel.js +159 -0
- package/dist/components/ChatGptSignInScreen.js +1 -1
- package/dist/components/CodexModelSelector.d.ts +63 -0
- package/dist/components/CodexModelSelector.js +148 -0
- package/dist/components/Commit.d.ts +2 -2
- package/dist/components/Commit.js +10 -22
- package/dist/components/Conversation.d.ts +2 -6
- package/dist/components/Conversation.js +2 -3
- package/dist/components/EnvironmentVariables.d.ts +2 -7
- package/dist/components/EnvironmentVariables.js +10 -33
- package/dist/components/Marker.js +1 -15
- package/dist/components/McpServerPicker.d.ts +31 -6
- package/dist/components/McpServerPicker.js +129 -67
- package/dist/components/Menu.d.ts +1 -1
- package/dist/components/Menu.js +2 -2
- package/dist/components/Message.d.ts +3 -2
- package/dist/components/Message.js +10 -3
- package/dist/components/ModelSelector.d.ts +11 -8
- package/dist/components/ModelSelector.js +1 -1
- package/dist/components/PromptInput.d.ts +2 -2
- package/dist/components/PromptInput.js +49 -98
- package/dist/components/Queue.d.ts +1 -12
- package/dist/components/Reasoning.js +2 -15
- package/dist/components/Stepper.js +1 -7
- package/dist/components/ThinkChat.d.ts +30 -30
- package/dist/components/ThinkChat.js +1 -152
- package/dist/components/ThinkChatActivity.d.ts +2 -2
- package/dist/components/ThinkChatActivity.js +3 -10
- package/dist/components/ThinkChatContext.d.ts +2 -2
- package/dist/components/ThinkChatContext.js +9 -2
- package/dist/components/ThinkChatToolPanels.d.ts +1 -1
- package/dist/components/ThinkChatToolPanels.js +19 -7
- package/dist/components/ThinkChatToolParts.d.ts +1 -1
- package/dist/components/ThinkExecutionWorkbench.d.ts +10 -7
- package/dist/components/ThinkExecutionWorkbench.js +382 -359
- package/dist/components/ThinkFullApp.d.ts +16 -13
- package/dist/components/ThinkFullApp.js +28 -18
- package/dist/components/ThinkThreadPicker.d.ts +1 -31
- package/dist/components/ThinkThreadPicker.js +32 -171
- package/dist/components/ThinkThreadShell.d.ts +35 -0
- package/dist/components/ThinkThreadShell.js +146 -0
- package/dist/components/WorkspaceExplorer.js +3 -1
- package/dist/merge-refs-DF_7w2x_.js +18 -0
- package/dist/styles/agent-chat.css +4 -1
- package/dist/styles/agent-connection.css +0 -166
- package/dist/styles/browser-run-panel.css +125 -0
- package/dist/styles/codex-model-selector.css +197 -0
- package/dist/styles/index.css +5 -0
- package/dist/styles/mcp-server-picker.css +62 -15
- package/dist/styles/message.css +1 -1
- package/dist/styles/model-selector.css +20 -8
- package/dist/styles/prompt-input.css +5 -0
- package/dist/styles/streamdown.css +2 -48
- package/dist/styles/think-execution-workbench.css +337 -0
- package/dist/styles/think-full-app.css +15 -390
- package/dist/styles/think-resize-handle.css +33 -0
- package/dist/styles/think-thread-picker.css +0 -238
- package/dist/styles/think-thread-shell.css +219 -0
- package/dist/styles/workspace-explorer.css +8 -2
- package/dist/summarize-tool-input-BUJsENSn.js +12 -0
- package/dist/utils/mcp-server-catalog.d.ts +2 -3
- package/package.json +2 -2
- package/dist/ThinkChatContext-BLAAb8J5.d.ts +0 -28
- package/dist/components/useStickToBottom.d.ts +0 -33
- package/dist/components/useStickToBottom.js +0 -107
|
@@ -1,160 +1,3 @@
|
|
|
1
|
-
.think-thread-shell {
|
|
2
|
-
container: think-thread-shell / inline-size;
|
|
3
|
-
block-size: 100%;
|
|
4
|
-
min-inline-size: 0;
|
|
5
|
-
min-block-size: 0;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
.think-thread-shell__frame {
|
|
9
|
-
--think-thread-mobile-sidebar-w: min(80cqi, 22rem);
|
|
10
|
-
|
|
11
|
-
position: relative;
|
|
12
|
-
isolation: isolate;
|
|
13
|
-
block-size: 100%;
|
|
14
|
-
min-inline-size: 0;
|
|
15
|
-
min-block-size: 0;
|
|
16
|
-
display: grid;
|
|
17
|
-
grid-template-columns: var(--think-thread-sidebar-w, 16rem) minmax(0, 1fr);
|
|
18
|
-
grid-template-rows: minmax(0, 1fr);
|
|
19
|
-
overflow: hidden;
|
|
20
|
-
background: var(--sigvelo-color-canvas);
|
|
21
|
-
color: var(--sigvelo-color-text);
|
|
22
|
-
font-family: var(--sigvelo-font-sans);
|
|
23
|
-
transition: grid-template-columns 180ms ease;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.think-thread-shell__sidebar,
|
|
27
|
-
.think-thread-shell__main {
|
|
28
|
-
min-inline-size: 0;
|
|
29
|
-
min-block-size: 0;
|
|
30
|
-
overflow: hidden;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
.think-thread-shell__sidebar {
|
|
34
|
-
grid-column: 1;
|
|
35
|
-
grid-row: 1;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
.think-thread-shell__main {
|
|
39
|
-
grid-column: 2;
|
|
40
|
-
grid-row: 1;
|
|
41
|
-
display: grid;
|
|
42
|
-
grid-template-rows: minmax(0, 1fr);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.think-thread-shell__peek {
|
|
46
|
-
display: none;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.think-thread-shell__toolbar {
|
|
50
|
-
position: absolute;
|
|
51
|
-
inset-block-start: calc(0.4375rem + env(safe-area-inset-top, 0px));
|
|
52
|
-
inset-inline-start: calc(0.5rem + env(safe-area-inset-left, 0px));
|
|
53
|
-
z-index: 30;
|
|
54
|
-
display: flex;
|
|
55
|
-
align-items: center;
|
|
56
|
-
pointer-events: none;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.think-thread-shell__panel-toggle {
|
|
60
|
-
display: inline-flex;
|
|
61
|
-
align-items: center;
|
|
62
|
-
gap: 0.125rem;
|
|
63
|
-
padding: 0.125rem;
|
|
64
|
-
border: var(--sigvelo-border-style) var(--sigvelo-border-width)
|
|
65
|
-
color-mix(in srgb, var(--sigvelo-color-neutral-border-subtle) 58%, transparent);
|
|
66
|
-
border-radius: 0.625rem;
|
|
67
|
-
background: color-mix(
|
|
68
|
-
in srgb,
|
|
69
|
-
color-mix(in oklab, var(--sigvelo-color-canvas), var(--sigvelo-color-primary-bg-subtle) 18%) 72%,
|
|
70
|
-
var(--sigvelo-color-surface)
|
|
71
|
-
);
|
|
72
|
-
pointer-events: auto;
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
.think-thread-shell__panel-toggle button {
|
|
76
|
-
min-block-size: 1.5rem;
|
|
77
|
-
min-inline-size: 1.625rem;
|
|
78
|
-
padding: 0.1875rem;
|
|
79
|
-
border: 0;
|
|
80
|
-
border-radius: 0.5rem;
|
|
81
|
-
background: transparent;
|
|
82
|
-
color: var(--sigvelo-color-text-muted);
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
.think-thread-shell__panel-toggle button svg {
|
|
86
|
-
display: block;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
.think-thread-shell__panel-toggle button:hover,
|
|
90
|
-
.think-thread-shell__panel-toggle button[data-selected="true"] {
|
|
91
|
-
background: color-mix(in srgb, var(--sigvelo-color-primary-bg-subtle) 78%, white);
|
|
92
|
-
color: var(--sigvelo-color-primary-text);
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
.think-thread-shell__panel-toggle button:focus-visible {
|
|
96
|
-
outline: 2px solid var(--sigvelo-color-focus);
|
|
97
|
-
outline-offset: 2px;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
.think-thread-shell__resizer {
|
|
101
|
-
position: absolute;
|
|
102
|
-
z-index: 25;
|
|
103
|
-
inset-block: 0;
|
|
104
|
-
inset-inline-start: var(--think-thread-sidebar-w, 16rem);
|
|
105
|
-
inline-size: 0.625rem;
|
|
106
|
-
margin-inline-start: -0.3125rem;
|
|
107
|
-
padding: 0;
|
|
108
|
-
border: 0;
|
|
109
|
-
background: transparent;
|
|
110
|
-
cursor: col-resize;
|
|
111
|
-
touch-action: pan-y;
|
|
112
|
-
appearance: none;
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
.think-thread-shell__resizer::before {
|
|
116
|
-
content: "";
|
|
117
|
-
position: absolute;
|
|
118
|
-
inset-block: 0;
|
|
119
|
-
inset-inline-start: 50%;
|
|
120
|
-
inline-size: 1px;
|
|
121
|
-
transform: translateX(-50%);
|
|
122
|
-
background: transparent;
|
|
123
|
-
transition: background 120ms ease;
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
.think-thread-shell__resizer:hover::before,
|
|
127
|
-
.think-thread-shell__resizer:focus-visible::before,
|
|
128
|
-
body.is-resizing-columns .think-thread-shell__resizer::before {
|
|
129
|
-
background: color-mix(in srgb, var(--sigvelo-color-primary-text) 38%, transparent);
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
.think-thread-shell__resizer:focus-visible {
|
|
133
|
-
outline: 2px solid var(--sigvelo-color-focus);
|
|
134
|
-
outline-offset: -2px;
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
body.is-resizing-columns .think-thread-shell__frame {
|
|
138
|
-
transition: none;
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
.think-thread-shell__frame[data-sidebar-open="false"] {
|
|
142
|
-
grid-template-columns: minmax(0, 1fr);
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
.think-thread-shell__frame[data-sidebar-open="false"] .think-thread-shell__sidebar {
|
|
146
|
-
position: absolute;
|
|
147
|
-
inset-block: 0;
|
|
148
|
-
inset-inline-start: 0;
|
|
149
|
-
transform: translateX(-100%);
|
|
150
|
-
visibility: hidden;
|
|
151
|
-
pointer-events: none;
|
|
152
|
-
}
|
|
153
|
-
|
|
154
|
-
.think-thread-shell__frame[data-sidebar-open="false"] .think-thread-shell__main {
|
|
155
|
-
grid-column: 1;
|
|
156
|
-
}
|
|
157
|
-
|
|
158
1
|
.think-thread-picker {
|
|
159
2
|
inline-size: 100%;
|
|
160
3
|
block-size: 100%;
|
|
@@ -178,10 +21,6 @@ body.is-resizing-columns .think-thread-shell__frame {
|
|
|
178
21
|
padding-inline: calc(0.875rem + env(safe-area-inset-left, 0px)) 0.625rem;
|
|
179
22
|
}
|
|
180
23
|
|
|
181
|
-
.think-thread-shell__frame[data-sidebar-open="true"] .think-thread-picker__header {
|
|
182
|
-
padding-inline-start: calc(4.25rem + env(safe-area-inset-left, 0px));
|
|
183
|
-
}
|
|
184
|
-
|
|
185
24
|
.think-thread-picker__title {
|
|
186
25
|
min-inline-size: 0;
|
|
187
26
|
margin: 0;
|
|
@@ -352,78 +191,6 @@ body.is-resizing-columns .think-thread-shell__frame {
|
|
|
352
191
|
flex: 0 0 auto;
|
|
353
192
|
}
|
|
354
193
|
|
|
355
|
-
@container think-thread-shell (inline-size <= 56rem) {
|
|
356
|
-
.think-thread-shell__frame {
|
|
357
|
-
grid-template-columns: minmax(0, 1fr);
|
|
358
|
-
}
|
|
359
|
-
|
|
360
|
-
.think-thread-shell__sidebar,
|
|
361
|
-
.think-thread-shell__main {
|
|
362
|
-
grid-column: 1;
|
|
363
|
-
grid-row: 1;
|
|
364
|
-
}
|
|
365
|
-
|
|
366
|
-
.think-thread-shell__sidebar {
|
|
367
|
-
z-index: 20;
|
|
368
|
-
inline-size: var(--think-thread-mobile-sidebar-w);
|
|
369
|
-
max-inline-size: calc(100cqi - 4rem);
|
|
370
|
-
transition: transform 180ms ease;
|
|
371
|
-
}
|
|
372
|
-
|
|
373
|
-
.think-thread-shell__resizer {
|
|
374
|
-
display: none;
|
|
375
|
-
}
|
|
376
|
-
|
|
377
|
-
.think-thread-shell__frame[data-sidebar-open="false"] .think-thread-shell__sidebar {
|
|
378
|
-
visibility: hidden;
|
|
379
|
-
}
|
|
380
|
-
|
|
381
|
-
.think-thread-shell__main {
|
|
382
|
-
transition:
|
|
383
|
-
transform 180ms ease,
|
|
384
|
-
filter 180ms ease;
|
|
385
|
-
}
|
|
386
|
-
|
|
387
|
-
.think-thread-shell__frame[data-sidebar-open="true"] .think-thread-shell__main {
|
|
388
|
-
transform: translateX(var(--think-thread-mobile-sidebar-w));
|
|
389
|
-
filter: brightness(0.86) saturate(0.92);
|
|
390
|
-
border-start-start-radius: 1.5rem;
|
|
391
|
-
border-end-start-radius: 1.5rem;
|
|
392
|
-
box-shadow: var(--sigvelo-shadow-lg);
|
|
393
|
-
pointer-events: none;
|
|
394
|
-
}
|
|
395
|
-
|
|
396
|
-
.think-thread-shell__frame[data-sidebar-open="true"] .think-thread-shell__peek {
|
|
397
|
-
position: absolute;
|
|
398
|
-
inset-block: 0;
|
|
399
|
-
inset-inline: var(--think-thread-mobile-sidebar-w) 0;
|
|
400
|
-
z-index: 22;
|
|
401
|
-
display: block;
|
|
402
|
-
padding: 0;
|
|
403
|
-
border: 0;
|
|
404
|
-
background: transparent;
|
|
405
|
-
cursor: pointer;
|
|
406
|
-
appearance: none;
|
|
407
|
-
}
|
|
408
|
-
|
|
409
|
-
.think-thread-shell__peek:focus-visible {
|
|
410
|
-
outline: 2px solid var(--sigvelo-color-focus);
|
|
411
|
-
outline-offset: -0.25rem;
|
|
412
|
-
border-start-start-radius: 1.5rem;
|
|
413
|
-
border-end-start-radius: 1.5rem;
|
|
414
|
-
}
|
|
415
|
-
|
|
416
|
-
.think-thread-shell__frame[data-sidebar-open="false"] .think-thread-shell__sidebar {
|
|
417
|
-
transform: translateX(-100%);
|
|
418
|
-
}
|
|
419
|
-
|
|
420
|
-
.think-thread-picker {
|
|
421
|
-
inline-size: 100%;
|
|
422
|
-
border-inline-end: 0;
|
|
423
|
-
box-shadow: var(--sigvelo-shadow-lg);
|
|
424
|
-
}
|
|
425
|
-
}
|
|
426
|
-
|
|
427
194
|
@keyframes think-thread-picker-spin {
|
|
428
195
|
to {
|
|
429
196
|
transform: rotate(360deg);
|
|
@@ -431,11 +198,6 @@ body.is-resizing-columns .think-thread-shell__frame {
|
|
|
431
198
|
}
|
|
432
199
|
|
|
433
200
|
@media (forced-colors: active) {
|
|
434
|
-
.think-thread-shell__panel-toggle {
|
|
435
|
-
border-color: canvastext;
|
|
436
|
-
background: canvas;
|
|
437
|
-
}
|
|
438
|
-
|
|
439
201
|
.think-thread-picker {
|
|
440
202
|
border-inline-end: 1px solid canvastext;
|
|
441
203
|
background: canvas;
|
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
.think-thread-shell {
|
|
2
|
+
container: think-thread-shell / inline-size;
|
|
3
|
+
block-size: 100%;
|
|
4
|
+
min-inline-size: 0;
|
|
5
|
+
min-block-size: 0;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.think-thread-shell__frame {
|
|
9
|
+
--think-thread-mobile-sidebar-w: min(80cqi, 22rem);
|
|
10
|
+
|
|
11
|
+
position: relative;
|
|
12
|
+
isolation: isolate;
|
|
13
|
+
block-size: 100%;
|
|
14
|
+
min-inline-size: 0;
|
|
15
|
+
min-block-size: 0;
|
|
16
|
+
display: grid;
|
|
17
|
+
grid-template-columns: var(--think-thread-sidebar-w, 16rem) minmax(0, 1fr);
|
|
18
|
+
grid-template-rows: minmax(0, 1fr);
|
|
19
|
+
overflow: hidden;
|
|
20
|
+
background: var(--sigvelo-color-canvas);
|
|
21
|
+
color: var(--sigvelo-color-text);
|
|
22
|
+
font-family: var(--sigvelo-font-sans);
|
|
23
|
+
transition: grid-template-columns 180ms ease;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.think-thread-shell__sidebar,
|
|
27
|
+
.think-thread-shell__main {
|
|
28
|
+
min-inline-size: 0;
|
|
29
|
+
min-block-size: 0;
|
|
30
|
+
overflow: hidden;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.think-thread-shell__sidebar {
|
|
34
|
+
grid-column: 1;
|
|
35
|
+
grid-row: 1;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.think-thread-shell__main {
|
|
39
|
+
grid-column: 2;
|
|
40
|
+
grid-row: 1;
|
|
41
|
+
display: grid;
|
|
42
|
+
grid-template-rows: minmax(0, 1fr);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.think-thread-shell__peek {
|
|
46
|
+
display: none;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.think-thread-shell__toolbar {
|
|
50
|
+
position: absolute;
|
|
51
|
+
inset-block-start: calc(0.4375rem + env(safe-area-inset-top, 0px));
|
|
52
|
+
inset-inline-start: calc(0.5rem + env(safe-area-inset-left, 0px));
|
|
53
|
+
z-index: 30;
|
|
54
|
+
display: flex;
|
|
55
|
+
align-items: center;
|
|
56
|
+
pointer-events: none;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.think-thread-shell__panel-toggle {
|
|
60
|
+
display: inline-flex;
|
|
61
|
+
align-items: center;
|
|
62
|
+
gap: 0.125rem;
|
|
63
|
+
padding: 0.125rem;
|
|
64
|
+
border: var(--sigvelo-border-style) var(--sigvelo-border-width)
|
|
65
|
+
color-mix(in srgb, var(--sigvelo-color-neutral-border-subtle) 58%, transparent);
|
|
66
|
+
border-radius: 0.625rem;
|
|
67
|
+
background: color-mix(
|
|
68
|
+
in srgb,
|
|
69
|
+
color-mix(in oklab, var(--sigvelo-color-canvas), var(--sigvelo-color-primary-bg-subtle) 18%) 72%,
|
|
70
|
+
var(--sigvelo-color-surface)
|
|
71
|
+
);
|
|
72
|
+
pointer-events: auto;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.think-thread-shell__panel-toggle button {
|
|
76
|
+
min-block-size: 1.5rem;
|
|
77
|
+
min-inline-size: 1.625rem;
|
|
78
|
+
padding: 0.1875rem;
|
|
79
|
+
border: 0;
|
|
80
|
+
border-radius: 0.5rem;
|
|
81
|
+
background: transparent;
|
|
82
|
+
color: var(--sigvelo-color-text-muted);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.think-thread-shell__panel-toggle button svg {
|
|
86
|
+
display: block;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.think-thread-shell__panel-toggle button:hover,
|
|
90
|
+
.think-thread-shell__panel-toggle button[data-selected="true"] {
|
|
91
|
+
background: color-mix(
|
|
92
|
+
in srgb,
|
|
93
|
+
var(--sigvelo-color-primary-bg-subtle) 78%,
|
|
94
|
+
var(--sigvelo-color-surface)
|
|
95
|
+
);
|
|
96
|
+
color: var(--sigvelo-color-primary-text);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.think-thread-shell__panel-toggle button:focus-visible {
|
|
100
|
+
outline: 2px solid var(--sigvelo-color-focus);
|
|
101
|
+
outline-offset: 2px;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.think-thread-shell__resizer {
|
|
105
|
+
z-index: 25;
|
|
106
|
+
inset-inline-start: var(--think-thread-sidebar-w, 16rem);
|
|
107
|
+
margin-inline-start: -0.3125rem;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
body.is-resizing-think-thread-shell .think-thread-shell__resizer::before {
|
|
111
|
+
background: color-mix(in srgb, var(--sigvelo-color-primary-text) 38%, transparent);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
body.is-resizing-think-thread-shell {
|
|
115
|
+
cursor: col-resize;
|
|
116
|
+
user-select: none;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
body.is-resizing-think-thread-shell .think-thread-shell__frame {
|
|
120
|
+
transition: none;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.think-thread-shell__frame[data-sidebar-open="false"] {
|
|
124
|
+
grid-template-columns: minmax(0, 1fr);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.think-thread-shell__frame[data-sidebar-open="false"] .think-thread-shell__sidebar {
|
|
128
|
+
position: absolute;
|
|
129
|
+
inset-block: 0;
|
|
130
|
+
inset-inline-start: 0;
|
|
131
|
+
transform: translateX(-100%);
|
|
132
|
+
visibility: hidden;
|
|
133
|
+
pointer-events: none;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.think-thread-shell__frame[data-sidebar-open="false"] .think-thread-shell__main {
|
|
137
|
+
grid-column: 1;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.think-thread-shell__frame[data-sidebar-open="true"] .think-thread-picker__header {
|
|
141
|
+
padding-inline-start: calc(4.25rem + env(safe-area-inset-left, 0px));
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
@container think-thread-shell (inline-size <= 56rem) {
|
|
145
|
+
.think-thread-shell__frame {
|
|
146
|
+
grid-template-columns: minmax(0, 1fr);
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.think-thread-shell__sidebar,
|
|
150
|
+
.think-thread-shell__main {
|
|
151
|
+
grid-column: 1;
|
|
152
|
+
grid-row: 1;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.think-thread-shell__sidebar {
|
|
156
|
+
z-index: 20;
|
|
157
|
+
inline-size: var(--think-thread-mobile-sidebar-w);
|
|
158
|
+
max-inline-size: calc(100cqi - 4rem);
|
|
159
|
+
transition: transform 180ms ease;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
.think-thread-shell__resizer {
|
|
163
|
+
display: none;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
.think-thread-shell__frame[data-sidebar-open="false"] .think-thread-shell__sidebar {
|
|
167
|
+
visibility: hidden;
|
|
168
|
+
transform: translateX(-100%);
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
.think-thread-shell__main {
|
|
172
|
+
transition:
|
|
173
|
+
transform 180ms ease,
|
|
174
|
+
filter 180ms ease;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
.think-thread-shell__frame[data-sidebar-open="true"] .think-thread-shell__main {
|
|
178
|
+
transform: translateX(var(--think-thread-mobile-sidebar-w));
|
|
179
|
+
filter: brightness(0.86) saturate(0.92);
|
|
180
|
+
border-start-start-radius: 1.5rem;
|
|
181
|
+
border-end-start-radius: 1.5rem;
|
|
182
|
+
box-shadow: var(--sigvelo-shadow-lg);
|
|
183
|
+
pointer-events: none;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.think-thread-shell__frame[data-sidebar-open="true"] .think-thread-shell__peek {
|
|
187
|
+
position: absolute;
|
|
188
|
+
inset-block: 0;
|
|
189
|
+
inset-inline: var(--think-thread-mobile-sidebar-w) 0;
|
|
190
|
+
z-index: 22;
|
|
191
|
+
display: block;
|
|
192
|
+
padding: 0;
|
|
193
|
+
background: transparent;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
.think-thread-shell__peek:hover {
|
|
197
|
+
background: transparent;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
.think-thread-shell__peek:focus-visible {
|
|
201
|
+
outline: 2px solid var(--sigvelo-color-focus);
|
|
202
|
+
outline-offset: -0.25rem;
|
|
203
|
+
border-start-start-radius: 1.5rem;
|
|
204
|
+
border-end-start-radius: 1.5rem;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
.think-thread-picker {
|
|
208
|
+
inline-size: 100%;
|
|
209
|
+
border-inline-end: 0;
|
|
210
|
+
box-shadow: var(--sigvelo-shadow-lg);
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
@media (forced-colors: active) {
|
|
215
|
+
.think-thread-shell__panel-toggle {
|
|
216
|
+
border-color: canvastext;
|
|
217
|
+
background: canvas;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
@@ -72,16 +72,22 @@
|
|
|
72
72
|
border-color: var(--sigvelo-color-focus);
|
|
73
73
|
}
|
|
74
74
|
|
|
75
|
-
.workspace-explorer__filter
|
|
75
|
+
.workspace-explorer__filter-input.input {
|
|
76
76
|
flex: 1;
|
|
77
77
|
min-width: 0;
|
|
78
|
+
height: auto;
|
|
78
79
|
padding-block: 0.25rem;
|
|
80
|
+
padding-inline: 0;
|
|
79
81
|
border: none;
|
|
82
|
+
border-radius: 0;
|
|
80
83
|
background: transparent;
|
|
81
84
|
color: var(--sigvelo-color-text);
|
|
82
85
|
font-family: inherit;
|
|
83
86
|
font-size: 0.75rem;
|
|
84
|
-
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.workspace-explorer__filter-input.input:focus-visible {
|
|
90
|
+
box-shadow: none;
|
|
85
91
|
}
|
|
86
92
|
|
|
87
93
|
.workspace-explorer__tree {
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
//#region src/components/_internal/summarize-tool-input.ts
|
|
2
|
+
/** First non-empty line of the salient string input (command, path, query…). */
|
|
3
|
+
function summarizeToolInput(input) {
|
|
4
|
+
if (!input || typeof input !== "object") return null;
|
|
5
|
+
for (const value of Object.values(input)) if (typeof value === "string" && value.trim()) {
|
|
6
|
+
const line = value.trim().split("\n", 1)[0] ?? "";
|
|
7
|
+
return line.length > 64 ? `${line.slice(0, 64)}…` : line;
|
|
8
|
+
}
|
|
9
|
+
return null;
|
|
10
|
+
}
|
|
11
|
+
//#endregion
|
|
12
|
+
export { summarizeToolInput as t };
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { MCPServer } from "agents";
|
|
2
2
|
|
|
3
3
|
//#region src/utils/mcp-server-catalog.d.ts
|
|
4
|
-
type
|
|
5
|
-
type McpServerPickerStatus = McpServerConnectionState | "needs-auth";
|
|
4
|
+
type McpServerPickerStatus = MCPServer["state"] | "needs-auth";
|
|
6
5
|
interface McpServerCardIcon {
|
|
7
6
|
src: string;
|
|
8
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mcp-b/react-components",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.12.0",
|
|
4
4
|
"description": "MCP-B React components built on Base UI and shared design tokens, including Cloudflare Think chat primitives.",
|
|
5
5
|
"homepage": "https://design-system.sigvelo.com",
|
|
6
6
|
"bugs": {
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"cloudflare": "^6.5.0",
|
|
53
53
|
"shiki": "^3.23.0",
|
|
54
54
|
"streamdown": "^2.5.0",
|
|
55
|
-
"@mcp-b/design-tokens": "0.
|
|
55
|
+
"@mcp-b/design-tokens": "0.12.0"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@ai-sdk/react": "^3.0.222",
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import { useAgentChat } from "@cloudflare/think/react";
|
|
3
|
-
import { UIMessage } from "ai";
|
|
4
|
-
|
|
5
|
-
//#region src/components/ThinkChatContext.d.ts
|
|
6
|
-
type ThinkChatValue = ReturnType<typeof useAgentChat<unknown, UIMessage>>;
|
|
7
|
-
declare const ThinkChatContext: React.Context<(Omit<import("@ai-sdk/react").UseChatHelpers<UIMessage<unknown, import("ai").UIDataTypes, import("ai").UITools>>, "addToolOutput"> & {
|
|
8
|
-
clearHistory: () => void;
|
|
9
|
-
addToolOutput: (opts: {
|
|
10
|
-
toolCallId: string;
|
|
11
|
-
toolName?: string;
|
|
12
|
-
output?: unknown;
|
|
13
|
-
state?: "output-available" | "output-error";
|
|
14
|
-
errorText?: string;
|
|
15
|
-
}) => void;
|
|
16
|
-
isServerStreaming: boolean;
|
|
17
|
-
isStreaming: boolean;
|
|
18
|
-
isRecovering: boolean;
|
|
19
|
-
isToolContinuation: boolean;
|
|
20
|
-
connectionError: (Error & {
|
|
21
|
-
code: number;
|
|
22
|
-
reason: string;
|
|
23
|
-
wasClean: boolean;
|
|
24
|
-
}) | null;
|
|
25
|
-
}) | null>;
|
|
26
|
-
declare function useThinkChatContext(component: string): ThinkChatValue;
|
|
27
|
-
//#endregion
|
|
28
|
-
export { ThinkChatValue as n, useThinkChatContext as r, ThinkChatContext as t };
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
//#region src/components/useStickToBottom.d.ts
|
|
2
|
-
interface UseStickToBottomOptions {
|
|
3
|
-
/**
|
|
4
|
-
* How close to the bottom (in pixels) still counts as "at bottom" for the
|
|
5
|
-
* sticky behavior. Larger values keep the viewport pinned through small
|
|
6
|
-
* scroll jitter.
|
|
7
|
-
*/
|
|
8
|
-
slackPx?: number;
|
|
9
|
-
}
|
|
10
|
-
interface UseStickToBottomResult {
|
|
11
|
-
/** Attach to the scrolling element. */
|
|
12
|
-
viewportRef: (element: HTMLElement | null) => void;
|
|
13
|
-
/**
|
|
14
|
-
* Attach to the element whose size determines whether the viewport
|
|
15
|
-
* overflows. Typically the immediate child of the viewport.
|
|
16
|
-
*/
|
|
17
|
-
contentRef: (element: HTMLElement | null) => void;
|
|
18
|
-
/** True while the viewport is pinned within `slackPx` of the bottom. */
|
|
19
|
-
isAtBottom: boolean;
|
|
20
|
-
/** Imperatively scroll the viewport to its bottom. */
|
|
21
|
-
scrollToBottom: (behavior?: ScrollBehavior) => void;
|
|
22
|
-
}
|
|
23
|
-
/**
|
|
24
|
-
* Pin a scrollable viewport to the bottom as its content grows, unless the
|
|
25
|
-
* user has scrolled up.
|
|
26
|
-
*
|
|
27
|
-
* @deprecated Use MessageScroller for chat transcripts. Keep this only for
|
|
28
|
-
* standalone streaming panes that do not need transcript row anchoring,
|
|
29
|
-
* history prepending, visibility tracking, or jump-to-message behavior.
|
|
30
|
-
*/
|
|
31
|
-
declare function useStickToBottom(options?: UseStickToBottomOptions): UseStickToBottomResult;
|
|
32
|
-
//#endregion
|
|
33
|
-
export { UseStickToBottomOptions, UseStickToBottomResult, useStickToBottom };
|