bito-code-review[bot] commented on code in PR #32995:
URL: https://github.com/apache/superset/pull/32995#discussion_r3557922654
##########
superset-frontend/src/pages/DatasetList/index.tsx:
##########
@@ -880,27 +853,19 @@ const DatasetList: FunctionComponent<DatasetListProps> =
({
title={t('Edit')}
placement="bottom"
>
- <span
+ <IconButton
data-test="dataset-row-edit"
- role="button"
- tabIndex={0}
- className="action-button"
onClick={() => setSvCurrentlyEditing(original)}
- >
- <Icons.EditOutlined iconSize="l" />
- </span>
+ icon={<Icons.EditOutlined iconSize="l" />}
+ />
</Tooltip>
)}
Review Comment:
<!-- Bito Reply -->
The update to the semantic view action logic is appropriate. By gating the
entire actions cell on both `allowEdit` and the existing permission checks, you
ensure that the ownership model is consistently enforced, preventing
unauthorized users from deleting semantic views.
**superset-frontend/src/pages/DatasetList/index.tsx**
```
{(canEdit || canDelete) && allowEdit && (
<Tooltip
title={t('Edit')}
placement="bottom"
>
<IconButton
data-test="dataset-row-edit"
onClick={() => setSvCurrentlyEditing(original)}
icon={<Icons.EditOutlined iconSize="l" />}
/>
</Tooltip>
)}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]