diff --git a/resources/js/components/accounts/account-list-card.tsx b/resources/js/components/accounts/account-list-card.tsx index a6ecd7ba..6416df9c 100644 --- a/resources/js/components/accounts/account-list-card.tsx +++ b/resources/js/components/accounts/account-list-card.tsx @@ -1,11 +1,13 @@ import { show } from '@/actions/App/Http/Controllers/AccountController'; import { AccountName } from '@/components/accounts/account-name'; import { BankLogo } from '@/components/bank-logo'; +import { AccountTypeIcon } from '@/components/dashboard/account-type-icon'; import { AmountTrendIndicator } from '@/components/dashboard/amount-trend-indicator'; import { AmountDisplay } from '@/components/ui/amount-display'; import { Card, CardContent } from '@/components/ui/card'; import { useChartColors } from '@/hooks/use-chart-color-scheme'; import { AccountWithMetrics } from '@/hooks/use-dashboard-data'; +import { cn } from '@/lib/utils'; import { formatAccountType, supportsInvestedAmount } from '@/types/account'; import { __ } from '@/utils/i18n'; import { Link } from '@inertiajs/react'; @@ -139,12 +141,11 @@ export function AccountListCard({
-
- {dragHandle} +

{account.bank && ( @@ -429,7 +430,22 @@ export function AccountListCard({

-
+
+
+ + {dragHandle && ( + + {dragHandle} + + )} +
+ {!isConnected && ( diff --git a/resources/js/components/dashboard/account-balance-card.tsx b/resources/js/components/dashboard/account-balance-card.tsx index c92a51bc..8d169829 100644 --- a/resources/js/components/dashboard/account-balance-card.tsx +++ b/resources/js/components/dashboard/account-balance-card.tsx @@ -6,6 +6,7 @@ import { AmountDisplay } from '@/components/ui/amount-display'; import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card'; import { useChartColors } from '@/hooks/use-chart-color-scheme'; import { AccountWithMetrics } from '@/hooks/use-dashboard-data'; +import { cn } from '@/lib/utils'; import { supportsInvestedAmount } from '@/types/account'; import { __ } from '@/utils/i18n'; import { Link } from '@inertiajs/react'; @@ -157,54 +158,57 @@ export function AccountBalanceCard({ return ( -
- {dragHandle} -
- - - +
+ + + - + + + {hasMortgage && linkedLoanMetrics.loanAccount && ( + + {__('Mortgage at')}{' '} + {linkedLoanMetrics.loanAccount.bank && ( + - - - {hasMortgage && linkedLoanMetrics.loanAccount && ( - - {__('Mortgage at')}{' '} - {linkedLoanMetrics.loanAccount.bank && ( - - )} - {linkedLoanMetrics.loanAccount.bank?.name ?? - linkedLoanMetrics.loanAccount.name} - - )} -
+ )} + {linkedLoanMetrics.loanAccount.bank?.name ?? + linkedLoanMetrics.loanAccount.name} + + )}
-
+
+ {dragHandle && ( + + {dragHandle} + + )}
diff --git a/resources/js/components/sortable-grid.tsx b/resources/js/components/sortable-grid.tsx index 97c54bc2..0ea26701 100644 --- a/resources/js/components/sortable-grid.tsx +++ b/resources/js/components/sortable-grid.tsx @@ -110,14 +110,12 @@ function SortableItem({ isDragging, } = useSortable({ id }); - // Collapsed to zero width by default; on card hover it expands and slides - // in, pushing the card's leading content (logo + name) to the right. const dragHandle = (