Skip to content

A team of long-lived bots for DeepSeek Harness, with main bots, bot-to-bot messages and group chats.

Remove the Connect plugins footer

klarkxy2a3f46fe9f06
diff --git a/ds-bot/client.js b/ds-bot/client.js
index 0c7d9bf8..d091cf5f 100644
--- a/ds-bot/client.js
+++ b/ds-bot/client.js
@@ -94,7 +94,6 @@ var ZH = {
// Sidebar and account menu
"Bot list": "Bot 列表",
"Setting up your Main Bot…": "正在设置你的主 Bot…",
- "Connect plugins": "连接插件",
"Automation tasks": "自动化任务",
Connectors: "连接器",
"Search connectors": "搜索连接器",
@@ -2330,7 +2329,6 @@ function useLinger(value, ms) {
}
// src/client/styles.js
-var SKIN_FOOT = ':is(div,footer):not([class*="_footArea"]):has(> div > [data-slot="sidebar.footer.action"] > .bt-connect-wrap)';
var SHELL_CSS = `
body{--bt-ink:#141414;--bt-danger:#e02135;--bt-ink-2:rgba(20,20,20,.6);--bt-ink-3:rgba(20,20,20,.36);--bt-bubble:#eeeeee;--bt-sidebar:#f7f7f7;--bt-main:#fcfcfc;--bt-line:rgba(20,20,20,.08);--bt-line-2:rgba(20,20,20,.15);--bt-line-weak:rgba(20,20,20,.1);--bt-hover:rgba(119,119,119,.09);--bt-active:rgba(119,119,119,.17);--bt-card:#ffffff;--bt-accent:#4d6bfe;--bt-green:#00c972;--bt-star:#ff9800;--bt-user:#070707;--bt-user-ink:#fcfcfc;--bt-tag-bg:rgba(20,20,20,.06);--bt-tag-ink:rgba(20,20,20,.56);--bt-knob:#ffffff;-webkit-tap-highlight-color:transparent;-webkit-text-size-adjust:100%}
/* iOS waits out a double-tap zoom on buttons; the plugin's own controls never zoom. */
@@ -2461,10 +2459,6 @@ body[data-bt-motion=quiet] .bt-mark[data-poke]{cursor:default}
.bt-rail{align-items:center;padding:0 0 8px}
.bt-rail .bt-row{justify-content:center;padding:6px 0;min-height:44px}
.bt-side-foot{display:flex;padding-top:8px}
-.bt-connect{flex:1;height:36px;border-radius:999px;border:1px solid var(--bt-line);background:var(--bt-main);color:var(--bt-ink);font-family:inherit;font-size:14px;line-height:20px;cursor:pointer;display:flex;align-items:center;justify-content:center;gap:8px;transition:background-color .12s ease}
-.bt-connect:hover{background:var(--bt-hover)}
-.bt-connect svg{flex:none;width:15px;height:15px}
-.bt-connect-wrap{position:relative;display:flex;flex:1 1 auto;min-width:0}
.bt-head{position:relative;display:flex;justify-content:center;align-items:center;height:40px;flex:none;pointer-events:none}
.bt-pill{pointer-events:auto;display:inline-flex;align-items:center;gap:8px;height:40px;padding:7.5px 13.5px 7.5px 7.5px;border-radius:999px;background:var(--bt-main);border:.5px solid var(--bt-line-2);box-shadow:0 2px 8px -1px rgba(0,0,0,.06),0 1px 2px rgba(0,0,0,.04);color:var(--bt-ink);font-family:inherit;font-size:14px;line-height:20px;cursor:pointer;max-width:70%;box-sizing:border-box;transition:background-color .12s ease,transform ${SPRING_TAP.duration}ms ${SPRING_TAP.easing}}
@@ -2861,21 +2855,17 @@ button.bt-set-row:hover{background:var(--bt-hover)}
html:not([data-windows-titlebar]) :not([class*="_collapsed"])>[class*="_logoRow"]{display:none!important}
html[data-windows-titlebar] :not([class*="_collapsed"])>[class*="_logoRow"]{height:0!important;margin:0!important}
html[data-windows-titlebar] .bt-side-collapse,html[data-platform=darwin] .bt-side-collapse{display:none}
-/* The footer ends in the Bot row: the whale's settings seat, then Connect plugins. Every
- other plugin's entry takes a whole row above it, in the shell's order, so none of them
- squeezes the Bot row. */
+/* The footer ends in the Bot row: the whale's settings seat, then the account menu
+ when no plugin holds that seat. Every other plugin's entry takes a whole row above
+ it, in the shell's order, so none of them squeezes the Bot row. */
[class*="_footArea"]{grid-template-columns:auto minmax(0,1fr);grid-auto-flow:row dense;align-items:center;gap:4px 9px;padding:8px 6px 6px!important}
/* DSH hides the footer of a collapsed sidebar under a Windows title bar; the grid
stays out of that one place. */
html:not([data-windows-titlebar]) [class*="_footArea"],:not([class*="_collapsed"])>[class*="_footArea"]{display:grid!important}
[class*="_footArea"]>[class*="_footerActions"],[class*="_footArea"]>[class*="_footerActions"]>div{display:contents!important}
[class*="_footArea"]>[class*="_footerActions"]>div>*{grid-column:1/-1}
-[class*="_footArea"]>[class*="_footerActions"]>div>.bt-connect-wrap{grid-column:2;order:1}
[class*="_footArea"]>[class*="_settingsArea"]{grid-column:1;order:1;width:auto!important}
[class*="_footArea"] button[aria-label="Settings"]{width:auto!important;padding:0!important;background:none!important;border-radius:50%!important;height:auto!important}
-${SKIN_FOOT}{display:flex!important;flex-direction:row!important;align-items:center!important;gap:9px!important}
-${SKIN_FOOT}>div:has(> [data-slot="sidebar.footer.action"]){display:flex!important;align-items:center!important;flex:1 1 auto!important;min-width:0!important}
-${SKIN_FOOT}>div:has(> [data-slot="sidebar.settings"]){order:-1!important;flex:none!important;width:auto!important}
[class*="_widthHandle"]{display:none!important}
.bt-voice-pane{flex-direction:column;align-items:center;justify-content:center;animation:bt-fade .2s ease-out}
@@ -2945,7 +2935,6 @@ body[data-bt-layout=flat] .bt-tools::after{display:none}
.bt-you{width:36px;height:36px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;background:color-mix(in srgb,var(--bt-ink) 5%,var(--bt-sidebar));color:var(--bt-ink-2);box-shadow:inset 0 0 0 1px var(--bt-line);transition:background-color .12s ease}
button:hover .bt-you{background:color-mix(in srgb,var(--bt-ink) 9%,var(--bt-sidebar))}
.bt-you-wrap{display:inline-flex;padding:0}
-.bt-connect-foot{width:100%;height:36px}
.bt-menu{position:fixed;pointer-events:auto;z-index:60;min-width:200px;padding:6px;border-radius:12px;background:var(--bt-main);border:.5px solid var(--bt-line-2);box-shadow:0 10px 20px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1),0 0 0 1px rgba(228,228,228,.04);display:flex;flex-direction:column;gap:2px;transform-origin:var(--bt-origin,top left);animation:bt-pop-drop ${SPRING_TAP.duration}ms ${SPRING_TAP.easing},bt-veil-in .14s ease-out;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",system-ui,sans-serif;box-sizing:border-box}
.bt-menu button{display:flex;align-items:center;gap:4px;width:100%;min-height:30px;text-align:left;border:0;background:none;border-radius:6px;padding:6px 8px;font:inherit;font-size:13px;line-height:18px;color:var(--bt-ink);cursor:pointer;box-sizing:border-box}
@@ -8702,23 +8691,6 @@ function UpdateButton({ useUpdate, actions }) {
), document.body) : null
);
}
-function ConnectPlugins({ wide, actions }) {
- if (!wide) return null;
- return (0, import_react14.createElement)(
- "span",
- { className: "bt-connect-wrap" },
- (0, import_react14.createElement)(
- "button",
- {
- type: "button",
- className: "bt-connect bt-connect-foot",
- onClick: () => actions.selectPanel("plugins")
- },
- (0, import_react14.createElement)(PlugIcon),
- t("Connect plugins")
- )
- );
-}
function YouAvatar() {
return (0, import_react14.createElement)(
"span",
@@ -9010,7 +8982,6 @@ var SIDEBAR_CSS = `
.bt-side .bt-read-only{margin:4px 8px 6px;padding:8px 10px;border-radius:10px;background:var(--bt-hover);font-size:12px;line-height:1.45;text-align:left}
[class*="_footArea"]:has(.bt-foot-account){grid-template-columns:auto minmax(0,1fr) auto;column-gap:6px}
[class*="_footArea"]>[class*="_footerActions"]>div>.bt-foot-account{grid-column:1;order:1;display:inline-flex}
-[class*="_footArea"]:has(.bt-foot-account)>[class*="_footerActions"]>div>.bt-connect-wrap{grid-column:2}
[class*="_footArea"]:has(.bt-foot-account)>[class*="_settingsArea"]{grid-column:3}
[class*="_footArea"]:has(.bt-foot-account)>[class*="_settingsArea"] button[class*="_trigger"] [class*="_label"]{display:none!important}
@@ -19452,7 +19423,6 @@ function apply(ctx) {
() => shadow("sidebar.brand.mark", { priority: BOT_PRIORITY }, BrandMark),
() => shadow("sidebar.brand.name", { priority: BOT_PRIORITY }, BrandName),
() => shadow("sidebar.footer.action", { id: "bot-account", order: -200, inject: face }, FooterAccount),
- () => shadow("sidebar.footer.action", { id: "bot-connect", order: -100, inject: face }, ConnectPlugins),
() => shadow("settings.trigger", { priority: BOT_PRIORITY }, YouAvatar),
// The whale wins the seat over a shell account plugin's own launcher (the
// Desktop's "··· More"), which comes back in Agent mode.
diff --git a/ds-bot/src/client/i18n.js b/ds-bot/src/client/i18n.js
index 3eb93caa..c96eccfb 100644
--- a/ds-bot/src/client/i18n.js
+++ b/ds-bot/src/client/i18n.js
@@ -58,7 +58,6 @@ const ZH = {
// Sidebar and account menu
'Bot list': 'Bot 列表',
'Setting up your Main Bot…': '正在设置你的主 Bot…',
- 'Connect plugins': '连接插件',
'Automation tasks': '自动化任务',
Connectors: '连接器',
'Search connectors': '搜索连接器',
diff --git a/ds-bot/src/client/index.js b/ds-bot/src/client/index.js
index 6b8b5589..1049bdf4 100644
--- a/ds-bot/src/client/index.js
+++ b/ds-bot/src/client/index.js
@@ -7,7 +7,7 @@ import { themeCss, shellTokens, registry, registerShape, registerTheme, allTheme
import { MENTION_ORIGIN, currentPart } from './text.js'
import { SHELL_CSS, CONVERSATION_CSS, installStyles, installCompiledStyles } from './styles.js'
import { lookOf } from './mark.js'
-import { TeamSidebar, ConnectPlugins, YouAvatar, AccountLauncher, FooterAccount, BrandMark, BrandName, BotReturn, SIDEBAR_CSS, RETURN_CSS, holdShellShortcuts, openHarnessOnboarding, openHarnessSettings } from './sidebar.js'
+import { TeamSidebar, YouAvatar, AccountLauncher, FooterAccount, BrandMark, BrandName, BotReturn, SIDEBAR_CSS, RETURN_CSS, holdShellShortcuts, openHarnessOnboarding, openHarnessSettings } from './sidebar.js'
import { HeaderPill } from './header.js'
import { ComposerPlus, ComposerVoice, menuIcons } from './composer.js'
import { CHATS_SOURCE, atSources } from './at-menu.js'
@@ -794,7 +794,6 @@ export function apply(ctx) {
() => shadow('sidebar.brand.mark', { priority: BOT_PRIORITY }, BrandMark),
() => shadow('sidebar.brand.name', { priority: BOT_PRIORITY }, BrandName),
() => shadow('sidebar.footer.action', { id: 'bot-account', order: -200, inject: face }, FooterAccount),
- () => shadow('sidebar.footer.action', { id: 'bot-connect', order: -100, inject: face }, ConnectPlugins),
() => shadow('settings.trigger', { priority: BOT_PRIORITY }, YouAvatar),
// The whale wins the seat over a shell account plugin's own launcher (the
// Desktop's "··· More"), which comes back in Agent mode.
diff --git a/ds-bot/src/client/sidebar.js b/ds-bot/src/client/sidebar.js
index b6c7c7a1..ef6e20f7 100644
--- a/ds-bot/src/client/sidebar.js
+++ b/ds-bot/src/client/sidebar.js
@@ -3,7 +3,7 @@ import { createPortal } from 'react-dom'
import { FishLogo } from './dsh-primitives.js'
import { isMainOf } from './sources.js'
import { currentPart, previewOf, relativeShort } from './text.js'
-import { PlusIcon, SearchIcon, SidebarIcon, GaugeIcon, PlugIcon, ClockIcon, GearIcon, PinMarkIcon, ConnectorIcon, SwitchIcon, CloudDownloadIcon, SignOutIcon } from './icons.js'
+import { PlusIcon, SearchIcon, SidebarIcon, GaugeIcon, ClockIcon, GearIcon, PinMarkIcon, ConnectorIcon, SwitchIcon, CloudDownloadIcon, SignOutIcon } from './icons.js'
import { MAIN_LOOK } from './characters.js'
import { botState, BotMark, BotAvatar, RoomAvatar } from './mark.js'
import { reducedMotion } from './activity-row.js'
@@ -413,17 +413,6 @@ function UpdateButton({ useUpdate, actions }) {
}, dshPhase === 'installing' ? t('Updating…') : dshPhase === 'failed' ? t('Try again') : t('Update')))) : null), document.body) : null)
}
-// The footer entry to the shell's plugin panel.
-export function ConnectPlugins({ wide, actions }) {
- if (!wide) return null
- return h('span', { className: 'bt-connect-wrap' },
- h('button', {
- type: 'button', className: 'bt-connect bt-connect-foot',
- onClick: () => actions.selectPanel('plugins'),
- },
- h(PlugIcon), t('Connect plugins')))
-}
-
// Account seat of the Settings trigger: the visible label stays for assistive tech only.
export function YouAvatar() {
return h('span', { className: 'bt-you-wrap' },
@@ -669,9 +658,9 @@ export function BrandName() {
return h('span', { style: { fontWeight: 600, fontSize: 14 } }, 'DS Bot')
}
-// With the whale holding the settings seat, the Bot row is just the account menu
-// and Connect plugins; FooterAccount only shows when the seat went to no one. The
-// shell's footer classes are CSS-module names, so they match on their stems.
+// With the whale holding the settings seat, the Bot row is just the account menu;
+// FooterAccount only shows when the seat went to no one. The shell's footer classes
+// are CSS-module names, so they match on their stems.
export const SIDEBAR_CSS = `
.bt-confirm{width:260px;max-width:72vw;padding:10px 12px 12px;display:flex;flex-direction:column;gap:10px}
.bt-confirm-text{margin:0;font-size:13px;line-height:19px;color:var(--bt-ink-2)}
@@ -690,7 +679,6 @@ export const SIDEBAR_CSS = `
.bt-side .bt-read-only{margin:4px 8px 6px;padding:8px 10px;border-radius:10px;background:var(--bt-hover);font-size:12px;line-height:1.45;text-align:left}
[class*="_footArea"]:has(.bt-foot-account){grid-template-columns:auto minmax(0,1fr) auto;column-gap:6px}
[class*="_footArea"]>[class*="_footerActions"]>div>.bt-foot-account{grid-column:1;order:1;display:inline-flex}
-[class*="_footArea"]:has(.bt-foot-account)>[class*="_footerActions"]>div>.bt-connect-wrap{grid-column:2}
[class*="_footArea"]:has(.bt-foot-account)>[class*="_settingsArea"]{grid-column:3}
[class*="_footArea"]:has(.bt-foot-account)>[class*="_settingsArea"] button[class*="_trigger"] [class*="_label"]{display:none!important}
diff --git a/ds-bot/src/client/styles.js b/ds-bot/src/client/styles.js
index 94125e68..393e44d8 100644
--- a/ds-bot/src/client/styles.js
+++ b/ds-bot/src/client/styles.js
@@ -6,11 +6,6 @@ import { SPRING_SHAPE, SPRING_TAP, SPRING_STRETCH, SPRING_POP, spring } from './
// The pill stretches for "Memory updated" on SPRING_STRETCH, and its icon pops on
// SPRING_POP; it closes on SPRING_SHAPE.
-// A sidebar skin may seat DSH's footer outlets in a footer of its own; matching the
-// outlets keeps that footer on one row whatever the skin names its boxes. The shell's
-// own footer is left to the _footArea rules, which lay it out differently.
-const SKIN_FOOT = ':is(div,footer):not([class*="_footArea"]):has(> div > [data-slot="sidebar.footer.action"] > .bt-connect-wrap)'
-
// The base styles split the way the surface groups do. SHELL_CSS carries the marks,
// the Bot sidebar, every overlay, and the shell chrome they reshape; markup shared
// with the overlays (the exchange dialog reuses bubbles, the Secrets page reuses
@@ -147,10 +142,6 @@ body[data-bt-motion=quiet] .bt-mark[data-poke]{cursor:default}
.bt-rail{align-items:center;padding:0 0 8px}
.bt-rail .bt-row{justify-content:center;padding:6px 0;min-height:44px}
.bt-side-foot{display:flex;padding-top:8px}
-.bt-connect{flex:1;height:36px;border-radius:999px;border:1px solid var(--bt-line);background:var(--bt-main);color:var(--bt-ink);font-family:inherit;font-size:14px;line-height:20px;cursor:pointer;display:flex;align-items:center;justify-content:center;gap:8px;transition:background-color .12s ease}
-.bt-connect:hover{background:var(--bt-hover)}
-.bt-connect svg{flex:none;width:15px;height:15px}
-.bt-connect-wrap{position:relative;display:flex;flex:1 1 auto;min-width:0}
.bt-head{position:relative;display:flex;justify-content:center;align-items:center;height:40px;flex:none;pointer-events:none}
.bt-pill{pointer-events:auto;display:inline-flex;align-items:center;gap:8px;height:40px;padding:7.5px 13.5px 7.5px 7.5px;border-radius:999px;background:var(--bt-main);border:.5px solid var(--bt-line-2);box-shadow:0 2px 8px -1px rgba(0,0,0,.06),0 1px 2px rgba(0,0,0,.04);color:var(--bt-ink);font-family:inherit;font-size:14px;line-height:20px;cursor:pointer;max-width:70%;box-sizing:border-box;transition:background-color .12s ease,transform ${SPRING_TAP.duration}ms ${SPRING_TAP.easing}}
@@ -547,21 +538,17 @@ button.bt-set-row:hover{background:var(--bt-hover)}
html:not([data-windows-titlebar]) :not([class*="_collapsed"])>[class*="_logoRow"]{display:none!important}
html[data-windows-titlebar] :not([class*="_collapsed"])>[class*="_logoRow"]{height:0!important;margin:0!important}
html[data-windows-titlebar] .bt-side-collapse,html[data-platform=darwin] .bt-side-collapse{display:none}
-/* The footer ends in the Bot row: the whale's settings seat, then Connect plugins. Every
- other plugin's entry takes a whole row above it, in the shell's order, so none of them
- squeezes the Bot row. */
+/* The footer ends in the Bot row: the whale's settings seat, then the account menu
+ when no plugin holds that seat. Every other plugin's entry takes a whole row above
+ it, in the shell's order, so none of them squeezes the Bot row. */
[class*="_footArea"]{grid-template-columns:auto minmax(0,1fr);grid-auto-flow:row dense;align-items:center;gap:4px 9px;padding:8px 6px 6px!important}
/* DSH hides the footer of a collapsed sidebar under a Windows title bar; the grid
stays out of that one place. */
html:not([data-windows-titlebar]) [class*="_footArea"],:not([class*="_collapsed"])>[class*="_footArea"]{display:grid!important}
[class*="_footArea"]>[class*="_footerActions"],[class*="_footArea"]>[class*="_footerActions"]>div{display:contents!important}
[class*="_footArea"]>[class*="_footerActions"]>div>*{grid-column:1/-1}
-[class*="_footArea"]>[class*="_footerActions"]>div>.bt-connect-wrap{grid-column:2;order:1}
[class*="_footArea"]>[class*="_settingsArea"]{grid-column:1;order:1;width:auto!important}
[class*="_footArea"] button[aria-label="Settings"]{width:auto!important;padding:0!important;background:none!important;border-radius:50%!important;height:auto!important}
-${SKIN_FOOT}{display:flex!important;flex-direction:row!important;align-items:center!important;gap:9px!important}
-${SKIN_FOOT}>div:has(> [data-slot="sidebar.footer.action"]){display:flex!important;align-items:center!important;flex:1 1 auto!important;min-width:0!important}
-${SKIN_FOOT}>div:has(> [data-slot="sidebar.settings"]){order:-1!important;flex:none!important;width:auto!important}
[class*="_widthHandle"]{display:none!important}
.bt-voice-pane{flex-direction:column;align-items:center;justify-content:center;animation:bt-fade .2s ease-out}
@@ -631,7 +618,6 @@ body[data-bt-layout=flat] .bt-tools::after{display:none}
.bt-you{width:36px;height:36px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;background:color-mix(in srgb,var(--bt-ink) 5%,var(--bt-sidebar));color:var(--bt-ink-2);box-shadow:inset 0 0 0 1px var(--bt-line);transition:background-color .12s ease}
button:hover .bt-you{background:color-mix(in srgb,var(--bt-ink) 9%,var(--bt-sidebar))}
.bt-you-wrap{display:inline-flex;padding:0}
-.bt-connect-foot{width:100%;height:36px}
.bt-menu{position:fixed;pointer-events:auto;z-index:60;min-width:200px;padding:6px;border-radius:12px;background:var(--bt-main);border:.5px solid var(--bt-line-2);box-shadow:0 10px 20px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1),0 0 0 1px rgba(228,228,228,.04);display:flex;flex-direction:column;gap:2px;transform-origin:var(--bt-origin,top left);animation:bt-pop-drop ${SPRING_TAP.duration}ms ${SPRING_TAP.easing},bt-veil-in .14s ease-out;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",system-ui,sans-serif;box-sizing:border-box}
.bt-menu button{display:flex;align-items:center;gap:4px;width:100%;min-height:30px;text-align:left;border:0;background:none;border-radius:6px;padding:6px 8px;font:inherit;font-size:13px;line-height:18px;color:var(--bt-ink);cursor:pointer;box-sizing:border-box}
diff --git a/ds-bot/test/account-sign-out.test.js b/ds-bot/test/account-sign-out.test.js
index 4c3403e5..2908c8de 100644
--- a/ds-bot/test/account-sign-out.test.js
+++ b/ds-bot/test/account-sign-out.test.js
@@ -54,7 +54,7 @@ const textOf = (node) => {
// `status` is what the account plugin's snapshot reports; `running` is what its
// hasRunningAccountTasks answers (or throws); `fail` makes signOut reject.
-function launcher({ status = 'credential-stored', running = false, runningError = false, fail = '', withEntry = true } = {}) {
+function launcher({ status = 'credential-stored', running = false, runningError = false, fail = '', withEntry = true, actions = {} } = {}) {
const calls = []
slots.length = 0
const ops = {
@@ -68,6 +68,7 @@ function launcher({ status = 'credential-stored', running = false, runningError
signInEntry: () => ((typeof withEntry === 'function' ? withEntry() : withEntry) ? { inject: () => ops } : null),
accountT: () => key => `acc:${key}`,
reportError: () => {},
+ ...actions,
},
}
const render = () => { cursor = 0; return AccountLauncher(props) }
@@ -157,3 +158,14 @@ test('cancel closes the confirm without signing out', async () => {
assert.equal(walk(tree, node => node.props?.className === 'bt-confirm').length, 0)
assert.deepEqual(side.calls, ['hasRunningAccountTasks'])
})
+
+// #452: the Connect plugins button left the Bot footer; the account menu that
+// stays keeps the way into the connectors and the automation panel.
+test('the account menu opens the connectors and the automation panel', () => {
+ const calls = []
+ const side = launcher({ actions: { openConnectors: () => calls.push('connectors'), selectPanel: id => calls.push(id) } })
+ const menu = side.open()
+ side.item(menu, 'Connectors').props.onClick()
+ side.item(menu, 'Automation tasks').props.onClick()
+ assert.deepEqual(calls, ['connectors', 'schedules'])
+})
diff --git a/ds-bot/test/sidebar-switch.test.js b/ds-bot/test/sidebar-switch.test.js
index af4a499e..c2f03db4 100644
--- a/ds-bot/test/sidebar-switch.test.js
+++ b/ds-bot/test/sidebar-switch.test.js
@@ -2,6 +2,7 @@ import { test } from 'node:test'
import assert from 'node:assert/strict'
import { createRequire } from 'node:module'
import { dirname, join } from 'node:path'
+import { readFileSync } from 'node:fs'
import { fileURLToPath } from 'node:url'
import { runInNewContext } from 'node:vm'
import { build } from 'esbuild'
@@ -375,3 +376,36 @@ test('the shell footer is a grid wherever the shell shows it', () => {
}
}
})
+
+// #452: the footer lost its Connect plugins button; the account menu and the
+// entries other plugins add keep the places they had.
+test('the Bot footer lays out the account, another plugin\'s entry and the settings trigger', () => {
+ const html = `<!doctype html><html><body><div class="x_root"><div class="x_footArea">
+ <div class="x_footerActions">
+ <div><span class="bt-foot-account"></span></div>
+ <div><span class="x_other-plugin"></span></div>
+ </div>
+ <div class="x_settingsArea"><button class="x_trigger"><span class="x_label">Settings</span></button></div>
+ </div></div></body></html>`
+ const { document } = new JSDOM(html).window
+ // The last rule that places a node is the one that counts, as in the cascade.
+ const columnOf = node => {
+ const placed = rules.filter(rule => node.matches(rule.selector) && /grid-column:/.test(rule.body))
+ assert.ok(placed.length > 0, `no grid placement for ${node.className}`)
+ return placed[placed.length - 1].body.match(/grid-column:([^;]+)/)[1]
+ }
+ // The account menu keeps the left of the row.
+ assert.equal(columnOf(document.querySelector('.bt-foot-account')), '1')
+ // Another plugin's entry takes a row of its own, above the Bot row.
+ assert.equal(columnOf(document.querySelector('.x_other-plugin')), '1/-1')
+ // The settings trigger keeps the right of the row.
+ assert.equal(columnOf(document.querySelector('.x_settingsArea')), '3')
+})
+
+// #452: the Connect plugins button left the footer; what DS Bot puts there is
+// the account menu and the way back from Agent mode.
+test('the Bot footer holds the account and the return button only', () => {
+ const source = readFileSync(new URL('../src/client/index.js', import.meta.url), 'utf8')
+ const ids = [...source.matchAll(/shadow\('sidebar\.footer\.action',\s*\{[^}]*?id:\s*['"]([^'"]+)['"]/g)].map(match => match[1])
+ assert.deepEqual(ids.sort(), ['bot-account', 'bot-return'])
+})