diff --git a/apps/sim/app/workspace/[workspaceId]/search/components/github-installation-modal.tsx b/apps/sim/app/workspace/[workspaceId]/search/components/github-installation-modal.tsx index b17d8e72c45..a966ed0c85c 100644 --- a/apps/sim/app/workspace/[workspaceId]/search/components/github-installation-modal.tsx +++ b/apps/sim/app/workspace/[workspaceId]/search/components/github-installation-modal.tsx @@ -112,88 +112,90 @@ export function GitHubInstallationModal({ - {installations.isError ? ( - void installations.refetch()} - variant='inline' - /> - ) : !data ? ( - Loading GitHub setup… - ) : !data.available ? ( - - GitHub App indexing is unavailable in this deployment. - - ) : data.needsUserConnection ? ( -
-

- {waitingForAccount - ? 'Finish connecting your account in the other tab, then refresh.' - : 'Connect your GitHub account to verify the installations you can manage.'} -

-
- - {waitingForAccount ? 'Open account connection' : 'Connect your GitHub account'} - - void installations.refetch()} - > - Refresh - + {(aria) => + installations.isError ? ( + void installations.refetch()} + variant='inline' + /> + ) : !data ? ( + Loading GitHub setup… + ) : !data.available ? ( + + GitHub App indexing is unavailable in this deployment. + + ) : data.needsUserConnection ? ( +
+

+ {waitingForAccount + ? 'Finish connecting your account in the other tab, then refresh.' + : 'Connect your GitHub account to verify the installations you can manage.'} +

+
+ + {waitingForAccount ? 'Open account connection' : 'Connect your GitHub account'} + + void installations.refetch()} + > + Refresh + +
-
- ) : ( -
-

- Install the app on your account or organization and choose its repositories, then - refresh. -

-
- {data.installUrl && ( - - Install GitHub App - + ) : ( +
+ {choices.length > 0 ? ( + ({ + value: item.installationId, + label: item.accountLogin, + }))} + value={selected?.installationId} + onChange={setInstallationId} + placeholder='Select an installation' + disabled={pending || installations.isFetching} + /> + ) : ( + + No eligible installations found. + )} - void installations.refetch()} - > - Refresh - +
+ {data.installUrl && ( + + Install GitHub App + + )} + void installations.refetch()} + > + Refresh + +
-
- )} + ) + } - {data?.available && !data.needsUserConnection && ( - - {choices.length > 0 ? ( - ({ - value: item.installationId, - label: item.accountLogin, - }))} - value={selected?.installationId} - onChange={setInstallationId} - placeholder='Select an installation' - disabled={pending || installations.isFetching} - /> - ) : ( - - No eligible installations found. - - )} - - )} {connectionError ?? ensureAccounts.error?.message ??