615 lines
10 KiB
CSS
615 lines
10 KiB
CSS
/* Notification */
|
|
.notification {
|
|
position: absolute;
|
|
top: 70px;
|
|
right: 20px;
|
|
background-color: white;
|
|
width: 250px;
|
|
border-radius: 8px;
|
|
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
|
|
padding: 15px;
|
|
border-left: 4px solid #ff5e3a;
|
|
z-index: 1000;
|
|
display: none;
|
|
|
|
[dir="rtl"] & {
|
|
left: 20px;
|
|
border-right: 4px solid #ff5e3a;
|
|
right: unset;
|
|
border-left: unset;
|
|
}
|
|
}
|
|
|
|
.notification-title {
|
|
font-weight: bold;
|
|
font-size: 14px;
|
|
margin-bottom: 5px;
|
|
color: #2d3748;
|
|
}
|
|
|
|
.notification-message {
|
|
font-size: 12px;
|
|
color: #718096;
|
|
}
|
|
|
|
/* Notification banner */
|
|
.notification-banner {
|
|
position: fixed;
|
|
top: 20px;
|
|
right: 20px;
|
|
padding: 15px 20px;
|
|
background-color: white;
|
|
border-radius: 8px;
|
|
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
max-width: 400px;
|
|
z-index: 2000;
|
|
transform: translateY(-100px);
|
|
opacity: 0;
|
|
transition:
|
|
transform 0.3s,
|
|
opacity 0.3s;
|
|
}
|
|
|
|
.notification-banner.active {
|
|
transform: translateY(0);
|
|
opacity: 1;
|
|
}
|
|
|
|
.notification-banner.success {
|
|
border-left: 4px solid #48bb78;
|
|
}
|
|
|
|
.notification-banner.error {
|
|
border-left: 4px solid #f56565;
|
|
}
|
|
|
|
.close-notification-btn {
|
|
background: none;
|
|
border: none;
|
|
font-size: 18px;
|
|
cursor: pointer;
|
|
color: #a0aec0;
|
|
margin-left: 10px;
|
|
}
|
|
|
|
/* Notification Bell */
|
|
.notif-wrapper {
|
|
position: relative;
|
|
}
|
|
|
|
.notif-bell-btn {
|
|
background: none;
|
|
border: none;
|
|
cursor: pointer;
|
|
font-size: 18px;
|
|
color: #64748b;
|
|
width: 40px;
|
|
height: 40px;
|
|
border-radius: 50%;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
transition: all 0.2s ease;
|
|
position: relative;
|
|
}
|
|
|
|
.notif-bell-btn:hover {
|
|
background: rgba(255, 94, 58, 0.08);
|
|
color: #ff5e3a;
|
|
}
|
|
|
|
.notif-bell-btn.active {
|
|
color: #ff5e3a;
|
|
background: rgba(255, 94, 58, 0.1);
|
|
}
|
|
|
|
.notif-badge {
|
|
position: absolute;
|
|
top: 4px;
|
|
right: 4px;
|
|
min-width: 16px;
|
|
height: 16px;
|
|
line-height: 16px;
|
|
border-radius: 8px;
|
|
background: #ff3b30;
|
|
color: #fff;
|
|
font-size: 10px;
|
|
font-weight: 700;
|
|
text-align: center;
|
|
padding: 0 4px;
|
|
pointer-events: none;
|
|
}
|
|
|
|
@keyframes bellRing {
|
|
0%,
|
|
100% {
|
|
transform: rotate(0deg);
|
|
}
|
|
13% {
|
|
transform: rotate(22deg);
|
|
}
|
|
26% {
|
|
transform: rotate(-22deg);
|
|
}
|
|
39% {
|
|
transform: rotate(14deg);
|
|
}
|
|
52% {
|
|
transform: rotate(-14deg);
|
|
}
|
|
65% {
|
|
transform: rotate(8deg);
|
|
}
|
|
78% {
|
|
transform: rotate(-8deg);
|
|
}
|
|
91% {
|
|
transform: rotate(3deg);
|
|
}
|
|
}
|
|
|
|
.notif-bell-btn.ring {
|
|
animation: bellRing 1s ease;
|
|
}
|
|
|
|
.notif-panel {
|
|
display: none;
|
|
position: absolute;
|
|
top: calc(100% + 10px);
|
|
right: -40px;
|
|
width: 380px;
|
|
max-height: 480px;
|
|
background: #fff;
|
|
border-radius: 16px;
|
|
box-shadow:
|
|
0 12px 40px rgba(0, 0, 0, 0.15),
|
|
0 0 0 1px rgba(0, 0, 0, 0.05);
|
|
z-index: 2000;
|
|
overflow: hidden;
|
|
animation: notifPanelIn 0.2s ease-out;
|
|
}
|
|
|
|
.notif-wrapper.open .notif-panel {
|
|
display: flex;
|
|
flex-direction: column;
|
|
}
|
|
|
|
@keyframes notifPanelIn {
|
|
from {
|
|
opacity: 0;
|
|
transform: translateY(-8px) scale(0.97);
|
|
}
|
|
to {
|
|
opacity: 1;
|
|
transform: translateY(0) scale(1);
|
|
}
|
|
}
|
|
|
|
.notif-panel-header {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
padding: 14px 16px;
|
|
border-bottom: 1px solid #f0f0f0;
|
|
}
|
|
|
|
.notif-panel-title {
|
|
font-weight: 600;
|
|
font-size: 15px;
|
|
color: #1e293b;
|
|
}
|
|
|
|
.notif-clear-btn {
|
|
background: none;
|
|
border: none;
|
|
cursor: pointer;
|
|
color: #94a3b8;
|
|
font-size: 14px;
|
|
padding: 4px 8px;
|
|
border-radius: 6px;
|
|
transition: all 0.15s;
|
|
}
|
|
|
|
.notif-clear-btn:hover {
|
|
color: #ff5e3a;
|
|
background: rgba(255, 94, 58, 0.08);
|
|
}
|
|
|
|
.notif-panel-body {
|
|
flex: 1;
|
|
overflow-y: auto;
|
|
max-height: 400px;
|
|
}
|
|
|
|
.notif-empty {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 40px 20px;
|
|
color: #94a3b8;
|
|
gap: 8px;
|
|
}
|
|
|
|
.notif-empty i {
|
|
font-size: 28px;
|
|
opacity: 0.5;
|
|
}
|
|
|
|
.notif-empty span {
|
|
font-size: 14px;
|
|
}
|
|
|
|
.notif-item {
|
|
display: flex;
|
|
align-items: flex-start;
|
|
padding: 12px 16px;
|
|
gap: 12px;
|
|
border-bottom: 1px solid #f5f5f5;
|
|
transition: background 0.15s;
|
|
cursor: default;
|
|
}
|
|
|
|
.notif-item:last-child {
|
|
border-bottom: none;
|
|
}
|
|
|
|
.notif-item:hover {
|
|
background: #f8fafc;
|
|
}
|
|
|
|
.notif-item-icon {
|
|
width: 32px;
|
|
height: 32px;
|
|
border-radius: 8px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
flex-shrink: 0;
|
|
font-size: 14px;
|
|
}
|
|
|
|
.notif-item-icon.upload {
|
|
background: rgba(255, 94, 58, 0.1);
|
|
color: #ff5e3a;
|
|
}
|
|
|
|
.notif-item-icon.success {
|
|
background: rgba(52, 199, 89, 0.1);
|
|
color: #34c759;
|
|
}
|
|
|
|
.notif-item-icon.error {
|
|
background: rgba(255, 59, 48, 0.1);
|
|
color: #ff3b30;
|
|
}
|
|
|
|
.notif-item-body {
|
|
flex: 1;
|
|
min-width: 0;
|
|
}
|
|
|
|
.notif-item-title {
|
|
font-size: 13px;
|
|
font-weight: 600;
|
|
color: #1e293b;
|
|
margin-bottom: 2px;
|
|
}
|
|
|
|
.notif-item-text {
|
|
font-size: 12px;
|
|
color: #64748b;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
}
|
|
|
|
.notif-item-time {
|
|
font-size: 11px;
|
|
color: #94a3b8;
|
|
margin-top: 3px;
|
|
}
|
|
|
|
.notif-upload-progress {
|
|
margin-top: 6px;
|
|
}
|
|
|
|
.notif-upload-bar {
|
|
height: 3px;
|
|
background: #eee;
|
|
border-radius: 2px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.notif-upload-fill {
|
|
height: 100%;
|
|
background: #ff5e3a;
|
|
width: 0%;
|
|
transition: width 0.2s ease;
|
|
border-radius: 2px;
|
|
}
|
|
|
|
.notif-upload-fill.done {
|
|
background: #34c759;
|
|
}
|
|
|
|
.notif-upload-fill.error {
|
|
background: #ff3b30;
|
|
}
|
|
|
|
.notif-upload-detail {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
margin-top: 3px;
|
|
}
|
|
|
|
.notif-upload-pct,
|
|
.notif-upload-stats {
|
|
font-size: 11px;
|
|
color: #94a3b8;
|
|
}
|
|
|
|
/* Upload Progress Toast (legacy — hidden, kept for compat) */
|
|
.upload-toast {
|
|
position: fixed;
|
|
bottom: 24px;
|
|
right: 24px;
|
|
width: 360px;
|
|
max-height: 400px;
|
|
background: #fff;
|
|
border-radius: 12px;
|
|
box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
|
|
z-index: 10000;
|
|
display: none;
|
|
flex-direction: column;
|
|
overflow: hidden;
|
|
font-family: inherit;
|
|
animation: uploadToastSlideIn 0.3s ease-out;
|
|
}
|
|
|
|
.upload-toast.visible {
|
|
display: flex;
|
|
}
|
|
|
|
@keyframes uploadToastSlideIn {
|
|
from {
|
|
transform: translateY(20px);
|
|
opacity: 0;
|
|
}
|
|
to {
|
|
transform: translateY(0);
|
|
opacity: 1;
|
|
}
|
|
}
|
|
|
|
.upload-toast-header {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
padding: 12px 16px;
|
|
background: #ff5e3a;
|
|
color: #fff;
|
|
}
|
|
|
|
.upload-toast-title {
|
|
font-weight: 600;
|
|
font-size: 14px;
|
|
}
|
|
|
|
.upload-toast-close {
|
|
background: none;
|
|
border: none;
|
|
color: #fff;
|
|
font-size: 20px;
|
|
cursor: pointer;
|
|
line-height: 1;
|
|
padding: 0 4px;
|
|
opacity: 0.8;
|
|
}
|
|
|
|
.upload-toast-close:hover {
|
|
opacity: 1;
|
|
}
|
|
|
|
.upload-toast-body {
|
|
flex: 1;
|
|
overflow-y: auto;
|
|
padding: 8px 0;
|
|
max-height: 260px;
|
|
}
|
|
|
|
.upload-toast-file {
|
|
display: flex;
|
|
align-items: center;
|
|
padding: 6px 16px;
|
|
gap: 10px;
|
|
}
|
|
|
|
.upload-toast-file-icon {
|
|
font-size: 16px;
|
|
color: #999;
|
|
flex-shrink: 0;
|
|
width: 20px;
|
|
text-align: center;
|
|
}
|
|
|
|
.upload-toast-file-icon.done {
|
|
color: #34c759;
|
|
}
|
|
|
|
.upload-toast-file-icon.error {
|
|
color: #ff3b30;
|
|
}
|
|
|
|
.upload-toast-file-info {
|
|
flex: 1;
|
|
min-width: 0;
|
|
}
|
|
|
|
.upload-toast-file-name {
|
|
font-size: 13px;
|
|
color: #333;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
}
|
|
|
|
.upload-toast-file-bar {
|
|
height: 3px;
|
|
background: #eee;
|
|
border-radius: 2px;
|
|
margin-top: 4px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.upload-toast-file-fill {
|
|
height: 100%;
|
|
background: #ff5e3a;
|
|
width: 0%;
|
|
transition: width 0.2s ease;
|
|
border-radius: 2px;
|
|
}
|
|
|
|
.upload-toast-file-fill.done {
|
|
background: #34c759;
|
|
}
|
|
|
|
.upload-toast-file-fill.error {
|
|
background: #ff3b30;
|
|
}
|
|
|
|
.upload-toast-file-pct {
|
|
font-size: 12px;
|
|
color: #999;
|
|
flex-shrink: 0;
|
|
width: 38px;
|
|
text-align: right;
|
|
}
|
|
|
|
.upload-toast-footer {
|
|
padding: 10px 16px;
|
|
border-top: 1px solid #f0f0f0;
|
|
}
|
|
|
|
.upload-toast-overall-bar {
|
|
height: 4px;
|
|
background: #eee;
|
|
border-radius: 2px;
|
|
overflow: hidden;
|
|
margin-bottom: 6px;
|
|
}
|
|
|
|
.upload-toast-overall-fill {
|
|
height: 100%;
|
|
background: #ff5e3a;
|
|
width: 0%;
|
|
transition: width 0.25s ease;
|
|
border-radius: 2px;
|
|
}
|
|
|
|
.upload-toast-stats {
|
|
font-size: 12px;
|
|
color: #888;
|
|
}
|
|
|
|
[data-theme="dark"] .notification {
|
|
background-color: #1e293b;
|
|
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
|
|
}
|
|
|
|
[data-theme="dark"] .notification-title {
|
|
color: #f1f5f9;
|
|
}
|
|
|
|
[data-theme="dark"] .notification-message {
|
|
color: #94a3b8;
|
|
}
|
|
|
|
[data-theme="dark"] .notification-banner {
|
|
background-color: #1e293b;
|
|
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
|
|
}
|
|
|
|
[data-theme="dark"] .notif-bell-btn {
|
|
color: #94a3b8;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-bell-btn:hover,
|
|
[data-theme="dark"] .notif-bell-btn.active {
|
|
color: #ff5e3a;
|
|
background: rgba(255, 94, 58, 0.15);
|
|
}
|
|
|
|
[data-theme="dark"] .notif-panel {
|
|
background: #1e293b;
|
|
box-shadow:
|
|
0 12px 40px rgba(0, 0, 0, 0.4),
|
|
0 0 0 1px rgba(255, 255, 255, 0.06);
|
|
}
|
|
|
|
[data-theme="dark"] .notif-panel-header {
|
|
border-bottom-color: #334155;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-panel-title {
|
|
color: #f1f5f9;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-clear-btn {
|
|
color: #64748b;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-clear-btn:hover {
|
|
color: #ff5e3a;
|
|
background: rgba(255, 94, 58, 0.12);
|
|
}
|
|
|
|
[data-theme="dark"] .notif-empty {
|
|
color: #64748b;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-item {
|
|
border-bottom-color: #1a2536;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-item:hover {
|
|
background: #162032;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-item-title {
|
|
color: #e2e8f0;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-item-text {
|
|
color: #94a3b8;
|
|
}
|
|
|
|
[data-theme="dark"] .notif-upload-bar {
|
|
background: #334155;
|
|
}
|
|
|
|
[data-theme="dark"] .upload-toast {
|
|
background: #1e293b;
|
|
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
|
|
}
|
|
|
|
[data-theme="dark"] .upload-toast-file-name {
|
|
color: #e2e8f0;
|
|
}
|
|
|
|
[data-theme="dark"] .upload-toast-file-bar {
|
|
background: #334155;
|
|
}
|
|
|
|
[data-theme="dark"] .upload-toast-file-pct {
|
|
color: #64748b;
|
|
}
|
|
|
|
[data-theme="dark"] .upload-toast-footer {
|
|
border-top-color: #334155;
|
|
}
|