Skip to content

Commit e254bcf

Browse files
committed
fix: move isReadOnly check from dropdown to list items
1 parent 0fb3841 commit e254bcf

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

frontend/src/components/Connect/List/ActionsCell.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ const ActionsCell: React.FC<CellContext<FullConnectorInfo, unknown>> = ({
6161
stateMutation.mutateAsync(ConnectorAction.RESTART_FAILED_TASKS);
6262

6363
return (
64-
<Dropdown disabled={isReadOnly}>
64+
<Dropdown>
6565
{status.state === ConnectorState.PAUSED && (
6666
<ActionDropdownItem
6767
onClick={resumeConnectorHandler}
@@ -77,7 +77,7 @@ const ActionsCell: React.FC<CellContext<FullConnectorInfo, unknown>> = ({
7777
)}
7878
<ActionDropdownItem
7979
onClick={restartConnectorHandler}
80-
disabled={isMutating}
80+
disabled={isMutating || isReadOnly}
8181
permission={{
8282
resource: ResourceType.CONNECT,
8383
action: Action.RESTART,
@@ -108,7 +108,7 @@ const ActionsCell: React.FC<CellContext<FullConnectorInfo, unknown>> = ({
108108
>
109109
Restart Failed Tasks
110110
</ActionDropdownItem>
111-
<DropdownItem onClick={handleDelete} danger>
111+
<DropdownItem onClick={handleDelete} disabled={isReadOnly} danger>
112112
Remove Connector
113113
</DropdownItem>
114114
</Dropdown>

0 commit comments

Comments
 (0)