Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
379 changes: 229 additions & 150 deletions mcp/python-react-agent-simple-ui/README.md

Large diffs are not rendered by default.

32 changes: 16 additions & 16 deletions mcp/python-react-agent-simple-ui/client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion mcp/python-react-agent-simple-ui/client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"preview": "vite preview"
},
"dependencies": {
"@thoughtspot/visual-embed-sdk": "^1.45.3-mcp.2",
"@thoughtspot/visual-embed-sdk": "^1.51.1",
"react": "^19.0.0",
"react-dom": "^19.0.0",
"react-markdown": "^10.1.0",
Expand Down
157 changes: 154 additions & 3 deletions mcp/python-react-agent-simple-ui/client/src/App.css
Original file line number Diff line number Diff line change
@@ -1,12 +1,42 @@
/* Light is the base palette. Only the tokens change under a dark system theme -
every rule below is written against these variables, so nothing else forks. */
:root {
color-scheme: light dark;

--primary: #4f46e5;
--primary-light: #eef2ff;
--primary-ring: rgba(79, 70, 229, 0.08);
--bg: #f9fafb;
--surface: #ffffff;
--text: #111827;
--text-secondary: #6b7280;
--border: #e5e7eb;
--error: #ef4444;
--hover: rgba(0, 0, 0, 0.05);
--hover-strong: rgba(0, 0, 0, 0.08);
--code-bg: #1f2937;
--code-text: #f9fafb;
--delete-hover: #c0392b;
}

@media (prefers-color-scheme: dark) {
:root {
/* Indigo lightened so it keeps contrast against the dark surface. */
--primary: #818cf8;
--primary-light: #312e81;
--primary-ring: rgba(129, 140, 248, 0.15);
--bg: #0f1115;
--surface: #171a21;
--text: #e8eaed;
--text-secondary: #9aa0a6;
--border: #2a2f3a;
--error: #f87171;
--hover: rgba(255, 255, 255, 0.06);
--hover-strong: rgba(255, 255, 255, 0.1);
--code-bg: #0b0d11;
--code-text: #e8eaed;
--delete-hover: #f87171;
}
}

* {
Expand Down Expand Up @@ -226,8 +256,8 @@ body {
}

.bubble pre {
background: #1f2937;
color: #f9fafb;
background: var(--code-bg);
color: var(--code-text);
padding: 14px 16px;
border-radius: 8px;
overflow-x: auto;
Expand Down Expand Up @@ -341,7 +371,7 @@ body {

.input-inner:focus-within {
border-color: var(--primary);
box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.08);
box-shadow: 0 0 0 3px var(--primary-ring);
}

.input-inner textarea {
Expand Down Expand Up @@ -406,3 +436,124 @@ body {
font-size: 19px;
}
}

/* MCP answer frames — rendered by startAutoMCPFrameRenderer */
.answer {
margin: 12px 0;
}

.answer figcaption {
font-size: 13px;
font-weight: 600;
color: var(--text-secondary);
margin-bottom: 6px;
}

.answer > div {
border: 1px solid var(--border);
border-radius: 10px;
overflow: hidden;
background: var(--surface);
}

.answer iframe {
display: block;
width: 100%;
border: none;
}

/* ---- Chat history sidebar ---- */

.shell {
display: flex;
height: 100vh;
}

.shell .app {
flex: 1;
min-width: 0;
}

.sidebar {
width: 260px;
flex-shrink: 0;
display: flex;
flex-direction: column;
gap: 10px;
padding: 14px;
background: var(--surface);
border-right: 1px solid var(--border);
overflow: hidden;
}

.sidebar-new {
width: 100%;
}

.sidebar-empty {
font-size: 13px;
color: var(--text-secondary);
padding: 4px 8px;
}

.conversation-list {
display: flex;
flex-direction: column;
gap: 2px;
overflow-y: auto;
}

.conversation {
display: flex;
align-items: center;
gap: 8px;
width: 100%;
padding: 8px 10px;
border: none;
border-radius: 8px;
background: transparent;
color: inherit;
font: inherit;
font-size: 13px;
text-align: left;
cursor: pointer;
}

.conversation:hover:not(:disabled) {
background: var(--hover);
}

.conversation.active {
background: var(--hover-strong);
font-weight: 600;
}

.conversation:disabled {
opacity: 0.5;
cursor: default;
}

.conversation-title {
flex: 1;
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}

.conversation-delete {
flex-shrink: 0;
opacity: 0;
padding: 0 4px;
font-size: 16px;
line-height: 1;
color: var(--text-secondary);
}

.conversation:hover .conversation-delete {
opacity: 1;
}

.conversation-delete:hover {
color: var(--delete-hover);
}
Loading