@1agh/maude 2.1.0 → 2.1.1
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/apps/studio/access/request.ts +1 -0
- package/apps/studio/actions/agents.ts +27 -0
- package/apps/studio/actions/defs/app.ts +28 -1
- package/apps/studio/actions/defs/sync.ts +4 -0
- package/apps/studio/actions.manifest.json +60 -2
- package/apps/studio/actions.parity.json +13 -1
- package/apps/studio/bin/_curl-local.mjs +7 -4
- package/apps/studio/client/app.jsx +16 -4
- package/apps/studio/client/home/HomeAccountsRow.jsx +221 -0
- package/apps/studio/client/home/HomeConnection.jsx +111 -0
- package/apps/studio/client/home/home-accounts-model.js +110 -1
- package/apps/studio/client/home/home-api.js +6 -2
- package/apps/studio/client/home/home-app.jsx +74 -12
- package/apps/studio/client/home/home-model.js +40 -1
- package/apps/studio/client/home/home-where-model.js +105 -0
- package/apps/studio/client/home/home.css +233 -1
- package/apps/studio/client/hooks/use-palette-and-panels.jsx +3 -1
- package/apps/studio/client/hooks/use-tabs.jsx +11 -4
- package/apps/studio/client/panels/TeamProjects.jsx +137 -134
- package/apps/studio/client/share-link.js +12 -0
- package/apps/studio/client/styles/_index.css +4 -0
- package/apps/studio/client/v2/diagnostics/diagnostics-host.jsx +1 -0
- package/apps/studio/client/v2/diagnostics/diagnostics-model.js +32 -2
- package/apps/studio/client/v2/diagnostics/diagnostics-sheet.jsx +35 -8
- package/apps/studio/client/v2/diagnostics/diagnostics.css +34 -0
- package/apps/studio/client/v2/diagnostics/sync-details/sync-details-model.js +94 -3
- package/apps/studio/client/v2/diagnostics/sync-details/sync-details.jsx +187 -4
- package/apps/studio/client/v2/link-server/LinkServerDialog.jsx +492 -0
- package/apps/studio/client/v2/link-server/LinkServerHost.jsx +42 -0
- package/apps/studio/client/v2/link-server/link-server-api.js +142 -0
- package/apps/studio/client/v2/link-server/link-server-model.js +438 -0
- package/apps/studio/client/v2/link-server/link-server.css +109 -0
- package/apps/studio/client/v2/onboarding/AdvancedSheets.jsx +31 -86
- package/apps/studio/client/v2/onboarding/onboarding-model.js +1 -18
- package/apps/studio/client/v2/search/search-keywords.js +3 -2
- package/apps/studio/client/v2/settings/account.jsx +4 -2
- package/apps/studio/client/v2/settings/advanced-section.jsx +245 -148
- package/apps/studio/client/v2/settings/connection-row.jsx +3 -59
- package/apps/studio/client/v2/settings/connections-section.jsx +118 -425
- package/apps/studio/client/v2/settings/general-section.jsx +138 -43
- package/apps/studio/client/v2/settings/project-sync-settings.jsx +4 -3
- package/apps/studio/client/v2/settings/reset-section.jsx +14 -3
- package/apps/studio/client/v2/settings/settings-card.jsx +142 -0
- package/apps/studio/client/v2/settings/settings-cards.js +220 -0
- package/apps/studio/client/v2/settings/settings-handlers.js +7 -6
- package/apps/studio/client/v2/settings/settings-model.js +91 -31
- package/apps/studio/client/v2/settings/settings-sheet.jsx +25 -6
- package/apps/studio/client/v2/settings/settings.css +374 -64
- package/apps/studio/client/v2/settings/this-project-card.jsx +730 -0
- package/apps/studio/client/v2/settings/this-project-model.js +172 -0
- package/apps/studio/client/v2/settings/use-connections.js +3 -2
- package/apps/studio/client/v2/settings/use-open-card.js +37 -0
- package/apps/studio/client/v2/shell/connection-state.js +197 -0
- package/apps/studio/client/v2/shell/menu-runner.js +7 -2
- package/apps/studio/client/v2/shell/project-account-bus.js +36 -0
- package/apps/studio/client/v2/shell/project-account-card.jsx +357 -148
- package/apps/studio/client/v2/shell/project-account-model.js +272 -149
- package/apps/studio/client/v2/shell/project-account-toast.js +66 -0
- package/apps/studio/client/v2/shell/project-account.css +237 -0
- package/apps/studio/client/v2/shell/share-cluster-host.jsx +166 -83
- package/apps/studio/client/v2/shell/shell-parity.js +3 -2
- package/apps/studio/client/v2/shell/shell-parity.json +40 -26
- package/apps/studio/client/v2/shell/use-account.js +2 -0
- package/apps/studio/client/v2/signin/use-signin.js +1 -1
- package/apps/studio/cloud/endpoints.ts +29 -4
- package/apps/studio/dist/client.bundle.js +834 -834
- package/apps/studio/dist/styles.css +1 -1
- package/apps/studio/home/accounts.ts +30 -11
- package/apps/studio/home/cloud.ts +6 -1
- package/apps/studio/home/hub-health.ts +76 -0
- package/apps/studio/home/routes.ts +9 -3
- package/apps/studio/http.ts +8 -0
- package/apps/studio/migrate/hub.ts +8 -1
- package/apps/studio/routes/hub-link-folder.ts +334 -0
- package/apps/studio/routes/hub-signin.ts +78 -1
- package/apps/studio/routes/index.ts +4 -0
- package/apps/studio/routes/sync.ts +22 -4
- package/apps/studio/shell/api-key.ts +11 -0
- package/apps/studio/sync/accepted-cold-start.ts +144 -8
- package/apps/studio/sync/action-stage.ts +18 -1
- package/apps/studio/sync/ctl-heal.ts +58 -0
- package/apps/studio/sync/file-ledger.ts +38 -4
- package/apps/studio/sync/file-plane.ts +226 -19
- package/apps/studio/sync/held-deletes.ts +86 -5
- package/apps/studio/sync/hub-link.ts +8 -0
- package/apps/studio/sync/index.ts +68 -4
- package/apps/studio/sync/link-consent.ts +22 -75
- package/apps/studio/sync/link-survey.ts +252 -0
- package/apps/studio/sync/local-kernel.ts +16 -1
- package/apps/studio/sync/seed-progress.ts +12 -0
- package/apps/studio/sync/source-recovery.ts +18 -2
- package/apps/studio/sync/status.ts +11 -1
- package/apps/studio/sync/writer-registry.ts +5 -0
- package/apps/studio/whats-new.json +18 -0
- package/cli/lib/bash-guard.mjs +19 -0
- package/cli/lib/design-help.gen.mjs +1 -1
- package/package.json +9 -8
- package/apps/studio/client/v2/onboarding/HubSheet.jsx +0 -212
- package/apps/studio/client/v2/shell/account-card-model.js +0 -114
- package/apps/studio/client/v2/shell/account-card.jsx +0 -189
|
@@ -1,189 +0,0 @@
|
|
|
1
|
-
// client/v2/shell/account-card.jsx — S1.22a: the account chip beside the faces and its card
|
|
2
|
-
// (canvas 11 · pn-accounts: "The account belongs to the project, on this Mac. It sits by the faces.
|
|
3
|
-
// Signing out signs out every project on that account.").
|
|
4
|
-
//
|
|
5
|
-
// PRESENTATIONAL. The words come from account-card-model.js, the handlers from the host
|
|
6
|
-
// (share-cluster-host.jsx): "Sign in as another account…" is the shell's own `account.switch` handler,
|
|
7
|
-
// and "Sign out of …" calls the EXISTING sign-out path (`POST /_api/cloud/signout`, the one Settings ›
|
|
8
|
-
// Connections uses — V2-3.8: it clears the calling project's profile credential, and every project on
|
|
9
|
-
// that profile is signed out with it). Nothing here signs anyone in or out by itself.
|
|
10
|
-
//
|
|
11
|
-
// The card is a popover under the chip (opaque, the largest shadow, no backdrop-filter — M1). Esc and a
|
|
12
|
-
// press outside close it; the sign-out row asks first, with the verb its button carries (CONTRACT §4).
|
|
13
|
-
|
|
14
|
-
import { useCallback, useEffect, useId, useRef, useState } from 'react';
|
|
15
|
-
import { StIcon } from '../../shell/icons.jsx';
|
|
16
|
-
import { onCanvasPointer } from './canvas-pointer.js';
|
|
17
|
-
|
|
18
|
-
function Face({ initial, tone, size = 'md' }) {
|
|
19
|
-
return (
|
|
20
|
-
<span className={`sh-acct-face sh-acct-face--${size}`} data-tone={tone} aria-hidden="true">
|
|
21
|
-
{initial}
|
|
22
|
-
</span>
|
|
23
|
-
);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* @param chip accountChip() — null renders nothing
|
|
28
|
-
* @param card accountCard()
|
|
29
|
-
* @param onSwitch () => void — the shell's `account.switch`
|
|
30
|
-
* @param onSignOut () => Promise — the existing sign-out path
|
|
31
|
-
*/
|
|
32
|
-
export function AccountChip({ chip, card, onSwitch, onSignOut, onOpen = null, opened = false }) {
|
|
33
|
-
const [open, setOpen] = useState(false);
|
|
34
|
-
const [asking, setAsking] = useState(false);
|
|
35
|
-
const [busy, setBusy] = useState(false);
|
|
36
|
-
const wrap = useRef(null);
|
|
37
|
-
const btn = useRef(null);
|
|
38
|
-
const titleId = useId();
|
|
39
|
-
|
|
40
|
-
const close = useCallback((refocus) => {
|
|
41
|
-
setOpen(false);
|
|
42
|
-
setAsking(false);
|
|
43
|
-
if (refocus) btn.current?.focus();
|
|
44
|
-
}, []);
|
|
45
|
-
|
|
46
|
-
useEffect(() => {
|
|
47
|
-
if (!open) return undefined;
|
|
48
|
-
const onDown = (e) => {
|
|
49
|
-
if (wrap.current && !wrap.current.contains(e.target)) close(false);
|
|
50
|
-
};
|
|
51
|
-
document.addEventListener('pointerdown', onDown, true);
|
|
52
|
-
// rc3 r4-12 — a press in the canvas closes it too (told over the dgn bridge; it never reaches this document)
|
|
53
|
-
const offCanvas = onCanvasPointer(() => close(false));
|
|
54
|
-
return () => {
|
|
55
|
-
document.removeEventListener('pointerdown', onDown, true);
|
|
56
|
-
offCanvas();
|
|
57
|
-
};
|
|
58
|
-
}, [open, close]);
|
|
59
|
-
|
|
60
|
-
if (!chip || !card) return null;
|
|
61
|
-
|
|
62
|
-
const signOut = async () => {
|
|
63
|
-
setBusy(true);
|
|
64
|
-
try {
|
|
65
|
-
await onSignOut?.();
|
|
66
|
-
} finally {
|
|
67
|
-
setBusy(false);
|
|
68
|
-
close(false);
|
|
69
|
-
}
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
return (
|
|
73
|
-
<div className="sh-acct" ref={wrap}>
|
|
74
|
-
<button
|
|
75
|
-
ref={btn}
|
|
76
|
-
type="button"
|
|
77
|
-
className={`sh-acct-chip${open || opened ? ' is-on' : ''}`}
|
|
78
|
-
data-testid="share-cluster-account"
|
|
79
|
-
data-account={chip.id}
|
|
80
|
-
// 2.0.5 W4 — with `onOpen` the chip opens the project's account card (project-account-card.jsx)
|
|
81
|
-
data-account-opener={onOpen ? 'true' : undefined}
|
|
82
|
-
aria-haspopup="dialog"
|
|
83
|
-
aria-expanded={open || opened ? 'true' : 'false'}
|
|
84
|
-
aria-label={`Account: ${chip.title}`}
|
|
85
|
-
title={chip.title}
|
|
86
|
-
onClick={() => {
|
|
87
|
-
if (onOpen) onOpen();
|
|
88
|
-
else if (open) close(false);
|
|
89
|
-
else setOpen(true);
|
|
90
|
-
}}
|
|
91
|
-
>
|
|
92
|
-
<Face initial={chip.initial} tone={chip.tone} />
|
|
93
|
-
<span className="sh-acct-name">{chip.label}</span>
|
|
94
|
-
<StIcon name="chevron-down" size={12} />
|
|
95
|
-
</button>
|
|
96
|
-
{open ? (
|
|
97
|
-
<div
|
|
98
|
-
className="sh-acct-card"
|
|
99
|
-
role="dialog"
|
|
100
|
-
aria-labelledby={titleId}
|
|
101
|
-
data-testid="account-card"
|
|
102
|
-
onKeyDown={(e) => {
|
|
103
|
-
if (e.key === 'Escape') {
|
|
104
|
-
e.stopPropagation();
|
|
105
|
-
close(true);
|
|
106
|
-
}
|
|
107
|
-
}}
|
|
108
|
-
>
|
|
109
|
-
<div className="sh-acct-row" data-testid="account-card-current">
|
|
110
|
-
<Face initial={card.current.initial} tone={card.current.tone} size="lg" />
|
|
111
|
-
<span className="sh-acct-txt">
|
|
112
|
-
<strong id={titleId}>{card.current.title}</strong>
|
|
113
|
-
<span>{card.current.sub}</span>
|
|
114
|
-
</span>
|
|
115
|
-
</div>
|
|
116
|
-
{card.others.length > 0 ? (
|
|
117
|
-
<>
|
|
118
|
-
<hr className="sh-acct-sep" />
|
|
119
|
-
<p className="sh-acct-gt">Also on this Mac</p>
|
|
120
|
-
{card.others.map((o) => (
|
|
121
|
-
<div
|
|
122
|
-
key={o.id}
|
|
123
|
-
className="sh-acct-row sh-acct-row--sm"
|
|
124
|
-
data-testid={`account-card-other-${o.id}`}
|
|
125
|
-
>
|
|
126
|
-
<Face initial={o.initial} tone={o.tone} />
|
|
127
|
-
<span className="sh-acct-txt">
|
|
128
|
-
<strong>{o.title}</strong>
|
|
129
|
-
<span>{o.sub}</span>
|
|
130
|
-
</span>
|
|
131
|
-
</div>
|
|
132
|
-
))}
|
|
133
|
-
</>
|
|
134
|
-
) : null}
|
|
135
|
-
<hr className="sh-acct-sep" />
|
|
136
|
-
<button
|
|
137
|
-
type="button"
|
|
138
|
-
className="sh-acct-act"
|
|
139
|
-
data-testid="account-card-switch"
|
|
140
|
-
onClick={() => {
|
|
141
|
-
close(false);
|
|
142
|
-
onSwitch?.();
|
|
143
|
-
}}
|
|
144
|
-
>
|
|
145
|
-
{card.switchLabel}
|
|
146
|
-
</button>
|
|
147
|
-
{asking ? (
|
|
148
|
-
<div className="sh-acct-ask" role="alertdialog" data-testid="account-card-confirm">
|
|
149
|
-
<strong>{card.signOut.confirm.title}</strong>
|
|
150
|
-
<span>{card.signOut.confirm.body}</span>
|
|
151
|
-
<span className="sh-acct-btns">
|
|
152
|
-
<button
|
|
153
|
-
type="button"
|
|
154
|
-
className="btn btn--sm"
|
|
155
|
-
data-testid="account-card-signout-cancel"
|
|
156
|
-
onClick={() => setAsking(false)}
|
|
157
|
-
>
|
|
158
|
-
{card.signOut.confirm.cancel}
|
|
159
|
-
</button>
|
|
160
|
-
<button
|
|
161
|
-
type="button"
|
|
162
|
-
className="btn btn--sm btn--danger"
|
|
163
|
-
data-testid="account-card-signout-confirm"
|
|
164
|
-
disabled={busy}
|
|
165
|
-
onClick={signOut}
|
|
166
|
-
>
|
|
167
|
-
{card.signOut.confirm.primary}
|
|
168
|
-
</button>
|
|
169
|
-
</span>
|
|
170
|
-
</div>
|
|
171
|
-
) : (
|
|
172
|
-
<button
|
|
173
|
-
type="button"
|
|
174
|
-
className="sh-acct-act sh-acct-act--two"
|
|
175
|
-
data-testid="account-card-signout"
|
|
176
|
-
onClick={() => setAsking(true)}
|
|
177
|
-
>
|
|
178
|
-
<span>{card.signOut.label}</span>
|
|
179
|
-
<span className="sh-acct-sub">{card.signOut.sub}</span>
|
|
180
|
-
</button>
|
|
181
|
-
)}
|
|
182
|
-
<p className="sh-acct-foot" data-testid="account-card-foot">
|
|
183
|
-
{card.foot}
|
|
184
|
-
</p>
|
|
185
|
-
</div>
|
|
186
|
-
) : null}
|
|
187
|
-
</div>
|
|
188
|
-
);
|
|
189
|
-
}
|