Skip to content

Remove Permission tooltip from OSS#2009

Merged
alexandrudanpop merged 5 commits intomainfrom
chore/permission-tooltip
Feb 25, 2026
Merged

Remove Permission tooltip from OSS#2009
alexandrudanpop merged 5 commits intomainfrom
chore/permission-tooltip

Conversation

@alexandrudanpop
Copy link
Copy Markdown
Contributor

Part of OPS-3675

Copilot AI review requested due to automatic review settings February 25, 2026 09:01
@linear
Copy link
Copy Markdown

linear Bot commented Feb 25, 2026

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes the “Permission needed” tooltip UI from the OSS React UI by deleting the shared PermissionNeededTooltip component and removing its usage from affected screens.

Changes:

  • Deleted PermissionNeededTooltip from @openops/components/ui.
  • Removed tooltip wrapping from the Connections header “New Connection” button and the Flow Versions “Use as Draft” menu item.
  • Updated Connections permission check to use Permission.WRITE_APP_CONNECTION.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
packages/ui-components/src/ui/permission-needed-tooltip.tsx Removes the tooltip component implementation from the UI components package.
packages/react-ui/src/app/features/connections/components/connection-table.tsx Drops tooltip wrapper and updates permission check; keeps the “New Connection” trigger disabled when lacking permission.
packages/react-ui/src/app/features/builder/flow-versions/flow-versions-card.tsx Drops tooltip wrapper from the “Use as Draft” dropdown action.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 264 to +268
const ConnectionsHeader = () => {
const { checkAccess } = useAuthorization();
const userHasPermissionToWriteAppConnection = checkAccess();
const userHasPermissionToWriteAppConnection = checkAccess(
Permission.WRITE_APP_CONNECTION,
);
Copy link

Copilot AI Feb 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

useAuthorization().checkAccess is currently defined as a zero-arg callback in authorization-hooks.ts (useCallback(() => true, [])). Calling it with Permission.WRITE_APP_CONNECTION will fail TypeScript type-checking unless checkAccess is updated to accept a permission argument (even as a no-op in OSS) or this call is reverted to checkAccess().

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, I think you will get a "Expected 0 arguments, but got 1" ts-error

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i changed it so we have the same interface as in internal for checkAccess function

@sonarqubecloud
Copy link
Copy Markdown

@alexandrudanpop alexandrudanpop merged commit 10ad42c into main Feb 25, 2026
21 checks passed
@alexandrudanpop alexandrudanpop deleted the chore/permission-tooltip branch February 25, 2026 13:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants