@hanzo/app 0.2.58 → 0.2.60
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/dist/App.js +1 -4
- package/dist/Board.js +37 -121
- package/dist/Boxes.js +12 -16
- package/dist/CalScheduler.js +40 -81
- package/dist/Chat.js +87 -78
- package/dist/Chrome.d.ts +2 -14
- package/dist/Chrome.js +7 -44
- package/dist/Column.js +6 -2
- package/dist/Contents.d.ts +1 -1
- package/dist/Contents.js +2 -1
- package/dist/Drive.js +100 -121
- package/dist/Inbox.js +7 -7
- package/dist/Market.js +10 -15
- package/dist/Meet.js +48 -78
- package/dist/Orgs.js +10 -9
- package/dist/Palette.d.ts +1 -1
- package/dist/Palette.js +2 -1
- package/dist/Rail.d.ts +1 -1
- package/dist/Rail.js +4 -4
- package/dist/Schedule.js +11 -15
- package/dist/Settings.d.ts +1 -1
- package/dist/SettingsPane.js +2 -2
- package/dist/Shared.js +11 -16
- package/dist/Shell.js +1 -1
- package/dist/Talk.js +4 -4
- package/dist/Terminals.js +1 -3
- package/dist/Top.js +1 -1
- package/dist/Usage.js +3 -3
- package/dist/WindowControls.js +3 -5
- package/dist/Work.js +28 -51
- package/dist/bots/Bots.js +73 -129
- package/dist/bots/runtime.js +41 -103
- package/dist/cast.d.ts +1 -1
- package/dist/cast.js +1 -1
- package/dist/failure.d.ts +1 -1
- package/dist/failure.js +1 -1
- package/dist/ground.d.ts +21 -0
- package/dist/ground.js +21 -0
- package/dist/lib/limits.d.ts +1 -1
- package/dist/lib/limits.js +1 -1
- package/dist/lib/org.d.ts +3 -3
- package/dist/lib/org.js +5 -4
- package/dist/lib/orgname.d.ts +1 -1
- package/dist/lib/orgname.js +1 -1
- package/dist/lib/pay.d.ts +2 -6
- package/dist/lib/pay.js +2 -15
- package/dist/lib/plans.d.ts +1 -1
- package/dist/lib/plans.js +1 -1
- package/dist/lib/tier.d.ts +2 -2
- package/dist/lib/tier.js +6 -6
- package/dist/look.js +8 -10
- package/dist/recent.d.ts +1 -1
- package/dist/recent.js +2 -1
- package/dist/say.d.ts +4 -0
- package/dist/say.js +7 -0
- package/dist/thread.js +1 -1
- package/package.json +3 -3
- package/assets/memoji/art.svg +0 -22
- package/assets/memoji/cyber.svg +0 -22
- package/assets/memoji/data.svg +0 -22
- package/assets/memoji/des.svg +0 -22
- package/assets/memoji/dev.svg +0 -22
- package/assets/memoji/doc.svg +0 -22
- package/assets/memoji/edu.svg +0 -22
- package/assets/memoji/fin.svg +0 -22
- package/assets/memoji/gov.svg +0 -22
- package/assets/memoji/huma.svg +0 -22
- package/assets/memoji/lang.svg +0 -22
- package/assets/memoji/law.svg +0 -22
- package/assets/memoji/mana.svg +0 -22
- package/assets/memoji/mark.svg +0 -22
- package/assets/memoji/mu.svg +0 -22
- package/assets/memoji/opera.svg +0 -22
- package/assets/memoji/rev.svg +0 -22
- package/assets/memoji/sal.svg +0 -22
- package/assets/memoji/sci.svg +0 -22
- package/assets/memoji/su.svg +0 -22
- package/assets/memoji/vi.svg +0 -22
- package/dist/TeamPreview.d.ts +0 -9
- package/dist/TeamPreview.js +0 -305
- package/dist/TeamStory.d.ts +0 -49
- package/dist/TeamStory.js +0 -67
- package/dist/preview.d.ts +0 -84
- package/dist/preview.js +0 -120
- package/dist/workday.d.ts +0 -247
- package/dist/workday.js +0 -642
package/dist/Chrome.js
CHANGED
|
@@ -9,18 +9,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
9
9
|
* At the end, once someone is signed in, who it is: the face, the name and the
|
|
10
10
|
* address, the other accounts signed in on this browser to be one tap away
|
|
11
11
|
* (lib/accounts), Add account and Log out. Signed out, nothing but the brand. Under gui's `md` the account folds into its face, a menu of the address
|
|
12
|
-
* and the same two ways out.
|
|
13
|
-
* in as `account`, and the bar draws that in this one's place (null: none).
|
|
14
|
-
*
|
|
15
|
-
* THE WORDMARK STANDS WHERE THE MARKETING BAR'S DOES: the bar's side is the
|
|
16
|
-
* page's gutter (@hanzo/design `--page-gutter`), 60px tall, and the name is a
|
|
17
|
-
* pill whose 12px of padding the bar takes back with a -12px start margin, the
|
|
18
|
-
* shape hanzo.ai's own bar gives it. So the name's first letter is at the gutter
|
|
19
|
-
* on every page of every host, the focused ones and the marketing ones alike.
|
|
20
|
-
* Under a pointer or keyboard focus the pill takes the bar's one highlight, the
|
|
21
|
-
* `$hover` ground and no outline or border, as every control on hanzo.ai's bar
|
|
22
|
-
* does, and an arrow opens before the name: this goes back to the site.
|
|
23
|
-
* Keyboard focus keeps its ring as well.
|
|
12
|
+
* and the same two ways out.
|
|
24
13
|
*
|
|
25
14
|
* Being another account, and adding one, write this page down first
|
|
26
15
|
* (destination.ts `rememberDestination`), so the sign-in that follows comes back
|
|
@@ -29,7 +18,6 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
29
18
|
* host mounts `IamProvider`.
|
|
30
19
|
*/
|
|
31
20
|
import { useEffect, useState } from 'react';
|
|
32
|
-
import { ArrowLeft, ArrowRight } from 'lucide-react';
|
|
33
21
|
import { useI18n } from '@hanzo/i18n/react';
|
|
34
22
|
import { useIam } from '@hanzo/iam/react';
|
|
35
23
|
import { Text, View, XStack, YStack } from '@hanzo/gui';
|
|
@@ -43,15 +31,6 @@ import { brand, site } from './where.js';
|
|
|
43
31
|
import { dragWindow, toggleWindowMaximize, WindowControls } from './WindowControls.js';
|
|
44
32
|
/** The bar's height under the notch: hanzo.ai's masthead's. */
|
|
45
33
|
const HEIGHT = 60;
|
|
46
|
-
/** The bar's side: the page's gutter, as hanzo.ai's marketing bar has it. */
|
|
47
|
-
const GUTTER = 'var(--page-gutter, 20px)';
|
|
48
|
-
/** The name's pill: its padding, which the bar takes back so the name's first letter is at the gutter. */
|
|
49
|
-
const PAD = 12;
|
|
50
|
-
/** The pill lit: the bar's one highlight, a ground and no outline. */
|
|
51
|
-
const LIT = '$hover';
|
|
52
|
-
/** The arrow that opens before the name, and the space after it. */
|
|
53
|
-
const CUE = 14;
|
|
54
|
-
const CUE_GAP = 6;
|
|
55
34
|
/** The bar's ground once the page has moved under it: the page's own, frosted. At rest it has none. */
|
|
56
35
|
const GLASS = '$background/72';
|
|
57
36
|
const BLUR = 'blur(20px) saturate(1.8)';
|
|
@@ -70,7 +49,7 @@ function useMoved() {
|
|
|
70
49
|
}
|
|
71
50
|
/** The notch's inset. gui carries a CSS function to the page unchanged; its types only name custom properties. */
|
|
72
51
|
const NOTCH = 'env(safe-area-inset-top)';
|
|
73
|
-
export function Chrome({ back
|
|
52
|
+
export function Chrome({ back }) {
|
|
74
53
|
const { t, dir } = useI18n();
|
|
75
54
|
const { user, isAuthenticated } = useIam();
|
|
76
55
|
const signOut = useSignOut();
|
|
@@ -85,25 +64,9 @@ export function Chrome({ back, account }) {
|
|
|
85
64
|
const others = accounts.filter((a) => a.sub !== current?.sub);
|
|
86
65
|
const signed = isAuthenticated && Boolean(who);
|
|
87
66
|
const moved = useMoved();
|
|
88
|
-
return (_jsxs(XStack, { render: "header", "data-slot": "masthead", "data-scrolled": moved ? 'true' : 'false', "data-tauri-drag-region": "deep", onMouseDown: dragWindow, onDoubleClick: toggleWindowMaximize, position: "sticky", t: 0, z: "var(--z-header)", shrink: 0, boxSizing: "content-box", height: HEIGHT, pt: NOTCH, px:
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
* and is not a hover, so it does not light.
|
|
94
|
-
*/
|
|
95
|
-
function Home() {
|
|
96
|
-
const { t, dir } = useI18n();
|
|
97
|
-
const [lit, setLit] = useState(false);
|
|
98
|
-
const Arrow = dir === 'rtl' ? ArrowRight : ArrowLeft;
|
|
99
|
-
const point = (on) => (e) => {
|
|
100
|
-
if (e.pointerType !== 'touch')
|
|
101
|
-
setLit(on);
|
|
102
|
-
};
|
|
103
|
-
const focus = (e) => setLit(e.currentTarget.matches(':focus-visible'));
|
|
104
|
-
return (_jsxs(Text, { render: _jsx("a", { href: "/", "aria-label": t('{brand} home', { brand: brand() }), "data-lit": lit ? 'true' : 'false', "data-tauri-drag-region": "deep", onClick: (e) => {
|
|
105
|
-
if (typeof document !== 'undefined' && document.documentElement.getAttribute('data-desktop') === 'true') {
|
|
106
|
-
e.preventDefault();
|
|
107
|
-
}
|
|
108
|
-
}, onPointerEnter: point(true), onPointerLeave: point(false), onFocus: focus, onBlur: () => setLit(false) }), "data-slot": "home", display: "flex", items: "center", shrink: 0, height: 34, marginInlineStart: -PAD, paddingInline: PAD, rounded: 999, color: "var(--foreground)", textDecorationLine: "none", bg: lit ? LIT : 'transparent', focusVisibleStyle: { outlineWidth: 2, outlineStyle: 'solid', outlineColor: '$outlineColor', outlineOffset: 2 }, transition: "quickest", "data-tauri-drag-region": "deep", children: [_jsx(View, { "aria-hidden": true, display: "flex", items: "center", overflow: "hidden", width: lit ? CUE : 0, marginInlineEnd: lit ? CUE_GAP : 0, opacity: lit ? 1 : 0, transition: "quickest", children: _jsx(Arrow, { size: CUE, strokeWidth: 2.2 }) }), _jsx(HanzoWordmark, { label: brand(), size: 22, "data-tauri-drag-region": "deep" })] }));
|
|
67
|
+
return (_jsxs(XStack, { render: "header", "data-slot": "masthead", "data-scrolled": moved ? 'true' : 'false', "data-tauri-drag-region": "deep", onMouseDown: dragWindow, onDoubleClick: toggleWindowMaximize, position: "sticky", t: 0, z: "var(--z-header)", shrink: 0, boxSizing: "content-box", height: HEIGHT, pt: NOTCH, px: 20, gap: 12, items: "center", bg: moved ? GLASS : 'transparent', backdropFilter: moved ? BLUR : 'none', transition: "quickest", borderBottomWidth: 0, children: [_jsx(Text, { render: _jsx("a", { href: "/", "aria-label": t('{brand} home', { brand: brand() }), "data-tauri-drag-region": "deep", onClick: (e) => {
|
|
68
|
+
if (typeof document !== 'undefined' && document.documentElement.getAttribute('data-desktop') === 'true') {
|
|
69
|
+
e.preventDefault();
|
|
70
|
+
}
|
|
71
|
+
} }), display: "flex", items: "center", shrink: 0, color: "var(--foreground)", textDecorationLine: "none", "data-tauri-drag-region": "deep", children: _jsx(HanzoWordmark, { label: brand(), size: 22, "data-tauri-drag-region": "deep" }) }), back, _jsx(View, { flex: 1, "data-tauri-drag-region": "deep" }), signed ? (_jsx(View, { render: "section", "aria-label": t('Account'), display: "flex", children: _jsxs(DropdownMenu, { placement: dir === 'rtl' ? 'bottom-start' : 'bottom-end', offset: 8, children: [_jsx(DropdownMenuTrigger, { asChild: true, children: _jsx(XStack, { render: "button", "aria-label": t('Account: {name}', { name: who }), width: 40, height: 40, rounded: 999, items: "center", justify: "center", borderWidth: 0, bg: "transparent", hoverStyle: { bg: '$hover' }, focusVisibleStyle: { outlineWidth: 2, outlineStyle: 'solid', outlineColor: '$outlineColor' }, cursor: "pointer", children: _jsx(Avatar, { src: avatar || null, name: who, alt: "" }) }) }), _jsxs(DropdownMenuContent, { minW: 240, maxW: "calc(100vw - 16px)", "aria-labelledby": undefined, "aria-label": t('Account'), children: [_jsx(DropdownMenuLabel, { children: _jsxs(YStack, { minW: 0, gap: 2, children: [_jsx(Text, { fontSize: "$3", fontWeight: "500", color: "$ink", numberOfLines: 1, children: who }), name && email ? (_jsx(Text, { fontSize: "$2", color: "$soft", numberOfLines: 1, children: email })) : null] }) }), _jsx(DropdownMenuSeparator, {}), _jsx(DropdownMenuItem, { onSelect: () => window.location.assign(site('/support')), children: _jsx(Text, { fontSize: "$3", color: "$ink", children: t('Help') }) }), _jsx(DropdownMenuSeparator, {}), others.map((a) => (_jsx(DropdownMenuItem, { onSelect: () => void switchTo(a), children: _jsx(XStack, { items: "center", gap: 10, minW: 0, children: _jsx(Face, { account: a }) }) }, a.sub))), _jsx(DropdownMenuItem, { onSelect: () => void add(), children: _jsx(Text, { fontSize: "$3", color: "$ink", children: t('Add account') }) }), _jsx(DropdownMenuItem, { onSelect: out, children: _jsx(Text, { fontSize: "$3", color: "$ink", children: t('Log out') }) })] })] }) })) : null, _jsx(WindowControls, {})] }));
|
|
109
72
|
}
|
package/dist/Column.js
CHANGED
|
@@ -47,7 +47,7 @@ import { talk } from './lib/host.js';
|
|
|
47
47
|
import { payUrl } from './lib/pay.js';
|
|
48
48
|
import { brand, wordmark } from './where.js';
|
|
49
49
|
import { dragWindow, toggleWindowMaximize } from './WindowControls.js';
|
|
50
|
-
import { BAND } from './ground.js';
|
|
50
|
+
import { BAND, HEAD as LINE, TOUCH_HEAD } from './ground.js';
|
|
51
51
|
/** The sidebar fills the column. Its `width` is typed in px alone, though its frame takes any gui size — the type is
|
|
52
52
|
* @hanzo/ui's to widen. */
|
|
53
53
|
const FILL = { width: '100%' };
|
|
@@ -121,7 +121,11 @@ export function Column({ host, mode, thread, go, onShut, onSeek, onBack, drawer
|
|
|
121
121
|
// inline-style: `--span`, the width a drag rewrites on the element itself (span.ts); no prop sets a variable.
|
|
122
122
|
style: drawer ? undefined : span.style, position: "relative", flex: drawer ? 1 : undefined, shrink: drawer ? 1 : 0, minW: 0, height: "100%", width: drawer ? undefined : 'var(--span)', children: [_jsxs(Sidebar, { "data-slot": "app-rail", role: "navigation", "aria-label": brand(), bg: "transparent", borderWidth: 0, ...FILL, px: "$2", pt: drawer ? 'var(--pane-gap)' : 0,
|
|
123
123
|
// In the drawer the menu's own foot padding is the gap; its foot row stands on it.
|
|
124
|
-
pb: drawer ? 0 : '$2', gap: "$0", children: [at ? (_jsxs(XStack, { "data-slot": "app-head", items: "center", gap: "$1", paddingInlineStart: 2, paddingInlineEnd: 2,
|
|
124
|
+
pb: drawer ? 0 : '$2', gap: "$0", children: [at ? (_jsxs(XStack, { "data-slot": "app-head", items: "center", gap: "$1", paddingInlineStart: 2, paddingInlineEnd: 2,
|
|
125
|
+
// The phone's drawer lines up with its bar (BAND); beside the rail, with the rail's first mark (ground.ts HEAD).
|
|
126
|
+
height: drawer ? BAND : LINE, $touchable: drawer ? undefined : { height: TOUCH_HEAD }, shrink: 0, minW: 0, "data-tauri-drag-region": "deep", onMouseDown: dragWindow, onDoubleClick: toggleWindowMaximize, children: [_jsx(SidebarIconButton, { label: t('Back'), "data-slot": "place-back", "data-tauri-drag-region": "false", onPress: onBack, ...HEAD, children: _jsx(ArrowLeft, { size: 16, "aria-hidden": true, "data-i18n-mirror": true }) }), _jsx(Text, { flex: 1, minW: 0, fontSize: 18, lineHeight: 24, fontWeight: "600", color: "$ink", numberOfLines: 1, "data-slot": "place-name", children: t(TITLE[at]) })] })) : (_jsxs(XStack, { "data-slot": "app-head", items: "center", gap: "$1", paddingInlineStart: "$2", paddingInlineEnd: 2,
|
|
127
|
+
// The phone's drawer lines up with its bar (BAND); beside the rail, with the rail's first mark (ground.ts HEAD).
|
|
128
|
+
height: drawer ? BAND : LINE, $touchable: drawer ? undefined : { height: TOUCH_HEAD }, shrink: 0, minW: 0, "data-tauri-drag-region": "deep", onMouseDown: dragWindow, onDoubleClick: toggleWindowMaximize, children: [_jsx(Text, { flex: 1, minW: 0, fontSize: drawer ? 20 : 18, lineHeight: 24, fontWeight: drawer ? '700' : '600', color: "$ink", numberOfLines: 1, children: wordmark(mode) }), drawer ? null : _jsx(Activity, { host: host }), _jsx(SidebarIconButton, { label: t('Search'), "data-tauri-drag-region": "false", onPress: onSeek, "aria-haspopup": "dialog", ...(drawer
|
|
125
129
|
? {
|
|
126
130
|
width: 40,
|
|
127
131
|
height: 40,
|
package/dist/Contents.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { type Say } from '@hanzo/i18n';
|
|
2
1
|
import { type Api, type Passage, type WorkFile } from './lib/files.js';
|
|
2
|
+
import { type Say } from './say.js';
|
|
3
3
|
/** How far a file's ingest has got, as Drive's badge and this pane's head say it, in the reader's words given their `t`. */
|
|
4
4
|
export declare function standing(f: WorkFile, t?: Say): string;
|
|
5
5
|
/** The badge a Drive row wears for its index state. */
|
package/dist/Contents.js
CHANGED
|
@@ -10,11 +10,12 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
10
10
|
// tree `retrieve` reads before it picks where to look, so what a person browses
|
|
11
11
|
// here is what an answer cites.
|
|
12
12
|
import { useEffect, useState } from 'react';
|
|
13
|
-
import { phrase
|
|
13
|
+
import { phrase } from '@hanzo/i18n';
|
|
14
14
|
import { useI18n } from '@hanzo/i18n/react';
|
|
15
15
|
import { ArrowLeft, MessageSquare, X } from 'lucide-react';
|
|
16
16
|
import { Box, Button, Text, XStack, YStack } from '@hanzo/ui';
|
|
17
17
|
import { pct, section as openSection, toc } from './lib/files.js';
|
|
18
|
+
import { english } from './say.js';
|
|
18
19
|
import { BAD } from './lib/mix.js';
|
|
19
20
|
/** What each stage of a file's ingest is doing, as a person reads it: authored English, drawn through `t`. */
|
|
20
21
|
const STAGE = {
|