From 1a2e0d7ab04ff6b2d90b5779e4f493c548bca8eb Mon Sep 17 00:00:00 2001 From: Matt Date: Thu, 12 Jun 2025 17:42:42 +0200 Subject: [PATCH] updates --- pages/dashboard/interest-list.vue | 567 +++++++++++++----------------- 1 file changed, 250 insertions(+), 317 deletions(-) diff --git a/pages/dashboard/interest-list.vue b/pages/dashboard/interest-list.vue index b9dd5a0..ae61d6b 100644 --- a/pages/dashboard/interest-list.vue +++ b/pages/dashboard/interest-list.vue @@ -118,8 +118,127 @@ - - + +
+ + +
+ mdi-account-search +

No interests found

+

Try adjusting your search or filters

+
+ +
+ + + +
+ + + {{ getInitials(item["Full Name"]) }} + + +
+
+

{{ item["Full Name"] }}

+ + + {{ item["Extra Comments"] }} + +
+

{{ item["Email Address"] }}

+
+ + {{ getRelativeTime(item["Created At"]) }} + +
+ + +
+
+ CURRENT STATUS + + {{ getDescriptiveSalesStatus(item['Sales Process Level']) }} + +
+
+ + +
+
+ EOI Status +
+ + + Awaiting Further Details + +
+
+ +
+ Lead Type +
+ + {{ item['Lead Category'] === 'Friends and Family' ? 'Friends & Family' : 'General Lead' }} + +
+
+ +
+ Contract +
+ +
+
+ +
+ Added +
+ {{ formatDate(item["Created At"]) }} +
+
+
+
+
+
+
+ + +
- -
@@ -349,13 +389,6 @@ const handleInterestCreated = async (interest: Interest) => { }; const headers = computed(() => { - if (mobile) { - return [ - { title: "Contact", key: "Full Name", sortable: true }, - { title: "Status", key: "Sales Process Level", sortable: true }, - { title: "Created", key: "Created At", sortable: true }, - ]; - } return [ { title: "Contact", key: "Full Name", sortable: true, width: "25%" }, { title: "Sales Status", key: "Sales Process Level", sortable: true }, @@ -377,6 +410,27 @@ const clearAllFilters = () => { selectedSalesLevel.value = 'all'; }; +// Helper functions for mobile card layout +const getDescriptiveSalesStatus = (status: string) => { + if (!status) return 'New Interest'; + if (status.includes('Qualified')) return 'Qualified Interest'; + if (status.includes('LOI')) return 'LOI & NDA Sent'; + if (status.includes('Signed')) return 'Signed LOI & NDA'; + if (status.includes('Reservation')) return 'Made Reservation'; + if (status.includes('Contract')) return 'Contract Stage'; + return status; +}; + +const getSalesStatusColor = (status: string) => { + if (!status) return 'grey'; + if (status.includes('Qualified')) return 'blue'; + if (status.includes('LOI')) return 'orange'; + if (status.includes('Signed')) return 'green'; + if (status.includes('Reservation')) return 'purple'; + if (status.includes('Contract')) return 'primary'; + return 'grey'; +}; + const formatDate = (dateString: string) => { if (!dateString) return "-"; @@ -514,6 +568,59 @@ const getRelativeTime = (dateString: string) => { box-shadow: 0 0 0 2px rgba(25, 118, 210, 0.2); } +/* Mobile Card Layout Styles */ +.mobile-card-container { + display: flex; + flex-direction: column; + gap: 12px; +} + +.mobile-interest-card { + width: 100%; +} + +.interest-card { + cursor: pointer; + transition: all 0.2s ease; + border-radius: 12px !important; +} + +.interest-card:hover { + transform: translateY(-2px); + box-shadow: 0 4px 8px rgba(0, 0, 0, 0.12) !important; +} + +.status-section { + border-top: 1px solid #e0e0e0; + padding-top: 12px; +} + +.status-grid { + display: grid; + grid-template-columns: 1fr 1fr; + gap: 12px; +} + +.status-item { + display: flex; + flex-direction: column; + gap: 4px; +} + +.status-label { + font-size: 0.75rem; + font-weight: 500; + color: #666; + text-transform: uppercase; + letter-spacing: 0.5px; +} + +.status-value { + display: flex; + align-items: center; +} + +/* Desktop Table Styles */ .modern-table :deep(.v-table__wrapper) { border-radius: 8px; overflow: hidden; @@ -553,80 +660,13 @@ const getRelativeTime = (dateString: string) => { font-size: 0.875rem; } -.logo-icon { - height: 32px; - width: auto; - max-width: 32px; - object-fit: contain; -} - -/* Mobile horizontal scrolling with visual indicators */ .table-container { position: relative; overflow-x: auto; -webkit-overflow-scrolling: touch; } -/* Scroll indicators */ -.table-container::before, -.table-container::after { - content: ''; - position: absolute; - top: 0; - bottom: 0; - width: 40px; - pointer-events: none; - z-index: 1; - transition: opacity 0.3s; -} - -.table-container::before { - left: 0; - background: linear-gradient(to right, white, transparent); - opacity: 0; -} - -.table-container::after { - right: 0; - background: linear-gradient(to left, white, transparent); -} - -.table-container:not(.scroll-start)::before { - opacity: 1; -} - -.table-container:not(.scroll-end)::after { - opacity: 1; -} - -/* Safari-specific fixes and scrolling performance improvements */ -.modern-table :deep(.v-table__wrapper) { - -webkit-transform: translateZ(0); - transform: translateZ(0); - /* Improve scrolling performance */ - will-change: scroll-position; - -webkit-backface-visibility: hidden; - backface-visibility: hidden; -} - -.modern-table :deep(.v-data-table__td) { - min-width: 0; - /* Optimize for better rendering */ - contain: layout style paint; -} - -/* Fix potential scrolling issues on desktop */ -.modern-table :deep(.v-table) { - table-layout: fixed; - width: 100%; -} - -.modern-table :deep(tbody tr) { - /* Prevent sub-pixel rendering issues */ - transform: translateZ(0); -} - -/* Responsive column widths */ +/* Responsive column widths for desktop */ @media (min-width: 769px) { .modern-table :deep(th:nth-child(1)), .modern-table :deep(td:nth-child(1)) { @@ -659,136 +699,29 @@ const getRelativeTime = (dateString: string) => { } } -/* Mobile-specific styles */ +/* Mobile-specific adjustments */ @media (max-width: 768px) { - /* Mobile Contact Cell with Stacked Layout */ - .mobile-contact-cell { - padding: 12px 8px !important; - vertical-align: top !important; - width: 60% !important; - min-width: 280px !important; - } - - .mobile-contact-container { - width: 100%; - } - - .mobile-badges-stack { - margin-left: 44px; /* Align with contact info text */ - } - - .mobile-badges-stack .v-chip { - height: 20px !important; - font-size: 0.65rem !important; - padding: 0 6px !important; - margin: 1px !important; - } - - /* Mobile Status Cell */ - .mobile-status-cell { - padding: 12px 4px !important; - text-align: center !important; - vertical-align: middle !important; - width: 20% !important; - min-width: 80px !important; - } - - /* Mobile Date Cell */ - .mobile-date-cell { - padding: 12px 8px !important; - text-align: center !important; - vertical-align: middle !important; - width: 20% !important; - min-width: 100px !important; - } - - .mobile-date-cell .text-caption { - font-size: 0.65rem !important; - line-height: 1.3; - } - - /* Table container improvements */ - .table-container { - position: relative; - overflow-x: auto; - -webkit-overflow-scrolling: touch; - margin: 0 -16px; - padding: 0 16px; - } - - .modern-table :deep(.v-table__wrapper) { - min-width: 460px; /* Minimum width to fit 3 columns properly */ - } - - /* Table headers for mobile */ - .modern-table :deep(th) { - padding: 8px 4px !important; - font-size: 0.75rem; - white-space: nowrap; - text-align: center; - } - - .modern-table :deep(th:first-child) { - text-align: left !important; - padding-left: 8px !important; - } - - /* Adjust table row height on mobile */ - .table-row td { - height: auto !important; - min-height: 80px !important; /* Increased for stacked content */ - } - - /* Contact cell text improvements */ - .mobile-contact-cell .text-truncate { - max-width: 200px; - } - - .mobile-contact-cell .v-avatar { - flex-shrink: 0; - } - - /* Fix container padding */ .v-container { padding: 12px 16px !important; } - /* Improve mobile row layout */ - .modern-table :deep(tbody tr) { - height: auto !important; + .status-grid { + grid-template-columns: 1fr; + gap: 8px; } - /* Better text overflow handling */ - .modern-table :deep(td) { - word-break: break-word; - overflow-wrap: break-word; + .status-item { + flex-direction: row; + justify-content: space-between; + align-items: center; } - /* Add visual scroll indicators */ - .table-container::after { - content: ''; - position: absolute; - top: 0; - right: 16px; - bottom: 0; - width: 20px; - background: linear-gradient(to right, transparent, rgba(255,255,255,0.9)); - pointer-events: none; - z-index: 1; + .status-label { + flex: 1; } - /* Hover effects for mobile */ - .modern-table :deep(tbody tr:hover) { - background-color: #f5f5f5; - } - - /* Optimize badge spacing in stacked layout */ - .mobile-badges-stack .d-flex { - gap: 4px !important; - } - - .mobile-badges-stack .gap-1 { - gap: 4px !important; + .status-value { + flex: 0 0 auto; } }