cohvu 2.21.0 → 3.0.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.
Files changed (102) hide show
  1. package/README.md +37 -0
  2. package/cli.js +15501 -0
  3. package/package.json +15 -26
  4. package/dist/__tests__/instruction-file.unit.test.d.ts +0 -1
  5. package/dist/__tests__/instruction-file.unit.test.js +0 -296
  6. package/dist/__tests__/instruction-file.unit.test.js.map +0 -1
  7. package/dist/__tests__/teardown.unit.test.d.ts +0 -1
  8. package/dist/__tests__/teardown.unit.test.js +0 -196
  9. package/dist/__tests__/teardown.unit.test.js.map +0 -1
  10. package/dist/api.d.ts +0 -292
  11. package/dist/api.js +0 -337
  12. package/dist/api.js.map +0 -1
  13. package/dist/auth.d.ts +0 -4
  14. package/dist/auth.js +0 -96
  15. package/dist/auth.js.map +0 -1
  16. package/dist/constants.d.ts +0 -2
  17. package/dist/constants.js +0 -10
  18. package/dist/constants.js.map +0 -1
  19. package/dist/index.d.ts +0 -2
  20. package/dist/index.js +0 -259
  21. package/dist/index.js.map +0 -1
  22. package/dist/instructions.d.ts +0 -33
  23. package/dist/instructions.js +0 -238
  24. package/dist/instructions.js.map +0 -1
  25. package/dist/log.d.ts +0 -6
  26. package/dist/log.js +0 -51
  27. package/dist/log.js.map +0 -1
  28. package/dist/pause.d.ts +0 -3
  29. package/dist/pause.js +0 -24
  30. package/dist/pause.js.map +0 -1
  31. package/dist/platforms.d.ts +0 -22
  32. package/dist/platforms.js +0 -79
  33. package/dist/platforms.js.map +0 -1
  34. package/dist/postinstall.d.ts +0 -2
  35. package/dist/postinstall.js +0 -11
  36. package/dist/postinstall.js.map +0 -1
  37. package/dist/proxy.d.ts +0 -1
  38. package/dist/proxy.js +0 -371
  39. package/dist/proxy.js.map +0 -1
  40. package/dist/setup.d.ts +0 -15
  41. package/dist/setup.js +0 -295
  42. package/dist/setup.js.map +0 -1
  43. package/dist/teardown.d.ts +0 -15
  44. package/dist/teardown.js +0 -235
  45. package/dist/teardown.js.map +0 -1
  46. package/dist/tui/App.d.ts +0 -1
  47. package/dist/tui/App.js +0 -2245
  48. package/dist/tui/App.js.map +0 -1
  49. package/dist/tui/components/Banner.d.ts +0 -4
  50. package/dist/tui/components/Banner.js +0 -71
  51. package/dist/tui/components/Banner.js.map +0 -1
  52. package/dist/tui/components/Divider.d.ts +0 -1
  53. package/dist/tui/components/Divider.js +0 -8
  54. package/dist/tui/components/Divider.js.map +0 -1
  55. package/dist/tui/components/Footer.d.ts +0 -4
  56. package/dist/tui/components/Footer.js +0 -183
  57. package/dist/tui/components/Footer.js.map +0 -1
  58. package/dist/tui/components/Header.d.ts +0 -4
  59. package/dist/tui/components/Header.js +0 -126
  60. package/dist/tui/components/Header.js.map +0 -1
  61. package/dist/tui/components/LockCard.d.ts +0 -17
  62. package/dist/tui/components/LockCard.js +0 -37
  63. package/dist/tui/components/LockCard.js.map +0 -1
  64. package/dist/tui/components/Modal.d.ts +0 -5
  65. package/dist/tui/components/Modal.js +0 -195
  66. package/dist/tui/components/Modal.js.map +0 -1
  67. package/dist/tui/components/TabBar.d.ts +0 -4
  68. package/dist/tui/components/TabBar.js +0 -17
  69. package/dist/tui/components/TabBar.js.map +0 -1
  70. package/dist/tui/components/Toast.d.ts +0 -4
  71. package/dist/tui/components/Toast.js +0 -9
  72. package/dist/tui/components/Toast.js.map +0 -1
  73. package/dist/tui/index.d.ts +0 -1
  74. package/dist/tui/index.js +0 -20
  75. package/dist/tui/index.js.map +0 -1
  76. package/dist/tui/platform-detect.d.ts +0 -2
  77. package/dist/tui/platform-detect.js +0 -79
  78. package/dist/tui/platform-detect.js.map +0 -1
  79. package/dist/tui/state.d.ts +0 -414
  80. package/dist/tui/state.js +0 -397
  81. package/dist/tui/state.js.map +0 -1
  82. package/dist/tui/tabs/BillingTab.d.ts +0 -5
  83. package/dist/tui/tabs/BillingTab.js +0 -72
  84. package/dist/tui/tabs/BillingTab.js.map +0 -1
  85. package/dist/tui/tabs/KeysTab.d.ts +0 -5
  86. package/dist/tui/tabs/KeysTab.js +0 -92
  87. package/dist/tui/tabs/KeysTab.js.map +0 -1
  88. package/dist/tui/tabs/KnowledgeTab.d.ts +0 -5
  89. package/dist/tui/tabs/KnowledgeTab.js +0 -143
  90. package/dist/tui/tabs/KnowledgeTab.js.map +0 -1
  91. package/dist/tui/tabs/ProjectTab.d.ts +0 -5
  92. package/dist/tui/tabs/ProjectTab.js +0 -34
  93. package/dist/tui/tabs/ProjectTab.js.map +0 -1
  94. package/dist/tui/tabs/TeamTab.d.ts +0 -5
  95. package/dist/tui/tabs/TeamTab.js +0 -57
  96. package/dist/tui/tabs/TeamTab.js.map +0 -1
  97. package/dist/tui/tabs/YouTab.d.ts +0 -5
  98. package/dist/tui/tabs/YouTab.js +0 -25
  99. package/dist/tui/tabs/YouTab.js.map +0 -1
  100. package/dist/tui/utils.d.ts +0 -6
  101. package/dist/tui/utils.js +0 -58
  102. package/dist/tui/utils.js.map +0 -1
@@ -1,126 +0,0 @@
1
- import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Box, Text, Spacer, useStdout } from 'ink';
3
- import { getActiveProject, getActiveTeam } from '../state.js';
4
- function truncStr(s, max) {
5
- if (max <= 0)
6
- return '';
7
- if (s.length <= max)
8
- return s;
9
- return s.slice(0, max - 1) + '\u2026';
10
- }
11
- export function Header({ state }) {
12
- const { stdout } = useStdout();
13
- const cols = stdout.columns;
14
- const project = getActiveProject(state);
15
- const team = getActiveTeam(state);
16
- const projectLabel = project
17
- ? team ? `${team.name} / ${project.name}` : project.name
18
- : 'no project';
19
- const statusText = getStatusText(state);
20
- const projectsText = state.projects.length >= 2 ? `${state.projects.length} projects` : '';
21
- const email = state.user?.email ?? '';
22
- const maxProjectLen = Math.max(8, cols - 20 - (statusText ? statusText.length + 5 : 0));
23
- const displayProject = truncStr(projectLabel, maxProjectLen);
24
- const leftUsed = 10 + displayProject.length + (statusText ? 5 + statusText.length : 0) + (projectsText ? 5 + projectsText.length : 0);
25
- const emailSpace = cols - leftUsed - 2;
26
- const displayEmail = emailSpace >= 10 ? truncStr(email, emailSpace) : '';
27
- return (_jsxs(Box, { width: cols, children: [_jsx(Text, { color: "gray", children: "cohvu" }), _jsx(Text, { color: "gray", dimColor: true, children: " \u00B7 " }), _jsx(Text, { dimColor: true, children: displayProject }), renderStatus(state), projectsText ? (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " \u00B7 " }), _jsx(Text, { color: "gray", children: projectsText })] })) : null, _jsx(Spacer, {}), displayEmail ? _jsx(Text, { color: "gray", children: displayEmail }) : null] }));
28
- }
29
- function getUsage(state) {
30
- const project = getActiveProject(state);
31
- if (!project)
32
- return null;
33
- if (project.owner.kind === 'team') {
34
- const team = getActiveTeam(state);
35
- if (team?.usage)
36
- return { used: team.usage.ops_used, limit: team.usage.ops_limit };
37
- return null;
38
- }
39
- if (state.usage)
40
- return { used: state.usage.ops_used, limit: state.usage.ops_limit };
41
- return null;
42
- }
43
- function getPlanLabel(state) {
44
- const project = getActiveProject(state);
45
- if (!project)
46
- return '';
47
- if (project.owner.kind === 'team') {
48
- const team = getActiveTeam(state);
49
- const sub = team?.subscription;
50
- if (sub && (sub.status === 'active' || sub.status === 'past_due'))
51
- return 'team';
52
- return 'free';
53
- }
54
- const sub = state.individualSubscription;
55
- if (sub && (sub.status === 'active' || sub.status === 'past_due'))
56
- return 'pro';
57
- return 'free';
58
- }
59
- function getStatusText(state) {
60
- if (state.paused)
61
- return 'paused';
62
- if (state.offline)
63
- return 'offline';
64
- if (!state.sseConnected && state.activeProjectId) {
65
- // "reconnecting" implies we had a connection and lost it. On fresh
66
- // launch we've never connected yet — the initial stream attempt is
67
- // in flight. Label it as "connecting" so the user isn't alarmed by
68
- // a false "reconnecting" flash during normal startup.
69
- return state.sseEverConnected ? 'reconnecting' : 'connecting';
70
- }
71
- const usage = getUsage(state);
72
- if (!usage)
73
- return '';
74
- const plan = getPlanLabel(state);
75
- if (usage.used >= usage.limit) {
76
- const project = getActiveProject(state);
77
- const isTeam = project?.owner.kind === 'team';
78
- const sub = isTeam ? getActiveTeam(state)?.subscription : state.individualSubscription;
79
- const isActive = sub && (sub.status === 'active' || sub.status === 'past_due');
80
- if (!isActive)
81
- return `${plan} · ${usage.used}/${usage.limit} ops`;
82
- const overflow = usage.used - usage.limit;
83
- return `${plan} · ${formatOps(usage.used)} ops (${formatOps(overflow)} overflow)`;
84
- }
85
- return `${plan} · ${formatOps(usage.used)}/${formatOps(usage.limit)} ops`;
86
- }
87
- function formatOps(n) {
88
- if (n >= 1000)
89
- return `${(n / 1000).toFixed(1).replace(/\.0$/, '')}k`;
90
- return String(n);
91
- }
92
- function renderStatus(state) {
93
- const text = getStatusText(state);
94
- if (!text)
95
- return null;
96
- let color = 'gray';
97
- let dim = true;
98
- if (text === 'paused') {
99
- color = 'yellow';
100
- dim = false;
101
- }
102
- else if (text === 'offline' || text === 'reconnecting' || text === 'connecting') {
103
- color = 'gray';
104
- dim = true;
105
- }
106
- else {
107
- const usage = getUsage(state);
108
- if (usage) {
109
- const ratio = usage.used / usage.limit;
110
- if (ratio >= 1) {
111
- color = 'yellow';
112
- dim = false;
113
- }
114
- else if (ratio >= 0.8) {
115
- color = 'yellow';
116
- dim = true;
117
- }
118
- else {
119
- color = 'gray';
120
- dim = true;
121
- }
122
- }
123
- }
124
- return _jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " \u00B7 " }), _jsx(Text, { color: color, dimColor: dim, children: text })] });
125
- }
126
- //# sourceMappingURL=Header.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Header.js","sourceRoot":"","sources":["../../../src/tui/components/Header.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,KAAK,CAAC;AAEnD,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE9D,S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;YAAC,CAAC;iBACnD,CAAC;gBAAC,KAAK,GAAG,MAAM,CAAC;gBAAC,GAAG,GAAG,IAAI,CAAC;YAAC,CAAC;QACtC,CAAC;IACH,CAAC;IAED,OAAO,8BAAE,KAAC,IAAI,IAAC,KAAK,EAAC,MAAM,EAAC,QAAQ,iCAAa,EAAA,KAAC,IAAI,IAAC,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,GAAG,YAAG,IAAI,GAAQ,IAAG,CAAC;AACvG,CAAC"}
@@ -1,17 +0,0 @@
1
- import type { TeamOverview } from '../../api.js';
2
- export type LockVariant = 'team' | 'downgrade';
3
- interface CommonProps {
4
- height?: number;
5
- label?: string;
6
- }
7
- type Props = CommonProps & ({
8
- variant: 'team';
9
- overview: TeamOverview | null;
10
- isAdmin: boolean;
11
- } | {
12
- variant: 'downgrade';
13
- otherLockedCount: number;
14
- projectName: string;
15
- });
16
- export declare function LockCard(props: Props): import("react/jsx-runtime").JSX.Element;
17
- export {};
@@ -1,37 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
- import { Box, Text } from 'ink';
3
- // A lock panel drawn OVER ghost-rendered contribution shapes. The actual
4
- // substrate is preserved server-side — the TUI renders placeholder blocks
5
- // so the user can see "there's something here, locked" without any real
6
- // data leaving the server. Pay to unlock, every time.
7
- //
8
- // Two variants:
9
- // - 'team' — team subscription canceled. Keybind `r` resubscribes
10
- // the team. Shows admin contacts for non-admin viewers.
11
- // - 'downgrade' — personal Pro canceled. Keybind `u` reactivates Pro
12
- // (single checkout). Unlocks every personal project at
13
- // once, no per-project choice.
14
- const GHOST_ROW_COUNT = 14;
15
- const GHOST_WIDTHS = [62, 45, 58, 40, 52, 71, 38, 55, 48, 63, 42, 50, 60, 35];
16
- function ghostLine(width) {
17
- return '\u2591'.repeat(width);
18
- }
19
- function formatCount(n) {
20
- return n.toLocaleString();
21
- }
22
- export function LockCard(props) {
23
- return (_jsxs(Box, { flexDirection: "column", height: props.height, overflowY: "hidden", children: [_jsx(Box, { height: 1 }), GHOST_WIDTHS.slice(0, GHOST_ROW_COUNT).map((w, i) => (_jsx(Box, { children: _jsxs(Text, { color: "gray", dimColor: true, children: [" ", ghostLine(w)] }) }, i))), _jsx(Box, { height: 1 }), _jsx(Box, { flexDirection: "column", borderStyle: "round", borderColor: "gray", paddingX: 2, paddingY: 1, children: props.variant === 'team' ? _jsx(TeamLockBody, { ...props }) : _jsx(DowngradeLockBody, { ...props }) })] }));
24
- }
25
- function TeamLockBody({ overview, isAdmin, label, }) {
26
- const count = overview?.contribution_count ?? 0;
27
- const contacts = overview?.admin_contacts ?? [];
28
- const teamName = overview?.name ?? 'this team';
29
- return (_jsxs(_Fragment, { children: [_jsxs(Text, { color: "yellow", children: [" ", teamName, " \u00B7 subscription canceled"] }), _jsx(Box, { height: 1 }), _jsxs(Text, { color: "gray", children: [" ", formatCount(count), " contribution", count === 1 ? '' : 's', " preserved."] }), _jsxs(Text, { color: "gray", dimColor: true, children: [" ", label ?? 'The substrate is locked until an admin resubscribes.'] }), isAdmin ? (_jsxs(_Fragment, { children: [_jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " r " }), _jsx(Text, { dimColor: true, children: "resubscribe \u2014 restores everything" })] })] })) : contacts.length > 0 ? (_jsxs(_Fragment, { children: [_jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", dimColor: true, children: " Ask an admin to resubscribe:" }), contacts.slice(0, 3).map((c, i) => (_jsxs(Text, { color: "gray", dimColor: true, children: [" ", c.name, " <", c.email, ">"] }, i)))] })) : (_jsxs(_Fragment, { children: [_jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", dimColor: true, children: " Ask a team admin to resubscribe." })] }))] }));
30
- }
31
- function DowngradeLockBody({ otherLockedCount, projectName, label, }) {
32
- const siblings = otherLockedCount > 0
33
- ? ` Plus ${formatCount(otherLockedCount)} other project${otherLockedCount === 1 ? '' : 's'}.`
34
- : '';
35
- return (_jsxs(_Fragment, { children: [_jsxs(Text, { color: "yellow", children: [" ", projectName, " \u00B7 locked"] }), _jsx(Box, { height: 1 }), _jsxs(Text, { color: "gray", children: [" Your Pro subscription was canceled. This project is preserved.", siblings] }), _jsxs(Text, { color: "gray", dimColor: true, children: [" ", label ?? 'Upgrade to Pro to unlock every personal project and restore integration keys.'] }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " u " }), _jsx(Text, { dimColor: true, children: "upgrade to Pro \u2014 unlocks everything" })] })] }));
36
- }
37
- //# sourceMappingURL=LockCard.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"LockCard.js","sourceRoot":"","sources":["../../../src/tui/components/LockCard.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAGhC,yEAAyE;AACzE,0EAA0E;AAC1E,wEAAwE;AACxE,sDAAsD;AACtD,EAAE;AACF,gBAAgB;AAChB,yEAAyE;AACzE,0EAA0E;AAC1E,uEAAuE;AACvE,yEAAyE;AACzE,iDAAiD;AAEjD,MAAM,eAAe,GAAG,EAAE,CAAC;AAC3B,MAAM,YAAY,GAAG,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;AAE9E,SAAS,SAAS,CAAC,KAAa;IAC9B,OAAO,QAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAChC,CAAC;AAED,SAAS,WAAW,CAAC,CAAS;IAC5B,OAAO,CAAC,CAAC,cAAc,EAAE,CAAC;AAC5B,CAAC;AAsBD,MAAM,UAAU,QAAQ,CAAC,KAAY;IACnC,OAAO,CACL,MAAC,GAAG,IAAC,aAAa,EAAC,QAAQ,EAAC,MAAM,EAAE,KAAK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MAAC,IAAI,IAAC,KAAK,EAAC,QAAQ,mBAAI,WAAW,sBAAiB,EACpD,KAAC,GAAG,IAAC,MAAM,EAAE,CAAC,GAAI,EAClB,MAAC,IAAI,IAAC,KAAK,EAAC,MAAM,iFAAkE,QAAQ,IAAQ,EACpG,MAAC,IAAI,IAAC,KAAK,EAAC,MAAM,EAAC,QAAQ,yBAAI,KAAK,IAAI,+EAA+E,IAAQ,EAC/H,KAAC,GAAG,IAAC,MAAM,EAAE,CAAC,GAAI,EAClB,MAAC,GAAG,eACF,KAAC,IAAI,IAAC,KAAK,EAAC,MAAM,sBAAa,EAC/B,KAAC,IAAI,IAAC,QAAQ,+DAA2C,IACrD,IACL,CACJ,CAAC;AACJ,CAAC"}
@@ -1,5 +0,0 @@
1
- import type { AppState } from '../state.js';
2
- export declare function ModalView({ state, height }: {
3
- state: AppState;
4
- height: number;
5
- }): import("react/jsx-runtime").JSX.Element | null;
@@ -1,195 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
- import React from 'react';
3
- import { Box, Text } from 'ink';
4
- import { ALL_KEY_ACTIONS, filterToSameEntity } from '../state.js';
5
- import { truncate } from '../utils.js';
6
- export function ModalView({ state, height }) {
7
- const modal = state.modal;
8
- if (!modal)
9
- return null;
10
- const pad = Math.floor(height / 4);
11
- return (_jsxs(Box, { flexDirection: "column", children: [Array.from({ length: pad }, (_, i) => _jsx(Box, { height: 1 }, i)), _jsx(ModalContent, { modal: modal, state: state })] }));
12
- }
13
- function ModalContent({ modal, state }) {
14
- switch (modal.kind) {
15
- case 'confirm-remove':
16
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " remove this contribution?" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " \"" }), _jsx(Text, { color: "gray", children: truncate(modal.preview, 60) }), _jsx(Text, { color: "gray", dimColor: true, children: "\"" })] }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " remove? " }), _jsx(Text, { children: "(y/n) _" })] })] }));
17
- case 'confirm-remove-all':
18
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "red", children: " remove all " }), _jsx(Text, { children: String(modal.contributionCount) }), _jsx(Text, { color: "red", children: " contributions from " }), _jsx(Text, { children: modal.slug }), _jsx(Text, { color: "red", children: "?" })] }), _jsx(Text, { color: "gray", children: " project, team, and billing remain intact." }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " type \"" }), _jsx(Text, { dimColor: true, children: modal.slug }), _jsx(Text, { color: "gray", children: "\" to confirm \u203A " }), _jsxs(Text, { children: [modal.input, "_"] })] })] }));
19
- case 'confirm-delete':
20
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "red", children: " permanently delete " }), _jsx(Text, { children: modal.slug }), _jsx(Text, { color: "red", children: " and all " }), _jsx(Text, { children: String(modal.contributionCount) }), _jsx(Text, { color: "red", children: " contributions?" })] }), _jsx(Text, { color: "gray", children: " this cannot be undone." }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " type \"" }), _jsx(Text, { dimColor: true, children: modal.slug }), _jsx(Text, { color: "gray", children: "\" to confirm \u203A " }), _jsxs(Text, { children: [modal.input, "_"] })] })] }));
21
- case 'confirm-clear':
22
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "red", children: " remove all " }), _jsx(Text, { children: String(modal.contributionCount) }), _jsx(Text, { color: "red", children: " contributions from " }), _jsx(Text, { children: modal.slug }), _jsx(Text, { color: "red", children: "?" })] }), _jsx(Text, { color: "gray", children: " project, team, and billing remain intact." }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " type \"" }), _jsx(Text, { dimColor: true, children: modal.slug }), _jsx(Text, { color: "gray", children: "\" to confirm \u203A " }), _jsxs(Text, { children: [modal.input, "_"] })] })] }));
23
- case 'confirm-remove-member': {
24
- const activeProject = state.projects.find(p => p.project_id === state.activeProjectId);
25
- const contextName = activeProject?.owner.kind === 'team'
26
- ? activeProject.owner.teamName
27
- : activeProject?.slug ?? 'the project';
28
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " remove " }), _jsx(Text, { dimColor: true, children: modal.email }), _jsx(Text, { color: "gray", children: " from " }), _jsx(Text, { dimColor: true, children: contextName }), _jsx(Text, { color: "gray", children: "?" })] }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " remove? " }), _jsx(Text, { children: "(y/n) _" })] })] }));
29
- }
30
- case 'confirm-leave': {
31
- const name = state.projects.find(p => p.project_id === state.activeProjectId)?.slug ?? 'this project';
32
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " leave " }), _jsx(Text, { dimColor: true, children: name }), _jsx(Text, { color: "gray", children: "?" })] }), _jsx(Text, { color: "gray", children: " you will lose access immediately." }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " leave? " }), _jsx(Text, { children: "(y/n) _" })] })] }));
33
- }
34
- case 'confirm-logout': {
35
- const email = state.user?.email ?? 'cohvu';
36
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " sign out of " }), _jsx(Text, { dimColor: true, children: email }), _jsx(Text, { color: "gray", children: "?" })] }), _jsx(Box, { height: 1 }), _jsx(Box, { children: _jsx(Text, { dimColor: true, children: " (y/n) _" }) })] }));
37
- }
38
- case 'rename': {
39
- const slug = modal.input.toLowerCase().replace(/[^a-z0-9]+/g, '-').replace(/^-+|-+$/g, '');
40
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " rename project" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " new name \u203A " }), _jsxs(Text, { children: [modal.input, "_"] })] }), _jsxs(Box, { children: [_jsx(Box, { width: 12, children: _jsx(Text, { color: "gray", dimColor: true, children: " slug" }) }), _jsx(Text, { color: "gray", children: slug || '(derived from name)' })] })] }));
41
- }
42
- case 'create-project': {
43
- const slug = modal.input.toLowerCase().replace(/[^a-z0-9]+/g, '-').replace(/^-+|-+$/g, '');
44
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " new project" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " name \u203A " }), _jsx(Text, { children: modal.input || '_' })] }), _jsxs(Box, { children: [_jsx(Box, { width: 10, children: _jsx(Text, { color: "gray", dimColor: true, children: " slug" }) }), _jsx(Text, { color: "gray", children: slug || '(derived from name)' })] })] }));
45
- }
46
- case 'switch-project': {
47
- const projects = state.projects;
48
- const activeId = state.activeProjectId;
49
- const personal = projects.filter(p => p.owner.kind === 'personal');
50
- const teamGroups = new Map();
51
- for (const p of projects) {
52
- if (p.owner.kind === 'team') {
53
- const key = p.owner.teamId;
54
- if (!teamGroups.has(key))
55
- teamGroups.set(key, { teamName: p.owner.teamName, projects: [] });
56
- teamGroups.get(key).projects.push(p);
57
- }
58
- }
59
- let flatIndex = 0;
60
- const rows = [];
61
- if (personal.length > 0) {
62
- rows.push(_jsx(Text, { color: "gray", dimColor: true, children: " personal" }, "ph"));
63
- for (const p of personal) {
64
- const isActive = p.project_id === activeId;
65
- const isSelected = flatIndex === modal.selected;
66
- rows.push(_jsxs(Box, { children: [_jsx(Text, { children: isSelected ? '> ' : ' ' }), _jsx(Text, { children: isActive ? _jsx(Text, { color: "green", children: "\u2713 " }) : _jsx(Text, { children: " " }) }), _jsx(Text, { ...(isSelected ? {} : { color: 'gray' }), children: p.slug })] }, p.project_id));
67
- flatIndex++;
68
- }
69
- }
70
- for (const [teamId, group] of teamGroups) {
71
- rows.push(_jsxs(Text, { color: "gray", dimColor: true, children: [" ", group.teamName, " (team)"] }, `th-${teamId}`));
72
- for (const p of group.projects) {
73
- const isActive = p.project_id === activeId;
74
- const isSelected = flatIndex === modal.selected;
75
- rows.push(_jsxs(Box, { children: [_jsx(Text, { children: isSelected ? '> ' : ' ' }), _jsx(Text, { children: isActive ? _jsx(Text, { color: "green", children: "\u2713 " }) : _jsx(Text, { children: " " }) }), _jsx(Text, { ...(isSelected ? {} : { color: 'gray' }), children: p.slug })] }, p.project_id));
76
- flatIndex++;
77
- }
78
- }
79
- const newProjectSelected = modal.selected === projects.length;
80
- rows.push(_jsx(Box, { height: 1 }, "gap"));
81
- rows.push(_jsxs(Box, { children: [_jsx(Text, { children: newProjectSelected ? '> ' : ' ' }), _jsx(Text, { ...(newProjectSelected ? {} : { color: 'gray', dimColor: true }), children: " + new project" })] }, "new"));
82
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " switch project" }), _jsx(Box, { height: 1 }), rows] }));
83
- }
84
- case 'edit-role': {
85
- const roles = ['admin', 'member', 'viewer'];
86
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " change role for " }), _jsx(Text, { dimColor: true, children: modal.targetEmail })] }), _jsx(Box, { height: 1 }), roles.map((r, i) => (_jsxs(Box, { children: [_jsx(Text, { children: i === modal.selected ? '> ' : ' ' }), _jsx(Text, { ...(i === modal.selected ? {} : { color: 'gray' }), children: r })] }, r)))] }));
87
- }
88
- case 'initiate-consensus': {
89
- const adminEmails = (state.members ?? [])
90
- .filter(m => m.role === 'admin')
91
- .map(m => m.email ?? m.user_id)
92
- .join(', ');
93
- return (_jsxs(_Fragment, { children: [_jsxs(Text, { color: "gray", children: [" ", modal.description, " requires approval from another admin"] }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " admins: " }), _jsx(Text, { dimColor: true, children: adminEmails })] }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", children: " initiate? other admins will be notified. expires in 24 hours." }), _jsx(Box, { height: 1 }), _jsx(Box, { children: _jsx(Text, { dimColor: true, children: " (y/n) _" }) })] }));
94
- }
95
- case 'approve-action':
96
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsxs(Text, { dimColor: true, children: [" ", modal.initiator] }), _jsx(Text, { color: "gray", children: " wants to " }), _jsx(Text, { color: "red", children: modal.description })] }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " expires in " }), _jsx(Text, { color: "gray", children: modal.expiresIn })] }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " approve? " }), _jsx(Text, { children: "(y/n) _" })] })] }));
97
- case 'confirm-regen-link':
98
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " regenerate " }), _jsx(Text, { dimColor: true, children: modal.role }), _jsx(Text, { color: "gray", children: " link?" })] }), _jsx(Text, { color: "gray", children: " old link stops working immediately." }), _jsx(Box, { height: 1 }), _jsx(Box, { children: _jsx(Text, { dimColor: true, children: " (y/n) _" }) })] }));
99
- case 'create-team': {
100
- const slug = modal.input.toLowerCase().replace(/[^a-z0-9]+/g, '-').replace(/^-+|-+$/g, '');
101
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " new team" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " name \u203A " }), _jsxs(Text, { children: [modal.input, "_"] })] }), _jsxs(Box, { children: [_jsx(Box, { width: 10, children: _jsx(Text, { color: "gray", dimColor: true, children: " slug" }) }), _jsx(Text, { color: "gray", children: slug || '(derived from name)' })] })] }));
102
- }
103
- case 'create-team-project': {
104
- const slug = modal.input.toLowerCase().replace(/[^a-z0-9]+/g, '-').replace(/^-+|-+$/g, '');
105
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " first project in " }), _jsx(Text, { dimColor: true, children: modal.teamName })] }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " name \u203A " }), _jsx(Text, { children: modal.input || '_' })] }), _jsxs(Box, { children: [_jsx(Box, { width: 10, children: _jsx(Text, { color: "gray", dimColor: true, children: " slug" }) }), _jsx(Text, { color: "gray", children: slug || '(derived from name)' })] })] }));
106
- }
107
- case 'select-owner': {
108
- const owners = [
109
- { label: 'personal', index: 0 },
110
- ...state.teams.map((t, i) => ({ label: `${t.name} (team)`, index: i + 1 })),
111
- ];
112
- const newTeamIndex = owners.length;
113
- const isNewTeamSelected = modal.selected === newTeamIndex;
114
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " create project in" }), _jsx(Box, { height: 1 }), owners.map(o => (_jsxs(Box, { children: [_jsx(Text, { children: o.index === modal.selected ? '> ' : ' ' }), _jsx(Text, { ...(o.index === modal.selected ? {} : { color: 'gray' }), children: o.label })] }, o.index))), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { children: isNewTeamSelected ? '> ' : ' ' }), _jsx(Text, { ...(isNewTeamSelected ? {} : { color: 'gray', dimColor: true }), children: "+ new team" })] })] }));
115
- }
116
- case 'invite': {
117
- const roles = ['admin', 'member', 'viewer'];
118
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " invite as" }), _jsx(Box, { height: 1 }), roles.map((r, i) => (_jsxs(Box, { children: [_jsx(Text, { children: i === modal.selected ? '> ' : ' ' }), _jsx(Text, { ...(i === modal.selected ? {} : { color: 'gray' }), children: r })] }, r)))] }));
119
- }
120
- case 'invite-link': {
121
- const seatCount = state.members.length;
122
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: modal.role }), _jsx(Text, { color: "gray", children: " invite link" })] }), _jsx(Box, { height: 1 }), _jsx(Text, { children: modal.url }), _jsx(Box, { height: 1 }), _jsxs(Text, { color: "gray", dimColor: true, children: [" ", seatCount, " seat", seatCount !== 1 ? 's' : '', " \u00B7 $", seatCount * 29, "/mo \u00B7 each join adds $29/mo"] }), _jsx(Box, { height: 1 }), state.copiedFeedback
123
- ? _jsx(Text, { color: "green", children: " copied!" })
124
- : _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " c" }), _jsx(Text, { color: "gray", children: " copy " }), _jsx(Text, { dimColor: true, children: "o" }), _jsx(Text, { color: "gray", children: " open in browser" })] })] }));
125
- }
126
- case 'configure-sso': {
127
- const ssoRoles = ['member', 'viewer', 'admin'];
128
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " configure sso" }), _jsx(Box, { height: 1 }), modal.step === 1 && (_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " issuer url \u203A " }), _jsxs(Text, { children: [modal.issuer, "_"] })] })), modal.step === 2 && (_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " client id \u203A " }), _jsxs(Text, { children: [modal.clientId, "_"] })] })), modal.step === 3 && (_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " client secret \u203A " }), _jsxs(Text, { children: ['•'.repeat(modal.clientSecret.length), "_"] })] })), modal.step === 4 && (_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " allowed domains \u203A " }), _jsxs(Text, { children: [modal.domains, "_"] })] })), modal.step === 5 && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " default role for new members" }), _jsx(Box, { height: 1 }), ssoRoles.map((r, i) => (_jsxs(Box, { children: [_jsx(Text, { children: i === modal.defaultRole ? '> ' : ' ' }), _jsx(Text, { ...(i === modal.defaultRole ? {} : { color: 'gray' }), children: r })] }, r)))] })), modal.step === 6 && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " require sso for all team members?" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { children: modal.requireSso ? '> ' : ' ' }), _jsx(Text, { ...(modal.requireSso ? {} : { color: 'gray' }), children: "yes" })] }), _jsxs(Box, { children: [_jsx(Text, { children: !modal.requireSso ? '> ' : ' ' }), _jsx(Text, { ...(!modal.requireSso ? {} : { color: 'gray' }), children: "no" })] })] })), modal.step === 7 && (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " issuer " }), _jsx(Text, { children: modal.issuer })] }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " client " }), _jsx(Text, { children: modal.clientId })] }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " secret " }), _jsx(Text, { children: modal.clientSecret ? '••••••••' : '(none)' })] }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " domains " }), _jsx(Text, { children: modal.domains || '(any)' })] }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " role " }), _jsx(Text, { children: ssoRoles[modal.defaultRole] ?? 'member' })] }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " require " }), _jsx(Text, { children: modal.requireSso ? 'yes' : 'no' })] }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " confirm? " }), _jsx(Text, { children: "(y/n) _" })] })] }))] }));
129
- }
130
- case 'confirm-delete-team': {
131
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "red", children: " permanently delete " }), _jsx(Text, { children: modal.teamName }), _jsx(Text, { color: "red", children: "?" })] }), _jsx(Text, { color: "gray", children: " this cannot be undone." }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " type \"" }), _jsx(Text, { dimColor: true, children: modal.slug }), _jsx(Text, { color: "gray", children: "\" to confirm \u203A " }), _jsxs(Text, { children: [modal.input, "_"] })] })] }));
132
- }
133
- case 'manage-sso': {
134
- const sso = state.ssoConfig;
135
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " sso configuration" }), _jsx(Box, { height: 1 }), sso ? (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Box, { width: 12, children: _jsx(Text, { color: "gray", dimColor: true, children: " issuer" }) }), _jsx(Text, { dimColor: true, children: sso.issuer })] }), _jsxs(Box, { children: [_jsx(Box, { width: 12, children: _jsx(Text, { color: "gray", dimColor: true, children: " domains" }) }), _jsx(Text, { dimColor: true, children: sso.allowed_domains.join(', ') })] }), _jsxs(Box, { children: [_jsx(Box, { width: 12, children: _jsx(Text, { color: "gray", dimColor: true, children: " role" }) }), _jsx(Text, { dimColor: true, children: sso.default_role })] }), _jsxs(Box, { children: [_jsx(Box, { width: 12, children: _jsx(Text, { color: "gray", dimColor: true, children: " require" }) }), _jsx(Text, { dimColor: true, children: sso.require_sso ? 'yes' : 'no' })] })] })) : (_jsx(Text, { color: "gray", children: " not configured" }))] }));
136
- }
137
- case 'confirm-rename-team': {
138
- const slug = modal.input.toLowerCase().replace(/[^a-z0-9]+/g, '-').replace(/^-+|-+$/g, '');
139
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " rename team" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " new name \u203A " }), _jsxs(Text, { children: [modal.input, "_"] })] }), _jsxs(Box, { children: [_jsx(Box, { width: 12, children: _jsx(Text, { color: "gray", dimColor: true, children: " slug" }) }), _jsx(Text, { color: "gray", children: slug || '(derived from name)' })] })] }));
140
- }
141
- case 'create-integration-key': {
142
- const adminProjectsRaw = state.projects.filter(p => {
143
- if (p.owner.kind === 'personal')
144
- return true;
145
- const team = state.teams.find(t => t.team_id === (p.owner.kind === 'team' ? p.owner.teamId : ''));
146
- return team?.role === 'admin';
147
- });
148
- // Silo rule: after the first pick, hide non-matching-entity projects
149
- // so the wizard can't even attempt a cross-entity scope.
150
- const adminProjects = filterToSameEntity(adminProjectsRaw, modal.selectedProjectIds, state.user?.id ?? null);
151
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " new key" }), _jsx(Box, { height: 1 }), modal.step === 'name' && (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " name \u203A " }), _jsx(Text, { children: modal.input || '_' })] }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", dimColor: true, children: " e.g. \"ci pipeline\", \"metrics dashboard\"" })] })), modal.step === 'agent' && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " default agent name (optional, enter to skip)" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " agent \u203A " }), _jsx(Text, { children: modal.agentName || '_' })] }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", dimColor: true, children: " identifies the caller in contributed_by metadata" })] })), modal.step === 'projects' && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " scope to which projects? (space toggles, enter to continue)" }), _jsx(Box, { height: 1 }), adminProjects.length === 0 ? (_jsx(Text, { color: "gray", children: " you are not admin on any project" })) : (adminProjects.map((p, i) => {
152
- const isOn = modal.selectedProjectIds.has(p.project_id);
153
- return (_jsxs(Box, { children: [_jsx(Text, { children: i === modal.projectSelectedIdx ? '> ' : ' ' }), _jsx(Text, { children: isOn ? '[x] ' : '[ ] ' }), _jsx(Text, { ...(i === modal.projectSelectedIdx ? {} : { color: 'gray' }), children: p.slug }), p.owner.kind === 'team' && (_jsxs(Text, { color: "gray", dimColor: true, children: [" (", p.owner.teamName, ")"] }))] }, p.project_id));
154
- }))] })), modal.step === 'permissions' && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " permissions per project (space toggles, tab next project, enter to continue)" }), _jsx(Box, { height: 1 }), renderPermissionsGrid(modal, adminProjects)] })), modal.step === 'scope' && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " ownership scope (\u2191\u2193 toggles, enter to continue)" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsxs(Text, { color: modal.globalScope === 'own' ? undefined : 'gray', dimColor: modal.globalScope !== 'own', children: [" ", modal.globalScope === 'own' ? '>' : ' ', " own"] }), _jsx(Text, { color: "gray", dimColor: true, children: " \u2014 mutate only what this key contributed" })] }), _jsxs(Box, { children: [_jsxs(Text, { color: modal.globalScope === 'all' ? undefined : 'gray', dimColor: modal.globalScope !== 'all', children: [" ", modal.globalScope === 'all' ? '>' : ' ', " all"] }), _jsx(Text, { color: "gray", dimColor: true, children: " \u2014 mutate any contribution in the scoped project(s)" })] }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", dimColor: true, children: " default is `own` (least privilege). pick `all` for" }), _jsx(Text, { color: "gray", dimColor: true, children: " keys that need to edit contributions from other agents" }), _jsx(Text, { color: "gray", dimColor: true, children: " or users (migration tools, cleanup bots, reviewers)." })] })), modal.step === 'limits' && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " limits (optional, tab to switch, enter to continue)" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { ...(modal.limitsField === 'expiry' ? {} : { color: 'gray', dimColor: true }), children: " expires in days \u203A " }), _jsx(Text, { children: modal.limitsField === 'expiry' ? (modal.expiresInDays || '_') : (modal.expiresInDays || '(none)') })] }), _jsxs(Box, { children: [_jsx(Text, { ...(modal.limitsField === 'ops' ? {} : { color: 'gray', dimColor: true }), children: " ops limit \u203A " }), _jsx(Text, { children: modal.limitsField === 'ops' ? (modal.opsLimit || '_') : (modal.opsLimit || '(none)') })] })] })), modal.step === 'confirm' && (_jsxs(_Fragment, { children: [summarizeIntegration(modal, state, adminProjects), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " create? " }), _jsx(Text, { children: "(y/n) _" })] })] }))] }));
155
- }
156
- case 'key-created':
157
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "green", children: " \u2713 key created" }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " " }), _jsx(Text, { children: modal.keyName }), _jsxs(Text, { color: "gray", dimColor: true, children: [" (", modal.kind2, ")"] })] }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "yellow", children: " copy this key now \u2014 it won't be shown again:" }), _jsx(Box, { height: 1 }), _jsxs(Text, { children: [" ", modal.keyValue] }), _jsx(Box, { height: 1 }), state.copiedFeedback
158
- ? _jsx(Text, { color: "green", children: " copied!" })
159
- : _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " c" }), _jsx(Text, { color: "gray", children: " copy " }), _jsx(Text, { dimColor: true, children: "esc" }), _jsx(Text, { color: "gray", children: " dismiss" })] })] }));
160
- case 'confirm-revoke-key':
161
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Text, { color: "red", children: " revoke key " }), _jsx(Text, { dimColor: true, children: modal.keyName }), _jsx(Text, { color: "red", children: "?" })] }), _jsx(Text, { color: "gray", children: " any client using this key will stop working immediately." }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { dimColor: true, children: " revoke? " }), _jsx(Text, { children: "(y/n) _" })] })] }));
162
- case 'confirm-account-delete':
163
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "red", children: " delete your account?" }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", children: " personal projects and contributions will be wiped." }), _jsx(Text, { color: "gray", children: " team contributions stay in the substrate but get" }), _jsx(Text, { color: "gray", children: " anonymized \u2014 your name is stripped from them." }), _jsx(Text, { color: "gray", children: " any active paid subscription is canceled immediately." }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", children: " you have 3 days to change your mind before the purge." }), _jsx(Box, { height: 1 }), _jsxs(Box, { children: [_jsx(Text, { color: "gray", children: " type \"" }), _jsx(Text, { dimColor: true, children: modal.email }), _jsx(Text, { color: "gray", children: "\" to confirm \u203A " }), _jsxs(Text, { children: [modal.input, "_"] })] })] }));
164
- case 'account-delete-blocked':
165
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "yellow", children: " can't delete your account yet" }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", children: " you're the only admin of these teams:" }), _jsx(Box, { height: 1 }), modal.teams.map((t) => (_jsxs(Box, { flexDirection: "column", children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " \u00B7 " }), _jsx(Text, { children: t.team_name }), _jsxs(Text, { color: "gray", dimColor: true, children: [" \u2014 ", t.other_member_count, " other ", t.other_member_count === 1 ? 'member' : 'members'] })] }), _jsx(Text, { color: "gray", dimColor: true, children: " promote another admin in the team tab, or disband the team" })] }, t.team_id))), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", dimColor: true, children: " press esc or any key to dismiss" })] }));
166
- case 'account-delete-scheduled':
167
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "green", children: " \u2713 account scheduled for deletion" }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", children: " your session keys have stopped working and any" }), _jsx(Text, { color: "gray", children: " active subscription has been canceled." }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", children: " the purge runs 3 days from now. until then you can" }), _jsxs(Text, { color: "gray", children: [" come back to this tab and press ", _jsx(Text, { children: "c" }), " to cancel and"] }), _jsx(Text, { color: "gray", children: " restore your account." }), _jsx(Box, { height: 1 }), _jsx(Text, { color: "gray", dimColor: true, children: " press esc to dismiss" })] }));
168
- case 'confirm-cancel-account-deletion':
169
- return (_jsxs(_Fragment, { children: [_jsx(Text, { color: "gray", children: " cancel pending deletion and restore your account?" }), _jsx(Box, { height: 1 }), _jsx(Box, { children: _jsx(Text, { dimColor: true, children: " (y/n) _" }) })] }));
170
- }
171
- }
172
- function renderPermissionsGrid(modal, adminProjects) {
173
- const selectedProjects = adminProjects.filter(p => modal.selectedProjectIds.has(p.project_id));
174
- return (_jsx(_Fragment, { children: selectedProjects.map((p, pIdx) => {
175
- const actions = modal.projectScopes.get(p.project_id) ?? new Set();
176
- const isCursorProject = pIdx === modal.permProjectIdx;
177
- return (_jsxs(Box, { flexDirection: "column", children: [_jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " " }), _jsx(Text, { ...(isCursorProject ? {} : { color: 'gray', dimColor: true }), children: p.slug }), p.owner.kind === 'team' && _jsxs(Text, { color: "gray", dimColor: true, children: [" (", p.owner.teamName, ")"] })] }), _jsxs(Box, { children: [_jsx(Text, { children: " " }), ALL_KEY_ACTIONS.map((a, aIdx) => {
178
- const isOn = actions.has(a);
179
- const isCursor = isCursorProject && aIdx === modal.permActionIdx;
180
- return (_jsxs(React.Fragment, { children: [_jsx(Text, { children: isCursor ? '>' : ' ' }), _jsx(Text, { ...(isCursor ? {} : { color: 'gray' }), children: isOn ? '[x]' : '[ ]' }), _jsxs(Text, { ...(isCursor ? {} : { color: 'gray', dimColor: true }), children: [a, " "] })] }, a));
181
- })] })] }, p.project_id));
182
- }) }));
183
- }
184
- function summarizeIntegration(modal, state, adminProjects) {
185
- const agent = modal.agentName || '(none)';
186
- const expiry = modal.expiresInDays ? `${modal.expiresInDays} days` : '(none)';
187
- const ops = modal.opsLimit ? `${modal.opsLimit} ops` : '(none)';
188
- const selectedProjects = adminProjects.filter(p => modal.selectedProjectIds.has(p.project_id));
189
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { children: [_jsx(Box, { width: 10, children: _jsx(Text, { color: "gray", dimColor: true, children: " name" }) }), _jsx(Text, { children: modal.input })] }), _jsxs(Box, { children: [_jsx(Box, { width: 10, children: _jsx(Text, { color: "gray", dimColor: true, children: " agent" }) }), _jsx(Text, { color: "gray", children: agent })] }), _jsxs(Box, { children: [_jsx(Box, { width: 10, children: _jsx(Text, { color: "gray", dimColor: true, children: " scope" }) }), _jsx(Text, { color: "gray", children: modal.globalScope })] }), _jsxs(Box, { children: [_jsx(Box, { width: 10, children: _jsx(Text, { color: "gray", dimColor: true, children: " expiry" }) }), _jsx(Text, { color: "gray", children: expiry })] }), _jsxs(Box, { children: [_jsx(Box, { width: 10, children: _jsx(Text, { color: "gray", dimColor: true, children: " ops" }) }), _jsx(Text, { color: "gray", children: ops })] }), _jsx(Box, { height: 1 }), selectedProjects.map(p => {
190
- const actions = modal.projectScopes.get(p.project_id) ?? new Set();
191
- const label = p.owner.kind === 'team' ? `${p.owner.teamName} / ${p.slug}` : p.slug;
192
- return (_jsxs(Box, { children: [_jsx(Text, { color: "gray", dimColor: true, children: " " }), _jsx(Text, { children: label }), _jsxs(Text, { color: "gray", dimColor: true, children: [" ", [...actions].join(' ')] })] }, p.project_id));
193
- })] }));
194
- }
195
- //# sourceMappingURL=Modal.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Modal.js","sourceRoot":"","sources":["../../../src/tui/components/Modal.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAEhC,OAAO,EAAE,eAAe,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAGvC,MAAM,UAAU,SAAS,CAAC,EAAE,KAAK,EAAE,MAAM,EAAuC;IAC9E,MAAM,KAAK,GAAG,KAAK,CAAC,KAAK,CAAC;IAC1B,IAAI,CAAC,KAAK;QAAE,OAAO,IAAI,CAAC;IAExB,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;IAEnC,OAAO,CACL,MAAC,GAAG,IAAC,aAAa,EAAC,QAAQ,aACxB,KAAK,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,GAAG,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,KAAC,GAAG,IAAS,MAAM,EAAE,CAAC,IAAZ,CAAC,CAAe,CAAC,EAClE,KAAC,YAAY,IAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,GAAI,IACxC,CACP,CAAC;AACJ,CAAC;AAED,SAAS,YAAY,CAAC,EAAE,KAAK,EAAE,KAAK,EAA8D;IA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IAAI,KAAK,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,QAAQ,MAAM,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;gBACnF,OAAO,CACL,MAAC,GAAG,eACF,KAAC,IAAI,IAAC,KAAK,EAAC,MAAM,EAAC,QAAQ,yBAAU,EACrC,KAAC,IAAI,cAAE,KAAK,GAAQ,EACpB,MAAC,IAAI,IAAC,KAAK,EAAC,MAAM,EAAC,QAAQ,yBAAI,CAAC,GAAG,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,IAAQ,KAHrD,CAAC,CAAC,UAAU,CAIhB,CACP,CAAC;YACJ,CAAC,CAAC,IACD,CACJ,CAAC;AACJ,CAAC"}
@@ -1,4 +0,0 @@
1
- import { type Tab } from '../state.js';
2
- export declare function TabBar({ active }: {
3
- active: Tab;
4
- }): import("react/jsx-runtime").JSX.Element;
@@ -1,17 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Box, Text } from 'ink';
3
- import { TABS } from '../state.js';
4
- const TAB_LABELS = {
5
- knowledge: 'Knowledge',
6
- team: 'Team',
7
- billing: 'Billing',
8
- project: 'Project',
9
- keys: 'Keys',
10
- you: 'You',
11
- };
12
- export function TabBar({ active }) {
13
- return (_jsx(Box, { children: TABS.map(t => (t === active
14
- ? _jsxs(Text, { children: ["[", _jsx(Text, { bold: true, children: TAB_LABELS[t] }), "]"] }, t)
15
- : _jsxs(Text, { children: [" ", _jsx(Text, { color: "gray", children: TAB_LABELS[t] })] }, t))) }));
16
- }
17
- //# sourceMappingURL=TabBar.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"TabBar.js","sourceRoot":"","sources":["../../../src/tui/components/TabBar.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAChC,OAAO,EAAE,IAAI,EAAY,MAAM,aAAa,CAAC;AAE7C,MAAM,UAAU,GAAwB;IACtC,SAAS,EAAE,WAAW;IACtB,IAAI,EAAE,MAAM;IACZ,OAAO,EAAE,SAAS;IAClB,OAAO,EAAE,SAAS;IAClB,IAAI,EAAE,MAAM;IACZ,GAAG,EAAE,KAAK;CACX,CAAC;AAEF,MAAM,UAAU,MAAM,CAAC,EAAE,MAAM,EAAmB;IAChD,OAAO,CACL,KAAC,GAAG,cACD,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CACb,CAAC,KAAK,MAAM;YACV,CAAC,CAAC,MAAC,IAAI,oBAAU,KAAC,IAAI,IAAC,IAAI,kBAAE,UAAU,CAAC,CAAC,CAAC,GAAQ,UAArC,CAAC,CAA4C;YAC1D,CAAC,CAAC,MAAC,IAAI,qBAAW,KAAC,IAAI,IAAC,KAAK,EAAC,MAAM,YAAE,UAAU,CAAC,CAAC,CAAC,GAAQ,KAA9C,CAAC,CAAoD,CACrE,CAAC,GACE,CACP,CAAC;AACJ,CAAC"}
@@ -1,4 +0,0 @@
1
- import type { AppState } from '../state.js';
2
- export declare function Toast({ toast }: {
3
- toast: NonNullable<AppState['toast']>;
4
- }): import("react/jsx-runtime").JSX.Element | null;
@@ -1,9 +0,0 @@
1
- import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
2
- import { Box, Text } from 'ink';
3
- export function Toast({ toast }) {
4
- if (Date.now() > toast.expiresAt)
5
- return null;
6
- const color = toast.type === 'success' ? 'green' : toast.type === 'error' ? 'red' : 'gray';
7
- return (_jsx(Box, { children: _jsxs(Text, { color: color, children: [" ", toast.message] }) }));
8
- }
9
- //# sourceMappingURL=Toast.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Toast.js","sourceRoot":"","sources":["../../../src/tui/components/Toast.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAGhC,MAAM,UAAU,KAAK,CAAC,EAAE,KAAK,EAA6C;IACxE,IAAI,IAAI,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,SAAS;QAAE,OAAO,IAAI,CAAC;IAC9C,MAAM,KAAK,GAAG,KAAK,CAAC,IAAI,KAAK,SAAS,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC;IAC3F,OAAO,CACL,KAAC,GAAG,cACF,MAAC,IAAI,IAAC,KAAK,EAAE,KAAK,mBAAK,KAAK,CAAC,OAAO,IAAQ,GACxC,CACP,CAAC;AACJ,CAAC"}
@@ -1 +0,0 @@
1
- export declare function launchDashboard(): Promise<void>;
package/dist/tui/index.js DELETED
@@ -1,20 +0,0 @@
1
- // TUI entry point — manages alt-screen and Ink lifecycle.
2
- import React from 'react';
3
- import { render } from 'ink';
4
- import App from './App.js';
5
- export async function launchDashboard() {
6
- // Enter alt-screen + hide cursor
7
- process.stdout.write('\x1b[?1049h\x1b[?25l');
8
- const { waitUntilExit } = render(React.createElement(App), {
9
- exitOnCtrlC: false,
10
- });
11
- try {
12
- await waitUntilExit();
13
- }
14
- finally {
15
- // Show cursor + reset attributes + exit alt-screen
16
- process.stdout.write('\x1b[?25h\x1b[0m\x1b[?1049l');
17
- process.exit(0);
18
- }
19
- }
20
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/tui/index.tsx"],"names":[],"mappings":"AAAA,0DAA0D;AAE1D,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,GAAG,MAAM,UAAU,CAAC;AAE3B,MAAM,CAAC,KAAK,UAAU,eAAe;IACnC,iCAAiC;IACjC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,sBAAsB,CAAC,CAAC;IAE7C,MAAM,EAAE,aAAa,EAAE,GAAG,MAAM,CAAC,KAAK,CAAC,aAAa,CAAC,GAAG,CAAC,EAAE;QACzD,WAAW,EAAE,KAAK;KACnB,CAAC,CAAC;IAEH,IAAI,CAAC;QACH,MAAM,aAAa,EAAE,CAAC;IACxB,CAAC;YAAS,CAAC;QACT,mDAAmD;QACnD,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,6BAA6B,CAAC,CAAC;QACpD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC"}
@@ -1,2 +0,0 @@
1
- import type { PlatformStatus } from "./state.js";
2
- export declare function detectPlatformStatuses(): PlatformStatus[];