feat(web): morph composer and panel action icons (#14924)
Co-authored-by: maria-rcks <[email protected]>
This commit is contained in:
1 parent
44bd4c9caf
commit
f2cc80a7a4
31 files changed
+278
-230
No files matched your search
@@ -48,8 +48,10 @@
|
||||
"jose": "catalog:",
|
||||
"jsonc-parser": "3.3.1",
|
||||
"jszip": "3.10.1",
|
||||
"lucide": "^0.564.0",
|
||||
"lucide-react": "^0.564.0",
|
||||
"mermaid": "^11.17.2",
|
||||
"morphicons": "^1.7.1",
|
||||
"react": "19.2.6",
|
||||
"react-dom": "19.2.6",
|
||||
"react-markdown": "^10.1.0",
|
||||
|
||||
@@ -5,10 +5,8 @@ import {
|
||||
encodeComposerContextClipboardHtml,
|
||||
} from "@t3tools/shared/composerContextClipboard";
|
||||
import {
|
||||
CheckIcon,
|
||||
ChevronRightIcon,
|
||||
CodeIcon,
|
||||
CopyIcon,
|
||||
FileSpreadsheetIcon,
|
||||
FileTextIcon,
|
||||
GlobeIcon,
|
||||
@@ -16,10 +14,8 @@ import {
|
||||
InfoIcon,
|
||||
LightbulbIcon,
|
||||
MailIcon,
|
||||
Maximize2Icon,
|
||||
MessageSquareIcon,
|
||||
MessageSquareWarningIcon,
|
||||
Minimize2Icon,
|
||||
OctagonAlertIcon,
|
||||
PlayIcon,
|
||||
PresentationIcon,
|
||||
@@ -29,6 +25,7 @@ import {
|
||||
WrapTextIcon,
|
||||
type LucideIcon,
|
||||
} from "lucide-react";
|
||||
import { Check, Copy, Maximize2, Minimize2 } from "lucide";
|
||||
import type {
|
||||
AssetResource,
|
||||
EnvironmentId,
|
||||
@@ -123,6 +120,7 @@ import {
|
||||
import { hasSpecificPierreIconForFileName, syntheticFileNameForLanguageId } from "../pierre-icons";
|
||||
import { Tooltip, TooltipPopup, TooltipTrigger } from "./ui/tooltip";
|
||||
import { Button } from "./ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { ContextChip } from "./ContextChip";
|
||||
import { Collapsible, CollapsiblePanel, CollapsibleTrigger } from "./ui/collapsible";
|
||||
import { ScrollArea } from "./ui/scroll-area";
|
||||
@@ -849,7 +847,7 @@ function MarkdownTable({ children, ...props }: React.ComponentProps<"table">) {
|
||||
/>
|
||||
}
|
||||
>
|
||||
{expanded ? <Minimize2Icon className="size-3" /> : <Maximize2Icon className="size-3" />}
|
||||
<MorphIcon className="size-3" icon={expanded ? Minimize2 : Maximize2} />
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">{expandLabel}</TooltipPopup>
|
||||
</Tooltip>
|
||||
@@ -869,7 +867,7 @@ function MarkdownTable({ children, ...props }: React.ComponentProps<"table">) {
|
||||
/>
|
||||
}
|
||||
>
|
||||
{copied ? <CheckIcon className="size-3" /> : <CopyIcon className="size-3" />}
|
||||
<MorphIcon className="size-3" icon={copied ? Check : Copy} />
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">{copyLabel}</TooltipPopup>
|
||||
</Tooltip>
|
||||
@@ -1063,7 +1061,7 @@ function MarkdownCodeBlock({
|
||||
/>
|
||||
}
|
||||
>
|
||||
{copied ? <CheckIcon className="size-3" /> : <CopyIcon className="size-3" />}
|
||||
<MorphIcon className="size-3" icon={copied ? Check : Copy} />
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">{copyLabel}</TooltipPopup>
|
||||
</Tooltip>
|
||||
|
||||
@@ -1,12 +1,14 @@
|
||||
import { CheckIcon, CopyIcon } from "lucide-react";
|
||||
import { Check, Copy } from "lucide";
|
||||
import { useRef } from "react";
|
||||
import { useCopyToClipboard } from "../hooks/useCopyToClipboard";
|
||||
import { cn } from "../lib/utils";
|
||||
import {
|
||||
ANCHORED_COPY_TOAST_TIMEOUT_MS,
|
||||
showAnchoredCopyErrorToast,
|
||||
showAnchoredCopySuccessToast,
|
||||
} from "./ui/anchoredCopyToast";
|
||||
import { Button } from "./ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { Tooltip, TooltipPopup, TooltipTrigger } from "./ui/tooltip";
|
||||
|
||||
export function DiffFilePathCopyButton({ filePath }: { filePath: string }) {
|
||||
@@ -30,7 +32,10 @@ export function DiffFilePathCopyButton({ filePath }: { filePath: string }) {
|
||||
/>
|
||||
}
|
||||
>
|
||||
{isCopied ? <CheckIcon className="size-3 text-success" /> : <CopyIcon className="size-3" />}
|
||||
<MorphIcon
|
||||
className={cn("size-3", isCopied && "text-success")}
|
||||
icon={isCopied ? Check : Copy}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup>
|
||||
<p>{isCopied ? "Copied" : "Copy path"}</p>
|
||||
|
||||
@@ -12,15 +12,13 @@ import {
|
||||
ArrowRightIcon,
|
||||
CheckIcon,
|
||||
ChevronDownIcon,
|
||||
ChevronRightIcon,
|
||||
ChevronsDownUpIcon,
|
||||
ChevronsUpDownIcon,
|
||||
Columns2Icon,
|
||||
FolderTreeIcon,
|
||||
PilcrowIcon,
|
||||
Rows3Icon,
|
||||
TextWrapIcon,
|
||||
} from "lucide-react";
|
||||
import { ChevronDown, ChevronRight, ChevronsDownUp, ChevronsUpDown } from "lucide";
|
||||
import * as Schema from "effect/Schema";
|
||||
import * as DateTime from "effect/DateTime";
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from "react";
|
||||
@@ -58,6 +56,7 @@ import { AnnotatableCodeView, type AnnotatableCodeViewHandle } from "./diffs/Ann
|
||||
import { DiffFileTree } from "./diffs/DiffFileTree";
|
||||
import { diffFileTreeEntries } from "./diffs/diffFileTree.logic";
|
||||
import { Button } from "./ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { ToggleGroup, Toggle } from "./ui/toggle-group";
|
||||
import { Switch } from "./ui/switch";
|
||||
import {
|
||||
@@ -873,11 +872,10 @@ export default function DiffPanel({
|
||||
/>
|
||||
}
|
||||
>
|
||||
{allDiffFilesCollapsed ? (
|
||||
<ChevronsUpDownIcon className="size-3.5" />
|
||||
) : (
|
||||
<ChevronsDownUpIcon className="size-3.5" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3.5"
|
||||
icon={allDiffFilesCollapsed ? ChevronsUpDown : ChevronsDownUp}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">
|
||||
{allDiffFilesCollapsed ? "Expand all files" : "Collapse all files"}
|
||||
@@ -1133,15 +1131,10 @@ export default function DiffPanel({
|
||||
/>
|
||||
}
|
||||
>
|
||||
{collapsed ? (
|
||||
<ChevronRightIcon
|
||||
className={cn("size-4", getDiffCollapseIconClassName(fileDiff))}
|
||||
/>
|
||||
) : (
|
||||
<ChevronDownIcon
|
||||
className={cn("size-4", getDiffCollapseIconClassName(fileDiff))}
|
||||
/>
|
||||
)}
|
||||
<MorphIcon
|
||||
className={cn("size-4", getDiffCollapseIconClassName(fileDiff))}
|
||||
icon={collapsed ? ChevronRight : ChevronDown}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">
|
||||
{collapsed ? "Expand diff" : "Collapse diff"}
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
import { MorphIcon as BaseMorphIcon, type MorphIconProps } from "morphicons/react";
|
||||
|
||||
/** Renders `lucide` icon data and morphs between shapes when `icon` changes. */
|
||||
export function MorphIcon({ reducedMotion = "user", ...props }: MorphIconProps) {
|
||||
return <BaseMorphIcon reducedMotion={reducedMotion} {...props} />;
|
||||
}
|
||||
@@ -23,9 +23,8 @@ import {
|
||||
Globe2,
|
||||
Plus,
|
||||
TerminalSquare,
|
||||
Volume2,
|
||||
VolumeOff,
|
||||
} from "lucide-react";
|
||||
import { Volume2, VolumeOff } from "lucide";
|
||||
import {
|
||||
type KeyboardEvent as ReactKeyboardEvent,
|
||||
type MouseEvent as ReactMouseEvent,
|
||||
@@ -44,6 +43,7 @@ import type { RightPanelSurface } from "~/rightPanelStore";
|
||||
import { cn } from "~/lib/utils";
|
||||
import { readLocalApi } from "~/localApi";
|
||||
import { Button } from "~/components/ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { AndroidIcon, AppleIcon } from "~/components/Icons";
|
||||
import { Tooltip, TooltipPopup, TooltipTrigger } from "~/components/ui/tooltip";
|
||||
import { Kbd } from "~/components/ui/kbd";
|
||||
@@ -1149,11 +1149,10 @@ export function RightPanelTabs(props: RightPanelTabsProps) {
|
||||
.catch(() => undefined);
|
||||
}}
|
||||
>
|
||||
{audio === "muted" ? (
|
||||
<VolumeOff className="size-3" />
|
||||
) : (
|
||||
<Volume2 className="size-3" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3"
|
||||
icon={audio === "muted" ? VolumeOff : Volume2}
|
||||
/>
|
||||
</button>
|
||||
}
|
||||
/>
|
||||
|
||||
@@ -6,20 +6,15 @@ import {
|
||||
summarizeTurnDiffStats,
|
||||
type TurnDiffTreeNode,
|
||||
} from "../../lib/turnDiffTree";
|
||||
import {
|
||||
ChevronsDownUpIcon,
|
||||
ChevronsUpDownIcon,
|
||||
ChevronRightIcon,
|
||||
FileDiffIcon,
|
||||
FolderIcon,
|
||||
FolderClosedIcon,
|
||||
} from "lucide-react";
|
||||
import { ChevronRightIcon, FileDiffIcon } from "lucide-react";
|
||||
import { ChevronsDownUp, ChevronsUpDown, Folder, FolderClosed } from "lucide";
|
||||
import { cn } from "~/lib/utils";
|
||||
import { DiffStatLabel, hasNonZeroStat } from "./DiffStatLabel";
|
||||
import { PierreEntryIcon } from "./PierreEntryIcon";
|
||||
import { Button } from "../ui/button";
|
||||
import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip";
|
||||
import { MiddleTruncate } from "../ui/middle-truncate";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
|
||||
const EMPTY_DIRECTORY_OVERRIDES: Record<string, boolean> = {};
|
||||
|
||||
@@ -86,11 +81,10 @@ export const ChangedFilesCard = memo(function ChangedFilesCard(props: {
|
||||
/>
|
||||
}
|
||||
>
|
||||
{allDirectoriesExpanded ? (
|
||||
<ChevronsDownUpIcon className="size-3" />
|
||||
) : (
|
||||
<ChevronsUpDownIcon className="size-3" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3"
|
||||
icon={allDirectoriesExpanded ? ChevronsDownUp : ChevronsUpDown}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">
|
||||
{allDirectoriesExpanded ? "Collapse all folders" : "Expand all folders"}
|
||||
@@ -195,11 +189,10 @@ export const ChangedFilesTree = memo(function ChangedFilesTree(props: {
|
||||
isExpanded && "rotate-90",
|
||||
)}
|
||||
/>
|
||||
{isExpanded ? (
|
||||
<FolderIcon className="size-3.5 shrink-0 text-muted-foreground/75" />
|
||||
) : (
|
||||
<FolderClosedIcon className="size-3.5 shrink-0 text-muted-foreground/75" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3.5 shrink-0 text-muted-foreground/75"
|
||||
icon={isExpanded ? Folder : FolderClosed}
|
||||
/>
|
||||
<span className="truncate font-mono text-2xs text-muted-foreground/90 group-hover:text-foreground/90">
|
||||
{node.name}
|
||||
</span>
|
||||
|
||||
@@ -1,12 +1,7 @@
|
||||
import { memo, type MouseEventHandler, type PointerEventHandler } from "react";
|
||||
import {
|
||||
CheckIcon,
|
||||
ChevronDownIcon,
|
||||
ChevronLeftIcon,
|
||||
CornerUpRightIcon,
|
||||
ListPlusIcon,
|
||||
PlayIcon,
|
||||
} from "lucide-react";
|
||||
import { CheckIcon, ChevronDownIcon, ChevronLeftIcon, PlayIcon } from "lucide-react";
|
||||
import { CornerUpRight, ListPlus } from "lucide";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { useEnvironmentIdentificationMode } from "~/hooks/useSettings";
|
||||
import { cn } from "~/lib/utils";
|
||||
import { useShortcutModifierState } from "../../shortcutModifierState";
|
||||
@@ -315,10 +310,8 @@ export const ComposerPrimaryActions = memo(function ComposerPrimaryActions({
|
||||
<PlayIcon className="size-4 fill-current" aria-hidden="true" />
|
||||
) : isEditingQueuedMessage ? (
|
||||
<CheckIcon className="size-4" aria-hidden="true" />
|
||||
) : isQueuing ? (
|
||||
<ListPlusIcon className="size-4" aria-hidden="true" />
|
||||
) : isRunning ? (
|
||||
<CornerUpRightIcon className="size-4" aria-hidden="true" />
|
||||
<MorphIcon className="size-4" icon={isQueuing ? ListPlus : CornerUpRight} />
|
||||
) : (
|
||||
<svg width="14" height="14" viewBox="0 0 14 14" fill="none" aria-hidden="true">
|
||||
<path
|
||||
|
||||
@@ -7,8 +7,10 @@ import {
|
||||
type ReactNode,
|
||||
type KeyboardEvent,
|
||||
} from "react";
|
||||
import { ChevronLeftIcon, ChevronRightIcon, ImageIcon, TextIcon, XIcon } from "lucide-react";
|
||||
import { ChevronLeftIcon, ChevronRightIcon, XIcon } from "lucide-react";
|
||||
import { Image as ImageGlyph, Text as TextGlyph } from "lucide";
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { Dialog, DialogPopup, DialogTitle } from "../ui/dialog";
|
||||
import type { ExpandedImageItem, ExpandedImagePreview } from "./ExpandedImagePreview";
|
||||
import { resolveExternalWebLinkHost } from "./externalLinkContextMenu";
|
||||
@@ -165,7 +167,6 @@ export const ExpandedImageDialog = memo(function ExpandedImageDialog({
|
||||
: accessibilityDetails?.format === "json"
|
||||
? "Show accessibility JSON"
|
||||
: "Show extracted text";
|
||||
const ContentsIcon = showingAccessibilityDetails ? ImageIcon : TextIcon;
|
||||
|
||||
return (
|
||||
<Dialog
|
||||
@@ -260,7 +261,11 @@ export const ExpandedImageDialog = memo(function ExpandedImageDialog({
|
||||
/>
|
||||
}
|
||||
>
|
||||
<ContentsIcon className="size-3" aria-hidden="true" />
|
||||
<MorphIcon
|
||||
className="size-3"
|
||||
aria-hidden="true"
|
||||
icon={showingAccessibilityDetails ? ImageGlyph : TextGlyph}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">{contentsLabel}</TooltipPopup>
|
||||
</Tooltip>
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import { memo, useRef } from "react";
|
||||
import { CopyIcon, CheckIcon } from "lucide-react";
|
||||
import { Check, Copy } from "lucide";
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { cn } from "~/lib/utils";
|
||||
import { useCopyToClipboard } from "~/hooks/useCopyToClipboard";
|
||||
import {
|
||||
ANCHORED_COPY_TOAST_TIMEOUT_MS,
|
||||
@@ -47,7 +49,10 @@ export const MessageCopyButton = memo(function MessageCopyButton({
|
||||
/>
|
||||
}
|
||||
>
|
||||
{isCopied ? <CheckIcon className="size-3 text-primary" /> : <CopyIcon className="size-3" />}
|
||||
<MorphIcon
|
||||
className={cn("size-3", isCopied && "text-primary")}
|
||||
icon={isCopied ? Check : Copy}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup>
|
||||
<p>Copy message</p>
|
||||
|
||||
@@ -140,12 +140,14 @@ import {
|
||||
XIcon,
|
||||
ZapIcon,
|
||||
} from "lucide-react";
|
||||
import { ChevronDown, ChevronRight } from "lucide";
|
||||
import type {
|
||||
ComposerContextId,
|
||||
ComposerContextRecord,
|
||||
KnownComposerContextRecord,
|
||||
} from "@t3tools/contracts";
|
||||
import { Button, InlineButton } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { useAssetUrlRefresh, useAssetUrls, useAssetUrlState } from "../../assets/assetUrls";
|
||||
import { MediaVideoPlayer } from "../media/MediaVideoPlayer";
|
||||
import { getVirtualizedScrollFadeClassName } from "../ui/scroll-area";
|
||||
@@ -2426,7 +2428,6 @@ function TimelineRowTimestamp({
|
||||
|
||||
function TurnFoldTimelineRow({ row }: { row: Extract<TimelineRow, { kind: "turn-fold" }> }) {
|
||||
const ctx = use(TimelineRowCtx);
|
||||
const Icon = row.expanded ? ChevronDownIcon : ChevronRightIcon;
|
||||
|
||||
return (
|
||||
<div className="group/timeline-row relative flex items-center gap-1 border-b border-border/60 pb-2 pe-0.5 pt-1">
|
||||
@@ -2438,7 +2439,7 @@ function TurnFoldTimelineRow({ row }: { row: Extract<TimelineRow, { kind: "turn-
|
||||
className="flex cursor-pointer select-none items-center gap-1 rounded-md px-1 text-sm leading-relaxed text-muted-foreground tabular-nums transition-colors hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring/70"
|
||||
>
|
||||
<span>{row.label}</span>
|
||||
<Icon className="size-3.5" />
|
||||
<MorphIcon className="size-3.5" icon={row.expanded ? ChevronDown : ChevronRight} />
|
||||
</button>
|
||||
<TimelineRowTimestamp
|
||||
createdAt={row.createdAt}
|
||||
@@ -2451,7 +2452,6 @@ function TurnFoldTimelineRow({ row }: { row: Extract<TimelineRow, { kind: "turn-
|
||||
|
||||
function AttemptFoldTimelineRow({ row }: { row: Extract<TimelineRow, { kind: "attempt-fold" }> }) {
|
||||
const ctx = use(TimelineRowCtx);
|
||||
const Icon = row.expanded ? ChevronDownIcon : ChevronRightIcon;
|
||||
|
||||
return (
|
||||
<button
|
||||
@@ -2462,7 +2462,10 @@ function AttemptFoldTimelineRow({ row }: { row: Extract<TimelineRow, { kind: "at
|
||||
onClick={() => ctx.onToggleAttemptFold(row.attemptId)}
|
||||
className="flex w-full cursor-pointer select-none items-center gap-2 rounded-md border border-border/60 bg-muted/20 px-2.5 py-2 text-left transition-colors hover:bg-muted/35 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring/70"
|
||||
>
|
||||
<Icon className="size-3.5 shrink-0 text-muted-foreground" />
|
||||
<MorphIcon
|
||||
className="size-3.5 shrink-0 text-muted-foreground"
|
||||
icon={row.expanded ? ChevronDown : ChevronRight}
|
||||
/>
|
||||
<span className="text-xs font-medium text-foreground/80">{row.label}</span>
|
||||
<span className="text-2xs text-muted-foreground">Partial output retained</span>
|
||||
</button>
|
||||
|
||||
@@ -1,10 +1,6 @@
|
||||
import {
|
||||
Maximize2Icon,
|
||||
Minimize2Icon,
|
||||
PanelBottomIcon,
|
||||
PanelRightIcon,
|
||||
SquareMenuIcon,
|
||||
} from "lucide-react";
|
||||
import { PanelBottomIcon, PanelRightIcon, SquareMenuIcon } from "lucide-react";
|
||||
import { Maximize2, Minimize2 } from "lucide";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { memo, type ReactElement } from "react";
|
||||
|
||||
import type { ThreadPanelPresentation } from "../../rightPanelLayout";
|
||||
@@ -163,11 +159,7 @@ export const RightPanelMaximizeControl = memo(function RightPanelMaximizeControl
|
||||
variant="ghost"
|
||||
size="sm"
|
||||
>
|
||||
{maximized ? (
|
||||
<Minimize2Icon className="size-4" />
|
||||
) : (
|
||||
<Maximize2Icon className="size-4" />
|
||||
)}
|
||||
<MorphIcon className="size-4" icon={maximized ? Minimize2 : Maximize2} />
|
||||
</Toggle>
|
||||
}
|
||||
/>
|
||||
|
||||
@@ -5,7 +5,7 @@ import {
|
||||
threadPullRequestKeyOf,
|
||||
visibleThreadPullRequests,
|
||||
} from "@t3tools/shared/threadPullRequests";
|
||||
import { MinusIcon, PlusIcon } from "lucide-react";
|
||||
import { Minus, Plus } from "lucide";
|
||||
import { useState, type ComponentProps, type MouseEvent as ReactMouseEvent } from "react";
|
||||
|
||||
import { findProjectOnChangeRequestHost, parseChangeRequestUrl } from "~/lib/openPullRequestLink";
|
||||
@@ -13,6 +13,7 @@ import { findProjectOnChangeRequestHost, parseChangeRequestUrl } from "~/lib/ope
|
||||
import { useProjects } from "~/state/entities";
|
||||
|
||||
import { pullRequestListLines } from "../pullRequest/pullRequestListLines";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { linkedPullRequestSnapshotStatus, prStatusIndicator } from "../ThreadStatusIndicators";
|
||||
|
||||
import { ThreadDetailsPrRow } from "./ThreadDetailsPrRow";
|
||||
@@ -96,11 +97,7 @@ export function ThreadDetailsPrRows({
|
||||
tone="muted"
|
||||
className="w-full active:scale-100"
|
||||
>
|
||||
{expanded ? (
|
||||
<MinusIcon aria-hidden className="size-4 shrink-0" />
|
||||
) : (
|
||||
<PlusIcon aria-hidden className="size-4 shrink-0" />
|
||||
)}
|
||||
<MorphIcon aria-hidden className="size-4 shrink-0" icon={expanded ? Minus : Plus} />
|
||||
{expanded ? "Show less" : `Show ${rest.length} more`}
|
||||
</ThreadDetailsControl>
|
||||
</>
|
||||
|
||||
@@ -6,8 +6,6 @@ import {
|
||||
import { formatDuration } from "@t3tools/shared/orchestrationTiming";
|
||||
import {
|
||||
CheckIcon,
|
||||
ChevronDownIcon,
|
||||
ChevronRightIcon,
|
||||
CircleAlertIcon,
|
||||
CircleIcon,
|
||||
LaptopIcon,
|
||||
@@ -15,9 +13,11 @@ import {
|
||||
TerminalIcon,
|
||||
XIcon,
|
||||
} from "lucide-react";
|
||||
import { ChevronDown, ChevronRight } from "lucide";
|
||||
import { useEffect, useState, type ReactNode } from "react";
|
||||
|
||||
import { Button } from "~/components/ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { Spinner } from "~/components/ui/spinner";
|
||||
import { MiddleTruncate } from "../ui/middle-truncate";
|
||||
import { observeVisibleAnimation } from "~/lib/visibleAnimation";
|
||||
@@ -409,7 +409,7 @@ export function WorktreeSetupCard({
|
||||
aria-expanded={detailsOpen}
|
||||
onClick={() => setDetailsOpen((open) => !open)}
|
||||
>
|
||||
{detailsOpen ? <ChevronDownIcon aria-hidden /> : <ChevronRightIcon aria-hidden />}
|
||||
<MorphIcon aria-hidden icon={detailsOpen ? ChevronDown : ChevronRight} />
|
||||
Details
|
||||
</Button>
|
||||
{showTerminal ? (
|
||||
|
||||
@@ -6,7 +6,6 @@ import {
|
||||
Keyboard,
|
||||
Box,
|
||||
Maximize,
|
||||
Moon,
|
||||
MoreHorizontal,
|
||||
PictureInPicture2,
|
||||
Power,
|
||||
@@ -14,12 +13,13 @@ import {
|
||||
SlidersHorizontal,
|
||||
Smartphone,
|
||||
Square,
|
||||
Sun,
|
||||
Type,
|
||||
X,
|
||||
} from "lucide-react";
|
||||
import { Moon, Sun } from "lucide";
|
||||
import type { ReactNode } from "react";
|
||||
import { Button } from "~/components/ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import {
|
||||
Menu,
|
||||
MenuItem,
|
||||
@@ -132,7 +132,7 @@ export function DeviceControlsRail(props: {
|
||||
disabled={controls.disabled || !settings?.appearance}
|
||||
onClick={() => void controls.act({ type: "setAppearance", value: nextAppearance })}
|
||||
>
|
||||
{settings?.appearance === "dark" ? <Sun /> : <Moon />}
|
||||
<MorphIcon icon={settings?.appearance === "dark" ? Sun : Moon} />
|
||||
</RailButton>
|
||||
<Menu>
|
||||
<MenuTrigger
|
||||
|
||||
@@ -1,10 +1,12 @@
|
||||
import { DeviceHostUpdates } from "./DeviceHostUpdates";
|
||||
import type { DevicePlatform, DeviceServiceState, EnvironmentId } from "@t3tools/contracts";
|
||||
import { Check, CircleAlert } from "lucide-react";
|
||||
import { Check } from "lucide-react";
|
||||
import { Check as CheckGlyph, CircleAlert } from "lucide";
|
||||
import { useState } from "react";
|
||||
|
||||
import { Button } from "~/components/ui/button";
|
||||
import { DialogClose } from "~/components/ui/dialog";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { WizardHeader, WizardPanel, WizardSteps, WizardFooter } from "~/components/ui/wizard";
|
||||
import { Spinner } from "~/components/ui/spinner";
|
||||
import { Switch } from "~/components/ui/switch";
|
||||
@@ -287,16 +289,16 @@ export function PlatformStatus(props: {
|
||||
readonly status: { readonly ready: boolean; readonly message: string };
|
||||
readonly compact?: boolean;
|
||||
}) {
|
||||
const Icon = props.status.ready ? Check : CircleAlert;
|
||||
return (
|
||||
<div
|
||||
className={cn("flex gap-2", !props.compact && "rounded-md border border-border/60 px-3 py-2")}
|
||||
>
|
||||
<Icon
|
||||
<MorphIcon
|
||||
className={cn(
|
||||
"mt-0.5 size-4 shrink-0",
|
||||
props.status.ready ? "text-success" : "text-muted-foreground",
|
||||
)}
|
||||
icon={props.status.ready ? CheckGlyph : CircleAlert}
|
||||
/>
|
||||
<div className={cn(props.compact && props.status.ready && "flex items-center gap-2")}>
|
||||
<p className="font-medium">{props.platform}</p>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { GitStatusEntry } from "@pierre/trees";
|
||||
import { FileTree, useFileTree, useFileTreeSelector } from "@pierre/trees/react";
|
||||
import { ChevronsDownUpIcon, ChevronsUpDownIcon } from "lucide-react";
|
||||
import { ChevronsDownUp, ChevronsUpDown } from "lucide";
|
||||
import { useEffect, useMemo, useRef, useState, type ReactNode } from "react";
|
||||
|
||||
import { useTheme } from "~/hooks/useTheme";
|
||||
@@ -10,6 +10,7 @@ import { PIERRE_TREE_UNSAFE_CSS, pierreTreeStyle } from "~/pierre-tree-theme";
|
||||
|
||||
import { areAllDirectoriesExpanded, setAllDirectoriesExpanded } from "../files/fileTreeExpansion";
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip";
|
||||
import {
|
||||
buildDiffFileTreeUpdates,
|
||||
@@ -189,11 +190,10 @@ export function DiffFileTree({
|
||||
/>
|
||||
}
|
||||
>
|
||||
{allDirectoriesExpanded ? (
|
||||
<ChevronsDownUpIcon className="size-3.5" />
|
||||
) : (
|
||||
<ChevronsUpDownIcon className="size-3.5" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3.5"
|
||||
icon={allDirectoriesExpanded ? ChevronsDownUp : ChevronsUpDown}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup>
|
||||
{allDirectoriesExpanded ? "Collapse all folders" : "Expand all folders"}
|
||||
|
||||
@@ -3,22 +3,13 @@ import type { EnvironmentId } from "@t3tools/contracts";
|
||||
import { formatAttachmentSize } from "@t3tools/client-runtime/state/attachments";
|
||||
import { readFilePreviewResponse } from "@t3tools/client-runtime/file-preview";
|
||||
import { filePreviewKind, FILE_TEXT_PREVIEW_MAX_BYTES } from "@t3tools/shared/filePreview";
|
||||
import {
|
||||
CheckIcon,
|
||||
ChevronRightIcon,
|
||||
Code2,
|
||||
CopyIcon,
|
||||
DownloadIcon,
|
||||
Eye,
|
||||
Table2,
|
||||
Trash2Icon,
|
||||
WrapTextIcon,
|
||||
XIcon,
|
||||
} from "lucide-react";
|
||||
import { ChevronRightIcon, DownloadIcon, Trash2Icon, WrapTextIcon, XIcon } from "lucide-react";
|
||||
import { Check, Code2, Copy, Eye, Table2 } from "lucide";
|
||||
import { lazy, Suspense, useEffect, useMemo, useRef, useState } from "react";
|
||||
|
||||
import { useAssetUrlRefresh } from "~/assets/assetUrls";
|
||||
import ChatMarkdown from "~/components/ChatMarkdown";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { ScrollArea } from "~/components/ui/scroll-area";
|
||||
import { toastManager } from "~/components/ui/toast";
|
||||
import { useCopyToClipboard } from "~/hooks/useCopyToClipboard";
|
||||
@@ -305,13 +296,10 @@ export function AttachmentFilePreview(props: {
|
||||
pressed={rendered}
|
||||
onPress={() => setRendered((value) => !value)}
|
||||
>
|
||||
{rendered ? (
|
||||
<Code2 className="size-3.5" />
|
||||
) : renderedMode === "table" ? (
|
||||
<Table2 className="size-3.5" />
|
||||
) : (
|
||||
<Eye className="size-3.5" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3.5"
|
||||
icon={rendered ? Code2 : renderedMode === "table" ? Table2 : Eye}
|
||||
/>
|
||||
</FileSurfaceAction>
|
||||
) : null}
|
||||
{showsRawText ? (
|
||||
@@ -328,7 +316,7 @@ export function AttachmentFilePreview(props: {
|
||||
label={isCopied ? "Copied" : content.truncated ? "Copy preview" : "Copy contents"}
|
||||
onPress={() => copyToClipboard(content.text, undefined)}
|
||||
>
|
||||
{isCopied ? <CheckIcon className="size-3.5" /> : <CopyIcon className="size-3.5" />}
|
||||
<MorphIcon className="size-3.5" icon={isCopied ? Check : Copy} />
|
||||
</FileSurfaceAction>
|
||||
) : null}
|
||||
{url ? (
|
||||
|
||||
@@ -6,11 +6,12 @@ import type {
|
||||
import type { EnvironmentId, ProjectEntry } from "@t3tools/contracts";
|
||||
import { FileTree, useFileTree, useFileTreeSearch, useFileTreeSelector } from "@pierre/trees/react";
|
||||
import { serializeComposerFileLink } from "@t3tools/shared/composerTrigger";
|
||||
import { ChevronsDownUpIcon, ChevronsUpDownIcon } from "lucide-react";
|
||||
import { ChevronsDownUp, ChevronsUpDown } from "lucide";
|
||||
import { useEffect, useMemo, useRef, useState } from "react";
|
||||
|
||||
import { Button } from "~/components/ui/button";
|
||||
import { InputGroup, InputGroupInput } from "~/components/ui/input-group";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { toastManager } from "~/components/ui/toast";
|
||||
import { Tooltip, TooltipPopup, TooltipTrigger } from "~/components/ui/tooltip";
|
||||
import { useComposerHandleContext } from "~/composerHandleContext";
|
||||
@@ -516,11 +517,10 @@ export default function FileBrowserPanel({
|
||||
/>
|
||||
}
|
||||
>
|
||||
{allDirectoriesExpanded ? (
|
||||
<ChevronsDownUpIcon className="size-3.5" />
|
||||
) : (
|
||||
<ChevronsUpDownIcon className="size-3.5" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3.5"
|
||||
icon={allDirectoriesExpanded ? ChevronsDownUp : ChevronsUpDown}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup>
|
||||
{expandAll || allDirectoriesExpanded ? "Collapse all folders" : "Expand all folders"}
|
||||
|
||||
@@ -21,7 +21,8 @@ import {
|
||||
squashAtomCommandFailure,
|
||||
} from "@t3tools/client-runtime/state/runtime";
|
||||
import { mediaFileReference } from "@t3tools/client-runtime/media-reference";
|
||||
import { Code2, Eye, FolderTree, Globe2, Table2, WrapTextIcon } from "lucide-react";
|
||||
import { FolderTree, Globe2, WrapTextIcon } from "lucide-react";
|
||||
import { Code2, Eye, Table2 } from "lucide";
|
||||
import * as Schema from "effect/Schema";
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from "react";
|
||||
|
||||
@@ -30,6 +31,7 @@ import { useAssetUrlRefresh, useAssetUrlState } from "~/assets/assetUrls";
|
||||
import { OpenInPicker } from "~/components/chat/OpenInPicker";
|
||||
import { MediaVideoPlayer } from "~/components/media/MediaVideoPlayer";
|
||||
import { MediaActions, type MediaActionSource } from "~/components/media/MediaActions";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { useRemoteOpenState } from "~/remoteOpen";
|
||||
import { useClientSettings, useUpdateClientSettings } from "~/hooks/useSettings";
|
||||
import { useTheme } from "~/hooks/useTheme";
|
||||
@@ -1140,13 +1142,10 @@ export default function FilePreviewPanel({
|
||||
);
|
||||
}}
|
||||
>
|
||||
{rendered ? (
|
||||
<Code2 className="size-3.5" />
|
||||
) : renderedMode === "table" ? (
|
||||
<Table2 className="size-3.5" />
|
||||
) : (
|
||||
<Eye className="size-3.5" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3.5"
|
||||
icon={rendered ? Code2 : renderedMode === "table" ? Table2 : Eye}
|
||||
/>
|
||||
</FileSurfaceAction>
|
||||
) : null}
|
||||
{showsRawText ? (
|
||||
|
||||
@@ -26,11 +26,11 @@ import {
|
||||
CheckIcon,
|
||||
ChevronRightIcon,
|
||||
CloudIcon,
|
||||
CopyIcon,
|
||||
LinkIcon,
|
||||
MonitorIcon,
|
||||
TerminalIcon,
|
||||
} from "lucide-react";
|
||||
import { Check, Copy } from "lucide";
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from "react";
|
||||
|
||||
import { TYPOGRAPHY_ADVANCED_STORAGE_KEY } from "../../appearanceFonts";
|
||||
@@ -77,6 +77,7 @@ import { T3Wordmark } from "../T3Wordmark";
|
||||
import { Alert, AlertDescription } from "../ui/alert";
|
||||
import { Button } from "../ui/button";
|
||||
import { Checkbox } from "../ui/checkbox";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { Collapsible, CollapsiblePanel, CollapsibleTrigger } from "../ui/collapsible";
|
||||
import { Input } from "../ui/input";
|
||||
import { Tooltip, TooltipTrigger, TooltipPopup } from "../ui/tooltip";
|
||||
@@ -1744,7 +1745,7 @@ function CommandBlock({
|
||||
aria-label="Copy command"
|
||||
onClick={() => copyToClipboard(command, undefined)}
|
||||
>
|
||||
{isCopied ? <CheckIcon className="size-3.5" /> : <CopyIcon className="size-3.5" />}
|
||||
<MorphIcon className="size-3.5" icon={isCopied ? Check : Copy} />
|
||||
</Button>
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -13,8 +13,6 @@ import type {
|
||||
import {
|
||||
ChevronDownIcon,
|
||||
ChevronRightIcon,
|
||||
ChevronsDownUpIcon,
|
||||
ChevronsUpDownIcon,
|
||||
Columns2Icon,
|
||||
FolderTreeIcon,
|
||||
InfoIcon,
|
||||
@@ -24,6 +22,7 @@ import {
|
||||
TextWrapIcon,
|
||||
TriangleAlertIcon,
|
||||
} from "lucide-react";
|
||||
import { ChevronDown, ChevronRight, ChevronsDownUp, ChevronsUpDown } from "lucide";
|
||||
import { useAtomRefresh } from "@effect/atom-react";
|
||||
import * as Schema from "effect/Schema";
|
||||
import { useCallback, useEffect, useMemo, useRef, useState, type ReactNode } from "react";
|
||||
@@ -64,6 +63,7 @@ import { useCodeViewFileReveal } from "../diffs/useCodeViewFileReveal";
|
||||
import { diffFileTreeEntries } from "../diffs/diffFileTree.logic";
|
||||
import { StyledDiffCodeView } from "../diffs/StyledDiffCodeView";
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { Checkbox } from "../ui/checkbox";
|
||||
import { Collapsible, CollapsiblePanel, CollapsibleTrigger } from "../ui/collapsible";
|
||||
import {
|
||||
@@ -791,11 +791,7 @@ function PullRequestCodeTab({
|
||||
toggleFile(item.id);
|
||||
}}
|
||||
>
|
||||
{collapsed ? (
|
||||
<ChevronRightIcon className="size-4" />
|
||||
) : (
|
||||
<ChevronDownIcon className="size-4" />
|
||||
)}
|
||||
<MorphIcon className="size-4" icon={collapsed ? ChevronRight : ChevronDown} />
|
||||
</Button>
|
||||
);
|
||||
},
|
||||
@@ -1249,11 +1245,10 @@ function PullRequestCodeTab({
|
||||
/>
|
||||
}
|
||||
>
|
||||
{allFilesCollapsed ? (
|
||||
<ChevronsUpDownIcon className="size-3.5" />
|
||||
) : (
|
||||
<ChevronsDownUpIcon className="size-3.5" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3.5"
|
||||
icon={allFilesCollapsed ? ChevronsUpDown : ChevronsDownUp}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">
|
||||
{allFilesCollapsed ? "Expand all files" : "Collapse all files"}
|
||||
|
||||
@@ -9,19 +9,15 @@ import type {
|
||||
PullRequestThreadCommentsResult,
|
||||
PullRequestThreadComment,
|
||||
} from "@t3tools/contracts";
|
||||
import {
|
||||
CheckCircle2Icon,
|
||||
CircleIcon,
|
||||
HammerIcon,
|
||||
MessageSquareIcon,
|
||||
Trash2Icon,
|
||||
} from "lucide-react";
|
||||
import { HammerIcon, MessageSquareIcon, Trash2Icon } from "lucide-react";
|
||||
import { Circle, CircleCheck } from "lucide";
|
||||
import { useRef, useState } from "react";
|
||||
|
||||
import { formatRelativeTimeLabel } from "~/timestampFormat";
|
||||
import { cn } from "~/lib/utils";
|
||||
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { PullRequestEditButton } from "./PullRequestEditButton";
|
||||
import { Textarea } from "../ui/textarea";
|
||||
import { isCommentSubmitShortcut } from "../diffs/commentSubmitShortcut";
|
||||
@@ -219,11 +215,10 @@ export function ReviewThreadCard({
|
||||
onPointerDown={(event) => event.stopPropagation()}
|
||||
>
|
||||
<div className="flex items-center gap-2 text-xs text-muted-foreground">
|
||||
{thread.isResolved ? (
|
||||
<CheckCircle2Icon className="size-3.5 text-success-foreground" />
|
||||
) : (
|
||||
<CircleIcon className="size-3.5" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className={cn("size-3.5", thread.isResolved && "text-success-foreground")}
|
||||
icon={thread.isResolved ? CircleCheck : Circle}
|
||||
/>
|
||||
<button
|
||||
type="button"
|
||||
className="hover:text-foreground"
|
||||
|
||||
@@ -1,13 +1,7 @@
|
||||
import { ProcessSignalActions } from "./ProcessSignalActions";
|
||||
import { RefreshIcon } from "~/components/ui/refresh-icon";
|
||||
import {
|
||||
AlertTriangleIcon,
|
||||
ChevronDownIcon,
|
||||
ChevronRightIcon,
|
||||
CopyIcon,
|
||||
FolderOpenIcon,
|
||||
InfoIcon,
|
||||
} from "lucide-react";
|
||||
import { AlertTriangleIcon, CopyIcon, FolderOpenIcon, InfoIcon } from "lucide-react";
|
||||
import { ChevronDown, ChevronRight } from "lucide";
|
||||
import {
|
||||
isAtomCommandInterrupted,
|
||||
squashAtomCommandFailure,
|
||||
@@ -30,6 +24,7 @@ import { serverEnvironment } from "../../state/server";
|
||||
import { shellEnvironment } from "../../state/shell";
|
||||
import { useCopyToClipboard } from "../../hooks/useCopyToClipboard";
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { ScrollArea } from "../ui/scroll-area";
|
||||
import { Toggle, ToggleGroup } from "../ui/toggle-group";
|
||||
import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip";
|
||||
@@ -268,7 +263,6 @@ function ProcessNameCell({
|
||||
}) {
|
||||
const name = formatProcessName(process.command);
|
||||
const hasChildren = process.childPids.length > 0;
|
||||
const ChevronIcon = isExpanded ? ChevronDownIcon : ChevronRightIcon;
|
||||
|
||||
return (
|
||||
<div
|
||||
@@ -282,7 +276,7 @@ function ProcessNameCell({
|
||||
aria-label={isExpanded ? `Collapse ${name}` : `Expand ${name}`}
|
||||
onClick={() => onToggle(process.pid)}
|
||||
>
|
||||
<ChevronIcon className="size-3.5" />
|
||||
<MorphIcon className="size-3.5" icon={isExpanded ? ChevronDown : ChevronRight} />
|
||||
</Button>
|
||||
) : (
|
||||
<span className="size-5 shrink-0" aria-hidden="true" />
|
||||
|
||||
@@ -7,13 +7,12 @@ import {
|
||||
ArrowUpCircleIcon,
|
||||
CopyIcon,
|
||||
DownloadIcon,
|
||||
LockIcon,
|
||||
LockOpenIcon,
|
||||
ExternalLinkIcon,
|
||||
PlusIcon,
|
||||
Trash2Icon,
|
||||
XIcon,
|
||||
} from "lucide-react";
|
||||
import { Lock as LockGlyph, LockOpen } from "lucide";
|
||||
import * as Arr from "effect/Array";
|
||||
import * as Result from "effect/Result";
|
||||
import { useEffect, useRef, useState, type ReactElement, type ReactNode } from "react";
|
||||
@@ -41,6 +40,7 @@ import { useCopyToClipboard } from "../../hooks/useCopyToClipboard";
|
||||
import { normalizeProviderAccentColor } from "../../providerInstances";
|
||||
import { Badge } from "../ui/badge";
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { DraftInput } from "../ui/draft-input";
|
||||
import { Popover, PopoverPopup, PopoverTrigger } from "../ui/popover";
|
||||
import { Switch } from "../ui/switch";
|
||||
@@ -438,11 +438,10 @@ function ProviderEnvironmentSection(props: {
|
||||
aria-pressed={variable.sensitive}
|
||||
aria-label={`Mark environment variable ${variable.name || index + 1} as sensitive`}
|
||||
>
|
||||
{variable.sensitive ? (
|
||||
<LockIcon className="size-3" />
|
||||
) : (
|
||||
<LockOpenIcon className="size-3" />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3"
|
||||
icon={variable.sensitive ? LockGlyph : LockOpen}
|
||||
/>
|
||||
</Button>
|
||||
}
|
||||
/>
|
||||
|
||||
@@ -4,14 +4,13 @@ import {
|
||||
ActivityIcon,
|
||||
AlertTriangleIcon,
|
||||
BatteryIcon,
|
||||
ChevronDownIcon,
|
||||
ChevronRightIcon,
|
||||
CpuIcon,
|
||||
DatabaseIcon,
|
||||
GaugeIcon,
|
||||
HardDriveIcon,
|
||||
MemoryStickIcon,
|
||||
} from "lucide-react";
|
||||
import { ChevronDown, ChevronRight } from "lucide";
|
||||
import type {
|
||||
BackgroundBooleanState,
|
||||
EnvironmentId,
|
||||
@@ -44,6 +43,7 @@ import { serverEnvironment } from "../../state/server";
|
||||
import { useAtomCommand } from "../../state/use-atom-command";
|
||||
import { formatRelativeTime } from "../../timestampFormat";
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { ScrollArea } from "../ui/scroll-area";
|
||||
import { Toggle, ToggleGroup } from "../ui/toggle-group";
|
||||
import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip";
|
||||
@@ -480,7 +480,6 @@ function ProcessTreeName({
|
||||
}) {
|
||||
const name = formatProcessName(process);
|
||||
const hasChildren = process.childPids.length > 0;
|
||||
const ChevronIcon = collapsed ? ChevronRightIcon : ChevronDownIcon;
|
||||
return (
|
||||
<div
|
||||
className="grid min-w-0 grid-cols-[1.25rem_0.375rem_minmax(0,1fr)] items-center gap-2"
|
||||
@@ -493,7 +492,7 @@ function ProcessTreeName({
|
||||
onClick={() => onToggle(process)}
|
||||
aria-label={collapsed ? `Expand ${name}` : `Collapse ${name}`}
|
||||
>
|
||||
<ChevronIcon className="size-3.5" />
|
||||
<MorphIcon className="size-3.5" icon={collapsed ? ChevronRight : ChevronDown} />
|
||||
</Button>
|
||||
) : (
|
||||
<span className="size-5" aria-hidden />
|
||||
|
||||
@@ -1,11 +1,5 @@
|
||||
import {
|
||||
ChevronDownIcon,
|
||||
ChevronUpIcon,
|
||||
MousePointer2Icon,
|
||||
PaintbrushIcon,
|
||||
PlusIcon,
|
||||
XIcon,
|
||||
} from "lucide-react";
|
||||
import { MousePointer2Icon, PaintbrushIcon, PlusIcon, XIcon } from "lucide-react";
|
||||
import { ChevronDown, ChevronUp } from "lucide";
|
||||
import {
|
||||
useCallback,
|
||||
useEffect,
|
||||
@@ -36,6 +30,7 @@ import {
|
||||
} from "../../themePalette";
|
||||
import { cn } from "../../lib/utils";
|
||||
import { Button } from "../ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { Input } from "../ui/input";
|
||||
import { Switch } from "../ui/switch";
|
||||
import { Toggle, ToggleGroup } from "../ui/toggle-group";
|
||||
@@ -1221,7 +1216,7 @@ export function ThemeEditorPanel({
|
||||
variant="ghost"
|
||||
onClick={() => setIsMinimized(!isMinimized)}
|
||||
>
|
||||
{isMinimized ? <ChevronUpIcon /> : <ChevronDownIcon />}
|
||||
<MorphIcon icon={isMinimized ? ChevronUp : ChevronDown} />
|
||||
</Button>
|
||||
<Button
|
||||
aria-label="Close the theme editor"
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
import { mergeProps } from "@base-ui/react/merge-props";
|
||||
import { useRender } from "@base-ui/react/use-render";
|
||||
import { cva, type VariantProps } from "class-variance-authority";
|
||||
import { PanelLeftCloseIcon, PanelLeftIcon } from "lucide-react";
|
||||
import { PanelLeft, PanelLeftClose } from "lucide";
|
||||
import * as React from "react";
|
||||
import { cn } from "~/lib/utils";
|
||||
import { Button } from "~/components/ui/button";
|
||||
import { Input, type InputProps } from "~/components/ui/input";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { ScrollArea } from "~/components/ui/scroll-area";
|
||||
import {
|
||||
Sheet,
|
||||
@@ -342,7 +343,7 @@ function SidebarTrigger({ className, onClick, ...props }: React.ComponentProps<t
|
||||
variant="ghost"
|
||||
{...props}
|
||||
>
|
||||
{isOpen ? <PanelLeftCloseIcon className="size-4" /> : <PanelLeftIcon className="size-4" />}
|
||||
<MorphIcon className="size-4" icon={isOpen ? PanelLeftClose : PanelLeft} />
|
||||
<span className="sr-only">Toggle Sidebar</span>
|
||||
</Button>
|
||||
);
|
||||
|
||||
@@ -14,20 +14,12 @@ import {
|
||||
} from "react";
|
||||
import { useParams } from "@tanstack/react-router";
|
||||
import { type ScopedThreadRef, type ThreadId } from "@t3tools/contracts";
|
||||
import {
|
||||
CheckIcon,
|
||||
ChevronDownIcon,
|
||||
ChevronUpIcon,
|
||||
CircleAlertIcon,
|
||||
CircleCheckIcon,
|
||||
CopyIcon,
|
||||
InfoIcon,
|
||||
TriangleAlertIcon,
|
||||
XIcon,
|
||||
} from "lucide-react";
|
||||
import { CircleAlertIcon, CircleCheckIcon, InfoIcon, TriangleAlertIcon, XIcon } from "lucide-react";
|
||||
import { Check, ChevronDown, ChevronUp, Copy } from "lucide";
|
||||
|
||||
import { cn } from "~/lib/utils";
|
||||
import { Button, buttonVariants } from "~/components/ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { useComposerDraftStore } from "~/composerDraftStore";
|
||||
import { useCopyToClipboard } from "~/hooks/useCopyToClipboard";
|
||||
import { resolveThreadRouteTarget } from "~/threadRoutes";
|
||||
@@ -135,7 +127,10 @@ function CopyErrorButton({ text }: { text: string }) {
|
||||
/>
|
||||
}
|
||||
>
|
||||
{isCopied ? <CheckIcon className="size-3 text-success" /> : <CopyIcon className="size-3" />}
|
||||
<MorphIcon
|
||||
className={cn("size-3", isCopied && "text-success")}
|
||||
icon={isCopied ? Check : Copy}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">{label}</TooltipPopup>
|
||||
</Tooltip>
|
||||
@@ -165,11 +160,11 @@ function ToastExpandableSection({
|
||||
onClick={() => setOpen((prev) => !prev)}
|
||||
type="button"
|
||||
>
|
||||
{open ? (
|
||||
<ChevronUpIcon className="size-3.5 shrink-0 opacity-80" strokeWidth={2.25} />
|
||||
) : (
|
||||
<ChevronDownIcon className="size-3.5 shrink-0 opacity-80" strokeWidth={2.25} />
|
||||
)}
|
||||
<MorphIcon
|
||||
className="size-3.5 shrink-0 opacity-80"
|
||||
icon={open ? ChevronUp : ChevronDown}
|
||||
strokeWidth={2.25}
|
||||
/>
|
||||
{open ? collapseLabel : expandLabel}
|
||||
</button>
|
||||
{open ? <div className={toastExpandablePanelClassName}>{children}</div> : null}
|
||||
@@ -249,19 +244,12 @@ function ToastDescriptionAndExpandable({
|
||||
data-slot="toast-description"
|
||||
/>
|
||||
</div>
|
||||
{open ? (
|
||||
<ChevronUpIcon
|
||||
aria-hidden
|
||||
className="mt-0.5 size-3.5 shrink-0 text-muted-foreground opacity-80"
|
||||
strokeWidth={2.25}
|
||||
/>
|
||||
) : (
|
||||
<ChevronDownIcon
|
||||
aria-hidden
|
||||
className="mt-0.5 size-3.5 shrink-0 text-muted-foreground opacity-80"
|
||||
strokeWidth={2.25}
|
||||
/>
|
||||
)}
|
||||
<MorphIcon
|
||||
aria-hidden
|
||||
className="mt-0.5 size-3.5 shrink-0 text-muted-foreground opacity-80"
|
||||
icon={open ? ChevronUp : ChevronDown}
|
||||
strokeWidth={2.25}
|
||||
/>
|
||||
</TooltipTrigger>
|
||||
<TooltipPopup side="top">{open ? collapseLabel : expandLabel}</TooltipPopup>
|
||||
</Tooltip>
|
||||
|
||||
@@ -11,7 +11,7 @@ import {
|
||||
useNavigate,
|
||||
useRouter,
|
||||
} from "@tanstack/react-router";
|
||||
import { CheckIcon, CopyIcon } from "lucide-react";
|
||||
import { Check, Copy } from "lucide";
|
||||
import { useEffect, useEffectEvent, useMemo, useRef, useState } from "react";
|
||||
|
||||
import { APP_BASE_NAME, APP_DISPLAY_NAME, APP_STAGE_LABEL, APP_VERSION } from "../branding";
|
||||
@@ -40,6 +40,7 @@ import { useCopyToClipboard } from "../hooks/useCopyToClipboard";
|
||||
import { useDefaultThemeAdoption } from "../hooks/useDefaultTheme";
|
||||
import { useEnvironmentThemeSync } from "../hooks/useEnvironmentTheme";
|
||||
import { Button } from "../components/ui/button";
|
||||
import { MorphIcon } from "~/components/MorphIcon";
|
||||
import { StandalonePage, StandalonePageHeader } from "../components/ui/standalone-page";
|
||||
import {
|
||||
AnchoredToastProvider,
|
||||
@@ -49,6 +50,7 @@ import {
|
||||
} from "../components/ui/toast";
|
||||
import { resolveAndPersistPreferredEditor } from "../editorPreferences";
|
||||
import { isElectron } from "../env";
|
||||
import { cn } from "../lib/utils";
|
||||
import { applyAppearanceFontVariables } from "~/appearanceFonts";
|
||||
import { applyAppearanceContrast } from "~/appearanceContrast";
|
||||
import { useClientSettings } from "../hooks/useSettings";
|
||||
@@ -418,7 +420,7 @@ function CopyErrorButton({ report }: { report: string }) {
|
||||
|
||||
return (
|
||||
<Button size="sm" variant="outline" onClick={() => copyToClipboard(report)}>
|
||||
{isCopied ? <CheckIcon className="text-success" /> : <CopyIcon />}
|
||||
<MorphIcon className={cn(isCopied && "text-success")} icon={isCopied ? Check : Copy} />
|
||||
{isCopied ? "Copied" : "Copy error"}
|
||||
</Button>
|
||||
);
|
||||
|
||||
Generated
+101
-2
@@ -640,7 +640,7 @@ importers:
|
||||
version: 0.9.0
|
||||
'@legendapp/list':
|
||||
specifier: 'catalog:'
|
||||
version: 3.3.5(patch_hash=680cc6a5c5b4a4032e467e7b3fde22f89a84c0ee2e6eac6fda737d6277cc0806)([email protected]([email protected]))([email protected])
|
||||
version: 3.3.5(patch_hash=680cc6a5c5b4a4032e467e7b3fde22f89a84c0ee2e6eac6fda737d6277cc0806)([email protected]([email protected]))(react[email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))(react@19.2.6)
|
||||
'@noble/hashes':
|
||||
specifier: 'catalog:'
|
||||
version: 1.8.0
|
||||
@@ -716,12 +716,18 @@ importers:
|
||||
jszip:
|
||||
specifier: 3.10.1
|
||||
version: 3.10.1
|
||||
lucide:
|
||||
specifier: ^0.564.0
|
||||
version: 0.564.0
|
||||
lucide-react:
|
||||
specifier: ^0.564.0
|
||||
version: 0.564.0([email protected])
|
||||
mermaid:
|
||||
specifier: ^11.17.2
|
||||
version: 11.17.2
|
||||
morphicons:
|
||||
specifier: ^1.7.1
|
||||
version: 1.7.1([email protected]([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected]))([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected])
|
||||
react:
|
||||
specifier: 19.2.6
|
||||
version: 19.2.6
|
||||
@@ -8814,6 +8820,9 @@ packages:
|
||||
peerDependencies:
|
||||
react: ^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0
|
||||
|
||||
[email protected]:
|
||||
resolution: {integrity: sha512-FasyXKHWon773WIl3HeCQpd5xS6E0aLjqxiQStlHNKktni+HDncc1sqY+6vRUbCfmDsIaKQz43EEQLAUDLZO0g==}
|
||||
|
||||
[email protected]:
|
||||
resolution: {integrity: sha512-h5bgJWpxJNswbU7qCrV0tIKQCaS3blPDrqKWx+QxzuzL1zGUzij9XCWLrSLsJPu5t+eWA/ycetzYAO5IOMcWAQ==}
|
||||
hasBin: true
|
||||
@@ -9200,6 +9209,26 @@ packages:
|
||||
socks:
|
||||
optional: true
|
||||
|
||||
[email protected]:
|
||||
resolution: {integrity: sha512-q5ylxy5/d7vBg0OAzanlooXf05PekovMYDuuQVpr6vAQZxl99lrJbaIi+jJ32PXQf9WEEaDO2pbNBsx1ZhEnFQ==}
|
||||
peerDependencies:
|
||||
react: '>=18'
|
||||
react-native: '>=0.71'
|
||||
react-native-svg: '>=14'
|
||||
svelte: '>=5'
|
||||
vue: '>=3.3'
|
||||
peerDependenciesMeta:
|
||||
react:
|
||||
optional: true
|
||||
react-native:
|
||||
optional: true
|
||||
react-native-svg:
|
||||
optional: true
|
||||
svelte:
|
||||
optional: true
|
||||
vue:
|
||||
optional: true
|
||||
|
||||
[email protected]:
|
||||
resolution: {integrity: sha512-Y3wQdFg2Va6etvQ5I82yUhGdsKrcYox6p7FfL1LbK2J4V01F9TGlepTIhnK24t7koZibmg82KGglhA1XK5IsLQ==}
|
||||
engines: {node: '>=10'}
|
||||
@@ -13988,12 +14017,13 @@ snapshots:
|
||||
dependencies:
|
||||
jsbi: 4.3.2
|
||||
|
||||
'@legendapp/[email protected](patch_hash=680cc6a5c5b4a4032e467e7b3fde22f89a84c0ee2e6eac6fda737d6277cc0806)([email protected]([email protected]))([email protected])':
|
||||
'@legendapp/[email protected](patch_hash=680cc6a5c5b4a4032e467e7b3fde22f89a84c0ee2e6eac6fda737d6277cc0806)([email protected]([email protected]))(react[email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))(react@19.2.6)':
|
||||
dependencies:
|
||||
react: 19.2.6
|
||||
use-sync-external-store: 1.6.0([email protected])
|
||||
optionalDependencies:
|
||||
react-dom: 19.2.6([email protected])
|
||||
react-native: 0.88.0-rc.3(@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected])
|
||||
|
||||
'@legendapp/[email protected](patch_hash=680cc6a5c5b4a4032e467e7b3fde22f89a84c0ee2e6eac6fda737d6277cc0806)([email protected]([email protected]))([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected])':
|
||||
dependencies:
|
||||
@@ -14921,6 +14951,16 @@ snapshots:
|
||||
|
||||
'@react-native/[email protected]': {}
|
||||
|
||||
'@react-native/[email protected](@types/[email protected])([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected])':
|
||||
dependencies:
|
||||
invariant: 2.2.4
|
||||
nullthrows: 1.1.1
|
||||
react: 19.2.6
|
||||
react-native: 0.88.0-rc.3(@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected])
|
||||
optionalDependencies:
|
||||
'@types/react': 19.3.0
|
||||
optional: true
|
||||
|
||||
'@react-native/[email protected](@types/[email protected])([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected])':
|
||||
dependencies:
|
||||
invariant: 2.2.4
|
||||
@@ -19285,6 +19325,8 @@ snapshots:
|
||||
dependencies:
|
||||
react: 19.2.6
|
||||
|
||||
[email protected]: {}
|
||||
|
||||
[email protected]: {}
|
||||
|
||||
[email protected]:
|
||||
@@ -19986,6 +20028,12 @@ snapshots:
|
||||
socks: 2.8.9
|
||||
optional: true
|
||||
|
||||
[email protected]([email protected]([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected]))([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected]):
|
||||
optionalDependencies:
|
||||
react: 19.2.6
|
||||
react-native: 0.88.0-rc.3(@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected])
|
||||
react-native-svg: 15.15.5([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected])
|
||||
|
||||
[email protected]: {}
|
||||
|
||||
[email protected]: {}
|
||||
@@ -20885,6 +20933,14 @@ snapshots:
|
||||
react: 19.3.0
|
||||
react-native: 0.88.0-rc.3(@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected])
|
||||
|
||||
[email protected]([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected]):
|
||||
dependencies:
|
||||
css-select: 5.2.2
|
||||
css-tree: 1.1.3
|
||||
react: 19.2.6
|
||||
react-native: 0.88.0-rc.3(@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected])
|
||||
optional: true
|
||||
|
||||
[email protected]([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected]):
|
||||
dependencies:
|
||||
css-select: 5.2.2
|
||||
@@ -20928,6 +20984,49 @@ snapshots:
|
||||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
[email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]):
|
||||
dependencies:
|
||||
'@react-native/asset-utils': 0.88.0-rc.3
|
||||
'@react-native/codegen': 0.88.0-rc.3(@babel/[email protected])
|
||||
'@react-native/community-cli-plugin': 0.88.0-rc.3(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))([email protected])([email protected])
|
||||
'@react-native/gradle-plugin': 0.88.0-rc.3
|
||||
'@react-native/normalize-colors': 0.88.0-rc.3
|
||||
'@react-native/virtualized-lists': 0.88.0-rc.3(@types/[email protected])([email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]))([email protected])
|
||||
anser: 1.4.10
|
||||
ansi-regex: 5.0.1
|
||||
base64-js: 1.5.1
|
||||
flow-enums-runtime: 0.0.6
|
||||
flow-parser: 0.327.0
|
||||
hermes-compiler: 260318099.0.4
|
||||
invariant: 2.2.4
|
||||
memoize-one: 5.2.1
|
||||
metro-runtime: 0.87.1
|
||||
metro-source-map: 0.87.1
|
||||
nullthrows: 1.1.1
|
||||
pretty-format: 29.7.0
|
||||
promise: 8.3.0
|
||||
react: 19.2.6
|
||||
react-devtools-core: 6.1.5([email protected])([email protected])
|
||||
react-refresh: 0.14.2
|
||||
regenerator-runtime: 0.13.11
|
||||
scheduler: 0.28.0
|
||||
semver: 7.8.5
|
||||
stacktrace-parser: 0.1.11
|
||||
tinyglobby: 0.2.17
|
||||
whatwg-fetch: 3.6.20
|
||||
ws: 7.5.11([email protected])([email protected])
|
||||
yargs: 17.7.2
|
||||
optionalDependencies:
|
||||
'@types/react': 19.3.0
|
||||
transitivePeerDependencies:
|
||||
- '@babel/core'
|
||||
- '@react-native-community/cli'
|
||||
- '@react-native/metro-config'
|
||||
- bufferutil
|
||||
- supports-color
|
||||
- utf-8-validate
|
||||
optional: true
|
||||
|
||||
[email protected](@babel/[email protected])(@react-native/[email protected](@babel/[email protected])([email protected])([email protected]))(@types/[email protected])([email protected])([email protected])([email protected]):
|
||||
dependencies:
|
||||
'@react-native/asset-utils': 0.88.0-rc.3
|
||||
|
||||
Reference in new issue
Block a user