@foldspace_npm/harness 0.1.18 → 0.1.19
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/bin/attach.mjs +8 -5
- package/package.json +1 -1
package/bin/attach.mjs
CHANGED
|
@@ -223,9 +223,12 @@ const SDK_PATTERNS = [
|
|
|
223
223
|
|
|
224
224
|
// The badge has three states, set from outside with \`foldspace badge\`:
|
|
225
225
|
// label - the small corner tag (default): who is attached, which mode
|
|
226
|
-
// working - a
|
|
227
|
-
// please leave it alone
|
|
228
|
-
// ready -
|
|
226
|
+
// working - a pill at the foot of the window: the agent is building in this
|
|
227
|
+
// window, please leave it alone
|
|
228
|
+
// ready - the same pill: it is the human's turn, with the question to try
|
|
229
|
+
// The pill sits bottom-left, never across the top: a bar there covered the
|
|
230
|
+
// app's own header and menu (seen on a CRM, 2026-09-22). The agent's panel
|
|
231
|
+
// is on the right, so bottom-left is the corner nothing else uses.
|
|
229
232
|
// The state lives in sessionStorage so it survives navigation inside the
|
|
230
233
|
// test window; \`foldspace badge\` writes it and the script redraws.
|
|
231
234
|
const badgeSrc = `(() => {
|
|
@@ -249,7 +252,7 @@ const badgeSrc = `(() => {
|
|
|
249
252
|
if (s.state === "working") {
|
|
250
253
|
// Attention, not decoration: a pulsing marker, the ask in bold, and an
|
|
251
254
|
// animated line underneath so it reads as "in progress" at a glance.
|
|
252
|
-
b.style.cssText = base + "right:
|
|
255
|
+
b.style.cssText = base + "top:auto;bottom:16px;left:16px;right:auto;max-width:min(560px,calc(100vw - 32px));border-radius:8px;overflow:hidden;background:#1F2A8A;padding:10px 14px 13px;font-size:13px;letter-spacing:.02em;text-align:left;line-height:1.3;";
|
|
253
256
|
b.innerHTML =
|
|
254
257
|
'<style>@keyframes fsPulse{0%,100%{opacity:1}50%{opacity:.25}}@keyframes fsSweep{0%{left:-30%}100%{left:100%}}' +
|
|
255
258
|
'#foldspace-dev-badge .fs-dot{display:inline-block;width:10px;height:10px;border-radius:50%;background:#FFB300;margin-right:10px;vertical-align:middle;animation:fsPulse 1s ease-in-out infinite}' +
|
|
@@ -263,7 +266,7 @@ const badgeSrc = `(() => {
|
|
|
263
266
|
// retypes it into the panel. The bar accepts clicks only on that button.
|
|
264
267
|
const esc = (t) => String(t).replace(/[<>&"]/g, (c) => ({ "<": "<", ">": ">", "&": "&", '"': """ })[c]);
|
|
265
268
|
const question = s.text ? esc(s.text) : "";
|
|
266
|
-
b.style.cssText = base + "right:
|
|
269
|
+
b.style.cssText = base + "top:auto;bottom:16px;left:16px;right:auto;max-width:min(560px,calc(100vw - 32px));border-radius:8px;overflow:hidden;background:#0F9D58;padding:10px 14px;font-size:13px;letter-spacing:.02em;text-align:left;line-height:1.3;pointer-events:none;";
|
|
267
270
|
b.innerHTML =
|
|
268
271
|
'<style>#foldspace-dev-badge .fs-copy{pointer-events:auto;margin-left:12px;padding:4px 10px;border:1px solid rgba(255,255,255,.7);border-radius:4px;background:transparent;color:#fff;font:inherit;font-size:12px;cursor:pointer;letter-spacing:0}' +
|
|
269
272
|
'#foldspace-dev-badge .fs-copy:hover{background:rgba(255,255,255,.15)}</style>' +
|