feat: Add PWA support and consolidate CSS design system
- Add PWA manifest, icons (192x192, 512x512), and service worker - Register service worker in index.html with Apple mobile web app support - Consolidate CSS variables and design tokens documentation - Update PrimeVue overrides for consistent theming - Refactor data-entry components to use shared CSS patterns - Add frontend-style-auditor agent for style consistency checks - Minor OCR validation and job worker improvements - Update start-prod.sh configuration 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
<div class="ocr-preview">
|
||||
<div class="preview-header">
|
||||
<div class="header-left">
|
||||
<i class="pi pi-check-circle" style="color: #22c55e; font-size: 1.25rem;"></i>
|
||||
<i class="pi pi-check-circle" style="color: var(--green-500); font-size: 1.25rem;"></i>
|
||||
<span class="title">Date extrase din imagine</span>
|
||||
</div>
|
||||
<div class="header-right">
|
||||
@@ -319,8 +319,8 @@ const formatProcessingTime = (ms) => {
|
||||
|
||||
<style scoped>
|
||||
.ocr-preview {
|
||||
background: #f0fdf4;
|
||||
border: 1px solid #86efac;
|
||||
background: var(--green-50);
|
||||
border: 1px solid var(--green-300);
|
||||
border-radius: 12px;
|
||||
margin: 1rem 0;
|
||||
overflow: hidden;
|
||||
@@ -331,8 +331,8 @@ const formatProcessingTime = (ms) => {
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: 0.75rem 1rem;
|
||||
background: #dcfce7;
|
||||
border-bottom: 1px solid #86efac;
|
||||
background: var(--green-100);
|
||||
border-bottom: 1px solid var(--green-300);
|
||||
}
|
||||
|
||||
.header-left {
|
||||
@@ -343,7 +343,7 @@ const formatProcessingTime = (ms) => {
|
||||
|
||||
.title {
|
||||
font-weight: 600;
|
||||
color: #166534;
|
||||
color: var(--green-800);
|
||||
}
|
||||
|
||||
.header-right {
|
||||
@@ -357,11 +357,11 @@ const formatProcessingTime = (ms) => {
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
font-size: 0.85rem;
|
||||
color: #166534;
|
||||
color: var(--green-800);
|
||||
}
|
||||
|
||||
.collapse-btn {
|
||||
color: #166534 !important;
|
||||
color: var(--green-800) !important;
|
||||
}
|
||||
|
||||
.preview-content {
|
||||
@@ -374,7 +374,7 @@ const formatProcessingTime = (ms) => {
|
||||
margin-bottom: 0.5rem;
|
||||
background: rgba(255, 255, 255, 0.5);
|
||||
border-radius: 8px;
|
||||
border: 1px solid #bbf7d0;
|
||||
border: 1px solid var(--green-200);
|
||||
}
|
||||
|
||||
.ocr-section:last-of-type {
|
||||
@@ -384,16 +384,16 @@ const formatProcessingTime = (ms) => {
|
||||
.ocr-section-title {
|
||||
font-size: 0.7rem;
|
||||
font-weight: 700;
|
||||
color: #166534;
|
||||
color: var(--green-800);
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.08em;
|
||||
margin-bottom: 0.5rem;
|
||||
padding-bottom: 0.35rem;
|
||||
border-bottom: 1px dashed #86efac;
|
||||
border-bottom: 1px dashed var(--green-300);
|
||||
}
|
||||
|
||||
.ocr-section-content {
|
||||
color: #1e293b;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
/* FURNIZOR section */
|
||||
@@ -407,13 +407,13 @@ const formatProcessingTime = (ms) => {
|
||||
|
||||
.vendor-cui {
|
||||
font-size: 0.85rem;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
margin-top: 0.15rem;
|
||||
}
|
||||
|
||||
.vendor-address {
|
||||
font-size: 0.8rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
margin-top: 0.15rem;
|
||||
}
|
||||
|
||||
@@ -428,19 +428,19 @@ const formatProcessingTime = (ms) => {
|
||||
|
||||
.client-cui {
|
||||
font-size: 0.85rem;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
margin-top: 0.15rem;
|
||||
}
|
||||
|
||||
.client-address {
|
||||
font-size: 0.8rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
margin-top: 0.15rem;
|
||||
}
|
||||
|
||||
/* Placeholder when no data extracted */
|
||||
.no-data {
|
||||
color: #9ca3af;
|
||||
color: var(--text-color-secondary);
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
@@ -454,20 +454,20 @@ const formatProcessingTime = (ms) => {
|
||||
|
||||
.doc-number {
|
||||
font-weight: 500;
|
||||
color: #334155;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.doc-date {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.35rem;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.doc-date .pi-calendar {
|
||||
font-size: 0.85rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Unified values table (TOTAL + Payment + TVA) */
|
||||
@@ -486,13 +486,13 @@ const formatProcessingTime = (ms) => {
|
||||
|
||||
.value-label {
|
||||
font-weight: 500;
|
||||
color: #374151;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.value-amount {
|
||||
font-weight: 600;
|
||||
margin-left: auto;
|
||||
color: #1f2937;
|
||||
color: var(--text-color);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
@@ -501,13 +501,13 @@ const formatProcessingTime = (ms) => {
|
||||
.value-row.total-row {
|
||||
margin-top: 0.35rem;
|
||||
padding-top: 0.5rem;
|
||||
border-top: 1px dashed #86efac;
|
||||
border-top: 1px dashed var(--green-300);
|
||||
}
|
||||
|
||||
/* Items count - subtle, at bottom of values section */
|
||||
.items-count-inline {
|
||||
font-size: 0.8rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
text-align: right;
|
||||
padding-top: 0.35rem;
|
||||
}
|
||||
@@ -519,7 +519,7 @@ const formatProcessingTime = (ms) => {
|
||||
|
||||
/* Warning row for calculated total */
|
||||
.value-row.warning-row {
|
||||
background: #fef3c7;
|
||||
background: var(--yellow-100);
|
||||
border-radius: 6px;
|
||||
padding: 0.5rem 0.75rem;
|
||||
margin: 0.25rem 0;
|
||||
@@ -529,22 +529,22 @@ const formatProcessingTime = (ms) => {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
color: #92400e;
|
||||
color: var(--yellow-800);
|
||||
}
|
||||
|
||||
.warning-icon {
|
||||
color: #f59e0b;
|
||||
color: var(--yellow-500);
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.value-amount.calculated {
|
||||
color: #92400e;
|
||||
color: var(--yellow-800);
|
||||
}
|
||||
|
||||
.value-amount .hint {
|
||||
font-size: 0.75rem;
|
||||
font-weight: 400;
|
||||
color: #a3a3a3;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Validation warnings */
|
||||
@@ -554,14 +554,14 @@ const formatProcessingTime = (ms) => {
|
||||
gap: 0.5rem;
|
||||
padding: 0.5rem 0.75rem;
|
||||
margin: 0.25rem 0;
|
||||
background: #fee2e2;
|
||||
background: var(--red-100);
|
||||
border-radius: 6px;
|
||||
font-size: 0.8rem;
|
||||
color: #991b1b;
|
||||
color: var(--red-800);
|
||||
}
|
||||
|
||||
.validation-warning i {
|
||||
color: #dc2626;
|
||||
color: var(--red-600);
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
@@ -572,21 +572,21 @@ const formatProcessingTime = (ms) => {
|
||||
gap: 0.5rem;
|
||||
padding: 0.5rem 0.75rem;
|
||||
margin: 0.25rem 0;
|
||||
background: #dbeafe;
|
||||
background: var(--blue-100);
|
||||
border-radius: 6px;
|
||||
font-size: 0.8rem;
|
||||
color: #1e40af;
|
||||
color: var(--blue-700);
|
||||
}
|
||||
|
||||
.validation-info i {
|
||||
color: #2563eb;
|
||||
color: var(--blue-600);
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.raw-text-section {
|
||||
margin-top: 1rem;
|
||||
padding-top: 1rem;
|
||||
border-top: 1px dashed #86efac;
|
||||
border-top: 1px dashed var(--green-300);
|
||||
}
|
||||
|
||||
.raw-text-header {
|
||||
@@ -607,44 +607,44 @@ const formatProcessingTime = (ms) => {
|
||||
}
|
||||
|
||||
.ocr-engine-badge.paddleocr {
|
||||
background: #dbeafe;
|
||||
color: #1e40af;
|
||||
background: var(--blue-100);
|
||||
color: var(--blue-700);
|
||||
}
|
||||
|
||||
.ocr-engine-badge.tesseract {
|
||||
background: #fef3c7;
|
||||
color: #92400e;
|
||||
background: var(--yellow-100);
|
||||
color: var(--yellow-800);
|
||||
}
|
||||
|
||||
.ocr-engine-badge.fast {
|
||||
background: #dcfce7;
|
||||
color: #166534;
|
||||
background: var(--green-100);
|
||||
color: var(--green-800);
|
||||
}
|
||||
|
||||
.ocr-engine-badge.adaptive {
|
||||
background: #dbeafe;
|
||||
color: #1e40af;
|
||||
background: var(--blue-100);
|
||||
color: var(--blue-700);
|
||||
}
|
||||
|
||||
.ocr-engine-badge.full {
|
||||
background: #fef3c7;
|
||||
color: #92400e;
|
||||
background: var(--yellow-100);
|
||||
color: var(--yellow-800);
|
||||
}
|
||||
|
||||
/* docTR engine styles */
|
||||
.ocr-engine-badge.doctr {
|
||||
background: #ede9fe;
|
||||
color: #5b21b6;
|
||||
background: var(--purple-100);
|
||||
color: var(--purple-700);
|
||||
}
|
||||
|
||||
.ocr-engine-badge.doctr-fast {
|
||||
background: #d1fae5;
|
||||
color: #047857;
|
||||
background: var(--teal-100);
|
||||
color: var(--teal-700);
|
||||
}
|
||||
|
||||
.ocr-engine-badge.doctr-adaptive {
|
||||
background: #e0e7ff;
|
||||
color: #3730a3;
|
||||
background: var(--indigo-100);
|
||||
color: var(--indigo-700);
|
||||
}
|
||||
|
||||
.ocr-message-badge {
|
||||
@@ -655,18 +655,18 @@ const formatProcessingTime = (ms) => {
|
||||
border-radius: 4px;
|
||||
font-size: 0.75rem;
|
||||
font-weight: 500;
|
||||
background: #f1f5f9;
|
||||
color: #475569;
|
||||
background: var(--surface-100);
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.ocr-message-badge.fast-mode {
|
||||
background: #dcfce7;
|
||||
color: #166534;
|
||||
background: var(--green-100);
|
||||
color: var(--green-800);
|
||||
}
|
||||
|
||||
.ocr-message-badge.full-pipeline {
|
||||
background: #fef3c7;
|
||||
color: #92400e;
|
||||
background: var(--yellow-100);
|
||||
color: var(--yellow-800);
|
||||
}
|
||||
|
||||
.ocr-time-badge {
|
||||
@@ -677,15 +677,15 @@ const formatProcessingTime = (ms) => {
|
||||
border-radius: 4px;
|
||||
font-size: 0.75rem;
|
||||
font-weight: 600;
|
||||
background: #e0e7ff;
|
||||
color: #3730a3;
|
||||
background: var(--indigo-100);
|
||||
color: var(--indigo-700);
|
||||
}
|
||||
|
||||
.raw-text {
|
||||
margin-top: 0.5rem;
|
||||
padding: 0.75rem;
|
||||
background: white;
|
||||
border: 1px solid #e2e8f0;
|
||||
background: var(--surface-card);
|
||||
border: 1px solid var(--surface-border);
|
||||
border-radius: 8px;
|
||||
max-height: 200px;
|
||||
overflow: auto;
|
||||
@@ -696,7 +696,7 @@ const formatProcessingTime = (ms) => {
|
||||
font-size: 0.75rem;
|
||||
white-space: pre-wrap;
|
||||
word-break: break-word;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.preview-actions {
|
||||
@@ -704,8 +704,8 @@ const formatProcessingTime = (ms) => {
|
||||
justify-content: flex-end;
|
||||
gap: 0.75rem;
|
||||
padding: 0.75rem 1rem;
|
||||
background: #f8fafc;
|
||||
border-top: 1px solid #e2e8f0;
|
||||
background: var(--surface-ground);
|
||||
border-top: 1px solid var(--surface-border);
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
@@ -722,9 +722,6 @@ const formatProcessingTime = (ms) => {
|
||||
.preview-actions {
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.preview-actions :deep(.p-button) {
|
||||
width: 100%;
|
||||
}
|
||||
/* PrimeVue button width moved to vendor/primevue-overrides.css */
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -26,13 +26,13 @@
|
||||
</div>
|
||||
|
||||
<div v-else-if="selectedFile" class="file-selected-state">
|
||||
<i class="pi pi-check-circle" style="font-size: 1.75rem; color: #22c55e;"></i>
|
||||
<i class="pi pi-check-circle" style="font-size: 1.75rem; color: var(--green-500);"></i>
|
||||
<p class="file-name">{{ selectedFile.name }}</p>
|
||||
<p class="file-size">{{ formatFileSize(selectedFile.size) }}</p>
|
||||
</div>
|
||||
|
||||
<div v-else class="empty-state">
|
||||
<i class="pi pi-camera" style="font-size: 2rem; color: #667eea;"></i>
|
||||
<i class="pi pi-camera" style="font-size: 2rem; color: var(--primary-500);"></i>
|
||||
<p class="main-text">
|
||||
<span v-if="isDragging">Elibereaza pentru a incarca</span>
|
||||
<span v-else>Trage poza bonului aici sau click pentru a selecta</span>
|
||||
@@ -436,29 +436,29 @@ defineExpose({ reset, processOCR })
|
||||
}
|
||||
|
||||
.upload-dropzone {
|
||||
border: 2px dashed #cbd5e1;
|
||||
border: 2px dashed var(--surface-border);
|
||||
border-radius: 10px;
|
||||
padding: 1rem 1.25rem;
|
||||
text-align: center;
|
||||
cursor: pointer;
|
||||
transition: all 0.3s ease;
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
}
|
||||
|
||||
.upload-dropzone:hover {
|
||||
border-color: #667eea;
|
||||
background: #f1f5f9;
|
||||
border-color: var(--primary-500);
|
||||
background: var(--surface-hover);
|
||||
}
|
||||
|
||||
.upload-dropzone.dragging {
|
||||
border-color: #667eea;
|
||||
background: #eef2ff;
|
||||
border-color: var(--primary-500);
|
||||
background: var(--primary-50);
|
||||
transform: scale(1.02);
|
||||
}
|
||||
|
||||
.upload-dropzone.processing {
|
||||
cursor: default;
|
||||
background: #fefefe;
|
||||
background: var(--surface-card);
|
||||
}
|
||||
|
||||
.hidden-input {
|
||||
@@ -475,13 +475,13 @@ defineExpose({ reset, processOCR })
|
||||
|
||||
.main-text {
|
||||
font-size: 0.9rem;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
margin: 0.25rem 0;
|
||||
}
|
||||
|
||||
.sub-text {
|
||||
font-size: 0.8rem;
|
||||
color: #94a3b8;
|
||||
color: var(--text-color-secondary);
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
@@ -496,14 +496,14 @@ defineExpose({ reset, processOCR })
|
||||
.file-name {
|
||||
font-weight: 600;
|
||||
font-size: 0.9rem;
|
||||
color: #1e293b;
|
||||
color: var(--text-color);
|
||||
margin: 0.25rem 0 0 0;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.file-size {
|
||||
font-size: 0.8rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
@@ -517,21 +517,11 @@ defineExpose({ reset, processOCR })
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
/* Engine selector dropdown */
|
||||
/* Engine selector dropdown - PrimeVue styles in vendor/primevue-overrides.css */
|
||||
.engine-selector {
|
||||
min-width: 180px;
|
||||
}
|
||||
|
||||
.engine-selector:deep(.p-dropdown-label) {
|
||||
padding: 0.5rem 0.75rem !important;
|
||||
font-size: 0.875rem;
|
||||
color: #475569;
|
||||
}
|
||||
|
||||
.engine-selector:deep(.p-dropdown-trigger) {
|
||||
width: 2rem !important;
|
||||
}
|
||||
|
||||
/* Engine dropdown option with description */
|
||||
.engine-option {
|
||||
display: flex;
|
||||
@@ -543,12 +533,12 @@ defineExpose({ reset, processOCR })
|
||||
.engine-label {
|
||||
font-weight: 500;
|
||||
font-size: 0.875rem;
|
||||
color: #1e293b;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.engine-desc {
|
||||
font-size: 0.75rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Processing state */
|
||||
@@ -561,14 +551,14 @@ defineExpose({ reset, processOCR })
|
||||
|
||||
.processing-text {
|
||||
font-size: 1rem;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
margin: 0.5rem 0 0 0;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.processing-subtext {
|
||||
font-size: 0.85rem;
|
||||
color: #94a3b8;
|
||||
color: var(--text-color-secondary);
|
||||
margin: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
|
||||
<!-- Empty State -->
|
||||
<div v-else-if="!hasData" class="empty-state">
|
||||
<i class="pi pi-chart-bar" style="font-size: 3rem; color: #94a3b8;"></i>
|
||||
<i class="pi pi-chart-bar empty-state-icon"></i>
|
||||
<h3>Nu exista date</h3>
|
||||
<p>Procesati imagini cu OCR pentru a vedea statisticile.</p>
|
||||
</div>
|
||||
@@ -163,28 +163,28 @@
|
||||
<h3>Statistici Generale</h3>
|
||||
<div class="stats-grid">
|
||||
<div class="stat-box">
|
||||
<i class="pi pi-file" style="color: #667eea;"></i>
|
||||
<i class="pi pi-file stat-icon stat-icon--primary"></i>
|
||||
<div class="stat-info">
|
||||
<span class="stat-number">{{ stats.total_jobs || 0 }}</span>
|
||||
<span class="stat-desc">Total joburi</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="stat-box">
|
||||
<i class="pi pi-check-circle" style="color: #22c55e;"></i>
|
||||
<i class="pi pi-check-circle stat-icon stat-icon--success"></i>
|
||||
<div class="stat-info">
|
||||
<span class="stat-number">{{ stats.successful_jobs || 0 }}</span>
|
||||
<span class="stat-desc">Procesate cu succes</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="stat-box">
|
||||
<i class="pi pi-times-circle" style="color: #ef4444;"></i>
|
||||
<i class="pi pi-times-circle stat-icon stat-icon--error"></i>
|
||||
<div class="stat-info">
|
||||
<span class="stat-number">{{ stats.failed_jobs || 0 }}</span>
|
||||
<span class="stat-desc">Esuate</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="stat-box">
|
||||
<i class="pi pi-clock" style="color: #f59e0b;"></i>
|
||||
<i class="pi pi-clock stat-icon stat-icon--warning"></i>
|
||||
<div class="stat-info">
|
||||
<span class="stat-number">{{ formatTime(stats.avg_processing_time_ms) }}</span>
|
||||
<span class="stat-desc">Timp mediu total</span>
|
||||
@@ -823,7 +823,7 @@ onBeforeUnmount(() => {
|
||||
.page-header h1 {
|
||||
font-size: 1.5rem;
|
||||
font-weight: 600;
|
||||
color: #1e293b;
|
||||
color: var(--text-color);
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
@@ -968,11 +968,11 @@ onBeforeUnmount(() => {
|
||||
|
||||
/* Section Card */
|
||||
.section-card {
|
||||
background: white;
|
||||
background: var(--surface-card);
|
||||
border-radius: 12px;
|
||||
padding: 1.25rem;
|
||||
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
|
||||
border: 1px solid #e2e8f0;
|
||||
box-shadow: var(--shadow-sm);
|
||||
border: 1px solid var(--surface-border);
|
||||
margin-bottom: 1.5rem;
|
||||
}
|
||||
|
||||
@@ -1115,11 +1115,11 @@ onBeforeUnmount(() => {
|
||||
}
|
||||
|
||||
.chart-card {
|
||||
background: white;
|
||||
background: var(--surface-card);
|
||||
border-radius: 12px;
|
||||
padding: 1.25rem;
|
||||
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
|
||||
border: 1px solid #e2e8f0;
|
||||
box-shadow: var(--shadow-sm);
|
||||
border: 1px solid var(--surface-border);
|
||||
}
|
||||
|
||||
.chart-card h3 {
|
||||
@@ -1136,11 +1136,11 @@ onBeforeUnmount(() => {
|
||||
|
||||
/* Stats Overview */
|
||||
.stats-overview {
|
||||
background: white;
|
||||
background: var(--surface-card);
|
||||
border-radius: 12px;
|
||||
padding: 1.25rem;
|
||||
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
|
||||
border: 1px solid #e2e8f0;
|
||||
box-shadow: var(--shadow-sm);
|
||||
border: 1px solid var(--surface-border);
|
||||
margin-bottom: 1.5rem;
|
||||
}
|
||||
|
||||
@@ -1162,7 +1162,7 @@ onBeforeUnmount(() => {
|
||||
align-items: center;
|
||||
gap: 0.75rem;
|
||||
padding: 0.75rem;
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
@@ -1178,12 +1178,12 @@ onBeforeUnmount(() => {
|
||||
.stat-number {
|
||||
font-size: 1.25rem;
|
||||
font-weight: 600;
|
||||
color: #1e293b;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.stat-desc {
|
||||
font-size: 0.8rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Engine Badges */
|
||||
@@ -1292,6 +1292,32 @@ onBeforeUnmount(() => {
|
||||
min-width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
/* Dark mode compatible icon styles */
|
||||
.empty-state-icon {
|
||||
font-size: 3rem;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.stat-icon {
|
||||
font-size: 1.5rem;
|
||||
}
|
||||
|
||||
.stat-icon--primary {
|
||||
color: var(--primary-500, #667eea);
|
||||
}
|
||||
|
||||
.stat-icon--success {
|
||||
color: var(--green-500, #22c55e);
|
||||
}
|
||||
|
||||
.stat-icon--error {
|
||||
color: var(--red-500, #ef4444);
|
||||
}
|
||||
|
||||
.stat-icon--warning {
|
||||
color: var(--yellow-500, #f59e0b);
|
||||
}
|
||||
</style>
|
||||
|
||||
<!-- Non-scoped styles for PrimeVue overrides -->
|
||||
|
||||
@@ -159,7 +159,7 @@
|
||||
v-else-if="att.mime_type?.startsWith('image/') && !attachmentBlobUrls[att.id]"
|
||||
class="image-placeholder"
|
||||
>
|
||||
<i class="pi pi-image" style="font-size: 2rem; color: #94a3b8;"></i>
|
||||
<i class="pi pi-image" style="font-size: 2rem; color: var(--text-color-secondary);"></i>
|
||||
<span>{{ att.filename }}</span>
|
||||
</div>
|
||||
<div v-else class="pdf-preview">
|
||||
@@ -2071,16 +2071,16 @@ const submitForReview = async () => {
|
||||
gap: 0.5rem;
|
||||
padding: 0.75rem 1rem;
|
||||
border-radius: 8px;
|
||||
background: #fef3c7;
|
||||
border: 1px solid #fbbf24;
|
||||
color: #92400e;
|
||||
background: var(--yellow-100);
|
||||
border: 1px solid var(--yellow-400);
|
||||
color: var(--yellow-800);
|
||||
font-size: 0.875rem;
|
||||
}
|
||||
|
||||
.validation-banner.warning {
|
||||
background: #fee2e2;
|
||||
border-color: #f87171;
|
||||
color: #991b1b;
|
||||
background: var(--red-100);
|
||||
border-color: var(--red-400);
|
||||
color: var(--red-800);
|
||||
}
|
||||
|
||||
.validation-banner i {
|
||||
@@ -2167,8 +2167,8 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
padding: 0.6rem 1rem;
|
||||
background: #dcfce7;
|
||||
border: 1px solid #86efac;
|
||||
background: var(--green-100);
|
||||
border: 1px solid var(--green-300);
|
||||
border-radius: 8px;
|
||||
cursor: pointer;
|
||||
margin-top: 0.75rem;
|
||||
@@ -2176,23 +2176,23 @@ const submitForReview = async () => {
|
||||
}
|
||||
|
||||
.ocr-applied-banner:hover {
|
||||
background: #bbf7d0;
|
||||
background: var(--green-200);
|
||||
}
|
||||
|
||||
.ocr-applied-banner .pi-check-circle {
|
||||
color: #22c55e;
|
||||
color: var(--green-500);
|
||||
font-size: 1.1rem;
|
||||
}
|
||||
|
||||
.ocr-applied-banner span {
|
||||
flex: 1;
|
||||
font-weight: 500;
|
||||
color: #166534;
|
||||
color: var(--green-800);
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.ocr-applied-banner .pi-chevron-down {
|
||||
color: #166534;
|
||||
color: var(--green-800);
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
@@ -2222,11 +2222,11 @@ const submitForReview = async () => {
|
||||
/* Pending files header */
|
||||
.pending-files-header {
|
||||
font-size: 0.85rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
font-weight: 500;
|
||||
margin-bottom: 0.5rem;
|
||||
padding-bottom: 0.35rem;
|
||||
border-bottom: 1px dashed #cbd5e1;
|
||||
border-bottom: 1px dashed var(--surface-border);
|
||||
}
|
||||
|
||||
.radio-group {
|
||||
@@ -2246,7 +2246,7 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
height: 100%;
|
||||
background: #f5f5f5;
|
||||
background: var(--surface-100);
|
||||
padding: 1rem;
|
||||
}
|
||||
|
||||
@@ -2270,20 +2270,20 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
gap: 0.75rem;
|
||||
padding: 0.5rem 0.75rem;
|
||||
background: #f8fafc;
|
||||
border: 1px solid #e2e8f0;
|
||||
background: var(--surface-ground);
|
||||
border: 1px solid var(--surface-border);
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
.selected-file-item i {
|
||||
color: #667eea;
|
||||
color: var(--primary-500);
|
||||
font-size: 1.25rem;
|
||||
}
|
||||
|
||||
.selected-file-item .file-name {
|
||||
flex: 1;
|
||||
font-weight: 500;
|
||||
color: #1e293b;
|
||||
color: var(--text-color);
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
@@ -2291,15 +2291,15 @@ const submitForReview = async () => {
|
||||
|
||||
.selected-file-item .file-size {
|
||||
font-size: 0.85rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Extra details section (TVA, items, address) */
|
||||
.extra-details-section {
|
||||
margin-top: 1rem;
|
||||
padding: 0.75rem;
|
||||
background: #f0f9ff;
|
||||
border: 1px solid #bae6fd;
|
||||
background: var(--blue-50);
|
||||
border: 1px solid var(--blue-200);
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
@@ -2309,7 +2309,7 @@ const submitForReview = async () => {
|
||||
gap: 0.5rem;
|
||||
margin-bottom: 0.75rem;
|
||||
margin-top: 0;
|
||||
color: #0284c7;
|
||||
color: var(--blue-600);
|
||||
font-size: 0.95rem;
|
||||
}
|
||||
|
||||
@@ -2329,13 +2329,13 @@ const submitForReview = async () => {
|
||||
.tva-row.total {
|
||||
margin-top: 0.5rem;
|
||||
padding-top: 0.5rem;
|
||||
border-top: 1px dashed #0284c7;
|
||||
border-top: 1px dashed var(--blue-600);
|
||||
}
|
||||
|
||||
.tva-label {
|
||||
min-width: 150px;
|
||||
font-weight: 500;
|
||||
color: #334155;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.tva-input {
|
||||
@@ -2344,7 +2344,7 @@ const submitForReview = async () => {
|
||||
|
||||
.tva-value {
|
||||
font-weight: 600;
|
||||
color: #0284c7;
|
||||
color: var(--blue-600);
|
||||
}
|
||||
|
||||
/* Supplier warning */
|
||||
@@ -2353,7 +2353,7 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
gap: 0.25rem;
|
||||
margin-top: 0.25rem;
|
||||
color: #f59e0b;
|
||||
color: var(--yellow-500);
|
||||
}
|
||||
|
||||
/* Supplier selected indicator */
|
||||
@@ -2362,7 +2362,7 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
gap: 0.25rem;
|
||||
margin-top: 0.25rem;
|
||||
color: #22c55e;
|
||||
color: var(--green-500);
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
@@ -2371,7 +2371,7 @@ const submitForReview = async () => {
|
||||
display: block;
|
||||
margin-top: 0.25rem;
|
||||
font-size: 0.8rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Payment methods display */
|
||||
@@ -2407,7 +2407,7 @@ const submitForReview = async () => {
|
||||
display: block;
|
||||
margin-bottom: 0.25rem;
|
||||
font-weight: 500;
|
||||
color: #334155;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
/* ========================================
|
||||
@@ -2416,7 +2416,7 @@ const submitForReview = async () => {
|
||||
|
||||
.form-section {
|
||||
padding: 0.6rem 0;
|
||||
border-bottom: 1px solid #e2e8f0;
|
||||
border-bottom: 1px solid var(--surface-border);
|
||||
}
|
||||
|
||||
.form-section:last-of-type {
|
||||
@@ -2426,7 +2426,7 @@ const submitForReview = async () => {
|
||||
.form-section-title {
|
||||
font-size: 0.7rem;
|
||||
font-weight: 600;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.05em;
|
||||
margin-bottom: 0.5rem;
|
||||
@@ -2489,7 +2489,7 @@ const submitForReview = async () => {
|
||||
.direction-header .field-label {
|
||||
font-size: 0.85rem;
|
||||
font-weight: 500;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.auto-tag {
|
||||
@@ -2519,7 +2519,7 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
gap: 0.25rem;
|
||||
font-size: 0.75rem;
|
||||
color: #22c55e;
|
||||
color: var(--green-500);
|
||||
font-weight: 500;
|
||||
white-space: nowrap;
|
||||
}
|
||||
@@ -2544,7 +2544,7 @@ const submitForReview = async () => {
|
||||
.tva-label-compact {
|
||||
min-width: 80px;
|
||||
font-size: 0.85rem;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.tva-input-compact {
|
||||
@@ -2554,12 +2554,12 @@ const submitForReview = async () => {
|
||||
.tva-edit-row.tva-total-row {
|
||||
margin-top: 0.35rem;
|
||||
padding-top: 0.35rem;
|
||||
border-top: 1px dashed #cbd5e1;
|
||||
border-top: 1px dashed var(--surface-border);
|
||||
}
|
||||
|
||||
.tva-total-value {
|
||||
font-weight: 600;
|
||||
color: #0284c7;
|
||||
color: var(--blue-600);
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
@@ -2578,7 +2578,7 @@ const submitForReview = async () => {
|
||||
/* Form groups with subtle borders */
|
||||
.form-group {
|
||||
padding: 0.75rem 0;
|
||||
border-bottom: 1px solid #e2e8f0;
|
||||
border-bottom: 1px solid var(--surface-border);
|
||||
}
|
||||
|
||||
.form-group:first-child {
|
||||
@@ -2606,24 +2606,24 @@ const submitForReview = async () => {
|
||||
gap: 0.4rem;
|
||||
padding: 0.3rem 0.5rem;
|
||||
margin-top: 0.4rem;
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
transition: background 0.15s;
|
||||
}
|
||||
|
||||
.address-collapsed:hover {
|
||||
background: #f1f5f9;
|
||||
background: var(--surface-hover);
|
||||
}
|
||||
|
||||
.address-collapsed i {
|
||||
font-size: 0.7rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.address-preview {
|
||||
font-size: 0.75rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
@@ -2634,7 +2634,7 @@ const submitForReview = async () => {
|
||||
.address-expanded {
|
||||
margin-top: 0.4rem;
|
||||
padding: 0.4rem;
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
@@ -2660,7 +2660,7 @@ const submitForReview = async () => {
|
||||
======================================== */
|
||||
|
||||
.values-section {
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
border-radius: 6px;
|
||||
padding: 0.5rem 0.75rem;
|
||||
}
|
||||
@@ -2702,55 +2702,23 @@ const submitForReview = async () => {
|
||||
.value-item label {
|
||||
font-size: 0.75rem;
|
||||
font-weight: 500;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
/* Force InputNumber to respect container width */
|
||||
/* Force InputNumber to respect container width - PrimeVue styles in vendor/primevue-overrides.css */
|
||||
.input-compact {
|
||||
width: 100% !important;
|
||||
max-width: 130px !important;
|
||||
}
|
||||
|
||||
:deep(.value-item-total .p-inputnumber) {
|
||||
width: 100% !important;
|
||||
max-width: 130px !important;
|
||||
}
|
||||
|
||||
:deep(.value-item-total .p-inputnumber-input) {
|
||||
width: 100% !important;
|
||||
}
|
||||
|
||||
:deep(.payment-method-item .p-inputnumber) {
|
||||
width: 100% !important;
|
||||
max-width: 110px !important;
|
||||
}
|
||||
|
||||
:deep(.payment-method-item .p-inputnumber-input) {
|
||||
width: 100% !important;
|
||||
}
|
||||
|
||||
.dropdown-payment {
|
||||
width: 100% !important;
|
||||
max-width: 190px !important;
|
||||
}
|
||||
|
||||
:deep(.dropdown-payment) {
|
||||
width: 100% !important;
|
||||
max-width: 190px !important;
|
||||
}
|
||||
|
||||
:deep(.dropdown-payment .p-dropdown) {
|
||||
width: 100% !important;
|
||||
}
|
||||
|
||||
.payment-method-value {
|
||||
display: inline-block;
|
||||
font-size: 0.95rem;
|
||||
font-weight: 500;
|
||||
color: #334155;
|
||||
background: #f8fafc;
|
||||
border: 1px solid #e2e8f0;
|
||||
color: var(--text-color);
|
||||
background: var(--surface-ground);
|
||||
border: 1px solid var(--surface-border);
|
||||
padding: 0.5rem 0.75rem;
|
||||
border-radius: 6px;
|
||||
min-width: 90px;
|
||||
@@ -2761,7 +2729,7 @@ const submitForReview = async () => {
|
||||
.tva-compact {
|
||||
margin-top: 0.5rem;
|
||||
padding-top: 0.5rem;
|
||||
border-top: 1px dashed #cbd5e1;
|
||||
border-top: 1px dashed var(--surface-border);
|
||||
}
|
||||
|
||||
.tva-item {
|
||||
@@ -2771,14 +2739,7 @@ const submitForReview = async () => {
|
||||
.input-tva {
|
||||
width: 110px !important;
|
||||
}
|
||||
|
||||
:deep(.input-tva) {
|
||||
width: 110px !important;
|
||||
}
|
||||
|
||||
:deep(.input-tva .p-inputnumber-input) {
|
||||
width: 110px !important;
|
||||
}
|
||||
/* PrimeVue input-tva styles moved to vendor/primevue-overrides.css */
|
||||
|
||||
.tva-total-item {
|
||||
padding-left: 0.5rem;
|
||||
@@ -2788,9 +2749,9 @@ const submitForReview = async () => {
|
||||
display: inline-block;
|
||||
font-size: 0.95rem;
|
||||
font-weight: 500;
|
||||
color: #334155;
|
||||
background: #f8fafc;
|
||||
border: 1px solid #e2e8f0;
|
||||
color: var(--text-color);
|
||||
background: var(--surface-ground);
|
||||
border: 1px solid var(--surface-border);
|
||||
padding: 0.5rem 0.75rem;
|
||||
border-radius: 6px;
|
||||
min-width: 90px;
|
||||
@@ -2800,12 +2761,12 @@ const submitForReview = async () => {
|
||||
/* Small labels for secondary fields */
|
||||
.label-small {
|
||||
font-size: 0.8rem !important;
|
||||
color: #64748b !important;
|
||||
color: var(--text-color-secondary) !important;
|
||||
}
|
||||
|
||||
/* Muted labels for optional fields */
|
||||
.label-muted {
|
||||
color: #94a3b8 !important;
|
||||
color: var(--text-color-secondary) !important;
|
||||
}
|
||||
|
||||
/* Small inputs */
|
||||
@@ -2845,7 +2806,7 @@ const submitForReview = async () => {
|
||||
align-items: flex-end;
|
||||
padding: 0.5rem 0;
|
||||
margin-top: 0.5rem;
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
border-radius: 4px;
|
||||
padding: 0.5rem;
|
||||
}
|
||||
@@ -2866,14 +2827,14 @@ const submitForReview = async () => {
|
||||
|
||||
.tva-total-inline {
|
||||
font-weight: 500;
|
||||
color: #334155;
|
||||
color: var(--text-color);
|
||||
font-size: 0.95rem;
|
||||
padding: 0.5rem 0;
|
||||
}
|
||||
|
||||
/* Optional fields row */
|
||||
.optional-fields {
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
padding: 0.5rem;
|
||||
border-radius: 4px;
|
||||
margin-top: 0.4rem;
|
||||
@@ -2958,20 +2919,15 @@ const submitForReview = async () => {
|
||||
min-width: 80px;
|
||||
}
|
||||
|
||||
/* Dropdowns and inputs full width in their containers */
|
||||
.form-field :deep(.p-dropdown),
|
||||
.form-field :deep(.p-autocomplete),
|
||||
.form-field :deep(.p-calendar) {
|
||||
width: 100% !important;
|
||||
}
|
||||
/* Dropdowns and inputs full width - styles in vendor/primevue-overrides.css */
|
||||
|
||||
/* Action buttons on mobile - not fixed, flow with content */
|
||||
.action-buttons-top {
|
||||
position: static;
|
||||
width: 100%;
|
||||
padding: 1rem;
|
||||
background: #f8fafc;
|
||||
border-top: 1px solid #e2e8f0;
|
||||
background: var(--surface-ground);
|
||||
border-top: 1px solid var(--surface-border);
|
||||
margin-top: 1rem;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
@@ -3006,28 +2962,28 @@ const submitForReview = async () => {
|
||||
}
|
||||
|
||||
.status-draft {
|
||||
background: #f1f5f9;
|
||||
color: #475569;
|
||||
background: var(--surface-100);
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.status-pending {
|
||||
background: #fef3c7;
|
||||
color: #92400e;
|
||||
background: var(--yellow-100);
|
||||
color: var(--yellow-800);
|
||||
}
|
||||
|
||||
.status-approved {
|
||||
background: #dcfce7;
|
||||
color: #166534;
|
||||
background: var(--green-100);
|
||||
color: var(--green-800);
|
||||
}
|
||||
|
||||
.status-rejected {
|
||||
background: #fee2e2;
|
||||
color: #991b1b;
|
||||
background: var(--red-100);
|
||||
color: var(--red-800);
|
||||
}
|
||||
|
||||
.status-synced {
|
||||
background: #dbeafe;
|
||||
color: #1e40af;
|
||||
background: var(--blue-100);
|
||||
color: var(--blue-700);
|
||||
}
|
||||
|
||||
/* Rejection Alert */
|
||||
@@ -3035,14 +2991,14 @@ const submitForReview = async () => {
|
||||
display: flex;
|
||||
gap: 1rem;
|
||||
padding: 1rem;
|
||||
background: #fff3e0;
|
||||
background: var(--orange-100);
|
||||
border-radius: 8px;
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
.rejection-alert i {
|
||||
font-size: 1.5rem;
|
||||
color: #f57c00;
|
||||
color: var(--orange-500);
|
||||
}
|
||||
|
||||
.rejection-alert p {
|
||||
@@ -3064,8 +3020,8 @@ const submitForReview = async () => {
|
||||
border-radius: 8px;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
border: 1px solid #e2e8f0;
|
||||
background: #f8fafc;
|
||||
border: 1px solid var(--surface-border);
|
||||
background: var(--surface-ground);
|
||||
}
|
||||
|
||||
.attachment-image {
|
||||
@@ -3085,12 +3041,12 @@ const submitForReview = async () => {
|
||||
|
||||
.pdf-attachment i {
|
||||
font-size: 2.5rem;
|
||||
color: #dc2626;
|
||||
color: var(--red-600);
|
||||
}
|
||||
|
||||
.pdf-attachment span {
|
||||
font-size: 0.85rem;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
text-align: center;
|
||||
word-break: break-word;
|
||||
}
|
||||
@@ -3122,8 +3078,8 @@ const submitForReview = async () => {
|
||||
position: relative;
|
||||
border-radius: 8px;
|
||||
overflow: hidden;
|
||||
border: 1px solid #e2e8f0;
|
||||
background: #f8fafc;
|
||||
border: 1px solid var(--surface-border);
|
||||
background: var(--surface-ground);
|
||||
}
|
||||
|
||||
.image-preview-item img {
|
||||
@@ -3141,8 +3097,8 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 0.5rem;
|
||||
background: #f1f5f9;
|
||||
color: #94a3b8;
|
||||
background: var(--surface-hover);
|
||||
color: var(--text-color-secondary);
|
||||
font-size: 0.75rem;
|
||||
text-align: center;
|
||||
padding: 0.5rem;
|
||||
@@ -3160,7 +3116,7 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 2rem;
|
||||
color: #94a3b8;
|
||||
color: var(--text-color-secondary);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
@@ -3177,7 +3133,7 @@ const submitForReview = async () => {
|
||||
.entries-section {
|
||||
margin-top: 1.5rem;
|
||||
padding: 1rem;
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
@@ -3186,7 +3142,7 @@ const submitForReview = async () => {
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
margin: 0 0 1rem 0;
|
||||
color: #334155;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.entries-table-container {
|
||||
@@ -3203,25 +3159,25 @@ const submitForReview = async () => {
|
||||
.entries-table td {
|
||||
padding: 0.75rem;
|
||||
text-align: left;
|
||||
border-bottom: 1px solid #e2e8f0;
|
||||
border-bottom: 1px solid var(--surface-border);
|
||||
}
|
||||
|
||||
.entries-table th {
|
||||
background: #f1f5f9;
|
||||
background: var(--surface-hover);
|
||||
font-weight: 600;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.entries-table tbody tr:hover {
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
}
|
||||
|
||||
.entries-table .debit {
|
||||
color: #dc2626;
|
||||
color: var(--red-600);
|
||||
}
|
||||
|
||||
.entries-table .credit {
|
||||
color: #16a34a;
|
||||
color: var(--green-600);
|
||||
}
|
||||
|
||||
.entries-table tfoot td {
|
||||
@@ -3235,9 +3191,9 @@ const submitForReview = async () => {
|
||||
gap: 0.5rem;
|
||||
margin-top: 1rem;
|
||||
padding: 0.75rem;
|
||||
background: #fff3e0;
|
||||
background: var(--orange-100);
|
||||
border-radius: 8px;
|
||||
color: #f57c00;
|
||||
color: var(--orange-500);
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
@@ -436,11 +436,12 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, computed, onMounted, onUnmounted } from 'vue'
|
||||
import { ref, computed, onMounted, onUnmounted, watch } from 'vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { useToast } from 'primevue/usetoast'
|
||||
import { useConfirm } from 'primevue/useconfirm'
|
||||
import { useReceiptsStore } from '@data-entry/stores/receiptsStore'
|
||||
import { useCompanyStore } from '@data-entry/stores/sharedStores'
|
||||
import Menu from 'primevue/menu'
|
||||
import Dialog from 'primevue/dialog'
|
||||
import Textarea from 'primevue/textarea'
|
||||
@@ -450,6 +451,7 @@ const router = useRouter()
|
||||
const toast = useToast()
|
||||
const confirm = useConfirm()
|
||||
const store = useReceiptsStore()
|
||||
const companyStore = useCompanyStore()
|
||||
|
||||
// Rejection dialog state
|
||||
const rejectDialogVisible = ref(false)
|
||||
@@ -477,6 +479,29 @@ onUnmounted(() => {
|
||||
window.removeEventListener('resize', handleResize)
|
||||
})
|
||||
|
||||
// Watch for company changes and reload data
|
||||
watch(
|
||||
() => companyStore.selectedCompany,
|
||||
async (newCompany, oldCompany) => {
|
||||
// Skip initial load (handled by onMounted) and same company
|
||||
if (!oldCompany || !newCompany) return
|
||||
if (newCompany.id_firma === oldCompany.id_firma) return
|
||||
|
||||
console.log('[ReceiptsList] Company changed, reloading data...')
|
||||
// Reset filters and pagination when company changes
|
||||
filters.value = {
|
||||
status: null,
|
||||
search: '',
|
||||
direction: null,
|
||||
dateFrom: null,
|
||||
dateTo: null,
|
||||
}
|
||||
store.clearFilters()
|
||||
await store.fetchStats()
|
||||
await store.fetchReceipts()
|
||||
}
|
||||
)
|
||||
|
||||
// Mobile context menu
|
||||
const menuRef = ref()
|
||||
const selectedReceipt = ref(null)
|
||||
@@ -966,7 +991,7 @@ const approveSelected = async () => {
|
||||
padding: 0.25rem 0.5rem;
|
||||
border-radius: 4px;
|
||||
font-size: 0.8rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
cursor: pointer;
|
||||
transition: all 0.15s ease;
|
||||
white-space: nowrap;
|
||||
@@ -974,12 +999,12 @@ const approveSelected = async () => {
|
||||
}
|
||||
|
||||
.status-chip:hover {
|
||||
background: #f1f5f9;
|
||||
background: var(--surface-hover);
|
||||
}
|
||||
|
||||
.status-chip.active {
|
||||
background: #e2e8f0;
|
||||
color: #1e293b;
|
||||
background: var(--surface-200);
|
||||
color: var(--text-color);
|
||||
font-weight: 600;
|
||||
position: relative;
|
||||
}
|
||||
@@ -991,22 +1016,22 @@ const approveSelected = async () => {
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 3px;
|
||||
background: #1e293b;
|
||||
background: var(--text-color);
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
/* Color accents for active status */
|
||||
.status-chip.status-draft.active { background: #dbeafe; color: #1d4ed8; }
|
||||
.status-chip.status-draft.active::after { background: #1d4ed8; }
|
||||
.status-chip.status-draft.active { background: var(--blue-100); color: var(--blue-700); }
|
||||
.status-chip.status-draft.active::after { background: var(--blue-700); }
|
||||
|
||||
.status-chip.status-pending.active { background: #fef3c7; color: #b45309; }
|
||||
.status-chip.status-pending.active::after { background: #d97706; }
|
||||
.status-chip.status-pending.active { background: var(--yellow-100); color: var(--yellow-700); }
|
||||
.status-chip.status-pending.active::after { background: var(--yellow-600); }
|
||||
|
||||
.status-chip.status-approved.active { background: #dcfce7; color: #15803d; }
|
||||
.status-chip.status-approved.active::after { background: #16a34a; }
|
||||
.status-chip.status-approved.active { background: var(--green-100); color: var(--green-700); }
|
||||
.status-chip.status-approved.active::after { background: var(--green-600); }
|
||||
|
||||
.status-chip.status-rejected.active { background: #fee2e2; color: #b91c1c; }
|
||||
.status-chip.status-rejected.active::after { background: #dc2626; }
|
||||
.status-chip.status-rejected.active { background: var(--red-100); color: var(--red-700); }
|
||||
.status-chip.status-rejected.active::after { background: var(--red-600); }
|
||||
|
||||
/* Search and Filters Row */
|
||||
.filters-row {
|
||||
@@ -1016,7 +1041,7 @@ const approveSelected = async () => {
|
||||
flex-wrap: wrap;
|
||||
margin-bottom: 0.75rem;
|
||||
padding-bottom: 0.75rem;
|
||||
border-bottom: 1px solid #e2e8f0;
|
||||
border-bottom: 1px solid var(--surface-border);
|
||||
}
|
||||
|
||||
.filter-search {
|
||||
@@ -1042,20 +1067,7 @@ const approveSelected = async () => {
|
||||
margin-left: auto;
|
||||
}
|
||||
|
||||
/* Compact DataTable */
|
||||
.compact-table :deep(.p-datatable-tbody > tr > td) {
|
||||
padding: 0.5rem 0.5rem;
|
||||
font-size: 0.875rem;
|
||||
}
|
||||
|
||||
.compact-table :deep(.p-datatable-thead > tr > th) {
|
||||
padding: 0.5rem 0.5rem;
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.compact-table :deep(.p-paginator) {
|
||||
padding: 0.5rem;
|
||||
}
|
||||
/* Compact DataTable - styles moved to vendor/primevue-overrides.css */
|
||||
|
||||
/* Action buttons - always on same line */
|
||||
.compact-table .button-group {
|
||||
@@ -1072,17 +1084,17 @@ const approveSelected = async () => {
|
||||
}
|
||||
|
||||
.receipt-card {
|
||||
background: white;
|
||||
background: var(--surface-card);
|
||||
border-radius: 8px;
|
||||
padding: 0.75rem;
|
||||
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
|
||||
box-shadow: var(--shadow-sm);
|
||||
cursor: pointer;
|
||||
border: 1px solid #e2e8f0;
|
||||
border: 1px solid var(--surface-border);
|
||||
transition: all 0.2s ease;
|
||||
}
|
||||
|
||||
.receipt-card:active {
|
||||
background: #f8fafc;
|
||||
background: var(--surface-ground);
|
||||
transform: scale(0.99);
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
|
||||
}
|
||||
@@ -1105,7 +1117,7 @@ const approveSelected = async () => {
|
||||
.card-row-1 .partner {
|
||||
font-weight: 600;
|
||||
font-size: 0.875rem;
|
||||
color: #1e293b;
|
||||
color: var(--text-color);
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
@@ -1113,7 +1125,7 @@ const approveSelected = async () => {
|
||||
|
||||
.card-row-1 .cui {
|
||||
font-size: 0.7rem;
|
||||
color: #94a3b8;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.card-row-1 .amount-block {
|
||||
@@ -1126,21 +1138,21 @@ const approveSelected = async () => {
|
||||
.card-row-1 .amount {
|
||||
font-weight: 700;
|
||||
font-size: 0.875rem;
|
||||
color: #0f172a;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.card-row-1 .amount-detail {
|
||||
font-size: 0.875rem;
|
||||
font-weight: 400;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
.card-row-1 .amount-detail.tva {
|
||||
color: #16a34a;
|
||||
color: var(--green-600);
|
||||
}
|
||||
|
||||
.card-row-1 .amount-detail.payment {
|
||||
color: #7c3aed;
|
||||
color: var(--purple-600);
|
||||
}
|
||||
|
||||
.card-row-2 {
|
||||
@@ -1148,12 +1160,12 @@ const approveSelected = async () => {
|
||||
align-items: center;
|
||||
gap: 0.375rem;
|
||||
font-size: 0.75rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.card-row-2 .sep {
|
||||
color: #cbd5e1;
|
||||
color: var(--surface-border);
|
||||
}
|
||||
|
||||
.card-row-2 .receipt-nr {
|
||||
@@ -1161,12 +1173,12 @@ const approveSelected = async () => {
|
||||
}
|
||||
|
||||
.card-row-2 .direction-out {
|
||||
color: #dc2626;
|
||||
color: var(--red-600);
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.card-row-2 .direction-in {
|
||||
color: #16a34a;
|
||||
color: var(--green-600);
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
@@ -1175,12 +1187,12 @@ const approveSelected = async () => {
|
||||
align-items: center;
|
||||
gap: 0.375rem;
|
||||
font-size: 0.7rem;
|
||||
color: #94a3b8;
|
||||
color: var(--text-color-secondary);
|
||||
margin-top: 0.25rem;
|
||||
}
|
||||
|
||||
.card-row-3 .sep {
|
||||
color: #cbd5e1;
|
||||
color: var(--surface-border);
|
||||
}
|
||||
|
||||
.card-row-3 .created-by {
|
||||
@@ -1192,7 +1204,7 @@ const approveSelected = async () => {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.125rem;
|
||||
color: #64748b;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Small status badge for mobile cards */
|
||||
@@ -1204,18 +1216,18 @@ const approveSelected = async () => {
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.status-badge-small.status-draft { background-color: #e3f2fd; color: #1976d2; }
|
||||
.status-badge-small.status-pending { background-color: #fff3e0; color: #f57c00; }
|
||||
.status-badge-small.status-approved { background-color: #e8f5e9; color: #388e3c; }
|
||||
.status-badge-small.status-rejected { background-color: #ffebee; color: #d32f2f; }
|
||||
.status-badge-small.status-synced { background-color: #e0f2f1; color: #00796b; }
|
||||
.status-badge-small.status-draft { background-color: var(--blue-100); color: var(--blue-600); }
|
||||
.status-badge-small.status-pending { background-color: var(--orange-100); color: var(--orange-600); }
|
||||
.status-badge-small.status-approved { background-color: var(--green-100); color: var(--green-600); }
|
||||
.status-badge-small.status-rejected { background-color: var(--red-100); color: var(--red-600); }
|
||||
.status-badge-small.status-synced { background-color: var(--teal-100); color: var(--teal-600); }
|
||||
|
||||
/* Status text colors for mobile */
|
||||
.status-text-draft { color: #1976d2; }
|
||||
.status-text-pending_review { color: #f57c00; }
|
||||
.status-text-approved { color: #388e3c; }
|
||||
.status-text-rejected { color: #d32f2f; }
|
||||
.status-text-synced { color: #00796b; }
|
||||
.status-text-draft { color: var(--blue-600); }
|
||||
.status-text-pending_review { color: var(--orange-600); }
|
||||
.status-text-approved { color: var(--green-600); }
|
||||
.status-text-rejected { color: var(--red-600); }
|
||||
.status-text-synced { color: var(--teal-600); }
|
||||
|
||||
/* Mobile Pagination */
|
||||
.mobile-pagination {
|
||||
@@ -1230,7 +1242,7 @@ const approveSelected = async () => {
|
||||
.page-info {
|
||||
font-size: 0.875rem;
|
||||
font-weight: 500;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
min-width: 60px;
|
||||
text-align: center;
|
||||
}
|
||||
@@ -1349,18 +1361,15 @@ const approveSelected = async () => {
|
||||
|
||||
.reject-dialog-content p {
|
||||
margin: 0;
|
||||
color: #475569;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Text muted helper */
|
||||
.text-muted {
|
||||
color: #94a3b8;
|
||||
color: var(--text-color-secondary);
|
||||
}
|
||||
|
||||
/* Compact table adjustments for more columns */
|
||||
.compact-table :deep(.p-datatable-wrapper) {
|
||||
overflow-x: auto;
|
||||
}
|
||||
/* Compact table adjustments - styles moved to vendor/primevue-overrides.css */
|
||||
|
||||
/* Bulk Actions Bar */
|
||||
.bulk-actions-bar {
|
||||
@@ -1368,8 +1377,8 @@ const approveSelected = async () => {
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 0.75rem 1rem;
|
||||
background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
|
||||
border: 1px solid #bfdbfe;
|
||||
background: linear-gradient(135deg, var(--blue-50) 0%, var(--blue-100) 100%);
|
||||
border: 1px solid var(--blue-200);
|
||||
border-radius: 6px;
|
||||
margin-bottom: 0.75rem;
|
||||
}
|
||||
@@ -1379,7 +1388,7 @@ const approveSelected = async () => {
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
font-weight: 600;
|
||||
color: #1e40af;
|
||||
color: var(--blue-700);
|
||||
}
|
||||
|
||||
.selection-info i {
|
||||
|
||||
Reference in New Issue
Block a user