MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / IntegrationsPage

Function IntegrationsPage

packages/react/src/pages/integrations.tsx:47–99  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

45// ---------------------------------------------------------------------------
46
47export function IntegrationsPage() {
48 useExecutorDocumentTitle("Integrations");
49 const integrations = useAtomValue(integrationsOptimisticAtom);
50 const refreshIntegrations = useAtomRefresh(integrationsOptimisticAtom);
51
52 return (
53 <PageContainer>
54 <PageHeader
55 title="Integrations"
56 description="Tool providers available in this workspace."
57 actions={
58 <Button asChild size="sm" className="gap-1.5">
59 <Link
60 to="/{-$orgSlug}/integrations/browse"
61 onClick={() => trackEvent("integration_browse_opened", { via: "header" })}
62 >
63 <PlusIcon className="size-4" />
64 Add integration
65 </Link>
66 </Button>
67 }
68 />
69
70 <div className="mb-8">
71 <McpInstallCard />
72 </div>
73
74 <div className="mb-8 border-t border-border/50" />
75
76 {isAsyncResultLoading(integrations) ? (
77 <IntegrationsGridSkeleton />
78 ) : (
79 AsyncResult.match(integrations, {
80 onInitial: () => <IntegrationsGridSkeleton />,
81 onFailure: () => (
82 <ErrorState message="Failed to load integrations" onRetry={refreshIntegrations} />
83 ),
84 onSuccess: ({ value }) => {
85 if (value.length === 0) {
86 return <EmptyIntegrations />;
87 }
88
89 return (
90 <div className="mb-8 space-y-3">
91 <IntegrationGrid integrations={value} />
92 </div>
93 );
94 },
95 })
96 )}
97 </PageContainer>
98 );
99}
100
101// ---------------------------------------------------------------------------
102// Empty state

Callers

nothing calls this directly

Calls 3

useExecutorDocumentTitleFunction · 0.90
trackEventFunction · 0.90
isAsyncResultLoadingFunction · 0.90

Tested by

no test coverage detected