@remit/ui 0.0.234 → 0.0.236
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/components/ErrorBanner.js +3 -3
- package/dist/components/ErrorState.js +3 -3
- package/dist/components/KeyboardShortcutsModal.js +1 -1
- package/dist/components/account-menu.js +1 -1
- package/dist/components/account-service-status.js +2 -2
- package/dist/components/address-display.js +1 -1
- package/dist/components/address-tag.js +1 -1
- package/dist/components/agenda-flow.d.ts +21 -0
- package/dist/components/agenda-flow.js +1 -1
- package/dist/components/agenda-panels.js +1 -1
- package/dist/components/app-switcher.js +1 -1
- package/dist/components/attachment-list.js +3 -3
- package/dist/components/attendee-row.js +1 -1
- package/dist/components/auto-moved-badge.js +1 -1
- package/dist/components/banner.js +1 -1
- package/dist/components/brief-empty.js +2 -2
- package/dist/components/brief-section.js +1 -1
- package/dist/components/button.d.ts +0 -1
- package/dist/components/calendar-clash-strip.js +1 -1
- package/dist/components/calendar-event-chip-content.js +1 -1
- package/dist/components/calendar-event-popup.js +2 -2
- package/dist/components/calendar-event-sidebar.js +1 -1
- package/dist/components/calendar-failure-note.js +1 -1
- package/dist/components/calendar-guests.js +2 -2
- package/dist/components/calendar-invite-card.js +2 -2
- package/dist/components/calendar-list.js +2 -2
- package/dist/components/calendar-parse-badge.js +2 -2
- package/dist/components/calendar-quick-create.js +1 -1
- package/dist/components/calendar-screen-toolbar.js +1 -1
- package/dist/components/calendar-side-pane.js +1 -1
- package/dist/components/calendar-suggestion-list.js +1 -1
- package/dist/components/calendar-task-popup.js +3 -3
- package/dist/components/calendar-time-grid.js +1 -1
- package/dist/components/checkbox.js +1 -1
- package/dist/components/compose-action-bar.js +3 -3
- package/dist/components/compose-attachments.js +3 -3
- package/dist/components/compose-fab.js +1 -1
- package/dist/components/compose-header.js +1 -1
- package/dist/components/compose-language-setting.js +1 -1
- package/dist/components/compose-smtp-missing-banner.js +2 -2
- package/dist/components/danger-zone-section.js +2 -2
- package/dist/components/event-editor-pane.js +1 -1
- package/dist/components/event-editor.js +1 -1
- package/dist/components/event-suggestion-card.js +2 -2
- package/dist/components/filter-clause-chip.js +1 -1
- package/dist/components/filter-preview-count.js +4 -4
- package/dist/components/flow-screen.js +1 -1
- package/dist/components/folder-manage-actions.js +2 -2
- package/dist/components/folder-mutation-dialog.js +2 -2
- package/dist/components/folder-rename-dialog.js +1 -1
- package/dist/components/folder-role.js +2 -2
- package/dist/components/folder-row.js +2 -2
- package/dist/components/folder-tree-picker.js +1 -1
- package/dist/components/input.d.ts +0 -1
- package/dist/components/intelligence-calendar.js +1 -1
- package/dist/components/intelligence-panel.js +2 -2
- package/dist/components/intelligence-toggle.js +1 -1
- package/dist/components/list-result-header.js +1 -1
- package/dist/components/mail-action-toolbar.js +2 -2
- package/dist/components/mail-header.js +1 -1
- package/dist/components/mcp-connected-apps-page.js +1 -1
- package/dist/components/mcp-permission-list.js +1 -1
- package/dist/components/message-list-pane.js +1 -1
- package/dist/components/message-list-state.js +3 -3
- package/dist/components/message-report-dialog.js +1 -1
- package/dist/components/message-row.js +1 -1
- package/dist/components/message-settlement.js +1 -1
- package/dist/components/mini-month.js +1 -1
- package/dist/components/mobile-message-action-bar.js +2 -2
- package/dist/components/mobile-reading-pane.js +1 -1
- package/dist/components/mobile-search-view.js +1 -1
- package/dist/components/nav-sidebar.js +5 -5
- package/dist/components/nav-toggle-button.js +1 -1
- package/dist/components/new-folder-action.js +1 -1
- package/dist/components/outbox-row.js +2 -2
- package/dist/components/outbox-status-badge.d.ts +1 -1
- package/dist/components/outbox-status-badge.js +6 -6
- package/dist/components/password-input.js +1 -1
- package/dist/components/popover-menu.js +1 -1
- package/dist/components/quarantine-entry-row.js +1 -1
- package/dist/components/quarantine-section.js +2 -2
- package/dist/components/quoted-text.js +1 -1
- package/dist/components/reading-pane-empty.js +1 -1
- package/dist/components/reading-pane.js +1 -1
- package/dist/components/refresh-button.js +2 -2
- package/dist/components/rescue-banner.js +1 -1
- package/dist/components/rescue-candidate-row.js +1 -1
- package/dist/components/rescue-from-spam-flow.js +3 -3
- package/dist/components/rescue-sender-group.js +1 -1
- package/dist/components/rich-text-correction-menu.js +1 -1
- package/dist/components/rich-text-spellcheck-notice.js +3 -3
- package/dist/components/rich-text-toolbar.js +1 -1
- package/dist/components/role-appointment-list.js +1 -1
- package/dist/components/role-appointment-prompt.js +3 -3
- package/dist/components/row-actions.js +2 -2
- package/dist/components/search-chip-input.js +1 -1
- package/dist/components/search-conversion-notice.js +1 -1
- package/dist/components/search-results.js +2 -2
- package/dist/components/search-token-chip.js +1 -1
- package/dist/components/select.d.ts +0 -1
- package/dist/components/select.js +1 -1
- package/dist/components/selection-top-bar.js +2 -2
- package/dist/components/selection-wizard.js +5 -5
- package/dist/components/self-update-confirm-dialog.js +1 -1
- package/dist/components/self-update-progress-overlay.js +3 -3
- package/dist/components/self-update-section.js +5 -5
- package/dist/components/sender-trust-indicator.js +1 -1
- package/dist/components/settings-screen.js +2 -2
- package/dist/components/shell-top-bar.d.ts +24 -0
- package/dist/components/shell-top-bar.js +1 -25
- package/dist/components/slide-panel.js +1 -1
- package/dist/components/swipeable-row.js +3 -3
- package/dist/components/sync-warning-row.js +1 -1
- package/dist/components/sync-warning-section.js +2 -2
- package/dist/components/touch-list.js +1 -1
- package/dist/components/wizard.js +1 -1
- package/dist/icons.d.ts +109 -0
- package/dist/icons.js +109 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/lib/merge-props.d.ts +8 -0
- package/dist/lib/merge-props.js +29 -0
- package/dist/lib/use-long-press.js +1 -1
- package/package.json +6 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { ChevronDown, ChevronRight, Repeat } from "lucide-react";
|
|
3
2
|
import { useId } from "react";
|
|
3
|
+
import { ChevronDown, ChevronRight, Repeat } from "../icons.js";
|
|
4
4
|
import { addDays, daysFrom } from "../lib/agenda-time.js";
|
|
5
5
|
import { calendarColorClasses } from "../lib/calendar-color.js";
|
|
6
6
|
import { cn } from "../lib/cn.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { AlertTriangle, Globe, Mail, Plus, SlidersHorizontal, X, } from "lucide-react";
|
|
3
2
|
import { useId, useState } from "react";
|
|
3
|
+
import { Globe, Mail, Plus, SlidersHorizontal, TriangleAlert, X, } from "../icons.js";
|
|
4
4
|
import { cn } from "../lib/cn.js";
|
|
5
5
|
import { BlockedReason } from "./blocked-reason.js";
|
|
6
6
|
import { Button } from "./button.js";
|
|
@@ -67,7 +67,7 @@ export function EventSuggestionCard({ suggestion, whenText, onAdd, onReview, onD
|
|
|
67
67
|
}
|
|
68
68
|
act(settlement.timeZone);
|
|
69
69
|
};
|
|
70
|
-
return (_jsxs("article", { "aria-label": suggestion.title, className: cn("flex flex-col gap-2 rounded-lg border border-dashed border-line-strong bg-surface-sunken p-3", className), children: [_jsxs("div", { className: "flex items-start gap-2", children: [_jsxs("span", { className: "min-w-0 flex-1", children: [_jsxs("span", { className: "block text-2xs uppercase tracking-wider text-fg-subtle", children: ["Suggested from mail \u00B7 ", confidenceText(suggestion.confidence)] }), _jsx("span", { className: "block truncate text-sm font-medium text-fg", children: suggestion.title }), _jsx("span", { className: "block text-xs text-fg-muted", children: whenText }), suggestion.location !== "" && (_jsx("span", { className: "block truncate text-xs text-fg-muted", children: suggestion.location }))] }), _jsx("button", { type: "button", "aria-label": "Dismiss suggestion", onClick: onDismiss, disabled: busy, className: cn("flex shrink-0 items-center justify-center rounded-md text-fg-subtle outline-none hover:bg-surface hover:text-fg focus-visible:ring-2 focus-visible:ring-ring", touch ? "size-11" : "size-7"), children: _jsx(X, { className: "size-4" }) })] }), suggestion.ambiguity !== "" && (_jsxs("p", { className: "flex items-start gap-1.5 text-2xs text-warning", children: [_jsx(
|
|
70
|
+
return (_jsxs("article", { "aria-label": suggestion.title, className: cn("flex flex-col gap-2 rounded-lg border border-dashed border-line-strong bg-surface-sunken p-3", className), children: [_jsxs("div", { className: "flex items-start gap-2", children: [_jsxs("span", { className: "min-w-0 flex-1", children: [_jsxs("span", { className: "block text-2xs uppercase tracking-wider text-fg-subtle", children: ["Suggested from mail \u00B7 ", confidenceText(suggestion.confidence)] }), _jsx("span", { className: "block truncate text-sm font-medium text-fg", children: suggestion.title }), _jsx("span", { className: "block text-xs text-fg-muted", children: whenText }), suggestion.location !== "" && (_jsx("span", { className: "block truncate text-xs text-fg-muted", children: suggestion.location }))] }), _jsx("button", { type: "button", "aria-label": "Dismiss suggestion", onClick: onDismiss, disabled: busy, className: cn("flex shrink-0 items-center justify-center rounded-md text-fg-subtle outline-none hover:bg-surface hover:text-fg focus-visible:ring-2 focus-visible:ring-ring", touch ? "size-11" : "size-7"), children: _jsx(X, { className: "size-4" }) })] }), suggestion.ambiguity !== "" && (_jsxs("p", { className: "flex items-start gap-1.5 text-2xs text-warning", children: [_jsx(TriangleAlert, { className: "mt-0.5 size-3 shrink-0", "aria-hidden": true }), suggestion.ambiguity] })), onOpenThread ? (_jsxs("button", { type: "button", onClick: onOpenThread, className: "flex w-full min-w-0 items-center gap-1.5 rounded-sm text-left text-2xs text-accent-2 outline-none hover:underline focus-visible:ring-2 focus-visible:ring-ring", children: [_jsx(Mail, { className: "size-3 shrink-0" }), _jsx("span", { className: "truncate", children: mailLine(suggestion) })] })) : (_jsxs("p", { className: "flex w-full min-w-0 items-center gap-1.5 text-2xs text-fg-subtle", children: [_jsx(Mail, { className: "size-3 shrink-0" }), _jsx("span", { className: "truncate", children: mailLine(suggestion) })] })), suggestion.zoneOptions && (_jsxs("div", { className: "flex flex-col gap-1.5 rounded-md border border-warning/40 p-2", children: [_jsxs("p", { className: "flex items-center gap-1.5 text-2xs font-semibold text-warning", children: [_jsx(Globe, { className: "size-3 shrink-0", "aria-hidden": true }), "Which clock is this on?"] }), suggestion.zoneOptions.map((option) => (_jsxs("button", { type: "button", "aria-pressed": choice === option.timeZone, onClick: () => pickZone(option.timeZone), className: cn("rounded-md border px-2 py-1 text-left outline-none focus-visible:ring-2 focus-visible:ring-ring", touch && "min-h-11", choice === option.timeZone
|
|
71
71
|
? "border-accent bg-accent-soft"
|
|
72
72
|
: "border-line bg-surface hover:border-line-strong"), children: [_jsx("span", { className: "block text-xs font-medium text-fg", children: option.label }), _jsx("span", { className: "block text-2xs text-fg-subtle", children: option.note })] }, option.timeZone)))] })), !settlement.settled && (_jsx(BlockedReason, { id: reasonId, reason: settlement.reason, nudged: nudged, className: "text-2xs text-warning" })), _jsxs("div", { className: "flex items-center gap-2", children: [_jsx(Button, { variant: "primary", size: touch ? "md" : "sm", icon: _jsx(Plus, { className: "size-3.5" }), onClick: carryingTheZone(onAdd), disabled: busy || addBlocked, "aria-describedby": settlement.settled ? undefined : reasonId, className: cn(touch && "min-h-11 flex-1", !settlement.settled && "opacity-55"), children: addLabel }), onReview && (_jsx(Button, { variant: "secondary", size: touch ? "md" : "sm", icon: _jsx(SlidersHorizontal, { className: "size-3.5" }), onClick: carryingTheZone(onReview), disabled: busy, "aria-describedby": settlement.settled ? undefined : reasonId, className: cn(touch && "min-h-11", !settlement.settled && "opacity-55"), children: "Change first" }))] })] }));
|
|
73
73
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Plus, X } from "
|
|
2
|
+
import { Plus, X } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
import { useSuggestList } from "../lib/use-suggest-list.js";
|
|
5
5
|
import { Button } from "./button.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { LoaderCircle, TriangleAlert } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
import { previewCountSummary } from "./filter-rule.js";
|
|
5
5
|
/**
|
|
@@ -10,15 +10,15 @@ import { previewCountSummary } from "./filter-rule.js";
|
|
|
10
10
|
export function FilterPreviewCount({ preview }) {
|
|
11
11
|
const summary = previewCountSummary(preview);
|
|
12
12
|
if (preview.status === "loading") {
|
|
13
|
-
return (_jsxs("p", { className: "flex items-center gap-2 text-xs text-fg-muted", "aria-live": "polite", children: [_jsx(
|
|
13
|
+
return (_jsxs("p", { className: "flex items-center gap-2 text-xs text-fg-muted", "aria-live": "polite", children: [_jsx(LoaderCircle, { className: "size-3.5 animate-spin", "aria-hidden": "true" }), summary] }));
|
|
14
14
|
}
|
|
15
15
|
if (preview.status === "error") {
|
|
16
|
-
return (_jsxs("p", { className: "flex items-center gap-2 text-xs text-danger", role: "alert", children: [_jsx(
|
|
16
|
+
return (_jsxs("p", { className: "flex items-center gap-2 text-xs text-danger", role: "alert", children: [_jsx(TriangleAlert, { className: "size-3.5 shrink-0", "aria-hidden": "true" }), summary] }));
|
|
17
17
|
}
|
|
18
18
|
const empty = preview.count === 0;
|
|
19
19
|
return (_jsxs("p", { className: cn("flex items-center gap-2 text-xs", preview.stale
|
|
20
20
|
? "text-fg-subtle"
|
|
21
21
|
: empty
|
|
22
22
|
? "text-fg-muted"
|
|
23
|
-
: "font-medium text-fg"), "aria-live": "polite", children: [preview.stale && (_jsx(
|
|
23
|
+
: "font-medium text-fg"), "aria-live": "polite", children: [preview.stale && (_jsx(LoaderCircle, { className: "size-3.5 animate-spin", "aria-hidden": "true" })), summary] }));
|
|
24
24
|
}
|
|
@@ -4,8 +4,8 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
4
4
|
* scrolling body, and a fixed footer in the thumb zone. Every multi-decision
|
|
5
5
|
* surface on a phone is this shape, so there is one implementation of it.
|
|
6
6
|
*/
|
|
7
|
-
import { ArrowLeft, X } from "lucide-react";
|
|
8
7
|
import { useRef } from "react";
|
|
8
|
+
import { ArrowLeft, X } from "../icons.js";
|
|
9
9
|
import { cn } from "../lib/cn.js";
|
|
10
10
|
import { useModalFocus } from "../lib/use-modal-focus.js";
|
|
11
11
|
export function FlowStepRail({ count, activeStep }) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Pencil,
|
|
2
|
+
import { Pencil, Trash } from "../icons.js";
|
|
3
3
|
import { Button } from "./button.js";
|
|
4
4
|
/**
|
|
5
5
|
* What a folder row offers beyond opening: rename it, or delete it. A folder
|
|
@@ -10,5 +10,5 @@ export const FolderManageActions = ({ label, onRename, onDelete, deleteBlockedRe
|
|
|
10
10
|
const deleteName = deleteBlockedReason
|
|
11
11
|
? `${deleteLabel(label)} — ${deleteBlockedReason}`
|
|
12
12
|
: deleteLabel(label);
|
|
13
|
-
return (_jsxs("span", { className: "flex shrink-0 items-center gap-0.5 pr-2", children: [_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Pencil, { className: "size-3.5" }), "aria-label": renameLabel(label), onClick: onRename }), _jsx("span", { title: deleteBlockedReason, children: _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(
|
|
13
|
+
return (_jsxs("span", { className: "flex shrink-0 items-center gap-0.5 pr-2", children: [_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Pencil, { className: "size-3.5" }), "aria-label": renameLabel(label), onClick: onRename }), _jsx("span", { title: deleteBlockedReason, children: _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Trash, { className: "size-3.5" }), "aria-label": deleteName, disabled: deleteBlockedReason !== undefined, onClick: onDelete }) })] }));
|
|
14
14
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { LoaderCircle, TriangleAlert } from "../icons.js";
|
|
3
3
|
import { Button } from "./button.js";
|
|
4
4
|
import { Dialog } from "./dialog.js";
|
|
5
5
|
function dialogTitle(intent, phase) {
|
|
@@ -43,6 +43,6 @@ export function FolderMutationDialog({ open, intent, folderName, targetName, pha
|
|
|
43
43
|
return null;
|
|
44
44
|
const title = dialogTitle(intent, phase);
|
|
45
45
|
const body = dialogBody(intent, folderName, targetName, phase);
|
|
46
|
-
const icon = phase.kind === "waiting" ? (_jsx(
|
|
46
|
+
const icon = phase.kind === "waiting" ? (_jsx(LoaderCircle, { className: "size-4 shrink-0 animate-spin text-accent-2" })) : phase.kind === "failed" || phase.kind === "conflict" ? (_jsx(TriangleAlert, { className: "size-4 shrink-0 text-danger" })) : null;
|
|
47
47
|
return (_jsxs(Dialog, { open: open, onClose: onClose, title: title, children: [_jsxs("header", { className: "flex items-center gap-2 border-b border-line px-5 py-3", children: [icon, _jsx("span", { className: "flex-1 text-sm font-semibold text-fg", children: title })] }), _jsx("div", { className: "space-y-3 px-5 py-4 text-sm text-fg-muted", children: _jsx("p", { children: body }) }), _jsxs("footer", { className: "flex items-center justify-end gap-2 border-t border-line px-5 py-3", children: [phase.kind === "failed" && (_jsx(Button, { variant: "secondary", size: "sm", onClick: onRetry, children: "Try again" })), phase.kind === "conflict" ? (_jsx(Button, { variant: "primary", size: "sm", onClick: onRefresh, children: "Refresh" })) : (_jsx(Button, { variant: "secondary", size: "sm", onClick: onClose, children: "Close" }))] })] }));
|
|
48
48
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { X } from "lucide-react";
|
|
3
2
|
import { useId } from "react";
|
|
3
|
+
import { X } from "../icons.js";
|
|
4
4
|
import { Button } from "./button.js";
|
|
5
5
|
import { Dialog } from "./dialog.js";
|
|
6
6
|
import { FieldLabel } from "./field-label.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Archive, FileText, Inbox, Mails, OctagonAlert, Send, Star,
|
|
2
|
+
import { Archive, FileText, Inbox, Mails, OctagonAlert, Send, Star, Trash, } from "../icons.js";
|
|
3
3
|
import { folderLeaf, folderPathSegments } from "../lib/folder-tree.js";
|
|
4
4
|
/* Canonical English labels, matching the `sidebar.${role}` i18n keys
|
|
5
5
|
(mail.json). At the app boundary these get localized; the kit ships the
|
|
@@ -72,7 +72,7 @@ export function roleIcon(role) {
|
|
|
72
72
|
if (role === "junk")
|
|
73
73
|
return _jsx(OctagonAlert, { className: "size-4" });
|
|
74
74
|
if (role === "trash")
|
|
75
|
-
return _jsx(
|
|
75
|
+
return _jsx(Trash, { className: "size-4" });
|
|
76
76
|
if (role === "flagged")
|
|
77
77
|
return _jsx(Star, { className: "size-4" });
|
|
78
78
|
return _jsx(Mails, { className: "size-4" });
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { Check, ChevronRight, CircleAlert, Folder } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
export const FOLDER_ROW_BASE = "flex min-h-11 min-w-0 flex-1 items-center gap-2 px-3 py-2.5 text-left text-sm transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-inset";
|
|
5
5
|
export const FOLDER_INDENT_STEP = 14;
|
|
@@ -19,7 +19,7 @@ export const FolderRow = ({ label, depth, expanded, ariaLabel, selected = false,
|
|
|
19
19
|
const chevron = (_jsx(ChevronRight, { className: cn("size-4 shrink-0 text-fg-subtle transition-transform", expanded && "rotate-90"), "aria-hidden": "true" }));
|
|
20
20
|
const icon = (_jsx(Folder, { className: "size-4 shrink-0 text-fg-subtle", "aria-hidden": "true" }));
|
|
21
21
|
const count = messageCount === undefined ? null : (_jsxs("span", { "aria-hidden": "true", className: "shrink-0 text-2xs text-fg-subtle", children: [messageCount, " ", messageCount === 1 ? "msg" : "msgs"] }));
|
|
22
|
-
const name = (_jsxs("span", { className: "min-w-0 flex-1", children: [_jsx("span", { className: "block truncate", children: label }), failure && (_jsxs("span", { className: "flex items-center gap-1 text-2xs text-danger", children: [_jsx(
|
|
22
|
+
const name = (_jsxs("span", { className: "min-w-0 flex-1", children: [_jsx("span", { className: "block truncate", children: label }), failure && (_jsxs("span", { className: "flex items-center gap-1 text-2xs text-danger", children: [_jsx(CircleAlert, { className: "size-3 shrink-0", "aria-hidden": "true" }), _jsx("span", { className: "truncate", children: failure })] }))] }));
|
|
23
23
|
const announced = failure ? `${ariaLabel} — ${failure}` : ariaLabel;
|
|
24
24
|
if (context) {
|
|
25
25
|
return (_jsxs("div", { className: "relative flex items-center", children: [_jsxs("div", { role: "treeitem", "aria-level": depth + 1, "aria-selected": false, "aria-expanded": expanded, "aria-label": announced, className: cn(FOLDER_ROW_BASE, "opacity-60"), children: [_jsx(FolderRowIndent, { depth: depth }), chevron, icon, name, count] }), actions, separated && _jsx(FolderRowSeparator, { depth: depth })] }));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Search } from "lucide-react";
|
|
3
2
|
import { useCallback, useEffect, useMemo, useRef, useState, } from "react";
|
|
3
|
+
import { Search } from "../icons.js";
|
|
4
4
|
import { isAbortError } from "../lib/abort.js";
|
|
5
5
|
import { collapseFolderTree, filterFolderTree, folderAncestors, orderFolderNodes, queryExpandedPaths, withCreateRows, } from "../lib/folder-tree.js";
|
|
6
6
|
import { findFirstFocusable, findLastFocusable, findNextFocusable, findParentRow, isFocusable, isSelectable, } from "../lib/folder-tree-focus.js";
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import type { InputHTMLAttributes, ReactNode, Ref } from "react";
|
|
2
2
|
export type InputVariant = "default" | "inline";
|
|
3
3
|
export interface InputProps extends InputHTMLAttributes<HTMLInputElement> {
|
|
4
|
-
/** Optional leading icon (lucide-react element). */
|
|
5
4
|
icon?: ReactNode;
|
|
6
5
|
/**
|
|
7
6
|
* `default` renders the boxed field (border, sunken surface, focus ring).
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { CalendarDays, Reply } from "lucide-react";
|
|
3
2
|
import { useState } from "react";
|
|
3
|
+
import { CalendarDays, Reply } from "../icons.js";
|
|
4
4
|
import { cn } from "../lib/cn.js";
|
|
5
5
|
import { Button } from "./button.js";
|
|
6
6
|
import { CalendarEventChip } from "./calendar-event-chip.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { BellOff, MailCheck, ShieldAlert, ShieldCheck, ShieldQuestion, ShieldX, Sparkles, Star, X, } from "lucide-react";
|
|
3
2
|
import { useId, useState } from "react";
|
|
4
3
|
import { categoryLabels, categoryTone, } from "../category-presentation.js";
|
|
4
|
+
import { BellOff, MailCheck, ShieldAlert, ShieldCheck, ShieldQuestionMark, ShieldX, Sparkles, Star, X, } from "../icons.js";
|
|
5
5
|
import { cn } from "../lib/cn.js";
|
|
6
6
|
import { Avatar } from "./avatar.js";
|
|
7
7
|
import { Badge } from "./badge.js";
|
|
@@ -36,7 +36,7 @@ function Authenticity({ auth }) {
|
|
|
36
36
|
return (_jsxs("div", { className: "flex items-start gap-2 text-xs text-fg-muted", children: [_jsx(ShieldCheck, { className: "mt-0.5 size-3.5 shrink-0 text-positive" }), _jsx("span", { children: auth.summary })] }));
|
|
37
37
|
}
|
|
38
38
|
if (auth.verdict === "caution") {
|
|
39
|
-
return (_jsxs("div", { className: "flex items-start gap-2 rounded-md bg-warning/10 p-3 text-warning", children: [_jsx(
|
|
39
|
+
return (_jsxs("div", { className: "flex items-start gap-2 rounded-md bg-warning/10 p-3 text-warning", children: [_jsx(ShieldQuestionMark, { className: "mt-0.5 size-4 shrink-0" }), _jsx("p", { className: "text-xs leading-relaxed", children: auth.summary })] }));
|
|
40
40
|
}
|
|
41
41
|
const headline = auth.addressUnreadable
|
|
42
42
|
? "This sender can't be verified"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { FolderInput, Forward, Reply, ReplyAll, Star,
|
|
2
|
+
import { FolderInput, Forward, Reply, ReplyAll, Star, Trash, } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
import { Button } from "./button.js";
|
|
5
5
|
/**
|
|
@@ -23,7 +23,7 @@ export function MailActionToolbar({ hasThread, onUnavailable, unavailableHint, i
|
|
|
23
23
|
}
|
|
24
24
|
handler();
|
|
25
25
|
};
|
|
26
|
-
return (_jsxs("div", { className: "relative", children: [_jsxs("header", { className: cn("flex h-pane-header shrink-0 items-center gap-1 border-b border-line bg-surface px-3", className), children: [_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Reply, { className: "size-4" }), title: replyTitle, "aria-label": "Reply", onClick: act("reply", onReply) }), _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(ReplyAll, { className: "size-4" }), title: replyAllTitle, "aria-label": "Reply all", onClick: act("replyAll", onReplyAll) }), _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Forward, { className: "size-4" }), title: forwardTitle, "aria-label": "Forward", onClick: act("forward", onForward) }), showTriage && (_jsxs(_Fragment, { children: [_jsx("span", { className: "mx-1 h-4 w-px bg-line", "aria-hidden": true }), _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(
|
|
26
|
+
return (_jsxs("div", { className: "relative", children: [_jsxs("header", { className: cn("flex h-pane-header shrink-0 items-center gap-1 border-b border-line bg-surface px-3", className), children: [_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Reply, { className: "size-4" }), title: replyTitle, "aria-label": "Reply", onClick: act("reply", onReply) }), _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(ReplyAll, { className: "size-4" }), title: replyAllTitle, "aria-label": "Reply all", onClick: act("replyAll", onReplyAll) }), _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Forward, { className: "size-4" }), title: forwardTitle, "aria-label": "Forward", onClick: act("forward", onForward) }), showTriage && (_jsxs(_Fragment, { children: [_jsx("span", { className: "mx-1 h-4 w-px bg-line", "aria-hidden": true }), _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Trash, { className: "size-4" }), title: deleteTitle, "aria-label": "Move to Trash", onClick: act("delete", onDelete) }), moveSlot ?? (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(FolderInput, { className: "size-4" }), title: "Move to mailbox", "aria-label": "Move to mailbox", onClick: act("move", onMove) })), _jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Star, { className: cn("size-4", isStarred && "fill-warning text-warning") }), title: flagTitle, "aria-label": "Star", "aria-pressed": isStarred, onClick: act("flag", onToggleStar) })] })), _jsx("div", { className: "flex-1" }), children] }), unavailableHint && (
|
|
27
27
|
// biome-ignore lint/a11y/useSemanticElements: <p> with role="status" preserves block layout; <output> is inline
|
|
28
28
|
_jsx("p", { role: "status", className: "border-b border-line bg-surface-sunken px-3 py-1 text-2xs text-fg-subtle", children: unavailableHint }))] }));
|
|
29
29
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Menu, Search, X } from "
|
|
2
|
+
import { Menu, Search, X } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
import { Button } from "./button.js";
|
|
5
5
|
import { SearchBar } from "./search-bar.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Unplug } from "
|
|
2
|
+
import { Unplug } from "../icons.js";
|
|
3
3
|
import { Banner } from "./banner.js";
|
|
4
4
|
import { Button } from "./button.js";
|
|
5
5
|
import { McpErrorNotice } from "./mcp-error-notice.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Check } from "
|
|
2
|
+
import { Check } from "../icons.js";
|
|
3
3
|
export function McpPermissionList({ permissions }) {
|
|
4
4
|
return (_jsx("ul", { className: "flex flex-col gap-2 text-sm", children: permissions.map((permission) => (_jsxs("li", { className: "flex items-start gap-2 text-fg", children: [_jsx(Check, { className: "mt-0.5 size-4 shrink-0 text-positive", "aria-hidden": "true" }), _jsx("span", { children: permission.description })] }, permission.scope))) }));
|
|
5
5
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Menu } from "lucide-react";
|
|
3
2
|
import { useCallback, useEffect, useRef, useState } from "react";
|
|
3
|
+
import { Menu } from "../icons.js";
|
|
4
4
|
import { defaultKeyboardHints, keyboardHintsFor } from "../lib/keymap.js";
|
|
5
5
|
import { LIST_ROW_SELECTOR, useRovingFocus } from "../lib/roving-focus.js";
|
|
6
6
|
import { deriveIsMultiSelectMode, modifiersOf } from "../lib/use-selection.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { CircleAlert, LoaderCircle } from "../icons.js";
|
|
3
3
|
import { Button } from "./button.js";
|
|
4
4
|
/**
|
|
5
5
|
* Skeleton mirror of the live web-client MessageList LoadingSkeleton: eight
|
|
@@ -64,7 +64,7 @@ function EmptyFrame({ children }) {
|
|
|
64
64
|
* reads as "nothing there".
|
|
65
65
|
*/
|
|
66
66
|
export function MessageListLoadingMore() {
|
|
67
|
-
return (_jsxs("div", { className: "flex items-center justify-center gap-2 py-4 text-sm text-fg-muted", role: "status", "aria-live": "polite", children: [_jsx(
|
|
67
|
+
return (_jsxs("div", { className: "flex items-center justify-center gap-2 py-4 text-sm text-fg-muted", role: "status", "aria-live": "polite", children: [_jsx(LoaderCircle, { className: "size-4 animate-spin", "aria-hidden": "true" }), _jsx("span", { children: "Loading more\u2026" })] }));
|
|
68
68
|
}
|
|
69
69
|
/**
|
|
70
70
|
* Fail-hard list error (ux.md): a centered, blocking message that stops the
|
|
@@ -73,5 +73,5 @@ export function MessageListLoadingMore() {
|
|
|
73
73
|
* plus a way for the failure to go somewhere (Report).
|
|
74
74
|
*/
|
|
75
75
|
export function MessageListError({ message = "Something went wrong loading this mailbox.", onRetry, onReport, }) {
|
|
76
|
-
return (_jsx("div", { className: "flex h-full flex-1 items-center justify-center p-4", children: _jsxs("div", { role: "alert", className: "flex max-w-sm flex-col items-center justify-center gap-3 text-center", children: [_jsx(
|
|
76
|
+
return (_jsx("div", { className: "flex h-full flex-1 items-center justify-center p-4", children: _jsxs("div", { role: "alert", className: "flex max-w-sm flex-col items-center justify-center gap-3 text-center", children: [_jsx(CircleAlert, { className: "size-8 text-danger", "aria-hidden": "true" }), _jsxs("div", { children: [_jsx("p", { className: "font-medium text-danger", children: "Couldn't load messages" }), _jsx("p", { className: "mt-1 break-words text-sm text-fg-muted", children: message })] }), _jsxs("div", { className: "flex items-center gap-2", children: [onRetry && (_jsx(Button, { variant: "secondary", size: "sm", onClick: onRetry, children: "Retry" })), onReport && (_jsx(Button, { variant: "ghost", size: "sm", onClick: onReport, children: "Report a problem" }))] })] }) }));
|
|
77
77
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { Check, Paperclip, ShieldAlert, Star } from "lucide-react";
|
|
3
2
|
import { categoryTone, getCategoryLabel } from "../category-presentation.js";
|
|
3
|
+
import { Check, Paperclip, ShieldAlert, Star } from "../icons.js";
|
|
4
4
|
import { cn } from "../lib/cn.js";
|
|
5
5
|
import { ROW_ATTRIBUTE } from "../lib/keymap-dispatch.js";
|
|
6
6
|
import { LIST_ROW_ATTRIBUTE } from "../lib/roving-focus.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { ChevronLeft, ChevronRight } from "
|
|
2
|
+
import { ChevronLeft, ChevronRight } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
import { miniMonthWeeks, shiftMonth } from "../lib/mini-month.js";
|
|
5
5
|
const WEEKDAYS = ["M", "T", "W", "T", "F", "S", "S"];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Forward, Mail, MailOpen, Reply, ReplyAll, Star,
|
|
2
|
+
import { Forward, Mail, MailOpen, Reply, ReplyAll, Star, Trash, } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
import { Button } from "./button.js";
|
|
5
5
|
import { PopoverMenu } from "./popover-menu.js";
|
|
@@ -38,7 +38,7 @@ export function MobileMessageActionBar({ hasThread, onReply, onReplyAll, onForwa
|
|
|
38
38
|
},
|
|
39
39
|
]
|
|
40
40
|
: [];
|
|
41
|
-
return (_jsxs("div", { className: cn("relative", className), children: [_jsxs("div", { className: "flex h-12 shrink-0 items-center gap-0.5 bg-canvas px-1", children: [onReply && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Reply, { className: "size-5" }), onClick: act("reply", onReply), "aria-label": "Reply", title: "Reply", className: TOUCH })), onReplyAll && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(ReplyAll, { className: "size-5" }), onClick: act("replyAll", onReplyAll), "aria-label": "Reply all", title: "Reply all", className: TOUCH })), onForward && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Forward, { className: "size-5" }), onClick: act("forward", onForward), "aria-label": "Forward", title: "Forward", className: TOUCH })), _jsx("div", { className: "flex-1" }), onToggleStar && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Star, { className: cn("size-5", isStarred && "fill-warning text-warning") }), onClick: act("star", onToggleStar), "aria-label": isStarred ? "Unstar" : "Star", "aria-pressed": isStarred, title: isStarred ? "Unstar" : "Star", className: TOUCH })), moveSlot, onDelete && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(
|
|
41
|
+
return (_jsxs("div", { className: cn("relative", className), children: [_jsxs("div", { className: "flex h-12 shrink-0 items-center gap-0.5 bg-canvas px-1", children: [onReply && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Reply, { className: "size-5" }), onClick: act("reply", onReply), "aria-label": "Reply", title: "Reply", className: TOUCH })), onReplyAll && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(ReplyAll, { className: "size-5" }), onClick: act("replyAll", onReplyAll), "aria-label": "Reply all", title: "Reply all", className: TOUCH })), onForward && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Forward, { className: "size-5" }), onClick: act("forward", onForward), "aria-label": "Forward", title: "Forward", className: TOUCH })), _jsx("div", { className: "flex-1" }), onToggleStar && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Star, { className: cn("size-5", isStarred && "fill-warning text-warning") }), onClick: act("star", onToggleStar), "aria-label": isStarred ? "Unstar" : "Star", "aria-pressed": isStarred, title: isStarred ? "Unstar" : "Star", className: TOUCH })), moveSlot, onDelete && (_jsx(Button, { variant: "ghost", size: "sm", icon: _jsx(Trash, { className: "size-5" }), onClick: act("delete", onDelete), "aria-label": "Move to Trash", title: "Move to Trash", className: TOUCH })), _jsx(PopoverMenu, { triggerLabel: "More actions", items: [...readItem, ...overflowItems] })] }), !hasThread && unavailableHint && (
|
|
42
42
|
// biome-ignore lint/a11y/useSemanticElements: <p> with role="status" preserves block layout; <output> is inline
|
|
43
43
|
_jsx("p", { role: "status", className: "bg-surface-sunken px-3 py-1 text-2xs text-fg-subtle", children: unavailableHint }))] }));
|
|
44
44
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { ArrowLeft, Info } from "lucide-react";
|
|
3
2
|
import { useState } from "react";
|
|
3
|
+
import { ArrowLeft, Info } from "../icons.js";
|
|
4
4
|
import { cn } from "../lib/cn.js";
|
|
5
5
|
import { SwipeSurface, useSwipeNavigation, } from "../lib/use-swipe-navigation.js";
|
|
6
6
|
import { Button } from "./button.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { X } from "
|
|
2
|
+
import { X } from "../icons.js";
|
|
3
3
|
import { Button } from "./button.js";
|
|
4
4
|
import { FilterPanelBoundary, FilterSheet, } from "./filter-sheet.js";
|
|
5
5
|
import { SearchBar } from "./search-bar.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { AlertCircle, AlertOctagon, Archive, BellOff, CalendarDays, ChevronDown, ChevronRight, FileText, Folder, Inbox, Mails, PauseCircle, Send, Sparkles, Star, Trash2, } from "lucide-react";
|
|
3
2
|
import { useRef, useState } from "react";
|
|
3
|
+
import { Archive, BellOff, CalendarDays, ChevronDown, ChevronRight, CircleAlert, CirclePause, FileText, Folder, Inbox, Mails, OctagonAlert, Send, Sparkles, Star, Trash, } from "../icons.js";
|
|
4
4
|
import { cn } from "../lib/cn.js";
|
|
5
5
|
import { useRovingFocus } from "../lib/roving-focus.js";
|
|
6
6
|
import { ACCOUNT_SERVICE_OFF_LABEL } from "./account-service-status.js";
|
|
@@ -17,7 +17,7 @@ function navItemClassName({ active, dimmed, indent, }) {
|
|
|
17
17
|
: "text-fg-muted hover:bg-surface hover:text-fg", dimmed && "opacity-55");
|
|
18
18
|
}
|
|
19
19
|
function NavItemInner({ icon, label, count, active, failure, }) {
|
|
20
|
-
return (_jsxs(_Fragment, { children: [icon && (_jsx("span", { className: cn("shrink-0", active ? "text-accent-2" : "text-fg-subtle"), children: icon })), _jsx("span", { className: "flex-1 truncate", children: label }), failure && (_jsx(
|
|
20
|
+
return (_jsxs(_Fragment, { children: [icon && (_jsx("span", { className: cn("shrink-0", active ? "text-accent-2" : "text-fg-subtle"), children: icon })), _jsx("span", { className: "flex-1 truncate", children: label }), failure && (_jsx(CircleAlert, { className: "size-3.5 shrink-0 text-danger", "aria-hidden": "true" })), count != null && count > 0 && (_jsx("span", { className: cn("text-2xs tabular-nums", active ? "text-accent-2" : "text-fg-subtle"), children: count }))] }));
|
|
21
21
|
}
|
|
22
22
|
/**
|
|
23
23
|
* A navigation entry. Renders a real anchor through `linkComponent` when given a
|
|
@@ -72,9 +72,9 @@ function roleIcon(role) {
|
|
|
72
72
|
case "all":
|
|
73
73
|
return _jsx(Mails, { className: "size-4" });
|
|
74
74
|
case "junk":
|
|
75
|
-
return _jsx(
|
|
75
|
+
return _jsx(OctagonAlert, { className: "size-4" });
|
|
76
76
|
case "trash":
|
|
77
|
-
return _jsx(
|
|
77
|
+
return _jsx(Trash, { className: "size-4" });
|
|
78
78
|
}
|
|
79
79
|
}
|
|
80
80
|
const hasRole = (mb) => mb.role != null;
|
|
@@ -135,7 +135,7 @@ function AccountNav({ account, selectedNavId, onSelectNav, linkComponent, }) {
|
|
|
135
135
|
const mailOff = account.syncedServices !== undefined &&
|
|
136
136
|
!account.syncedServices.includes("Mail");
|
|
137
137
|
const isEmpty = status === "ready" && system.length === 0 && folders.length === 0;
|
|
138
|
-
return (_jsxs("div", { className: "mt-3", children: [_jsxs("button", { type: "button", onClick: toggleAccount, "aria-expanded": accountOpen, className: cn("flex w-full items-center gap-1.5 px-2 pb-1 text-left transition-colors hover:text-fg", FOCUS_RING, account.muted && "opacity-55"), children: [accountOpen ? (_jsx(ChevronDown, { className: "size-3 shrink-0 text-fg-subtle" })) : (_jsx(ChevronRight, { className: "size-3 shrink-0 text-fg-subtle" })), _jsx("span", { className: "truncate text-2xs font-semibold uppercase tracking-wider text-fg-subtle", children: account.label }), account.muted && (_jsxs(_Fragment, { children: [_jsx(BellOff, { className: "size-3 shrink-0 text-fg-subtle" }), _jsx("span", { className: "text-2xs text-fg-subtle", children: "muted" })] })), mailOff && (_jsxs(_Fragment, { children: [_jsx(
|
|
138
|
+
return (_jsxs("div", { className: "mt-3", children: [_jsxs("button", { type: "button", onClick: toggleAccount, "aria-expanded": accountOpen, className: cn("flex w-full items-center gap-1.5 px-2 pb-1 text-left transition-colors hover:text-fg", FOCUS_RING, account.muted && "opacity-55"), children: [accountOpen ? (_jsx(ChevronDown, { className: "size-3 shrink-0 text-fg-subtle" })) : (_jsx(ChevronRight, { className: "size-3 shrink-0 text-fg-subtle" })), _jsx("span", { className: "truncate text-2xs font-semibold uppercase tracking-wider text-fg-subtle", children: account.label }), account.muted && (_jsxs(_Fragment, { children: [_jsx(BellOff, { className: "size-3 shrink-0 text-fg-subtle" }), _jsx("span", { className: "text-2xs text-fg-subtle", children: "muted" })] })), mailOff && (_jsxs(_Fragment, { children: [_jsx(CirclePause, { className: "size-3 shrink-0 text-fg-subtle" }), _jsx("span", { className: "text-2xs text-fg-subtle", children: ACCOUNT_SERVICE_OFF_LABEL.Mail })] }))] }), accountOpen && (_jsxs(_Fragment, { children: [status === "loading" && (_jsx("div", { className: "px-2 py-1 text-sm text-fg-muted", children: "Loading\u2026" })), status === "error" && (_jsxs("div", { role: "alert", className: "mx-2 my-1 flex items-start gap-2 rounded-md border border-danger/40 bg-danger-soft px-2 py-1.5 text-sm", children: [_jsx(CircleAlert, { className: "mt-0.5 size-4 shrink-0 text-danger", "aria-hidden": "true" }), _jsx("div", { className: "min-w-0 flex-1", children: _jsx("p", { className: "font-medium text-danger", children: "Couldn't load mailboxes" }) }), account.onRetry && (_jsx("button", { type: "button", onClick: account.onRetry, className: "shrink-0 text-sm font-medium text-accent hover:underline", children: "Retry" }))] })), isEmpty && (_jsx("div", { className: "px-2 py-1 text-sm text-fg-muted", children: "No mailboxes" })), status === "ready" && (_jsxs(_Fragment, { children: [system.map((mb) => (_jsx(NavItem, { navId: mb.id, linkComponent: linkComponent, icon: roleIcon(mb.role), label: mb.name, ariaLabel: mb.name, title: mb.fullPath ?? mb.name, failure: mb.failure, count: mb.unseen, active: selectedNavId === mb.id, dimmed: account.muted, onClick: () => onSelectNav?.(mb.id) }, mb.id))), account.outboxPending !== undefined && (_jsx(NavItem, { navId: "outbox", linkComponent: linkComponent, icon: _jsx(Send, { className: "size-4" }), label: "Outbox", ariaLabel: "Outbox", count: account.outboxPending > 0
|
|
139
139
|
? account.outboxPending
|
|
140
140
|
: undefined, active: selectedNavId === "outbox", dimmed: account.muted, onClick: () => onSelectNav?.("outbox") })), folders.length > 0 && (_jsxs(_Fragment, { children: [_jsxs("button", { type: "button", onClick: toggleFolders, "aria-expanded": foldersOpen, className: cn("mt-1 flex w-full items-center gap-1 px-2 py-1 text-left text-2xs font-semibold uppercase tracking-wider text-fg-subtle transition-colors hover:text-fg", FOCUS_RING), children: [foldersOpen ? (_jsx(ChevronDown, { className: "size-3 shrink-0" })) : (_jsx(ChevronRight, { className: "size-3 shrink-0" })), _jsx("span", { className: "flex-1", children: "Folders" }), _jsx("span", { className: "tabular-nums opacity-70", children: folders.length })] }), foldersOpen && (_jsxs(_Fragment, { children: [visibleFolders.map((mb) => (_jsx(NavItem, { navId: mb.id, linkComponent: linkComponent, icon: _jsx(Folder, { className: "size-4" }), label: mb.name, ariaLabel: mb.name, title: mb.fullPath ?? mb.name, failure: mb.failure, count: mb.unseen, active: selectedNavId === mb.id, dimmed: account.muted, onClick: () => onSelectNav?.(mb.id) }, mb.id))), (hiddenCount > 0 || showAllFolders) &&
|
|
141
141
|
folders.length > FOLDER_COLLAPSE_THRESHOLD && (_jsx("button", { type: "button", onClick: () => setShowAllFolders((all) => !all), className: cn("ml-7 flex items-center px-2 py-1 text-2xs font-medium text-accent transition-colors hover:underline", FOCUS_RING), children: showAllFolders
|
|
@@ -9,7 +9,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
9
9
|
*
|
|
10
10
|
* Renders nothing outside an `AppShellSlotted` — there is no nav to act on.
|
|
11
11
|
*/
|
|
12
|
-
import { Menu } from "
|
|
12
|
+
import { Menu } from "../icons.js";
|
|
13
13
|
import { useAppShellLayout } from "./app-shell-slotted.js";
|
|
14
14
|
import { Button } from "./button.js";
|
|
15
15
|
export function NavToggleButton() {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { FolderPlus } from "
|
|
2
|
+
import { FolderPlus } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
import { FOLDER_ROW_BASE, FolderRowIndent, FolderRowSeparator, } from "./folder-row.js";
|
|
5
5
|
/** Makes a folder where the user is looking, as a row in the list. */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { RotateCcw, Send,
|
|
2
|
+
import { RotateCcw, Send, Trash } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
import { LIST_ROW_ATTRIBUTE } from "../lib/roving-focus.js";
|
|
5
5
|
import { OutboxStatusBadge } from "./outbox-status-badge.js";
|
|
@@ -41,7 +41,7 @@ export function OutboxRow({ recipients, subject, time, status, error, selected,
|
|
|
41
41
|
], destructive: {
|
|
42
42
|
label: "Delete message",
|
|
43
43
|
iconOnly: true,
|
|
44
|
-
icon: _jsx(
|
|
44
|
+
icon: _jsx(Trash, { className: "size-3.5" }),
|
|
45
45
|
busy: deleting,
|
|
46
46
|
confirm: {
|
|
47
47
|
prompt: "Delete this message?",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Clock } from "
|
|
1
|
+
import { Clock } from "../icons.js";
|
|
2
2
|
/** The non-draft outbox lifecycle states (drafts live in a separate view). */
|
|
3
3
|
export type OutboxStatus = "queued" | "sending" | "sent" | "unfiled" | "failed" | "blocked";
|
|
4
4
|
interface StatusConfig {
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { CircleAlert, CircleCheckBig, Clock, LoaderCircle, TriangleAlert, } from "../icons.js";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
4
|
export const outboxStatusConfig = {
|
|
5
5
|
queued: { icon: Clock, label: "Queued", className: "text-warning" },
|
|
6
6
|
sending: {
|
|
7
|
-
icon:
|
|
7
|
+
icon: LoaderCircle,
|
|
8
8
|
label: "Sending…",
|
|
9
9
|
className: "text-accent-2",
|
|
10
10
|
spin: true,
|
|
11
11
|
},
|
|
12
|
-
sent: { icon:
|
|
12
|
+
sent: { icon: CircleCheckBig, label: "Sent", className: "text-positive" },
|
|
13
13
|
unfiled: {
|
|
14
|
-
icon:
|
|
14
|
+
icon: TriangleAlert,
|
|
15
15
|
label: "Sent, not filed",
|
|
16
16
|
className: "text-warning",
|
|
17
17
|
},
|
|
18
|
-
failed: { icon:
|
|
19
|
-
blocked: { icon:
|
|
18
|
+
failed: { icon: CircleAlert, label: "Failed", className: "text-danger" },
|
|
19
|
+
blocked: { icon: TriangleAlert, label: "Blocked", className: "text-warning" },
|
|
20
20
|
};
|
|
21
21
|
/** Status-tinted icon + label for an outbox message row. */
|
|
22
22
|
export function OutboxStatusBadge({ status, iconOnly, className, }) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Eye, EyeOff } from "lucide-react";
|
|
3
2
|
import { useState } from "react";
|
|
3
|
+
import { Eye, EyeOff } from "../icons.js";
|
|
4
4
|
import { Input } from "./input.js";
|
|
5
5
|
/**
|
|
6
6
|
* A password field with an in-field reveal toggle. Only `type` changes when
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { EllipsisVertical } from "lucide-react";
|
|
3
2
|
import { useEffect, useLayoutEffect, useRef, useState, } from "react";
|
|
4
3
|
import { createPortal } from "react-dom";
|
|
4
|
+
import { EllipsisVertical } from "../icons.js";
|
|
5
5
|
import { cn } from "../lib/cn.js";
|
|
6
6
|
import { useOverlayScope } from "../lib/overlay-scope.js";
|
|
7
7
|
import { Button } from "./button.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Bug } from "
|
|
2
|
+
import { Bug } from "../icons.js";
|
|
3
3
|
import { folderLeaf } from "../lib/folder-tree.js";
|
|
4
4
|
import { Badge } from "./badge.js";
|
|
5
5
|
import { Button } from "./button.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { CircleCheck, TriangleAlert } from "../icons.js";
|
|
3
3
|
import { Banner } from "./banner.js";
|
|
4
4
|
import { QuarantineEntryRow } from "./quarantine-entry-row.js";
|
|
5
5
|
/**
|
|
@@ -11,5 +11,5 @@ import { QuarantineEntryRow } from "./quarantine-entry-row.js";
|
|
|
11
11
|
* it raises an alert.
|
|
12
12
|
*/
|
|
13
13
|
export function QuarantineSection({ entries, onCutBug, }) {
|
|
14
|
-
return (_jsxs("section", { className: "space-y-3", children: [_jsxs("header", { className: "space-y-1", children: [_jsx("h2", { className: "text-sm font-semibold text-fg", children: "Messages set aside" }), _jsx("p", { className: "text-xs text-fg-muted", children: "Mail Remit could not read is set aside here instead of being skipped, so nothing goes missing quietly. The rest of the folder keeps syncing. Recovering a set-aside message is a re-sync, not a per-row action." })] }), entries.length === 0 && (_jsxs("div", { className: "flex items-center gap-2 rounded-sm border border-line bg-surface px-row-inset py-3", children: [_jsx(
|
|
14
|
+
return (_jsxs("section", { className: "space-y-3", children: [_jsxs("header", { className: "space-y-1", children: [_jsx("h2", { className: "text-sm font-semibold text-fg", children: "Messages set aside" }), _jsx("p", { className: "text-xs text-fg-muted", children: "Mail Remit could not read is set aside here instead of being skipped, so nothing goes missing quietly. The rest of the folder keeps syncing. Recovering a set-aside message is a re-sync, not a per-row action." })] }), entries.length === 0 && (_jsxs("div", { className: "flex items-center gap-2 rounded-sm border border-line bg-surface px-row-inset py-3", children: [_jsx(CircleCheck, { className: "size-4 shrink-0 text-positive", "aria-hidden": true }), _jsx("p", { className: "text-sm text-fg-muted", children: "Every message has been read successfully. Nothing is set aside." })] })), entries.length > 1 && (_jsx(Banner, { tone: "warning", children: _jsxs("p", { className: "flex items-start gap-2", children: [_jsx(TriangleAlert, { className: "mt-0.5 size-4 shrink-0", "aria-hidden": true }), _jsxs("span", { children: [_jsx("span", { className: "font-semibold", children: `${entries.length} messages could not be read.` }), " ", "More than one means something is wrong with how Remit reads mail, not with the mail. Reporting one of these gets it fixed."] })] }) })), entries.length > 0 && (_jsx("ul", { className: "rounded-sm border border-line bg-surface", children: entries.map((entry) => (_jsx(QuarantineEntryRow, { entry: entry, onCutBug: onCutBug }, entry.quarantineId))) }))] }));
|
|
15
15
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { ChevronDown, ChevronRight } from "lucide-react";
|
|
3
2
|
import { useState } from "react";
|
|
3
|
+
import { ChevronDown, ChevronRight } from "../icons.js";
|
|
4
4
|
/**
|
|
5
5
|
* Collapsible quoted-message block for reply/forward compose. Renders a muted
|
|
6
6
|
* attribution toggle ("<sender> on <date> wrote:") that expands to reveal the
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { ChevronDown, ChevronRight, ShieldAlert } from "lucide-react";
|
|
3
2
|
import { useState } from "react";
|
|
3
|
+
import { ChevronDown, ChevronRight, ShieldAlert } from "../icons.js";
|
|
4
4
|
import { cn } from "../lib/cn.js";
|
|
5
5
|
import { isSelfRowActivation } from "../lib/row-keyboard.js";
|
|
6
6
|
import { Avatar } from "./avatar.js";
|