@ruixinkeji/prism-ui 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/README.md +141 -0
  2. package/components/PrismAIAssist/PrismAIAssist.vue +98 -0
  3. package/components/PrismAddressInput/PrismAddressInput.vue +597 -0
  4. package/components/PrismCityCascadeSelect/PrismCityCascadeSelect.vue +793 -0
  5. package/components/PrismCityPicker/PrismCityPicker.vue +1008 -0
  6. package/components/PrismCitySelect/PrismCitySelect.vue +435 -0
  7. package/components/PrismCode/PrismCode.vue +749 -0
  8. package/components/PrismCodeInput/PrismCodeInput.vue +156 -0
  9. package/components/PrismDateTimePicker/PrismDateTimePicker.vue +953 -0
  10. package/components/PrismDropdown/PrismDropdown.vue +77 -0
  11. package/components/PrismGroupSticky/PrismGroupSticky.vue +352 -0
  12. package/components/PrismIdCardInput/PrismIdCardInput.vue +253 -0
  13. package/components/PrismImagePicker/PrismImagePicker.vue +457 -0
  14. package/components/PrismIndexBar/PrismIndexBar.vue +243 -0
  15. package/components/PrismLicensePlateInput/PrismLicensePlateInput.vue +1100 -0
  16. package/components/PrismMusicPlayer/PrismMusicPlayer.vue +530 -0
  17. package/components/PrismNavBar/PrismNavBar.vue +199 -0
  18. package/components/PrismSecureInput/PrismSecureInput.vue +360 -0
  19. package/components/PrismSticky/PrismSticky.vue +173 -0
  20. package/components/PrismSwiper/PrismSwiper.vue +339 -0
  21. package/components/PrismSwitch/PrismSwitch.vue +202 -0
  22. package/components/PrismTabBar/PrismTabBar.vue +147 -0
  23. package/components/PrismTabs/PrismTabs.vue +49 -0
  24. package/components/PrismVoiceInput/PrismVoiceInput.vue +529 -0
  25. package/index.d.ts +24 -0
  26. package/index.esm.js +25 -0
  27. package/index.js +25 -0
  28. package/package.json +89 -0
  29. package/styles/base.scss +227 -0
  30. package/styles/button.scss +120 -0
  31. package/styles/card.scss +306 -0
  32. package/styles/colors.scss +877 -0
  33. package/styles/data.scss +1229 -0
  34. package/styles/effects.scss +407 -0
  35. package/styles/feedback.scss +698 -0
  36. package/styles/form.scss +1574 -0
  37. package/styles/index.scss +46 -0
  38. package/styles/list.scss +184 -0
  39. package/styles/navigation.scss +554 -0
  40. package/styles/overlay.scss +182 -0
  41. package/styles/utilities.scss +134 -0
  42. package/styles/variables.scss +138 -0
  43. package/theme/blue.scss +36 -0
  44. package/theme/cyan.scss +32 -0
  45. package/theme/green.scss +32 -0
  46. package/theme/orange.scss +32 -0
  47. package/theme/purple.scss +32 -0
  48. package/theme/red.scss +32 -0
@@ -0,0 +1,1229 @@
1
+ /**
2
+ * Prism UI - 数据展示组件样式
3
+ * 统计卡片、徽章、头像、进度条等
4
+ */
5
+
6
+ /* ============================================================
7
+ 数据统计卡片
8
+ ============================================================ */
9
+
10
+ /* 统计卡片网格 */
11
+ .prism-stats-grid {
12
+ display: grid;
13
+ grid-template-columns: repeat(2, 1fr);
14
+ gap: 16rpx;
15
+ }
16
+
17
+ /* 统计卡片 */
18
+ .prism-stat-card {
19
+ padding: 20rpx;
20
+ position: relative;
21
+
22
+ &:active {
23
+ opacity: 0.9;
24
+ }
25
+
26
+ .stat-icon {
27
+ position: absolute;
28
+ right: 12rpx;
29
+ bottom: 12rpx;
30
+ width: 56rpx;
31
+ height: 56rpx;
32
+ border-radius: 14rpx;
33
+ }
34
+
35
+ .stat-info {
36
+ margin-bottom: 4rpx;
37
+ }
38
+
39
+ .stat-value {
40
+ display: block;
41
+ font-size: 36rpx;
42
+ font-weight: 700;
43
+ color: var(--prism-text-primary, #1D2129);
44
+ line-height: 1.2;
45
+
46
+ .dark-mode & {
47
+ color: var(--prism-text-primary, #E5E6EB);
48
+ }
49
+ }
50
+
51
+ .stat-label {
52
+ display: block;
53
+ font-size: 22rpx;
54
+ color: var(--prism-text-secondary, #86909C);
55
+ margin-top: 4rpx;
56
+ }
57
+
58
+ .stat-trend {
59
+ position: absolute;
60
+ top: 12rpx;
61
+ right: 12rpx;
62
+ display: flex;
63
+ align-items: center;
64
+ font-size: 20rpx;
65
+ gap: 6rpx;
66
+
67
+ &.up {
68
+ color: var(--prism-success-color, #00B42A);
69
+ }
70
+
71
+ &.down {
72
+ color: var(--prism-danger-color, #F53F3F);
73
+ }
74
+
75
+ .fa, .fa-solid {
76
+ font-size: 18rpx;
77
+ }
78
+ }
79
+ }
80
+
81
+
82
+ /* ============================================================
83
+ 徽章组件
84
+ ============================================================ */
85
+
86
+ /* 红点徽章 */
87
+ .prism-badge {
88
+ position: absolute;
89
+ width: 16rpx;
90
+ height: 16rpx;
91
+ padding: 0;
92
+ background: var(--prism-danger-color, #ff4d4f);
93
+ border-radius: 50%;
94
+ border: 2rpx solid #fff;
95
+ box-sizing: border-box;
96
+ top: 8rpx;
97
+ right: 8rpx;
98
+
99
+ &.top-left {
100
+ top: 8rpx;
101
+ left: 8rpx;
102
+ right: auto;
103
+ }
104
+
105
+ &.bottom-right {
106
+ top: auto;
107
+ bottom: 8rpx;
108
+ right: 8rpx;
109
+ }
110
+ }
111
+
112
+ /* 数字徽章 */
113
+ .prism-number-badge {
114
+ position: absolute;
115
+ min-width: 32rpx;
116
+ height: 32rpx;
117
+ background: var(--prism-danger-color, #F53F3F);
118
+ border-radius: 16rpx;
119
+ font-size: 20rpx;
120
+ color: #fff;
121
+ display: flex !important;
122
+ align-items: center !important;
123
+ justify-content: center !important;
124
+ padding: 0 8rpx;
125
+ padding-bottom: 2rpx;
126
+ line-height: 1;
127
+ text-align: center;
128
+ box-sizing: border-box;
129
+ top: -4rpx;
130
+ right: -4rpx;
131
+
132
+ &.top-left {
133
+ top: -4rpx;
134
+ left: -4rpx;
135
+ right: auto;
136
+ }
137
+
138
+ &.bottom-right {
139
+ top: auto;
140
+ bottom: -4rpx;
141
+ right: -4rpx;
142
+ }
143
+ }
144
+
145
+ /* ============================================================
146
+ 头像组件
147
+ ============================================================ */
148
+
149
+ .prism-avatar {
150
+ position: relative;
151
+ display: inline-flex;
152
+ align-items: center;
153
+ justify-content: center;
154
+ border-radius: 50%;
155
+ flex-shrink: 0;
156
+
157
+ /* 默认尺寸 (md) */
158
+ width: 80rpx;
159
+ height: 80rpx;
160
+
161
+ /* 默认背景色(仅用于图片头像和图标头像) */
162
+ &:not(.blue):not(.green):not(.orange):not(.purple):not(.red):not(.cyan):not(.pink):not(.indigo) {
163
+ background: var(--prism-bg-color, #F7F8FA);
164
+ }
165
+
166
+ .avatar-img,
167
+ .avatar-image {
168
+ width: 100%;
169
+ height: 100%;
170
+ object-fit: cover;
171
+ object-position: top;
172
+ border-radius: inherit;
173
+ }
174
+
175
+ .avatar-icon {
176
+ font-size: 40rpx;
177
+ color: var(--prism-text-placeholder, #C9CDD4);
178
+ }
179
+
180
+ .avatar-text {
181
+ font-size: 32rpx;
182
+ font-weight: 500;
183
+ color: #FFFFFF;
184
+ line-height: 1;
185
+ user-select: none;
186
+ }
187
+
188
+ /* 尺寸修饰符 */
189
+ &.xs {
190
+ width: 48rpx;
191
+ height: 48rpx;
192
+ .avatar-icon { font-size: 24rpx; }
193
+ .avatar-text { font-size: 20rpx; }
194
+ }
195
+
196
+ &.sm {
197
+ width: 64rpx;
198
+ height: 64rpx;
199
+ .avatar-icon { font-size: 32rpx; }
200
+ .avatar-text { font-size: 26rpx; }
201
+ }
202
+
203
+ &.md {
204
+ width: 80rpx;
205
+ height: 80rpx;
206
+ .avatar-icon { font-size: 40rpx; }
207
+ .avatar-text { font-size: 32rpx; }
208
+ }
209
+
210
+ &.lg {
211
+ width: 96rpx;
212
+ height: 96rpx;
213
+ .avatar-icon { font-size: 48rpx; }
214
+ .avatar-text { font-size: 40rpx; }
215
+ }
216
+
217
+ &.xl {
218
+ width: 128rpx;
219
+ height: 128rpx;
220
+ .avatar-icon { font-size: 64rpx; }
221
+ .avatar-text { font-size: 52rpx; }
222
+ }
223
+
224
+ /* 方形头像 */
225
+ &.square {
226
+ border-radius: 12rpx;
227
+ }
228
+
229
+ /* 带边框 */
230
+ &.bordered {
231
+ border: 4rpx solid #FFFFFF;
232
+ box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.1);
233
+ }
234
+
235
+ /* 文字头像颜色修饰符 */
236
+ &.blue {
237
+ background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
238
+ }
239
+
240
+ &.green {
241
+ background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
242
+ }
243
+
244
+ &.orange {
245
+ background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
246
+ }
247
+
248
+ &.purple {
249
+ background: linear-gradient(135deg, #a18cd1 0%, #fbc2eb 100%);
250
+ }
251
+
252
+ &.red {
253
+ background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
254
+ }
255
+
256
+ &.cyan {
257
+ background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
258
+ }
259
+
260
+ &.pink {
261
+ background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
262
+ }
263
+
264
+ &.indigo {
265
+ background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
266
+ }
267
+
268
+ /* 在线状态指示器 - 圆点形式 */
269
+ .avatar-status {
270
+ position: absolute;
271
+ bottom: -2rpx;
272
+ right: -2rpx;
273
+ width: 24rpx;
274
+ height: 24rpx;
275
+ border-radius: 50%;
276
+ border: 3rpx solid var(--prism-bg-color-card, #FFFFFF);
277
+
278
+ &.online {
279
+ background: var(--prism-success-color, #00B42A);
280
+ }
281
+
282
+ &.offline {
283
+ background: var(--prism-text-disabled, #C9CDD4);
284
+ }
285
+
286
+ &.busy {
287
+ background: var(--prism-warning-color, #FF7D00);
288
+ }
289
+ }
290
+
291
+ .dark-mode & {
292
+ // 只有没有颜色修饰符的头像才使用深色背景
293
+ &:not(.blue):not(.green):not(.orange):not(.purple):not(.red):not(.cyan):not(.pink):not(.indigo) {
294
+ background: var(--prism-bg-color-card, #242424);
295
+ }
296
+
297
+ .avatar-icon {
298
+ color: var(--prism-text-secondary, #86909C);
299
+ }
300
+
301
+ &.bordered {
302
+ border-color: #FFFFFF;
303
+ box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.3);
304
+ }
305
+
306
+ .avatar-status {
307
+ border-color: var(--prism-bg-color-card, #242424);
308
+ }
309
+ }
310
+ }
311
+
312
+ /* 头像组 */
313
+ .prism-avatar-group {
314
+ display: flex;
315
+ align-items: center;
316
+
317
+ .prism-avatar {
318
+ margin-left: -24rpx;
319
+ border: 3rpx solid var(--prism-bg-color-card, #FFFFFF);
320
+
321
+ &:first-child {
322
+ margin-left: 0;
323
+ }
324
+ }
325
+
326
+ .avatar-more {
327
+ width: 64rpx;
328
+ height: 64rpx;
329
+ border-radius: 50%;
330
+ background: rgba(247, 248, 250, 0.75);
331
+ display: flex;
332
+ align-items: center;
333
+ justify-content: center;
334
+ font-size: 22rpx;
335
+ color: var(--prism-text-secondary, #86909C);
336
+ margin-left: -24rpx;
337
+ border: 3rpx solid var(--prism-bg-color-card, #FFFFFF);
338
+ box-shadow: 0 2rpx 8rpx rgba(0, 0, 0, 0.1);
339
+ z-index: 100;
340
+ }
341
+
342
+ .dark-mode & {
343
+ .prism-avatar {
344
+ border-color: #FFFFFF;
345
+ }
346
+
347
+ .avatar-more {
348
+ background: rgba(255, 255, 255, 0.75);
349
+ border-color: #FFFFFF;
350
+ color: var(--prism-primary-color, #3478F6);
351
+ }
352
+ }
353
+ }
354
+
355
+ /* ============================================================
356
+ 进度条
357
+ ============================================================ */
358
+
359
+ .prism-progress {
360
+ width: 100%;
361
+ height: 12rpx;
362
+ background: var(--prism-bg-color, #F7F8FA);
363
+ border-radius: 6rpx;
364
+ overflow: hidden;
365
+
366
+ .progress-bar {
367
+ height: 100%;
368
+ background: var(--prism-primary-color, #3478F6);
369
+ border-radius: 6rpx;
370
+ transition: width 0.3s ease;
371
+ }
372
+
373
+ &--success .progress-bar {
374
+ background: var(--prism-success-color, #00B42A);
375
+ }
376
+
377
+ &--warning .progress-bar {
378
+ background: var(--prism-warning-color, #FF7D00);
379
+ }
380
+
381
+ &--danger .progress-bar {
382
+ background: var(--prism-danger-color, #F53F3F);
383
+ }
384
+
385
+ &--lg {
386
+ height: 20rpx;
387
+ border-radius: 10rpx;
388
+
389
+ .progress-bar {
390
+ border-radius: 10rpx;
391
+ }
392
+ }
393
+
394
+ .dark-mode & {
395
+ background: rgba(255, 255, 255, 0.1);
396
+ }
397
+ }
398
+
399
+ /* ============================================================
400
+ 图片组件
401
+ ============================================================ */
402
+
403
+ .prism-img {
404
+ display: block;
405
+ object-fit: cover;
406
+
407
+ /* 尺寸修饰符 */
408
+ &.img-xs { width: 48rpx; height: 48rpx; }
409
+ &.img-sm { width: 64rpx; height: 64rpx; }
410
+ &.img-md { width: 96rpx; height: 96rpx; }
411
+ &.img-lg { width: 128rpx; height: 128rpx; }
412
+ &.img-xl { width: 160rpx; height: 160rpx; }
413
+
414
+ /* 圆角修饰符 */
415
+ &.img-rounded { border-radius: 8rpx; }
416
+ &.img-rounded-md { border-radius: 12rpx; }
417
+ &.img-rounded-lg { border-radius: 16rpx; }
418
+ &.img-circle { border-radius: 50%; }
419
+ }
420
+
421
+ /* ============================================================
422
+ 空状态占位
423
+ ============================================================ */
424
+
425
+ .prism-placeholder {
426
+ display: flex;
427
+ flex-direction: column;
428
+ align-items: center;
429
+ justify-content: center;
430
+ padding: 100rpx 0;
431
+
432
+ .placeholder-icon {
433
+ font-size: 80rpx;
434
+ color: var(--prism-text-placeholder, #C9CDD4);
435
+ margin-bottom: 24rpx;
436
+ }
437
+
438
+ .placeholder-text {
439
+ font-size: 28rpx;
440
+ color: var(--prism-text-placeholder, #999);
441
+ }
442
+
443
+ .placeholder-action {
444
+ margin-top: 32rpx;
445
+ }
446
+ }
447
+
448
+ /* ============================================================
449
+ Skeleton 骨架屏
450
+ ============================================================ */
451
+
452
+ .prism-skeleton {
453
+ &__item {
454
+ background: linear-gradient(90deg,
455
+ var(--prism-bg-color, #F7F8FA) 25%,
456
+ #E8E8E8 50%,
457
+ var(--prism-bg-color, #F7F8FA) 75%
458
+ );
459
+ background-size: 400% 100%;
460
+ animation: prism-skeleton-loading 1.5s ease infinite;
461
+ border-radius: 8rpx;
462
+ }
463
+
464
+ &__avatar {
465
+ width: 80rpx;
466
+ height: 80rpx;
467
+ border-radius: 50%;
468
+ }
469
+
470
+ &__title {
471
+ height: 32rpx;
472
+ width: 40%;
473
+ margin-bottom: 24rpx;
474
+ }
475
+
476
+ &__text {
477
+ height: 28rpx;
478
+ margin-bottom: 16rpx;
479
+
480
+ &:last-child {
481
+ width: 60%;
482
+ }
483
+ }
484
+
485
+ &__image {
486
+ width: 100%;
487
+ height: 200rpx;
488
+ border-radius: 12rpx;
489
+ }
490
+
491
+ .dark-mode & {
492
+ &__item {
493
+ background: linear-gradient(90deg,
494
+ rgba(255, 255, 255, 0.06) 25%,
495
+ rgba(255, 255, 255, 0.12) 50%,
496
+ rgba(255, 255, 255, 0.06) 75%
497
+ );
498
+ background-size: 400% 100%;
499
+ }
500
+ }
501
+ }
502
+
503
+ @keyframes prism-skeleton-loading {
504
+ 0% { background-position: 100% 50%; }
505
+ 100% { background-position: 0 50%; }
506
+ }
507
+
508
+ /* ============================================================
509
+ NoticeBar 通知栏
510
+ ============================================================ */
511
+
512
+ .prism-notice {
513
+ display: flex;
514
+ align-items: center;
515
+ padding: 16rpx 24rpx;
516
+ background: #FFFBE6;
517
+ font-size: 26rpx;
518
+ color: #FAAD14;
519
+ overflow: hidden;
520
+ border-radius: 12rpx;
521
+
522
+ &__icon {
523
+ font-size: 28rpx;
524
+ margin-right: 12rpx;
525
+ flex-shrink: 0;
526
+ }
527
+
528
+ &__content {
529
+ flex: 1;
530
+ overflow: hidden;
531
+ }
532
+
533
+ &__text {
534
+ white-space: nowrap;
535
+
536
+ &--scroll {
537
+ display: inline-block;
538
+ animation: prism-notice-scroll 10s linear infinite;
539
+ }
540
+ }
541
+
542
+ &__close {
543
+ font-size: 24rpx;
544
+ margin-left: 12rpx;
545
+ flex-shrink: 0;
546
+ padding: 8rpx;
547
+ }
548
+ }
549
+
550
+ // 原子化颜色修饰类
551
+ .info.prism-notice {
552
+ background: #E6F7FF;
553
+ color: #1890FF;
554
+ }
555
+
556
+ .success.prism-notice {
557
+ background: #F6FFED;
558
+ color: #52C41A;
559
+ }
560
+
561
+ .error.prism-notice {
562
+ background: #FFF2F0;
563
+ color: #FF4D4F;
564
+ }
565
+
566
+ // 深色模式 - 原子化方式
567
+ .dark-mode .prism-notice {
568
+ background: rgba(250, 173, 20, 0.15);
569
+ }
570
+
571
+ .dark-mode .info.prism-notice {
572
+ background: rgba(24, 144, 255, 0.15);
573
+ }
574
+
575
+ .dark-mode .success.prism-notice {
576
+ background: rgba(82, 196, 26, 0.15);
577
+ }
578
+
579
+ .dark-mode .error.prism-notice {
580
+ background: rgba(255, 77, 79, 0.15);
581
+ }
582
+
583
+ @keyframes prism-notice-scroll {
584
+ 0% { transform: translateX(100%); }
585
+ 100% { transform: translateX(-100%); }
586
+ }
587
+
588
+ /* ============================================================
589
+ Collapse 折叠面板
590
+ ============================================================ */
591
+
592
+ .prism-collapse {
593
+ background: var(--prism-bg-color-card, #fff);
594
+ border-radius: 12rpx;
595
+ overflow: hidden;
596
+
597
+ .dark-mode & {
598
+ background: var(--prism-bg-color-card, #242424);
599
+ }
600
+ }
601
+
602
+ .prism-collapse-item {
603
+ border-bottom: 1rpx solid var(--prism-border-color-light, #F2F3F5);
604
+
605
+ &:last-child {
606
+ border-bottom: none;
607
+ }
608
+
609
+ .dark-mode & {
610
+ border-bottom-color: rgba(255, 255, 255, 0.08);
611
+ }
612
+ }
613
+
614
+ .prism-collapse-item__header {
615
+ display: flex;
616
+ align-items: center;
617
+ justify-content: space-between;
618
+ padding: 24rpx 32rpx;
619
+ font-size: 28rpx;
620
+ color: var(--prism-text-primary, #1D2129);
621
+ transition: all 0.3s ease;
622
+
623
+ &:active {
624
+ background: var(--prism-bg-color, #F7F8FA);
625
+ }
626
+
627
+ .dark-mode & {
628
+ color: var(--prism-text-primary, #E5E6EB);
629
+
630
+ &:active {
631
+ background: rgba(255, 255, 255, 0.05);
632
+ }
633
+ }
634
+ }
635
+
636
+ .prism-collapse-item__arrow {
637
+ font-size: 24rpx;
638
+ color: var(--prism-text-placeholder, #C9CDD4);
639
+ transition: transform 0.3s ease;
640
+
641
+ &--active {
642
+ transform: rotate(180deg);
643
+ }
644
+ }
645
+
646
+ .prism-collapse-item__content {
647
+ max-height: 0;
648
+ overflow: hidden;
649
+ transition: max-height 0.3s ease;
650
+
651
+ &--show {
652
+ max-height: 1000rpx;
653
+ }
654
+ }
655
+
656
+ .prism-collapse-item__body {
657
+ padding: 0 32rpx 24rpx;
658
+ font-size: 26rpx;
659
+ color: var(--prism-text-secondary, #86909C);
660
+ line-height: 1.6;
661
+ }
662
+
663
+ /* ============================================================
664
+ CountDown 倒计时
665
+ ============================================================ */
666
+
667
+ .prism-countdown {
668
+ display: inline-flex;
669
+ align-items: center;
670
+ gap: 8rpx;
671
+ font-size: 28rpx;
672
+ color: var(--prism-text-primary, #1D2129);
673
+
674
+ .dark-mode & {
675
+ color: var(--prism-text-primary, #E5E6EB);
676
+ }
677
+ }
678
+
679
+ .prism-countdown__block {
680
+ min-width: 44rpx;
681
+ height: 44rpx;
682
+ background: var(--prism-primary-color, #3478F6);
683
+ border-radius: 8rpx;
684
+ display: flex;
685
+ align-items: center;
686
+ justify-content: center;
687
+ font-size: 26rpx;
688
+ font-weight: 600;
689
+ color: #fff;
690
+ }
691
+
692
+ .prism-countdown__colon {
693
+ font-weight: 600;
694
+ color: var(--prism-text-primary, #1D2129);
695
+
696
+ .dark-mode & {
697
+ color: var(--prism-text-primary, #E5E6EB);
698
+ }
699
+ }
700
+
701
+ /* ============================================================
702
+ Swiper 轮播图
703
+ ============================================================ */
704
+
705
+ .prism-swiper {
706
+ width: 100%;
707
+
708
+ &__container {
709
+ width: 100%;
710
+ }
711
+
712
+ &__item {
713
+ width: 100%;
714
+ height: 100%;
715
+ overflow: hidden;
716
+ }
717
+
718
+ &__image {
719
+ width: 100%;
720
+ height: 100%;
721
+ }
722
+
723
+ &__color {
724
+ width: 100%;
725
+ height: 100%;
726
+ display: flex;
727
+ align-items: center;
728
+ justify-content: center;
729
+ }
730
+
731
+ &__text {
732
+ color: #fff;
733
+ font-size: 32rpx;
734
+ font-weight: 500;
735
+ }
736
+ }
737
+
738
+ /* ============================================================
739
+ Milestone 里程碑
740
+ ============================================================ */
741
+
742
+ .prism-milestone {
743
+ padding: 24rpx 0;
744
+ }
745
+
746
+ .prism-milestone-item {
747
+ display: flex;
748
+ align-items: flex-start;
749
+ padding-bottom: 40rpx;
750
+ position: relative;
751
+
752
+ &::before {
753
+ content: '';
754
+ position: absolute;
755
+ left: 16rpx;
756
+ top: 32rpx;
757
+ bottom: 0;
758
+ width: 2rpx;
759
+ background: var(--prism-border-color-light, #E5E6EB);
760
+ }
761
+
762
+ &:last-child {
763
+ padding-bottom: 0;
764
+
765
+ &::before {
766
+ display: none;
767
+ }
768
+ }
769
+
770
+ .milestone-dot {
771
+ width: 32rpx;
772
+ height: 32rpx;
773
+ border-radius: 50%;
774
+ background: var(--prism-bg-color-container, #F7F8FA);
775
+ display: flex;
776
+ align-items: center;
777
+ justify-content: center;
778
+ flex-shrink: 0;
779
+ position: relative;
780
+ z-index: 1;
781
+ margin-top: 2rpx;
782
+
783
+ .fa {
784
+ font-size: 16rpx;
785
+ color: var(--prism-text-disabled, #C9CDD4);
786
+ }
787
+ }
788
+
789
+ .milestone-content {
790
+ flex: 1;
791
+ margin-left: 24rpx;
792
+ }
793
+
794
+ .milestone-title {
795
+ font-size: 30rpx;
796
+ font-weight: 600;
797
+ color: var(--prism-text-primary, #1D2129);
798
+ margin-bottom: 8rpx;
799
+ line-height: 1.2;
800
+ }
801
+
802
+ .milestone-time {
803
+ font-size: 24rpx;
804
+ color: var(--prism-text-secondary, #86909C);
805
+ margin-bottom: 12rpx;
806
+ }
807
+
808
+ .milestone-desc {
809
+ font-size: 26rpx;
810
+ color: var(--prism-text-secondary, #86909C);
811
+ line-height: 1.6;
812
+ }
813
+
814
+ // 已完成状态
815
+ &.completed {
816
+ .milestone-dot {
817
+ background: var(--prism-success-color, #00B42A);
818
+
819
+ .fa {
820
+ color: #FFFFFF;
821
+ }
822
+ }
823
+
824
+ &::before {
825
+ background: var(--prism-success-color, #00B42A);
826
+ }
827
+ }
828
+
829
+ // 激活状态
830
+ &.active {
831
+ .milestone-dot {
832
+ background: var(--prism-primary-color, #3478F6);
833
+ box-shadow: 0 0 0 8rpx rgba(52, 120, 246, 0.15);
834
+
835
+ .fa {
836
+ color: #FFFFFF;
837
+ }
838
+ }
839
+
840
+ .milestone-title {
841
+ color: var(--prism-primary-color, #3478F6);
842
+ }
843
+ }
844
+ }
845
+
846
+ .dark-mode {
847
+ .prism-milestone-item {
848
+ &::before {
849
+ background: var(--prism-border-color-base, #3A3A3A);
850
+ }
851
+
852
+ .milestone-dot {
853
+ background: var(--prism-bg-color-container, #2A2A2A);
854
+ }
855
+
856
+ .milestone-title {
857
+ color: var(--prism-text-primary, #E5E6EB);
858
+ }
859
+
860
+ &.completed {
861
+ .milestone-dot {
862
+ background: var(--prism-success-color, #00B42A);
863
+
864
+ .fa {
865
+ color: #FFFFFF;
866
+ }
867
+ }
868
+
869
+ &::before {
870
+ background: var(--prism-success-color, #00B42A);
871
+ }
872
+ }
873
+
874
+ &.active {
875
+ .milestone-dot {
876
+ background: var(--prism-primary-color, #3478F6);
877
+
878
+ .fa {
879
+ color: #FFFFFF;
880
+ }
881
+ }
882
+
883
+ .milestone-title {
884
+ color: var(--prism-primary-color, #3478F6);
885
+ }
886
+ }
887
+ }
888
+ }
889
+
890
+ /* ============================================================
891
+ Steps 快递进展
892
+ ============================================================ */
893
+
894
+ .prism-steps {
895
+ padding: 24rpx 0;
896
+ }
897
+
898
+ .prism-step-item {
899
+ position: relative;
900
+ padding-left: 36rpx;
901
+ padding-bottom: 36rpx;
902
+
903
+ &::before {
904
+ content: '';
905
+ position: absolute;
906
+ left: 8rpx;
907
+ top: 20rpx;
908
+ bottom: 0;
909
+ width: 1rpx;
910
+ background: var(--prism-border-color-light, #E5E6EB);
911
+ }
912
+
913
+ &:last-child {
914
+ padding-bottom: 0;
915
+
916
+ &::before {
917
+ display: none;
918
+ }
919
+ }
920
+
921
+ .step-dot {
922
+ position: absolute;
923
+ left: 0;
924
+ top: 4rpx;
925
+ width: 16rpx;
926
+ height: 16rpx;
927
+ border-radius: 50%;
928
+ background: var(--prism-border-color-light, #E5E6EB);
929
+ }
930
+
931
+ .step-content {
932
+ /* 内容自然流动 */
933
+ }
934
+
935
+ .step-title {
936
+ font-size: 28rpx;
937
+ font-weight: 400;
938
+ color: var(--prism-text-primary, #1D2129);
939
+ margin-bottom: 8rpx;
940
+ line-height: 1.5;
941
+ }
942
+
943
+ .step-time {
944
+ font-size: 22rpx;
945
+ color: var(--prism-text-placeholder, #C9CDD4);
946
+ margin-bottom: 8rpx;
947
+ }
948
+
949
+ .step-desc {
950
+ font-size: 24rpx;
951
+ color: var(--prism-text-secondary, #86909C);
952
+ line-height: 1.6;
953
+ }
954
+
955
+ // 已完成状态
956
+ &.completed {
957
+ .step-dot {
958
+ background: var(--prism-primary-color, #3478F6);
959
+ }
960
+
961
+ &::before {
962
+ background: var(--prism-primary-color, #3478F6);
963
+ }
964
+ }
965
+
966
+ // 激活状态(最新一条)
967
+ &.active {
968
+ .step-dot {
969
+ width: 24rpx;
970
+ height: 24rpx;
971
+ left: -4rpx;
972
+ top: 0;
973
+ background: var(--prism-success-color, #00B42A);
974
+ border: 4rpx solid rgba(0, 180, 42, 0.2);
975
+ box-sizing: border-box;
976
+ }
977
+
978
+ &::before {
979
+ left: 12rpx;
980
+ background: var(--prism-success-color, #00B42A);
981
+ }
982
+
983
+ .step-title {
984
+ font-weight: 600;
985
+ color: var(--prism-success-color, #00B42A);
986
+ }
987
+ }
988
+ }
989
+
990
+ .dark-mode {
991
+ .prism-step-item {
992
+ &::before {
993
+ background: var(--prism-border-color-base, #3A3A3A);
994
+ }
995
+
996
+ .step-dot {
997
+ background: var(--prism-border-color-base, #3A3A3A);
998
+ }
999
+
1000
+ .step-title {
1001
+ color: var(--prism-text-primary, #E5E6EB);
1002
+ }
1003
+
1004
+ &.completed {
1005
+ .step-dot {
1006
+ background: var(--prism-primary-color, #3478F6);
1007
+ }
1008
+
1009
+ &::before {
1010
+ background: var(--prism-primary-color, #3478F6);
1011
+ }
1012
+ }
1013
+
1014
+ &.active {
1015
+ .step-dot {
1016
+ background: var(--prism-success-color, #00B42A);
1017
+ border-color: rgba(0, 180, 42, 0.3);
1018
+ }
1019
+
1020
+ &::before {
1021
+ background: var(--prism-success-color, #00B42A);
1022
+ }
1023
+
1024
+ .step-title {
1025
+ color: var(--prism-success-color, #00B42A);
1026
+ }
1027
+ }
1028
+ }
1029
+ }
1030
+
1031
+ /* ============================================================
1032
+ 核心指标卡片
1033
+ ============================================================ */
1034
+
1035
+ /* 核心指标网格 */
1036
+ .prism-metric-grid {
1037
+ display: grid;
1038
+ grid-template-columns: repeat(2, 1fr);
1039
+ gap: 16rpx;
1040
+ }
1041
+
1042
+ /* 核心指标卡片 */
1043
+ .prism-metric-card {
1044
+ padding: 20rpx;
1045
+ display: flex;
1046
+ flex-direction: column;
1047
+ gap: 16rpx;
1048
+
1049
+ &:active {
1050
+ opacity: 0.9;
1051
+ }
1052
+
1053
+ .metric-header {
1054
+ display: flex;
1055
+ align-items: center;
1056
+ justify-content: space-between;
1057
+ }
1058
+
1059
+ .metric-icon-wrapper {
1060
+ width: 56rpx;
1061
+ height: 56rpx;
1062
+ border-radius: 14rpx;
1063
+ display: flex;
1064
+ align-items: center;
1065
+ justify-content: center;
1066
+ font-size: 28rpx;
1067
+
1068
+ /* 图标背景色 */
1069
+ &.icon-bg-sleep {
1070
+ background: rgba(124, 58, 237, 0.1);
1071
+ color: #7C3AED;
1072
+ }
1073
+ &.icon-bg-oxygen {
1074
+ background: rgba(16, 185, 129, 0.1);
1075
+ color: #10B981;
1076
+ }
1077
+ &.icon-bg-pressure {
1078
+ background: rgba(59, 130, 246, 0.1);
1079
+ color: #3B82F6;
1080
+ }
1081
+ &.icon-bg-heart {
1082
+ background: rgba(239, 68, 68, 0.1);
1083
+ color: #EF4444;
1084
+ }
1085
+ &.icon-bg-hrv {
1086
+ background: rgba(245, 158, 11, 0.1);
1087
+ color: #F59E0B;
1088
+ }
1089
+ &.icon-bg-temp {
1090
+ background: rgba(236, 72, 153, 0.1);
1091
+ color: #EC4899;
1092
+ }
1093
+ &.icon-bg-steps {
1094
+ background: rgba(6, 182, 212, 0.1);
1095
+ color: #06B6D4;
1096
+ }
1097
+ &.icon-bg-calories {
1098
+ background: rgba(249, 115, 22, 0.1);
1099
+ color: #F97316;
1100
+ }
1101
+ }
1102
+
1103
+ .metric-body {
1104
+ display: flex;
1105
+ flex-direction: column;
1106
+ align-items: flex-start;
1107
+ }
1108
+
1109
+ .metric-value {
1110
+ font-size: 40rpx;
1111
+ font-weight: 700;
1112
+ line-height: 1.2;
1113
+ display: flex;
1114
+ align-items: baseline;
1115
+ gap: 4rpx;
1116
+ color: var(--prism-text-primary, #1D2129);
1117
+
1118
+ &.text-success {
1119
+ color: var(--prism-success-color, #00B42A);
1120
+ }
1121
+ &.text-warning {
1122
+ color: var(--prism-warning-color, #FF7D00);
1123
+ }
1124
+ &.text-danger {
1125
+ color: var(--prism-danger-color, #F53F3F);
1126
+ }
1127
+ }
1128
+
1129
+ .metric-unit {
1130
+ font-size: 24rpx;
1131
+ font-weight: 500;
1132
+ color: var(--prism-text-secondary, #86909C);
1133
+ margin-left: 4rpx;
1134
+ }
1135
+
1136
+ .metric-label {
1137
+ font-size: 24rpx;
1138
+ color: var(--prism-text-secondary, #86909C);
1139
+ margin-top: 4rpx;
1140
+ }
1141
+
1142
+ /* uCharts 趋势图 */
1143
+ .metric-sparkline {
1144
+ width: 100%;
1145
+ height: 100rpx;
1146
+ margin-top: 12rpx;
1147
+ }
1148
+
1149
+ .trend-canvas {
1150
+ width: 100%;
1151
+ height: 100rpx;
1152
+ }
1153
+ }
1154
+
1155
+ /* 状态徽章 - 用于核心指标 */
1156
+ .prism-badge.success,
1157
+ .prism-badge.warning,
1158
+ .prism-badge.danger {
1159
+ position: static;
1160
+ width: auto;
1161
+ height: auto;
1162
+ padding: 6rpx 14rpx;
1163
+ border-radius: 16rpx;
1164
+ font-size: 22rpx;
1165
+ font-weight: 600;
1166
+ border: none;
1167
+ }
1168
+
1169
+ .success.prism-badge {
1170
+ background: linear-gradient(135deg, #10B981 0%, #34D399 100%);
1171
+ color: #FFFFFF;
1172
+ }
1173
+
1174
+ .warning.prism-badge {
1175
+ background: linear-gradient(135deg, #F59E0B 0%, #FCD34D 100%);
1176
+ color: #FFFFFF;
1177
+ }
1178
+
1179
+ .danger.prism-badge {
1180
+ background: linear-gradient(135deg, #EF4444 0%, #F87171 100%);
1181
+ color: #FFFFFF;
1182
+ }
1183
+
1184
+ /* 深色模式 */
1185
+ .dark-mode {
1186
+ .prism-metric-card {
1187
+ .metric-value {
1188
+ color: var(--prism-text-primary, #E5E6EB);
1189
+
1190
+ &.text-success {
1191
+ color: #34D399;
1192
+ }
1193
+ &.text-warning {
1194
+ color: #FBBF24;
1195
+ }
1196
+ &.text-danger {
1197
+ color: #F87171;
1198
+ }
1199
+ }
1200
+
1201
+ .metric-icon-wrapper {
1202
+ &.icon-bg-sleep {
1203
+ background: rgba(124, 58, 237, 0.2);
1204
+ }
1205
+ &.icon-bg-oxygen {
1206
+ background: rgba(16, 185, 129, 0.2);
1207
+ }
1208
+ &.icon-bg-pressure {
1209
+ background: rgba(59, 130, 246, 0.2);
1210
+ }
1211
+ &.icon-bg-heart {
1212
+ background: rgba(239, 68, 68, 0.2);
1213
+ }
1214
+ &.icon-bg-hrv {
1215
+ background: rgba(245, 158, 11, 0.2);
1216
+ }
1217
+ &.icon-bg-temp {
1218
+ background: rgba(236, 72, 153, 0.2);
1219
+ }
1220
+ &.icon-bg-steps {
1221
+ background: rgba(6, 182, 212, 0.2);
1222
+ }
1223
+ &.icon-bg-calories {
1224
+ background: rgba(249, 115, 22, 0.2);
1225
+ }
1226
+ }
1227
+ }
1228
+ }
1229
+