refactor: consolidate finance workflow modules

This commit is contained in:
caoxiaozhu
2026-06-23 11:21:18 +08:00
parent 1f40ce3df3
commit 73966b3a7b
52 changed files with 3468 additions and 2865 deletions

View File

@@ -475,42 +475,30 @@
top: calc(100% + 12px);
right: 0;
z-index: 60;
width: 380px;
width: 428px;
max-width: calc(100vw - 24px);
max-height: min(520px, calc(100vh - 96px));
max-height: min(560px, calc(100vh - 68px));
display: flex;
flex-direction: column;
gap: 0;
overflow: hidden;
border: 1px solid rgba(0, 0, 0, 0.06);
border-radius: 12px;
border: 1px solid #dbe4ef;
border-radius: 10px;
background: #ffffff;
box-shadow:
0 16px 36px rgba(0, 0, 0, 0.08),
0 4px 12px rgba(0, 0, 0, 0.03),
0 0 1px rgba(0, 0, 0, 0.1);
0 18px 42px rgba(15, 23, 42, 0.13),
0 4px 12px rgba(15, 23, 42, 0.06);
overscroll-behavior-y: contain;
}
.notification-popover::before {
content: "";
display: block;
height: 3px;
background: linear-gradient(
90deg,
var(--theme-primary-active) 0%,
var(--theme-primary-light-3, #7eb3d4) 100%
);
}
.notification-head {
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
padding: 12px 14px 10px;
border-bottom: 1px solid #edf2f7;
background: #fafbfd;
padding: 14px 16px 12px;
border-bottom: 1px solid #e6edf6;
background: #ffffff;
}
.notification-head-brand {
@@ -522,14 +510,14 @@
}
.notification-head-icon {
width: 32px;
height: 32px;
width: 34px;
height: 34px;
flex: 0 0 auto;
display: grid;
place-items: center;
border: 1px solid var(--theme-primary-light-6);
border: 1px solid #dbeafe;
border-radius: 4px;
background: #fff;
background: #f8fbff;
color: var(--theme-primary-active);
font-size: 17px;
}
@@ -561,22 +549,25 @@
}
.notification-clear-btn {
height: 28px;
height: 30px;
padding: 0 10px;
border: 0;
border: 1px solid transparent;
border-radius: 4px;
background: transparent;
color: var(--theme-primary-active);
color: #475569;
font-size: 12px;
font-weight: 750;
white-space: nowrap;
transition:
background 160ms var(--ease),
border-color 160ms var(--ease),
color 160ms var(--ease);
}
.notification-clear-btn:hover:not(:disabled) {
background: var(--theme-primary-light-9);
border-color: #bfdbfe;
background: #eff6ff;
color: var(--theme-primary-active);
}
.notification-clear-btn:disabled {
@@ -585,8 +576,8 @@
}
.notification-close-btn {
width: 28px;
height: 28px;
width: 30px;
height: 30px;
display: inline-grid;
place-items: center;
border: 0;
@@ -608,15 +599,15 @@
display: flex;
align-items: stretch;
gap: 0;
padding: 0 14px;
border-bottom: 1px solid #edf2f7;
background: #fff;
padding: 0 16px;
border-bottom: 1px solid #e6edf6;
background: #f8fafc;
}
.notification-tabs button {
position: relative;
flex: 1 1 0;
height: 38px;
height: 40px;
display: inline-flex;
align-items: center;
justify-content: center;
@@ -666,10 +657,10 @@
display: flex;
flex-direction: column;
min-height: 0;
max-height: min(336px, calc(100vh - 226px));
max-height: min(420px, calc(100vh - 166px));
overflow-x: hidden;
overflow-y: auto;
padding: 4px 0 12px;
padding: 10px 0 14px;
scrollbar-width: thin;
scrollbar-color: #cbd5e1 #f8fafc;
overscroll-behavior-y: contain;
@@ -691,179 +682,151 @@
.notification-row {
display: grid;
grid-template-columns: 34px minmax(0, 1fr) 16px;
align-items: center;
gap: 12px;
min-height: 68px;
padding: 12px 16px;
grid-template-columns: 52px minmax(0, 1fr);
align-items: start;
gap: 16px;
min-height: 104px;
padding: 20px 22px;
border: 0;
border-radius: 0;
background: #ffffff;
flex-shrink: 0;
cursor: pointer;
text-align: left;
transition:
background 180ms var(--ease),
border-color 180ms var(--ease);
transform 180ms var(--ease);
}
.notification-row + .notification-row {
border-top: 1px solid #f1f5f9;
border-top: 1px solid #f4f6fb;
}
.notification-row.unread {
background: #f8fafc;
position: relative;
}
.notification-row.unread::before {
content: '';
position: absolute;
left: 0;
top: 16px;
bottom: 16px;
width: 3px;
border-radius: 0 4px 4px 0;
background: var(--theme-primary-active);
background: #ffffff;
}
.notification-row:hover {
background: #f1f5f9;
background: #f8fafc;
}
.notification-row.unread:hover {
background: #f1f5f9;
background: #f8fafc;
}
.notification-type-icon {
width: 34px;
height: 34px;
.notification-avatar {
position: relative;
width: 52px;
height: 52px;
display: grid;
place-items: center;
border: 1px solid rgba(0,0,0,0.04);
border-radius: 8px;
background: #ffffff;
color: var(--theme-primary-active);
font-size: 16px;
box-shadow: 0 1.5px 4px rgba(0,0,0,0.03);
border: 1px solid #dbeafe;
border-radius: 999px;
background: #eff6ff;
color: #2563eb;
font-size: 18px;
font-weight: 800;
box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}
.notification-type-icon.danger {
.notification-avatar.danger {
border-color: #fecaca;
background: #fff5f5;
color: #dc2626;
background: #fff1f2;
color: #be123c;
}
.notification-type-icon.warning {
.notification-avatar.warning {
border-color: #fde68a;
background: #fffbeb;
color: #d97706;
color: #b45309;
}
.notification-type-icon.success {
.notification-avatar.success {
border-color: #bbf7d0;
background: #f0fdf4;
color: #16a34a;
color: #15803d;
}
.notification-type-icon.info {
.notification-avatar.info {
border-color: #bfdbfe;
background: #eff6ff;
color: #2563eb;
}
.notification-copy {
min-width: 0;
display: flex;
flex-direction: column;
gap: 4px;
padding-top: 1px;
padding-bottom: 1px;
.notification-avatar-label {
line-height: 1;
}
.notification-title-line {
min-width: 0;
display: flex;
align-items: center;
gap: 8px;
}
.notification-copy strong {
min-width: 0;
color: #0f172a;
font-size: 13.5px;
font-weight: 750;
line-height: 1.3;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.notification-title-line b {
flex: 0 0 auto;
.notification-avatar-badge {
position: absolute;
top: -2px;
right: -2px;
min-width: 18px;
height: 18px;
display: inline-flex;
align-items: center;
justify-content: center;
padding: 0 5px;
border-radius: 4px;
background: #dc2626;
color: #fff;
padding: 0 4px;
border: 2px solid #ffffff;
border-radius: 999px;
background: #ef4444;
color: #ffffff;
font-size: 10px;
font-weight: 800;
line-height: 1;
}
.notification-copy small {
color: #64748b;
font-size: 12px;
line-height: 1.4;
.notification-row-content {
min-width: 0;
display: grid;
gap: 8px;
padding-top: 2px;
}
.notification-row-top {
min-width: 0;
display: flex;
align-items: flex-start;
justify-content: space-between;
gap: 14px;
}
.notification-row-title {
min-width: 0;
color: #111827;
font-size: 15px;
font-weight: 800;
line-height: 1.25;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.notification-row.unread .notification-row-title {
color: #0f172a;
}
.notification-preview {
max-width: 100%;
color: #8a94a6;
font-size: 13.5px;
line-height: 1.55;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
text-overflow: ellipsis;
margin-bottom: 2px;
}
.notification-meta {
min-width: 0;
display: flex;
align-items: center;
justify-content: flex-end;
gap: 8px;
margin-top: 2px;
}
.notification-meta em,
.notification-meta time {
min-width: 0;
overflow: hidden;
color: #94a3b8;
font-size: 11px;
font-style: normal;
font-weight: 600;
text-overflow: ellipsis;
white-space: nowrap;
}
.notification-meta em {
display: none;
}
.notification-meta time {
.notification-time {
flex: 0 0 auto;
}
.notification-row-arrow {
color: #cbd5e1;
font-size: 18px;
transition: color 160ms var(--ease), transform 160ms var(--ease);
}
.notification-row:hover .notification-row-arrow {
color: var(--theme-primary-active);
transform: translateX(2px);
color: #b4bcc8;
font-size: 13px;
font-style: normal;
font-weight: 700;
font-variant-numeric: tabular-nums;
line-height: 1.3;
white-space: nowrap;
}
.notification-empty {
@@ -1573,7 +1536,24 @@
}
.notification-row {
padding: 9px 12px;
grid-template-columns: 44px minmax(0, 1fr);
gap: 12px;
min-height: 90px;
padding: 16px 14px;
}
.notification-avatar {
width: 44px;
height: 44px;
font-size: 16px;
}
.notification-row-top {
gap: 8px;
}
.notification-time {
font-size: 12px;
}
.company-switcher {
@@ -1641,7 +1621,7 @@
}
.notification-head-icon,
.notification-type-icon {
.notification-avatar {
width: 30px;
height: 30px;
}
@@ -1653,10 +1633,26 @@
.notification-row {
grid-template-columns: 30px minmax(0, 1fr);
gap: 8px;
min-height: 82px;
padding: 13px 10px;
}
.notification-row-arrow {
display: none;
.notification-avatar {
font-size: 13px;
}
.notification-avatar-badge {
min-width: 16px;
height: 16px;
font-size: 9px;
}
.notification-row-title {
font-size: 13.5px;
}
.notification-preview {
font-size: 12.5px;
}
.topbar.detail-mode {