Skip to content

Commit 67abd0d

Browse files
committed
Dashboard: Migrate engine/contract-submissions from chakra to tailwind (#7721)
<!-- ## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes" If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000): ## Notes for the reviewer Anything important to call out? Be sure to also clarify these in your comments. ## How to test Unit tests, playground, etc. --> <!-- start pr-codex --> --- ## PR-Codex overview This PR focuses on refactoring the `EngineContractSubscriptions` and `ContractSubscriptionTable` components to improve their structure, style, and functionality. It also enhances the user experience by updating UI elements and integrating new components. ### Detailed summary - Updated `className` in the `input` component to use `selection:bg-inverted`. - Refactored `EngineContractSubscriptions` to use `div` instead of `Flex` for layout. - Integrated `UnderlineLink` for better link styling. - Changed `Switch` component's props from `isChecked` to `checked` and `onChange` to `onCheckedChange`. - Replaced `Flex` with `div` for various elements to improve layout consistency. - Enhanced `ContractSubscriptionTable` with new styling and improved event handling. - Updated modal components to use `Dialog` instead of `Modal`. - Improved error handling and user notifications using `toast` for actions like adding and removing subscriptions. - Refactored form handling with `react-hook-form` and `zod` for validation. - Updated `FilterSelector` to use `MultiSelect` for better user interaction. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex --> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Improved contract subscription management with a redesigned multi-step form, enhanced validation, and more user-friendly filtering controls. * Updated contract subscriptions table with improved modals and tooltips for better usability. * **Refactor** * Replaced Chakra UI components with a custom UI library for dialogs, forms, tables, tooltips, and switches. * Enhanced visual styling using Tailwind CSS classes. * Streamlined error notifications and form validation for a more consistent user experience. * **Style** * Updated selection styling for input fields to improve appearance. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
1 parent 6e2f535 commit 67abd0d

File tree

4 files changed

+611
-602
lines changed

4 files changed

+611
-602
lines changed

apps/dashboard/src/@/components/ui/input.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ const Input = React.forwardRef<HTMLInputElement, InputProps>(
1010
return (
1111
<input
1212
className={cn(
13-
"flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background selection:bg-foreground/10 file:border-0 file:bg-transparent file:font-medium file:text-sm placeholder:text-muted-foreground placeholder:text-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:selection:bg-foreground/20",
13+
"flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background selection:bg-inverted selection:text-inverted-foreground file:border-0 file:bg-transparent file:font-medium file:text-sm placeholder:text-muted-foreground placeholder:text-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
1414
className,
1515
)}
1616
ref={ref}

0 commit comments

Comments
 (0)