Skip to content

Commit

Permalink
feat: add fallback
Browse files Browse the repository at this point in the history
  • Loading branch information
Cahllagerfeld committed Oct 24, 2024
1 parent cfc0734 commit 6a28368
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion src/app/components/columns.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { CopyButton } from "@/components/CopyButton";
import { DisplayDate } from "@/components/DisplayDate";
import { InlineAvatar } from "@/components/InlineAvatar";
import { ComponentBadge } from "@/components/stack-components/ComponentBadge";
import { ComponentFallbackDialog } from "@/components/stack-components/ComponentFallbackDialog";
import { snakeCaseToTitleCase } from "@/lib/strings";
import { sanitizeUrl } from "@/lib/url";
import { StackComponent } from "@/types/components";
Expand All @@ -27,7 +28,14 @@ export function getComponentList(): ColumnDef<StackComponent>[] {
/>
<div>
<div className="flex items-center gap-1">
<h2 className="text-text-md font-semibold">{name}</h2>
<ComponentFallbackDialog
name={name}
type={row.original.body?.type || "orchestrator"}
>
<button>
<h2 className="text-text-md font-semibold">{name}</h2>
</button>
</ComponentFallbackDialog>
<CopyButton copyText={name} />
</div>
<div className="flex items-center gap-1">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ function Info({ type }: InfoProps) {
<div className="flex w-full flex-wrap justify-between gap-2">
<div className="min-w-0">
<p className="truncate text-text-sm font-semibold">
We are working on the new Stacks experience.
We are working on the new Stack Components experience.
</p>
<p className="truncate text-text-sm">
Meanwhile you can use the CLI to manage your {snakeCaseToLowerCase(type)}.
Expand Down

0 comments on commit 6a28368

Please sign in to comment.