feat(web): ask before sending analytics, drop team screens, hide v1-absent memory features (P1.3a)
- Analytics are opt-in (decision Q7, ADR-0006). PostHog does not start or capture anything until the user clicks Allow in a first-run dialog that says what is sent. Escape or closing stores nothing and asks again. The existing Privacy & Telemetry toggle in Settings withdraws consent at once. Builds without VITE_POSTHOG_KEY show no dialog and send nothing. - Remove the remaining upsell copy: the /team page with its per-seat price, Stripe and Teams wording in the erase-data dialog, Teams/Enterprise hints. - Remove team screens (decision Q3): Waggle Dance, team presence in chat, team storage and sharing in workspace creation, storage and files. - Hide memory features that are not in v1 (decision Q2) behind one map in lib/memory-features.ts: the knowledge graph, import history, wiki, agent memory hooks and Room launches. The map is the seam P1.5 fills from the memory store's capabilities. - Say Windows, macOS and Linux instead of "Linux soon". - Update the e2e specs for the removed and hidden screens. Also logs UF-029: the Settings "Import Data" button has no handler.
This commit is contained in:
@@ -217,21 +217,6 @@ const PERSONAS: PersonaBundle[] = [
|
||||
],
|
||||
expected: /360 events|Used bulk_tool_000/i,
|
||||
},
|
||||
{
|
||||
id: 'wiki-export-obsidian-failure',
|
||||
path: '/memory?tab=wiki',
|
||||
action: 'wiki-export-obsidian-failure',
|
||||
mocks: [
|
||||
{ url: '**/api/wiki/pages', status: 200, body: wikiPages() },
|
||||
{
|
||||
url: '**/api/wiki/export/obsidian',
|
||||
status: 500,
|
||||
body: { error: 'Disk permission denied for C:/Research Vault' },
|
||||
},
|
||||
],
|
||||
expected: /Export Failed|Disk permission denied for C:\/Research Vault/i,
|
||||
expectedConsoleErrors: [/Failed to load resource: the server responded with a status of 500/i],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -366,7 +351,6 @@ const PERSONAS: PersonaBundle[] = [
|
||||
nonMainGateDecisions: ['T13/T14/T15 evidenced or explicitly deferred for launch, desktop, and admin/utility paths.'],
|
||||
routes: [
|
||||
{ id: 'vault', path: '/settings/vault', expected: /vault|secret|encrypted|key/i },
|
||||
{ id: 'team', path: '/team', expected: /team|governance|permission|member|upgrade/i },
|
||||
{ id: 'approvals', path: '/approvals', expected: /approval|pending|risk|agent/i },
|
||||
],
|
||||
failureProbes: [
|
||||
@@ -696,19 +680,6 @@ function largeMemoryList(count = 200): unknown {
|
||||
};
|
||||
}
|
||||
|
||||
function wikiPages(): unknown[] {
|
||||
return [{
|
||||
slug: 'research-guide',
|
||||
pageType: 'entity',
|
||||
name: 'Research Guide',
|
||||
contentHash: 'hash-research-guide',
|
||||
markdown: '# Research Guide\n\nField notes for the Researcher judge export-failure lane.',
|
||||
frameIds: 'memory-1',
|
||||
compiledAt: '2026-07-09T12:00:00.000Z',
|
||||
sourceCount: 3,
|
||||
}];
|
||||
}
|
||||
|
||||
function approvalGrants(): unknown[] {
|
||||
return [{
|
||||
id: 'grant-send-email',
|
||||
|
||||
@@ -69,7 +69,6 @@ async function openCurrentApp(page: Page, label: string) {
|
||||
Timeline: '/settings/timeline',
|
||||
'Usage & Cost': '/settings/usage',
|
||||
'Events & Logs': '/settings/events',
|
||||
'Team Governance': '/team',
|
||||
'Skills Hub': '/skills',
|
||||
'Connector Hub': '/connectors',
|
||||
'MCP Hub': '/mcps',
|
||||
@@ -263,7 +262,6 @@ const ZONE_APPS = [
|
||||
{ label: 'Timeline', zone: 'System', expect: /timeline|activity|no.*activity|last/i },
|
||||
{ label: 'Usage & Cost', zone: 'System', expect: /usage|telemetry|token|cost/i },
|
||||
{ label: 'Events & Logs', zone: 'System', expect: /event|log|step|filter/i },
|
||||
{ label: 'Team Governance', zone: 'Team', expect: /governance|role|team|permission/i },
|
||||
{ label: 'Skills Hub', zone: 'Intelligence', expect: /skill|installed|marketplace|starter|build/i },
|
||||
{ label: 'Connector Hub', zone: 'Extend', expect: /connector|connect|service|integration/i },
|
||||
{ label: 'MCP Hub', zone: 'Extend', expect: /mcp|installed|catalog|server/i },
|
||||
|
||||
@@ -76,7 +76,9 @@ test.describe('Launcher rendered states', () => {
|
||||
await expect(page.getByText(/sidecar may be offline/i)).not.toBeVisible();
|
||||
});
|
||||
|
||||
test('long hook stderr is summarized instead of flooding the rendered panel', async ({ page }) => {
|
||||
// Agent memory hooks are hidden in v1 by the memory feature map (ADR-0002,
|
||||
// apps/web/src/lib/memory-features.ts). Re-enable with the agentHooks feature.
|
||||
test.skip('long hook stderr is summarized instead of flooding the rendered panel', async ({ page }) => {
|
||||
await mockProcesses(page);
|
||||
await page.route('**/api/tools/detect', route => route.fulfill({
|
||||
status: 200,
|
||||
@@ -134,7 +136,9 @@ test.describe('Launcher rendered states', () => {
|
||||
await expect(page.getByText('Recovery')).toBeVisible();
|
||||
});
|
||||
|
||||
test('standard hook install output renders changed file, pointer, backup, and recovery labels', async ({ page }) => {
|
||||
// Agent memory hooks are hidden in v1 by the memory feature map (ADR-0002,
|
||||
// apps/web/src/lib/memory-features.ts). Re-enable with the agentHooks feature.
|
||||
test.skip('standard hook install output renders changed file, pointer, backup, and recovery labels', async ({ page }) => {
|
||||
await mockProcesses(page);
|
||||
await page.route('**/api/tools/detect', route => route.fulfill({
|
||||
status: 200,
|
||||
@@ -192,7 +196,9 @@ test.describe('Launcher rendered states', () => {
|
||||
await expect(page.getByText(/hive-mind\/codex-hooks: install/i)).not.toBeVisible();
|
||||
});
|
||||
|
||||
test('all hook-capable tools render install, verify, and uninstall state transitions', async ({ page }) => {
|
||||
// Agent memory hooks are hidden in v1 by the memory feature map (ADR-0002,
|
||||
// apps/web/src/lib/memory-features.ts). Re-enable with the agentHooks feature.
|
||||
test.skip('all hook-capable tools render install, verify, and uninstall state transitions', async ({ page }) => {
|
||||
const hookState = new Map(HOOK_RENDER_CASES.map(tool => [tool.id, false]));
|
||||
|
||||
await mockProcesses(page);
|
||||
@@ -312,8 +318,9 @@ test.describe('Launcher rendered states', () => {
|
||||
await expect(page.getByText('Foo CLI', { exact: true })).toBeVisible();
|
||||
await expect(page.getByText(/v2\.1\.0/i)).toBeVisible();
|
||||
await expect(page.getByText(/Sent to:/i)).not.toBeVisible();
|
||||
await expect(page.getByText(/Launch only/i)).toBeVisible();
|
||||
await expect(page.getByText(/Hook management is not supported for this tool yet/i)).toBeVisible();
|
||||
// Hooks are hidden in v1 (ADR-0002), so there is no "launch only" contrast.
|
||||
await expect(page.getByText(/Launch only/i)).not.toBeVisible();
|
||||
await expect(page.getByText(/Hook management is not supported for this tool yet/i)).not.toBeVisible();
|
||||
await expect(page.getByRole('button', { name: /^Launch$/ })).toBeVisible();
|
||||
await expect(page.getByRole('button', { name: /install hooks/i })).not.toBeVisible();
|
||||
await expect(page.getByRole('button', { name: /^Verify$/ })).not.toBeVisible();
|
||||
|
||||
@@ -486,8 +486,8 @@ test.describe('10. Fresh User Onboarding', () => {
|
||||
await onboarding.getByRole('button', { name: /continue/i }).click();
|
||||
await onboarding.getByRole('button', { name: /continue/i }).click();
|
||||
await expect(onboarding.getByRole('button', { name: /continue/i })).toBeEnabled({ timeout: 10_000 });
|
||||
// History import is hidden in v1 (ADR-0002): the model step leads straight to templates.
|
||||
await onboarding.getByRole('button', { name: /continue/i }).click();
|
||||
await onboarding.getByRole('button', { name: /skip this step/i }).click();
|
||||
|
||||
await expect(page.getByText(/Research Hub|Engineering|Sales Pipeline/i).first()).toBeVisible({ timeout: 5_000 });
|
||||
});
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { expect, test, type APIRequestContext, type Page } from '@playwright/test';
|
||||
import { expect, test, type Page } from '@playwright/test';
|
||||
import { readFileSync } from 'node:fs';
|
||||
import { createRequire } from 'node:module';
|
||||
|
||||
@@ -27,10 +27,7 @@ const ROUTES = [
|
||||
'/memory?tab=trust',
|
||||
'/memory?tab=memories',
|
||||
'/memory?tab=timeline',
|
||||
'/memory?tab=graph',
|
||||
'/memory?tab=harvest',
|
||||
'/memory?tab=weaver',
|
||||
'/memory?tab=wiki',
|
||||
'/workspaces',
|
||||
'/workspaces/default-workspace/chat',
|
||||
'/workspaces/default-workspace/tasks',
|
||||
@@ -38,7 +35,6 @@ const ROUTES = [
|
||||
'/automations',
|
||||
'/skills',
|
||||
'/room',
|
||||
'/waggle-dance',
|
||||
'/launcher',
|
||||
'/connectors',
|
||||
'/mcps',
|
||||
@@ -46,7 +42,6 @@ const ROUTES = [
|
||||
'/files',
|
||||
'/approvals',
|
||||
'/artifacts',
|
||||
'/team',
|
||||
'/benchmarks',
|
||||
'/platform',
|
||||
] as const;
|
||||
@@ -107,40 +102,25 @@ function formatViolations(violations: AxeViolation[]) {
|
||||
}));
|
||||
}
|
||||
|
||||
async function seedWaggleDanceSignal(request: APIRequestContext) {
|
||||
const response = await request.post('/api/waggle/signals', {
|
||||
data: {
|
||||
type: 'discovery',
|
||||
workspaceId: 'default-workspace',
|
||||
content: 'Accessible signal timestamp',
|
||||
metadata: { senderId: 'runtime-a11y' },
|
||||
},
|
||||
});
|
||||
expect(response.status()).toBe(201);
|
||||
}
|
||||
|
||||
test.describe('Runtime accessibility smoke', () => {
|
||||
test('milestone toast and signal badges have no mobile accessibility violations', async ({ page, request }) => {
|
||||
test('milestone toast has no mobile accessibility violations', async ({ page }) => {
|
||||
await page.setViewportSize({ width: 390, height: 844 });
|
||||
await seedWaggleDanceSignal(request);
|
||||
await page.addInitScript(() => {
|
||||
window.localStorage.setItem('waggle:session-count', '49');
|
||||
window.localStorage.setItem('waggle:dock-nudge-dismissed', '[10]');
|
||||
});
|
||||
|
||||
await gotoApp(page, '/waggle-dance');
|
||||
await gotoApp(page, '/agents');
|
||||
await expect(page.getByText('50 sessions in — nicely done', { exact: true })).toBeVisible();
|
||||
await expect(page.getByRole('button', { name: 'Close notification' })).toHaveCSS('opacity', '1');
|
||||
await expect(page.getByTestId('waggle-unacknowledged-count')).toBeVisible();
|
||||
|
||||
expect(formatViolations(await runAxe(page))).toEqual([]);
|
||||
});
|
||||
|
||||
for (const viewport of VIEWPORTS) {
|
||||
test(`axe has no violations across core routes (${viewport.name})`, async ({ page, request }) => {
|
||||
test(`axe has no violations across core routes (${viewport.name})`, async ({ page }) => {
|
||||
test.setTimeout(150_000);
|
||||
await page.setViewportSize({ width: viewport.width, height: viewport.height });
|
||||
await seedWaggleDanceSignal(request);
|
||||
|
||||
const findings: Array<{ route: string; violations: ReturnType<typeof formatViolations> }> = [];
|
||||
for (const route of ROUTES) {
|
||||
|
||||
@@ -349,7 +349,9 @@ test.describe('User Journey Tests', () => {
|
||||
await expect.poll(() => allowCalled).toBe(true);
|
||||
});
|
||||
|
||||
test('J3g: wiki export destinations use in-app forms', async ({ page }) => {
|
||||
// The wiki is hidden in v1 by the memory feature map (ADR-0002,
|
||||
// apps/web/src/lib/memory-features.ts). Re-enable with the wiki feature.
|
||||
test.skip('J3g: wiki export destinations use in-app forms', async ({ page }) => {
|
||||
const nativeDialogs: string[] = [];
|
||||
let obsidianCalled = false;
|
||||
let notionCalled = false;
|
||||
@@ -898,7 +900,6 @@ test.describe('User Journey Tests', () => {
|
||||
const routeChecks: Array<[string, RegExp]> = [
|
||||
['/launcher', /tool launcher|optional prompt|detecting installed tools|launch/i],
|
||||
['/launcher?watch=1', /tool launcher|optional prompt|detecting installed tools|launch/i],
|
||||
['/waggle-dance', /waggle dance|signals|discovery|handoff/i],
|
||||
['/artifacts', /artifact|library|document|presentation/i],
|
||||
['/settings/profile', /who are you|identity|writing style|save/i],
|
||||
['/settings/timeline', /timeline|workspace|activity/i],
|
||||
|
||||
Reference in New Issue
Block a user