Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(dashboard): Make the whole workflow row clickable #7408

Merged
merged 1 commit into from
Dec 31, 2024

Conversation

desiprisg
Copy link
Contributor

What changed? Why was the change needed?

Screenshots

Expand for optional sections

Related enterprise PR

Special notes for your reviewer

@desiprisg desiprisg self-assigned this Dec 30, 2024
Copy link

linear bot commented Dec 30, 2024

Copy link

netlify bot commented Dec 30, 2024

Deploy Preview for dev-web-novu ready!

Name Link
🔨 Latest commit f5a64e3
🔍 Latest deploy log https://app.netlify.com/sites/dev-web-novu/deploys/6772a09147b1ad0008956660
😎 Deploy Preview https://deploy-preview-7408.dashboard.novu-staging.co
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Dec 30, 2024

Deploy Preview for dashboard-v2-novu-staging ready!

Name Link
🔨 Latest commit f5a64e3
🔍 Latest deploy log https://app.netlify.com/sites/dashboard-v2-novu-staging/deploys/6772a0919a0eb600087a6834
😎 Deploy Preview https://deploy-preview-7408.dashboard-v2.novu-staging.co
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@@ -160,47 +180,43 @@ export const WorkflowRow = ({ workflow }: WorkflowRowProps) => {
};

return (
<TableRow key={workflow._id} className="relative">
<TableRow key={workflow._id} className="group relative isolate">
Copy link
Contributor

Choose a reason for hiding this comment

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

What if we just do:

    <TableRow key={workflow._id} className="hover:bg-accent/50 relative hover:cursor-pointer" onClick={handleRowClick}>

On the main row, and add to the onHoverCopy and actions cell:

          onClick={(e) => e.stopPropagation()}

Might simplify this a bit, wdyt?

Copy link
Contributor

Choose a reason for hiding this comment

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

The implementation feels like an overkill, but if I am not mistaken, it's the only way to maintain valid Table/tr/td HTML while treating each row as a link, making right-clicking Open in a new Tab work.

@desiprisg Please confirm.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes that's the thinking behind this. Also checked with some other implementations like stripe's and they seem to follow the same approach.

@desiprisg desiprisg merged commit 2c21e44 into next Dec 31, 2024
38 checks passed
@desiprisg desiprisg deleted the nv-4810-ux-make-the-whole-workflow-list-clickable branch December 31, 2024 09:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants