@oxmumu3/dsh-incidental-learn 0.1.7 → 0.2.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.
package/client.js CHANGED
@@ -14,6 +14,8 @@ window.__ModuleLoader__.load({
14
14
  const PANEL_KEY = 'incidental-learn'
15
15
  const COACH_TAB_ID = '@oxmumu3/dsh-incidental-learn/coach'
16
16
  const COACH_TAB_KIND = 'incidental-learn-coach'
17
+ const MAX_AUTO_TRIAGE = 8
18
+ const MAX_DIRECT_UNREAD = 3
17
19
 
18
20
  const SOURCES = ['dsh-chat', 'antigravity', 'codex', 'superagent-review', 'manual']
19
21
  const EPISTEMIC_STATES = ['verified', 'explicit', 'inferred']
@@ -479,6 +481,22 @@ function buildDeepLearnStarterPrompt(item) {
479
481
  ].filter(Boolean).join('\n')
480
482
  }
481
483
 
484
+ function buildSprintStarterPrompt(stations) {
485
+ const list = Array.isArray(stations) ? stations.filter(Boolean).slice(0, 3) : []
486
+ if (list.length === 0) return buildDeepLearnStarterPrompt({ title: '一本手账精选串联闯关', masteryTier: 1 })
487
+ if (list.length === 1) return buildDeepLearnStarterPrompt(list[0])
488
+ const lines = list.map((st, idx) => {
489
+ const label = cleanText(st.masteryLabel, 40) || MASTERY_LABELS[clampTier(st.masteryTier || 1)]
490
+ return `第 ${idx + 1} 站:${cleanText(st.title, 120)}(itemId: ${cleanText(st.itemId || st.id, 80) || 'ad-hoc'},当前 ${label})`
491
+ })
492
+ return [
493
+ '[顺带私教·专心闯关]',
494
+ `本次开启 ${list.length} 站串联考考我(共约 ${list.length * 5} 分钟),逐站按「先探后讲 + 换景追问」过关:`,
495
+ ...lines,
496
+ '请先从第 1 站开始,直接输出一个 ```learn-quiz JSON 代码块让我先盲选判断并停下等我回复,暂不要剧透完整解释;每过一站在调用 learn_checkpoint 后再进入下一站。',
497
+ ].join('\n')
498
+ }
499
+
482
500
  // Scoped CSS stylesheet for @oxmumu3/dsh-incidental-learn (`顺带私教`).
483
501
  // Strictly adheres to modern-web-guidance & DSH `--dsw-alias-*` conventions:
484
502
  // - color-scheme: light dark on plugin roots; never touches host :root or *
@@ -497,44 +515,49 @@ const ILP_STYLE_ID = 'dsh-incidental-learn-styles'
497
515
  const ILP_CSS = [
498
516
  // Shared semantic tokens scoped only to plugin roots
499
517
  '.ilp-wb,.ilp-fence,.ilp-drawer,.ilp-dialog,.ilp-pill,.ilp-tool{',
500
- ' --ilp-bg:var(--dsw-alias-bg-base,#f7f7f4);',
518
+ ' --ilp-bg:var(--dsw-alias-bg-base,#f7f6f2);',
501
519
  ' --ilp-panel:var(--dsw-alias-bg-layer-2,#ffffff);',
502
- ' --ilp-sub:var(--dsw-alias-bg-layer-1,#efeee9);',
503
- ' --ilp-ink:var(--dsw-alias-label-primary,#16181d);',
504
- ' --ilp-ink2:var(--dsw-alias-label-secondary,#434954);',
505
- ' --ilp-ink3:var(--dsw-alias-label-tertiary,#666d7a);',
520
+ ' --ilp-sub:var(--dsw-alias-bg-layer-1,#efece4);',
521
+ ' --ilp-ink:var(--dsw-alias-label-primary,#17191e);',
522
+ ' --ilp-ink2:var(--dsw-alias-label-secondary,#434955);',
523
+ ' --ilp-ink3:var(--dsw-alias-label-tertiary,#69707d);',
506
524
  ' --ilp-card-ink:color-mix(in oklab,var(--ilp-ink) 68%,var(--ilp-bg));',
507
525
  ' --ilp-card-muted:color-mix(in oklab,var(--ilp-ink) 61%,var(--ilp-bg));',
508
526
  ' --ilp-strip-surface:color-mix(in oklab,var(--ilp-sub) 44%,var(--ilp-panel));',
509
- ' --ilp-line:var(--dsw-alias-border-l2,rgba(22,24,29,.10));',
510
- ' --ilp-line2:var(--dsw-alias-border-l4,rgba(22,24,29,.19));',
511
- ' --ilp-hover:var(--dsw-alias-interactive-bg-hover,rgba(22,24,29,.05));',
512
- ' --ilp-pri:var(--dsw-alias-button-primary-fill,#16181d);',
527
+ ' --ilp-line:var(--dsw-alias-border-l2,rgba(23,25,30,.10));',
528
+ ' --ilp-line2:var(--dsw-alias-border-l4,rgba(23,25,30,.18));',
529
+ ' --ilp-hover:var(--dsw-alias-interactive-bg-hover,rgba(23,25,30,.05));',
530
+ ' --ilp-pri:var(--dsw-alias-button-primary-fill,#17191e);',
513
531
  ' --ilp-on-pri:var(--dsw-alias-label-primary-foreground,var(--dsw-alias-label-primary-inverted,#ffffff));',
514
- ' --ilp-run:var(--dsw-alias-link,#1d4ed8);',
532
+ ' --ilp-run:var(--dsw-alias-link,#3b5ccc);',
515
533
  ' --ilp-run-bg:color-mix(in srgb,var(--ilp-run) 11%,transparent);',
516
- ' --ilp-run-line:color-mix(in srgb,var(--ilp-run) 34%,var(--ilp-line));',
534
+ ' --ilp-run-soft:color-mix(in oklab,var(--ilp-run) 9%,var(--ilp-panel));',
535
+ ' --ilp-run-line:color-mix(in srgb,var(--ilp-run) 32%,var(--ilp-line));',
517
536
  ' --ilp-wait:var(--dsw-alias-state-warn-primary,#9a5b00);',
518
537
  ' --ilp-wait-bg:color-mix(in srgb,var(--ilp-wait) 11%,transparent);',
519
- ' --ilp-wait-line:color-mix(in srgb,var(--ilp-wait) 38%,var(--ilp-line));',
520
- ' --ilp-ok:var(--dsw-alias-state-success-primary,#136f42);',
538
+ ' --ilp-wait-soft:color-mix(in oklab,var(--ilp-wait) 8%,var(--ilp-panel));',
539
+ ' --ilp-wait-line:color-mix(in srgb,var(--ilp-wait) 36%,var(--ilp-line));',
540
+ ' --ilp-ok:var(--dsw-alias-state-success-primary,#146c43);',
521
541
  ' --ilp-ok-bg:color-mix(in srgb,var(--ilp-ok) 11%,transparent);',
522
- ' --ilp-ok-line:color-mix(in srgb,var(--ilp-ok) 36%,var(--ilp-line));',
523
- ' --ilp-bad:var(--dsw-alias-state-error-primary,#dc2626);',
524
- ' --ilp-bad-bg:color-mix(in srgb,var(--ilp-bad) 11%,transparent);',
542
+ ' --ilp-ok-soft:color-mix(in oklab,var(--ilp-ok) 9%,var(--ilp-panel));',
543
+ ' --ilp-ok-line:color-mix(in srgb,var(--ilp-ok) 34%,var(--ilp-line));',
544
+ ' --ilp-bad:var(--dsw-alias-state-error-primary,#b42318);',
545
+ ' --ilp-bad-bg:color-mix(in srgb,var(--ilp-bad) 10%,transparent);',
546
+ ' --ilp-bad-soft:color-mix(in oklab,var(--ilp-bad) 8%,var(--ilp-panel));',
547
+ ' --ilp-bad-line:color-mix(in srgb,var(--ilp-bad) 30%,var(--ilp-line));',
525
548
  ' --ilp-seg-empty:color-mix(in srgb,var(--ilp-ink) 14%,transparent);',
526
549
  ' --ilp-sans:var(--dsw-font-family,-apple-system,BlinkMacSystemFont,"PingFang SC","Helvetica Neue",sans-serif);',
527
550
  ' --ilp-serif:"Songti SC","STSong","Noto Serif CJK SC","Source Han Serif SC",Georgia,serif;',
528
551
  ' --ilp-mono:ui-monospace,"SF Mono",Menlo,Consolas,monospace;',
529
- ' --ilp-r-btn:var(--dsw-radius-sm,7px);',
552
+ ' --ilp-r-btn:var(--dsw-radius-sm,8px);',
530
553
  ' --ilp-r-sm:var(--dsw-radius-sm,8px);',
531
- ' --ilp-r-md:var(--dsw-radius-md,10px);',
532
- ' --ilp-r-lg:var(--dsw-radius-lg,14px);',
554
+ ' --ilp-r-md:var(--dsw-radius-md,12px);',
555
+ ' --ilp-r-lg:var(--dsw-radius-lg,16px);',
533
556
  ' color-scheme:light dark;',
534
557
  ' color:var(--ilp-ink);',
535
558
  ' font-family:var(--ilp-sans);',
536
559
  ' font-size:13.5px;',
537
- ' line-height:1.58;',
560
+ ' line-height:1.56;',
538
561
  ' -webkit-font-smoothing:antialiased;',
539
562
  '}',
540
563
 
@@ -549,10 +572,10 @@ const ILP_CSS = [
549
572
  '.ilp-wb :focus-visible,.ilp-fence :focus-visible,.ilp-drawer :focus-visible,.ilp-dialog :focus-visible,.ilp-pill:focus-visible{outline:2px solid var(--ilp-run);outline-offset:2px}',
550
573
  '@media (prefers-reduced-motion:reduce){:where(.ilp-wb,.ilp-fence,.ilp-drawer,.ilp-dialog) *{transition:none!important;animation:none!important}}',
551
574
 
552
- // Buttons & Badges
553
- '.ilp-btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-block-size:33px;padding:6px 14px;border-radius:var(--ilp-r-btn);font-size:12.5px;font-weight:500;line-height:1.25;white-space:nowrap;transition:opacity .12s}',
554
- '.ilp-btn.sm{min-block-size:28px;padding:4px 11px;font-size:12px}',
555
- '.ilp-btn.xs{min-block-size:24px;padding:3px 9px;font-size:11.5px}',
575
+ // Buttons & Badges (two-class / container-scoped so zero-specificity reset never strips padding)
576
+ '.ilp-wb .ilp-btn,.ilp-dialog .ilp-btn,.ilp-fence .ilp-btn,.ilp-drawer .ilp-btn,.ilp-btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-block-size:34px;padding:7px 14px;border-radius:var(--ilp-r-btn);font-size:12.5px;font-weight:500;line-height:1.25;white-space:nowrap;transition:background-color .12s,border-color .12s,opacity .12s}',
577
+ '.ilp-wb .ilp-btn.sm,.ilp-dialog .ilp-btn.sm,.ilp-fence .ilp-btn.sm,.ilp-drawer .ilp-btn.sm,.ilp-btn.sm{min-block-size:30px;padding:5px 11px;font-size:12px}',
578
+ '.ilp-wb .ilp-btn.xs,.ilp-dialog .ilp-btn.xs,.ilp-fence .ilp-btn.xs,.ilp-drawer .ilp-btn.xs,.ilp-btn.xs{min-block-size:25px;padding:3px 9px;font-size:11.5px}',
556
579
  '.ilp-btn.solid{background:var(--ilp-pri);color:var(--ilp-on-pri);border:1px solid var(--ilp-pri);font-weight:600}',
557
580
  '.ilp-btn.solid:hover:not(:disabled){opacity:.89}',
558
581
  '.ilp-btn.line{border:1px solid var(--ilp-line2);background:var(--ilp-panel);color:var(--ilp-ink)}',
@@ -561,6 +584,10 @@ const ILP_CSS = [
561
584
  '.ilp-btn.soft:hover:not(:disabled){background:var(--ilp-hover);color:var(--ilp-ink)}',
562
585
  '.ilp-btn.ghost{color:var(--ilp-ink2)}',
563
586
  '.ilp-btn.ghost:hover:not(:disabled){background:var(--ilp-hover);color:var(--ilp-ink)}',
587
+ '.ilp-btn.danger-text{color:var(--ilp-bad)}',
588
+ '.ilp-btn.danger-text:hover:not(:disabled){background:var(--ilp-bad-bg);color:var(--ilp-bad)}',
589
+ '.ilp-btn.indigo-line{background:var(--ilp-run-bg);border:1px solid var(--ilp-run-line);color:var(--ilp-run);font-weight:600}',
590
+ '.ilp-btn.indigo-line:hover:not(:disabled){opacity:.88}',
564
591
  '.ilp-btn:disabled{opacity:.44;cursor:not-allowed}',
565
592
 
566
593
  '.ilp-tag{display:inline-flex;align-items:center;gap:4px;height:21px;padding:0 8px;border-radius:5px;font-size:11px;font-weight:600;line-height:1;white-space:nowrap;border:1px solid var(--ilp-line);background:var(--ilp-sub);color:var(--ilp-ink2)}',
@@ -569,49 +596,63 @@ const ILP_CSS = [
569
596
  '.ilp-tag.wait{background:var(--ilp-wait-bg);border-color:var(--ilp-wait-line);color:var(--ilp-wait)}',
570
597
  '.ilp-tag.outline{background:transparent;border:1px solid var(--ilp-line);color:var(--ilp-ink3)}',
571
598
 
572
- // 4-segment behavioral mastery meter
599
+ // 4-segment behavioral mastery meter (supports both tier 0 unread and tiers 1..4)
573
600
  '.ilp-meter{display:inline-flex;align-items:center;gap:7px;flex-wrap:wrap}',
574
601
  '.ilp-bars{display:inline-flex;align-items:center;gap:3px}',
575
- '.ilp-bars span{width:13px;height:6px;border-radius:2px;background:var(--ilp-seg-empty)}',
602
+ '.ilp-bars span{width:12px;height:5px;border-radius:999px;background:var(--ilp-seg-empty)}',
576
603
  '.ilp-scene .ilp-bars{gap:2.5px}',
577
- '.ilp-scene .ilp-bars span{width:10px;height:5px}',
578
- '.ilp-meter[data-tier="1"] .ilp-bars span:nth-child(-n+1){background:var(--ilp-wait)}',
604
+ '.ilp-scene .ilp-bars span{width:9px;height:4px}',
605
+ '.ilp-meter[data-tier="1"] .ilp-bars span:nth-child(-n+1){background:var(--ilp-run)}',
579
606
  '.ilp-meter[data-tier="2"] .ilp-bars span:nth-child(-n+2){background:var(--ilp-run)}',
580
607
  '.ilp-meter[data-tier="3"] .ilp-bars span:nth-child(-n+3){background:var(--ilp-ok)}',
581
608
  '.ilp-meter[data-tier="4"] .ilp-bars span:nth-child(-n+4){background:var(--ilp-ok)}',
582
- '.ilp-meter-label{font-size:11.5px;font-weight:500;color:var(--ilp-ink2)}',
583
- '.ilp-scene .ilp-meter-label{font-size:10px}',
584
- '.ilp-meter[data-tier="1"] .ilp-meter-label{color:var(--ilp-wait)}',
585
- '.ilp-meter[data-tier="2"] .ilp-meter-label{color:var(--ilp-run)}',
609
+ '.ilp-meter-label{font-size:11.5px;font-weight:600;font-variant-numeric:tabular-nums;color:var(--ilp-ink2)}',
610
+ '.ilp-scene .ilp-meter-label{font-size:9.5px}',
611
+ '.ilp-meter[data-tier="0"] .ilp-meter-label{color:var(--ilp-wait)}',
612
+ '.ilp-meter[data-tier="1"] .ilp-meter-label,.ilp-meter[data-tier="2"] .ilp-meter-label{color:var(--ilp-run)}',
586
613
  '.ilp-meter[data-tier="3"] .ilp-meter-label,.ilp-meter[data-tier="4"] .ilp-meter-label{color:var(--ilp-ok)}',
587
614
 
588
615
  // Main Workbench container (scrolls inside flex layout, NEVER position:absolute inset:0)
589
- '.ilp-wb{flex:1 1 0;height:100%;min-height:0;min-width:0;width:100%;overflow-y:auto;overflow-x:hidden;background:var(--ilp-bg);container-type:inline-size;container-name:ilpwb}',
590
- '.ilp-wb-inner{max-width:920px;width:100%;margin:0 auto;padding:24px 28px 64px;display:flex;flex-direction:column;gap:20px;min-width:0}',
591
- '.ilp-header{display:flex;flex-direction:column;gap:5px;min-width:0}',
616
+ '.ilp-wb{flex:1 1 0;height:100%;min-height:0;min-width:0;width:100%;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;scrollbar-gutter:stable;background:var(--ilp-bg);container-type:inline-size;container-name:ilpwb}',
617
+ '.ilp-wb-inner{max-width:920px;width:100%;margin:0 auto;padding:24px 28px 68px;display:flex;flex-direction:column;gap:18px;min-width:0}',
618
+ '.ilp-header{display:flex;flex-direction:column;gap:4px;min-width:0}',
592
619
  '.ilp-toprow{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 14px;min-height:26px;min-width:0}',
593
- '.ilp-eyebrow{font-size:11px;font-weight:600;letter-spacing:.04em;color:var(--ilp-ink3)}',
594
- '.ilp-title-row{display:flex;align-items:baseline;justify-content:flex-start;flex-wrap:wrap;gap:8px 14px;min-width:0}',
595
- '.ilp-h1{font:600 24px/1.28 var(--ilp-sans);letter-spacing:-.02em;color:var(--ilp-ink)}',
596
- '.ilp-summary{font-size:12.5px;color:var(--ilp-ink3)}',
620
+ '.ilp-eyebrow{font-size:11.5px;font-weight:600;letter-spacing:.03em;color:var(--ilp-ink3)}',
621
+ '.ilp-title-row{display:flex;align-items:baseline;justify-content:flex-start;flex-wrap:wrap;gap:6px 14px;min-width:0}',
622
+ '.ilp-h1{font:700 24px/1.24 var(--ilp-sans);letter-spacing:-.02em;color:var(--ilp-ink)}',
623
+ '.ilp-summary{font-size:12.5px;color:var(--ilp-ink2);font-variant-numeric:tabular-nums}',
597
624
  '.ilp-header-acts{display:flex;align-items:center;flex-wrap:wrap;gap:6px}',
598
625
  '.ilp-preview-banner{border-radius:var(--ilp-r-md);border:1px solid var(--ilp-wait-line);background:var(--ilp-wait-bg);padding:9px 14px;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px 12px;font-size:12.5px;color:var(--ilp-ink)}',
599
626
 
600
- // Welcome v5 Guide Shell (unboxed on 0/0 empty, softly boxed when reopened on non-empty)
601
- '.ilp-guide-stack{display:flex;flex-direction:column;gap:18px;min-width:0}',
602
- '.ilp-guide-stack[data-guide-mode="accumulated"]{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line);background:var(--ilp-sub);padding:18px 20px}',
603
-
604
- // Tier 1: Open Editorial Hero
605
- '.ilp-hero{display:flex;flex-direction:column;align-items:flex-start;gap:8px;min-width:0}',
627
+ // Unified Top 1-on-1 Study Intent Box (always accessible at top across 0/0 and non-empty states)
628
+ '.ilp-intent-box{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line2);background:var(--ilp-panel);padding:15px 16px 13px;display:flex;flex-direction:column;gap:10px;min-width:0}',
629
+ '.ilp-intent-top{display:flex;align-items:baseline;justify-content:space-between;flex-wrap:wrap;gap:4px 12px;min-width:0}',
630
+ '.ilp-intent-label{font-size:14px;font-weight:600;color:var(--ilp-ink)}',
631
+ '.ilp-intent-hint{font-size:12px;color:var(--ilp-ink3);overflow-wrap:anywhere}',
632
+ '.ilp-intent-main{display:flex;align-items:center;gap:8px;padding:5px 5px 5px 12px;border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line2);background:var(--ilp-bg);min-width:0}',
633
+ '.ilp-intent-main:focus-within{border-color:var(--ilp-run)}',
634
+ '.ilp-intent-input{flex:1 1 0%;min-width:0;min-block-size:36px;border:0;background:transparent;font-size:13.5px;line-height:1.4;color:var(--ilp-ink);outline:none}',
635
+ '.ilp-intent-input::placeholder{color:var(--ilp-ink3)}',
636
+ '.ilp-intent-controls{display:flex;align-items:center;gap:6px;flex:none}',
637
+ '.ilp-ws-pill{max-inline-size:168px;min-block-size:34px;padding:4px 9px;border-radius:8px;border:1px solid var(--ilp-line);background:var(--ilp-panel);font-size:12px;color:var(--ilp-ink2)}',
638
+ '.ilp-chip-row{display:flex;flex-wrap:wrap;align-items:center;gap:6px;min-width:0}',
639
+ '.ilp-wb .ilp-chip{display:inline-flex;align-items:center;min-block-size:25px;padding:3px 10px;border-radius:999px;border:1px solid var(--ilp-line);background:var(--ilp-bg);font-size:12px;line-height:1.3;color:var(--ilp-ink2)}',
640
+ '@media (hover:hover){.ilp-wb .ilp-chip:hover:not(:disabled){border-color:var(--ilp-line2);background:var(--ilp-sub);color:var(--ilp-ink)}}',
641
+
642
+ // Visual 3-Step Storyboard + Principle Guide (unboxed on 0/0 empty, softly boxed when reopened)
643
+ '.ilp-guide-stack{display:flex;flex-direction:column;gap:16px;min-width:0}',
644
+ '.ilp-guide-stack[data-guide-mode="accumulated"]{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line2);background:color-mix(in oklab,var(--ilp-sub) 55%,var(--ilp-panel));padding:18px 20px}',
645
+
646
+ '.ilp-hero{display:flex;flex-direction:column;align-items:flex-start;gap:7px;min-width:0}',
606
647
  '.ilp-hero-top{width:100%;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;min-width:0}',
607
- '.ilp-hero-kicker{font-size:11.5px;font-weight:600;color:var(--ilp-run);letter-spacing:.02em}',
608
- '.ilp-hero-lead{font-size:clamp(19px,2.3vw,22px);line-height:1.34;font-weight:600;letter-spacing:-.02em;color:var(--ilp-ink);max-width:680px}',
609
- '.ilp-hero-sub{font-size:13.5px;line-height:1.52;color:var(--ilp-ink2);max-width:640px}',
610
- '.ilp-onb-cta{margin-top:4px;display:flex;flex-wrap:wrap;align-items:center;gap:10px}',
611
-
612
- // Tier 2: Connected 3-Step Visual Storyboard (01 -> 02 -> 03 with subgrid + explicit preceding fallback)
613
- '.ilp-story-grid{display:grid;grid-template-columns:minmax(0,1fr) 26px minmax(0,1fr) 26px minmax(0,1fr);grid-template-rows:132px auto auto;column-gap:6px;row-gap:8px;align-items:stretch;min-width:0}',
614
- '.ilp-onb-step{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line);background:var(--ilp-panel);padding:13px;display:grid;grid-row:1 / 4;grid-template-rows:132px auto auto;grid-template-rows:subgrid;gap:8px;min-width:0}',
648
+ '.ilp-hero-kicker{font-size:12px;font-weight:600;color:var(--ilp-run)}',
649
+ '.ilp-hero-lead{font-size:clamp(18.5px,2.2vw,20px);line-height:1.34;font-weight:700;letter-spacing:-.015em;color:var(--ilp-ink);max-width:700px}',
650
+ '.ilp-hero-sub{font-size:13.5px;line-height:1.52;color:var(--ilp-ink2);max-width:700px}',
651
+ '.ilp-onb-cta{margin-top:4px;display:flex;flex-wrap:wrap;align-items:center;gap:8px}',
652
+
653
+ // Connected 3-Step Visual Storyboard (subgrid + explicit preceding fallback)
654
+ '.ilp-story-grid{display:grid;grid-template-columns:minmax(0,1fr) 24px minmax(0,1fr) 24px minmax(0,1fr);grid-template-rows:138px auto 1fr;column-gap:6px;row-gap:8px;align-items:stretch;min-width:0}',
655
+ '.ilp-onb-step{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line2);background:var(--ilp-panel);padding:13px;display:grid;grid-row:1 / 4;grid-template-rows:138px auto 1fr;grid-template-rows:subgrid;gap:8px;min-width:0}',
615
656
  '.ilp-step-col-1{grid-column:1}',
616
657
  '.ilp-conn-col-1{grid-column:2;grid-row:1}',
617
658
  '.ilp-step-col-2{grid-column:3}',
@@ -621,41 +662,40 @@ const ILP_CSS = [
621
662
  '.ilp-conn-badge{width:24px;height:24px;border-radius:999px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);color:var(--ilp-ink3);display:inline-flex;align-items:center;justify-content:center}',
622
663
  '.ilp-scene{border-radius:10px;border:1px solid var(--ilp-line);background:var(--ilp-bg);padding:9px 10px;display:flex;flex-direction:column;justify-content:space-between;gap:6px;min-width:0;overflow:hidden}',
623
664
  '.ilp-step-head{display:flex;flex-direction:column;gap:2px;min-width:0}',
624
- '.ilp-onb-num{font-size:11px;font-weight:600;letter-spacing:.03em;color:var(--ilp-ink3)}',
625
- '.ilp-onb-step-h{font-size:14px;font-weight:600;line-height:1.35;color:var(--ilp-ink)}',
665
+ '.ilp-onb-num{font-size:11px;font-weight:600;letter-spacing:.02em;color:var(--ilp-ink3)}',
666
+ '.ilp-onb-step-h{font-size:14px;font-weight:700;line-height:1.32;color:var(--ilp-ink)}',
626
667
  '.ilp-onb-step-p{font-size:12.5px;line-height:1.48;color:var(--ilp-ink2)}',
627
668
 
628
- // Step 01 Wireframe: calm white user prompt pill + mini card (zero black fill!)
629
- '.ilp-wf-user{display:flex;align-items:center;justify-content:space-between;gap:6px;min-width:0}',
630
- '.ilp-wf-u-pill{display:inline-flex;align-items:center;gap:5px;padding:2px 7px;border-radius:6px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);font-size:10.5px;font-weight:500;color:var(--ilp-ink);white-space:nowrap}',
669
+ // Step 01 Wireframe
670
+ '.ilp-wf-user{display:flex;align-items:center;justify-content:space-between;gap:4px;min-width:0}',
671
+ '.ilp-wf-u-pill{display:inline-flex;align-items:center;gap:4px;padding:2px 6px;border-radius:6px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);font-size:10px;font-weight:500;color:var(--ilp-ink);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}',
631
672
  '.ilp-wf-dot-role{width:13px;height:13px;border-radius:999px;border:1px solid var(--ilp-line2);background:var(--ilp-sub);font-size:8.5px;font-weight:600;display:inline-flex;align-items:center;justify-content:center;color:var(--ilp-ink2);flex:none}',
632
- '.ilp-wf-quiet{font-size:10px;color:var(--ilp-ink3);white-space:nowrap}',
673
+ '.ilp-wf-quiet{font-size:9.5px;color:var(--ilp-ink3);white-space:nowrap;flex:none}',
633
674
  '.ilp-wf-card{border-radius:7px;border:1px solid var(--ilp-run-line);background:var(--ilp-run-bg);padding:7px 8px;display:flex;flex-direction:column;gap:5px}',
634
- '.ilp-wf-card-head{display:flex;align-items:center;justify-content:space-between;gap:4px;font-size:10.5px;font-weight:600;color:var(--ilp-run)}',
675
+ '.ilp-wf-card-head{display:flex;align-items:center;justify-content:space-between;gap:4px;font-size:10px;font-weight:600;color:var(--ilp-run)}',
635
676
  '.ilp-wf-lines{display:flex;flex-direction:column;gap:3px}',
636
677
  '.ilp-wf-skel{height:4px;border-radius:2px;background:color-mix(in oklab,var(--ilp-run) 24%,var(--ilp-line2))}',
637
678
  '.ilp-wf-skel.w82{width:84%}',
638
679
  '.ilp-wf-skel.w62{width:62%}',
639
- '.ilp-wf-btn-row{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px;margin-top:1px}',
640
- '.ilp-wf-mini-btn{height:14px;border-radius:4px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);font-size:9px;font-weight:500;color:var(--ilp-ink2);display:flex;align-items:center;justify-content:center;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}',
680
+ '.ilp-wf-btn-row{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}',
681
+ '.ilp-wf-mini-btn{height:15px;border-radius:4px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);font-size:9px;font-weight:500;color:var(--ilp-ink2);display:flex;align-items:center;justify-content:center;white-space:nowrap;overflow:hidden;padding-inline:2px}',
641
682
 
642
- // Step 02 Wireframe: 22x72 Bezier branch diagram
683
+ // Step 02 Wireframe: Bezier fork
643
684
  '.ilp-branch-diag{flex:1;display:flex;align-items:center;gap:2px;min-width:0}',
644
685
  '.ilp-branch-in{flex:none;padding:5px 6px;border-radius:7px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);display:flex;flex-direction:column;align-items:center;gap:3px}',
645
686
  '.ilp-branch-in-k{font-size:9.5px;font-weight:600;color:var(--ilp-ink2);white-space:nowrap}',
646
687
  '.ilp-branch-dots{display:flex;gap:2.5px}',
647
- '.ilp-branch-dots span{width:9px;height:4px;border-radius:2px;border:1px solid var(--ilp-line2);background:var(--ilp-sub)}',
688
+ '.ilp-branch-dots span{width:8px;height:4px;border-radius:2px;border:1px solid var(--ilp-line2);background:var(--ilp-sub)}',
648
689
  '.ilp-branch-svg{flex:none;display:block}',
649
690
  '.ilp-branch-outs{flex:1 1 0;min-width:0;display:flex;flex-direction:column;justify-content:space-between;gap:7px}',
650
- '.ilp-branch-pill{padding:4px 7px;border-radius:7px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);display:flex;flex-direction:column;gap:1px;min-width:0}',
651
- '.ilp-branch-pill b{font-size:10px;font-weight:600;color:var(--ilp-ink);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}',
652
- '.ilp-branch-pill span{font-size:9px;color:var(--ilp-ink3);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}',
691
+ '.ilp-branch-pill{padding:4px 7px;border-radius:7px;border:1px solid var(--ilp-run-line);background:var(--ilp-run-bg);display:flex;flex-direction:column;gap:1px;min-width:0}',
692
+ '.ilp-branch-pill b{font-size:10px;font-weight:600;color:var(--ilp-run);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}',
693
+ '.ilp-branch-pill span{font-size:9px;color:var(--ilp-ink2);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}',
653
694
  '.ilp-branch-pill.is-idle{border-color:var(--ilp-wait-line);background:var(--ilp-wait-bg)}',
654
695
  '.ilp-branch-pill.is-idle b{color:var(--ilp-wait)}',
655
- '.ilp-branch-pill.is-idle span{color:var(--ilp-ink2)}',
656
696
 
657
- // Step 03 Wireframe: Multi-source square badges + funnel SVG + mastery progression
658
- '.ilp-source-badge{display:inline-flex;align-items:center;gap:4px;font-size:10.5px;font-weight:500;padding:2px 6px;border-radius:5px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);color:var(--ilp-ink2);white-space:nowrap}',
697
+ // Step 03 Wireframe: Multi-source funnel
698
+ '.ilp-source-badge{display:inline-flex;align-items:center;gap:4px;font-size:10px;font-weight:500;padding:2px 6px;border-radius:5px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);color:var(--ilp-ink2);white-space:nowrap}',
659
699
  '.ilp-source-badge.is-local{border-color:var(--ilp-run-line);background:var(--ilp-run-bg);color:var(--ilp-run)}',
660
700
  '.ilp-source-dot{width:5px;height:5px;border-radius:999px;background:currentColor;flex:none}',
661
701
  '.ilp-funnel-sources{display:flex;align-items:center;justify-content:space-between;gap:4px;min-width:0}',
@@ -667,29 +707,31 @@ const ILP_CSS = [
667
707
  '.ilp-delta-tag.ok{color:var(--ilp-ok)}',
668
708
  '.ilp-delta-mid{display:flex;flex-direction:column;align-items:center;gap:1px;font-size:9px;font-weight:500;color:var(--ilp-ink3);white-space:nowrap}',
669
709
 
670
- // Tier 3: Default-Closed Native <details> Button Simulator + role="toolbar" focusgroup
671
- '.ilp-sim-disclosure{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line);background:var(--ilp-panel);min-width:0}',
672
- '.ilp-sim-summary{list-style:none;padding:11px 15px;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px 12px;cursor:pointer;border-radius:var(--ilp-r-lg);color:var(--ilp-ink)}',
710
+ // Native <details> Card Button Simulator + role="toolbar"
711
+ '.ilp-sim-disclosure{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line2);background:var(--ilp-panel);min-width:0}',
712
+ '.ilp-sim-summary{list-style:none;padding:11px 15px;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px 12px;cursor:pointer;border-radius:var(--ilp-r-lg);color:var(--ilp-ink);user-select:none}',
673
713
  '.ilp-sim-summary::-webkit-details-marker{display:none}',
674
714
  '@media (hover:hover){.ilp-sim-summary:hover{background:var(--ilp-hover)}}',
675
715
  '.ilp-sim-summary-left{display:inline-flex;align-items:center;gap:8px;font-size:13px;font-weight:600;color:var(--ilp-ink)}',
676
- '.ilp-summary-chevron{flex:none;transition:transform .16s ease}',
716
+ '.ilp-summary-chevron{flex:none;transition:transform .18s ease}',
677
717
  '.ilp-sim-disclosure[open] .ilp-summary-chevron{transform:rotate(90deg)}',
718
+ '.ilp-sim-disclosure::details-content{interpolate-size:allow-keywords;overflow:clip;contain:layout}',
719
+ '.ilp-sim-disclosure:not([open])::details-content{block-size:0}',
720
+ '@media (prefers-reduced-motion:no-preference){.ilp-sim-disclosure::details-content{transition:block-size .24s ease,content-visibility .24s allow-discrete,display .24s allow-discrete}}',
678
721
  '.ilp-sim-body{border-top:1px solid var(--ilp-line);padding:14px 16px 16px;display:flex;flex-direction:column;gap:12px;min-width:0}',
679
722
  '.ilp-sim-toolbar{display:flex;flex-wrap:wrap;align-items:center;gap:8px;min-width:0}',
680
723
  '.ilp-sim-group{display:inline-flex;flex-wrap:wrap;align-items:center;gap:6px}',
681
724
  '.ilp-sim-sep{width:1px;height:20px;border-left:1px solid var(--ilp-line2);margin:0 2px;flex:none}',
682
- '.ilp-sim-btn{display:inline-flex;align-items:center;gap:5px;padding:6px 11px;border-radius:var(--ilp-r-btn);border:1px solid var(--ilp-line2);background:var(--ilp-panel);color:var(--ilp-ink2);font-size:12px;font-weight:500;white-space:nowrap}',
725
+ '.ilp-wb .ilp-sim-btn,.ilp-sim-btn{display:inline-flex;align-items:center;gap:5px;padding:6px 11px;border-radius:var(--ilp-r-btn);border:1px solid var(--ilp-line2);background:var(--ilp-panel);color:var(--ilp-ink2);font-size:12px;font-weight:500;white-space:nowrap}',
683
726
  '@media (hover:hover){.ilp-sim-btn:hover{background:var(--ilp-hover);color:var(--ilp-ink)}}',
684
727
  '.ilp-sim-check{display:none;flex:none}',
685
- // Styled strictly from [aria-pressed="true"], soft blue/amber tint (never --ilp-pri black fill!)
686
728
  '.ilp-sim-btn[aria-pressed="true"]{border-color:var(--ilp-run);background:var(--ilp-run-bg);color:var(--ilp-run);font-weight:600}',
687
729
  '.ilp-sim-btn.is-idle[aria-pressed="true"]{border-color:var(--ilp-wait);background:var(--ilp-wait-bg);color:var(--ilp-wait)}',
688
730
  '.ilp-sim-btn[aria-pressed="true"] .ilp-sim-check{display:inline-block}',
689
731
  '.ilp-sim-stage{display:flex;flex-direction:column;gap:10px;min-width:0}',
690
732
  '.ilp-sim-mini-grid{display:grid;grid-template-columns:minmax(0,1fr) 24px minmax(0,1fr);gap:8px;align-items:stretch;min-width:0}',
691
733
  '.ilp-sim-arrow{align-self:center;justify-self:center;color:var(--ilp-ink3)}',
692
- '.ilp-mini-win{border-radius:10px;border:1px solid var(--ilp-line);background:var(--ilp-bg);overflow:hidden;display:flex;flex-direction:column;min-width:0}',
734
+ '.ilp-mini-win{border-radius:10px;border:1px solid var(--ilp-line2);background:var(--ilp-bg);overflow:hidden;display:flex;flex-direction:column;min-width:0}',
693
735
  '.ilp-mini-win-bar{padding:7px 11px;border-bottom:1px solid var(--ilp-line);background:var(--ilp-sub);display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:11px;font-weight:600;color:var(--ilp-ink2)}',
694
736
  '.ilp-mini-win-body{padding:10px 12px;display:flex;flex-direction:column;gap:7px;font-size:12px;min-width:0}',
695
737
  '.ilp-mini-prose{padding-left:8px;border-left:2px solid var(--ilp-line2);font-size:11.5px;color:var(--ilp-ink2)}',
@@ -701,71 +743,67 @@ const ILP_CSS = [
701
743
  '.ilp-mini-collapsed{border-radius:7px;border:1px dashed var(--ilp-line2);background:var(--ilp-panel);padding:6px 10px;font-size:11.5px;color:var(--ilp-ink3);display:flex;align-items:center;justify-content:space-between;gap:8px}',
702
744
  '.ilp-sim-takeaway{font-size:12px;color:var(--ilp-ink2);padding:8px 11px;border-radius:8px;border:1px solid var(--ilp-line);background:var(--ilp-sub)}',
703
745
 
704
- // Spotlight Hero Card (Accumulated Workbench)
705
- '.ilp-spot-card{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line2);background:var(--ilp-panel);padding:20px 22px;display:grid;grid-template-columns:minmax(0,1.4fr) auto;gap:14px 22px;align-items:center;min-width:0}',
706
- '.ilp-spot-main{display:flex;flex-direction:column;gap:7px;min-width:0;overflow-wrap:anywhere}',
707
- '.ilp-spot-eyebrow{display:flex;flex-wrap:wrap;align-items:center;gap:6px 8px}',
708
- '.ilp-spot-title{font:600 16.5px/1.4 var(--ilp-sans);color:var(--ilp-ink);overflow-wrap:anywhere}',
709
- '.ilp-spot-desc{font-size:13px;color:var(--ilp-ink2);overflow-wrap:anywhere}',
710
- '.ilp-spot-probe{font-size:12.5px;color:var(--ilp-ink2);padding:8px 11px;border-radius:var(--ilp-r-sm);background:var(--ilp-sub);border:1px solid var(--ilp-line);overflow-wrap:anywhere}',
711
- '.ilp-spot-acts{display:flex;flex-direction:column;align-items:stretch;gap:8px;min-width:168px}',
712
-
713
- // Direct Focused Study Launcher (always reachable without prior triage acceptance)
714
- '.ilp-direct-box{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line);background:var(--ilp-panel);padding:16px 18px;display:flex;flex-direction:column;gap:10px;min-width:0}',
715
- '.ilp-direct-box.is-hero{border-color:var(--ilp-line2);padding:18px 20px}',
716
- '.ilp-direct-head{display:flex;align-items:baseline;justify-content:space-between;flex-wrap:wrap;gap:4px 12px;min-width:0}',
717
- '.ilp-direct-title{font-size:14.5px;font-weight:600;color:var(--ilp-ink)}',
718
- '.ilp-direct-sub{font-size:12px;color:var(--ilp-ink3);overflow-wrap:anywhere}',
719
- '.ilp-direct-row{display:flex;align-items:center;gap:8px;min-width:0}',
720
- '.ilp-direct-input{flex:1 1 0%;min-width:0;min-height:35px;padding:6px 11px;border-radius:var(--ilp-r-btn);border:1px solid var(--ilp-line2);background:var(--ilp-bg);color:var(--ilp-ink);font-size:13px;line-height:1.4}',
721
- '.ilp-direct-input::placeholder{color:var(--ilp-ink3)}',
722
- '.ilp-direct-ws{max-width:180px;min-height:35px;padding:6px 10px;border-radius:var(--ilp-r-btn);border:1px solid var(--ilp-line2);background:var(--ilp-bg);color:var(--ilp-ink2);font-size:12px}',
723
- '.ilp-direct-chips{display:flex;flex-wrap:wrap;align-items:center;gap:6px;min-width:0}',
724
- '.ilp-chip-btn{display:inline-flex;align-items:center;min-height:25px;padding:3px 10px;border-radius:999px;border:1px solid var(--ilp-line);background:var(--ilp-sub);color:var(--ilp-ink2);font-size:11.5px;line-height:1.3}',
725
- '@media (hover:hover){.ilp-chip-btn:hover:not(:disabled){background:var(--ilp-hover);border-color:var(--ilp-line2);color:var(--ilp-ink)}}',
726
-
727
- // Collapsible Background Auto-Archive Inbox
728
- '.ilp-triage-box{border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line);background:var(--ilp-panel);overflow:hidden;min-width:0}',
729
- '.ilp-triage-head{width:100%;padding:12px 16px;display:flex;align-items:center;justify-content:space-between;gap:10px;background:var(--ilp-panel);min-width:0}',
730
- '.ilp-triage-head:hover:not(:disabled){background:var(--ilp-hover)}',
731
- '.ilp-triage-head-left{display:flex;align-items:center;flex-wrap:wrap;gap:8px;min-width:0}',
732
- '.ilp-triage-body{border-top:1px solid var(--ilp-line);display:flex;flex-direction:column}',
733
- '.ilp-triage-batch{padding:10px 16px;background:var(--ilp-wait-bg);border-bottom:1px solid var(--ilp-line);display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px}',
734
- '.ilp-triage-subbar{padding:9px 16px;background:var(--ilp-sub);border-bottom:1px solid var(--ilp-line);display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;font-size:12px;color:var(--ilp-ink2)}',
735
- '.ilp-triage-row{padding:12px 16px;border-bottom:1px solid var(--ilp-line);display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:10px 14px;min-width:0}',
736
- '.ilp-triage-row:last-child{border-bottom:0}',
737
- '.ilp-triage-info{flex:1 1 280px;min-width:0;display:flex;flex-direction:column;gap:4px}',
738
- '.ilp-triage-title{font-weight:500;font-size:13px;overflow-wrap:anywhere}',
739
- '.ilp-triage-why{font-size:12px;color:var(--ilp-ink2);overflow-wrap:anywhere}',
740
- '.ilp-triage-acts{display:flex;align-items:center;flex-wrap:wrap;gap:6px;flex-shrink:0}',
741
- '.ilp-empty-tracks-note{font-size:12px;color:var(--ilp-ink3);padding:2px 2px;overflow-wrap:anywhere}',
742
-
743
- // Accordion Capability Tracks
744
- '.ilp-tracks{display:flex;flex-direction:column;gap:10px;min-width:0}',
745
- '.ilp-section-label{font-size:12px;font-weight:600;color:var(--ilp-ink3);letter-spacing:.02em}',
746
- '.ilp-track{border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line);background:var(--ilp-panel);overflow:hidden;min-width:0}',
747
- '.ilp-track-head{width:100%;padding:13px 16px;display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0}',
748
- '.ilp-track-head:hover:not(:disabled){background:var(--ilp-hover)}',
749
- '.ilp-track-meta{min-width:0;display:flex;flex-direction:column;gap:2px}',
750
- '.ilp-track-title{font-size:14.5px;font-weight:600;color:var(--ilp-ink);overflow-wrap:anywhere}',
751
- '.ilp-track-sub{font-size:12px;color:var(--ilp-ink3);overflow-wrap:anywhere}',
752
- '.ilp-track-right{display:flex;align-items:center;gap:10px;flex-shrink:0}',
753
- '.ilp-track-list{border-top:1px solid var(--ilp-line);display:flex;flex-direction:column}',
754
- '.ilp-item-row{padding:12px 16px;border-bottom:1px solid var(--ilp-line);display:flex;align-items:flex-start;justify-content:space-between;flex-wrap:wrap;gap:10px 16px;min-width:0}',
755
- '.ilp-item-row:last-child{border-bottom:0}',
756
- '.ilp-item-main{flex:1 1 300px;min-width:0;display:flex;flex-direction:column;gap:4px}',
757
- '.ilp-item-badges{display:flex;align-items:center;flex-wrap:wrap;gap:6px}',
758
- '.ilp-item-title{font-weight:500;font-size:13.5px;color:var(--ilp-ink);overflow-wrap:anywhere}',
759
- '.ilp-item-title:hover{text-decoration:underline;text-underline-offset:3px}',
760
- '.ilp-item-evidence{font-size:12px;color:var(--ilp-ink2);overflow-wrap:anywhere}',
761
- '.ilp-item-acts{display:flex;align-items:center;flex-wrap:wrap;gap:6px;flex-shrink:0}',
762
-
763
- // 15-min course panel & Export preview
764
- '.ilp-course-box{border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line2);background:var(--ilp-panel);padding:18px 20px;display:flex;flex-direction:column;gap:12px;min-width:0}',
765
- '.ilp-course-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;min-width:0}',
766
- '.ilp-station{padding:12px 13px;border-radius:var(--ilp-r-sm);border:1px solid var(--ilp-line);background:var(--ilp-sub);display:flex;flex-direction:column;gap:5px;min-width:0;overflow-wrap:anywhere}',
746
+ // Plan A Spotlight Hero Card
747
+ '.ilp-spotlight{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-run-line);background:var(--ilp-run-soft);padding:16px 18px;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px 18px;align-items:center;min-width:0}',
748
+ '.ilp-spot-meta{display:flex;align-items:center;flex-wrap:wrap;gap:6px 8px;font-size:12px;color:var(--ilp-run);font-weight:600}',
749
+ '.ilp-spot-title{margin:5px 0 3px;font-size:16.5px;font-weight:700;line-height:1.35;color:var(--ilp-ink);overflow-wrap:anywhere}',
750
+ '.ilp-spot-why{font-size:13px;color:var(--ilp-ink2);overflow-wrap:anywhere}',
751
+ '.ilp-spot-acts{display:flex;flex-direction:column;gap:7px;min-width:146px}',
752
+
753
+ // Unified Plan A Toolbar & Filter Pills
754
+ '.ilp-toolbar{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;min-width:0}',
755
+ '.ilp-filter-row{display:flex;align-items:center;flex-wrap:wrap;gap:6px;min-width:0}',
756
+ '.ilp-wb .ilp-filter-pill{display:inline-flex;align-items:center;gap:5px;min-block-size:29px;padding:4px 11px;border-radius:999px;border:1px solid var(--ilp-line);background:var(--ilp-panel);font-size:12px;color:var(--ilp-ink2);font-variant-numeric:tabular-nums;white-space:nowrap}',
757
+ '@media (hover:hover){.ilp-wb .ilp-filter-pill:hover{background:var(--ilp-hover);color:var(--ilp-ink)}}',
758
+ '.ilp-wb .ilp-filter-pill[aria-pressed="true"]{border-color:var(--ilp-pri);background:var(--ilp-pri);color:var(--ilp-on-pri);font-weight:600}',
759
+ '.ilp-amber-dot{width:7px;height:7px;border-radius:50%;background:var(--ilp-wait);flex:none}',
760
+ '.ilp-toolbar-acts{display:flex;align-items:center;flex-wrap:wrap;gap:6px}',
761
+
762
+ // Plan A Unified Single Sheet + Layer 3 Overflow Bar + Uniform 3-col Scan Rows
763
+ '.ilp-sheet{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line2);background:var(--ilp-panel);overflow:hidden;min-width:0}',
764
+ '.ilp-sheet-head{padding:11px 16px;border-block-end:1px solid var(--ilp-line);display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;background:color-mix(in oklab,var(--ilp-sub) 45%,var(--ilp-panel))}',
765
+ '.ilp-sheet-title{font-size:12.5px;font-weight:600;color:var(--ilp-ink2)}',
766
+ '.ilp-guard-pill{font-size:11.5px;font-weight:600;color:var(--ilp-ok);background:var(--ilp-ok-bg);border:1px solid var(--ilp-ok-line);padding:2px 8px;border-radius:6px;white-space:nowrap}',
767
+ '.ilp-track-pills{display:flex;align-items:center;flex-wrap:wrap;gap:6px;padding:9px 16px;border-block-end:1px solid var(--ilp-line);background:var(--ilp-panel)}',
768
+ '.ilp-wb .ilp-track-pill{min-block-size:26px;padding:3px 10px;border-radius:999px;border:1px solid var(--ilp-line);background:var(--ilp-bg);font-size:11.5px;color:var(--ilp-ink2);white-space:nowrap}',
769
+ '.ilp-wb .ilp-track-pill[aria-pressed="true"]{border-color:var(--ilp-run-line);background:var(--ilp-run-bg);color:var(--ilp-run);font-weight:600}',
770
+
771
+ '.ilp-overflow-bar{padding:10px 16px;border-block-end:1px solid var(--ilp-line);background:var(--ilp-wait-soft);display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px}',
772
+ '.ilp-overflow-msg{display:flex;align-items:center;gap:8px;font-size:12.5px;color:var(--ilp-ink2);min-width:0;overflow-wrap:anywhere}',
773
+ '.ilp-overflow-msg strong{color:var(--ilp-ink)}',
774
+
775
+ '.ilp-row-wrap{border-block-end:1px solid var(--ilp-line);min-width:0}',
776
+ '.ilp-row-wrap:last-child{border-block-end:0}',
777
+ '.ilp-row{min-block-size:78px;padding:13px 16px;display:grid;grid-template-columns:126px minmax(0,1fr) auto;gap:8px 14px;align-items:center;min-width:0}',
778
+ '.ilp-row.is-unread{border-inline-start:3px solid var(--ilp-wait);background:color-mix(in oklab,var(--ilp-wait) 6%,var(--ilp-panel))}',
779
+ '.ilp-meter-col{display:flex;flex-direction:column;gap:4px;min-width:0}',
780
+ '.ilp-row-body{min-width:0;display:flex;flex-direction:column;gap:2px}',
781
+ '.ilp-wb .ilp-row-title-btn{font-size:14.5px;font-weight:600;color:var(--ilp-ink);line-height:1.35;overflow-wrap:anywhere;text-align:start}',
782
+ '@media (hover:hover){.ilp-wb .ilp-row-title-btn:hover{text-decoration:underline;text-underline-offset:3px}}',
783
+ '.ilp-row-summary{font-size:12.5px;color:var(--ilp-ink2);display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;line-clamp:1;overflow:clip}',
784
+ '.ilp-row-sub{font-size:11.5px;color:var(--ilp-ink3);overflow-wrap:anywhere}',
785
+ '.ilp-row-acts{display:flex;align-items:center;gap:6px;flex-wrap:wrap;flex-shrink:0}',
786
+ '.ilp-empty-sheet{padding:26px 18px;text-align:center;font-size:13px;color:var(--ilp-ink3)}',
787
+
788
+ // Inline 10s Blind Quiz inside unread row + evidence modal cards
789
+ '.ilp-inline-quiz{margin:0 16px 14px;padding:13px 14px;border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line2);background:var(--ilp-bg);display:flex;flex-direction:column;gap:10px;min-width:0}',
790
+ '.ilp-compare-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;min-width:0}',
791
+ '.ilp-compare-card{padding:9px 11px;border-radius:var(--ilp-r-sm);border:1px solid var(--ilp-line);background:var(--ilp-panel);font-size:12px;color:var(--ilp-ink2);overflow-wrap:anywhere}',
792
+ '.ilp-compare-card.good{border-color:var(--ilp-ok-line);background:var(--ilp-ok-soft)}',
793
+ '.ilp-compare-card.bad{border-color:var(--ilp-bad-line);background:var(--ilp-bad-soft)}',
794
+ '.ilp-compare-k{font-weight:600;margin-block-end:3px;color:var(--ilp-ink)}',
795
+ '.ilp-quiz-q{font-size:13px;font-weight:600;color:var(--ilp-ink);overflow-wrap:anywhere}',
796
+ '.ilp-quiz-fb{padding:9px 11px;border-radius:var(--ilp-r-sm);background:var(--ilp-panel);border:1px solid var(--ilp-line);display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;font-size:12px;color:var(--ilp-ink2)}',
797
+
798
+ // Optional Export box & Course stations inside Sprint Dialog
799
+ '.ilp-course-box{border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line2);background:var(--ilp-panel);padding:16px 18px;display:flex;flex-direction:column;gap:10px;min-width:0}',
767
800
  '.ilp-empty-card{border-radius:var(--ilp-r-lg);border:1px solid var(--ilp-line);background:var(--ilp-panel);padding:24px;display:flex;flex-direction:column;gap:14px;align-items:flex-start;min-width:0}',
768
- '.ilp-onb-triage-tip{font-size:12.5px;line-height:1.55;color:var(--ilp-ink2);padding:12px 14px;border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line);background:var(--ilp-sub)}',
801
+ '.ilp-stage-track{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px}',
802
+ '.ilp-stage-node{padding:6px 4px;border-radius:8px;border:1px solid var(--ilp-line);background:var(--ilp-bg);font-size:11.5px;color:var(--ilp-ink3);text-align:center}',
803
+ '.ilp-stage-node.done{border-color:var(--ilp-ok-line);background:var(--ilp-ok-soft);color:var(--ilp-ok);font-weight:600}',
804
+ '.ilp-stage-node.curr{border-color:var(--ilp-run);background:var(--ilp-run-soft);color:var(--ilp-run);font-weight:600}',
805
+ '.ilp-station{padding:11px 13px;border-radius:10px;border:1px solid var(--ilp-line);background:var(--ilp-bg);display:grid;grid-template-columns:30px minmax(0,1fr) auto;gap:10px;align-items:center;min-width:0}',
806
+ '.ilp-station-num{width:28px;height:28px;border-radius:50%;background:var(--ilp-run-soft);border:1px solid var(--ilp-run-line);color:var(--ilp-run);display:grid;place-items:center;font-weight:700;font-size:12px}',
769
807
 
770
808
  // Markdown Fences (`shield`, `learn-quiz`, `learn-pass`)
771
809
  '.ilp-fence{container-type:inline-size;container-name:ilpfence;width:100%;max-width:100%;min-width:0;margin:8px 0}',
@@ -789,7 +827,6 @@ const ILP_CSS = [
789
827
  '.ilp-strip-chevron{flex-shrink:0;color:var(--ilp-card-muted);transform:rotate(-90deg)}',
790
828
  '.ilp-strip-details[open] > .ilp-strip-summary .ilp-strip-chevron{transform:rotate(0deg)}',
791
829
  '@media (prefers-reduced-motion:no-preference){.ilp-strip-chevron{transition:transform .18s ease}}',
792
- // Muted gray & unbolded weight=400 both when closed and when expanded (never steals focus from AI prose!)
793
830
  '.ilp-strip-topic{font-size:12.5px;font-weight:400;color:var(--ilp-card-ink);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}',
794
831
  '.ilp-strip-details[open] > .ilp-strip-summary .ilp-strip-topic{white-space:normal;color:var(--ilp-card-ink);font-weight:400}',
795
832
  '.ilp-strip-hint{font-size:11px;color:var(--ilp-card-muted);white-space:nowrap;flex-shrink:0}',
@@ -816,17 +853,14 @@ const ILP_CSS = [
816
853
  // Full-width Cards for `learn-quiz` and `learn-pass`
817
854
  '.ilp-card{border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line2);background:var(--ilp-panel);padding:14px 16px;display:flex;flex-direction:column;gap:11px;min-width:0}',
818
855
  '.ilp-card.streaming{padding:10px 14px;flex-direction:row;align-items:center;justify-content:space-between;background:var(--ilp-sub)}',
819
- '.ilp-card.collapsed{padding:8px 12px;flex-direction:row;align-items:center;justify-content:space-between;background:var(--ilp-sub)}',
820
856
  '.ilp-card.pass{border-color:color-mix(in srgb,var(--ilp-ok) 40%,var(--ilp-line));background:color-mix(in srgb,var(--ilp-ok) 6%,var(--ilp-panel))}',
821
857
  '.ilp-card-head{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px;min-width:0}',
822
858
  '.ilp-card-title{font-weight:600;font-size:14px;color:var(--ilp-ink);overflow-wrap:anywhere}',
823
859
  '.ilp-shield-k{font-size:12px;font-weight:600;color:var(--ilp-ink3)}',
824
- '.ilp-shield-probe{padding:9px 12px;border-radius:var(--ilp-r-sm);background:var(--ilp-sub);border:1px solid var(--ilp-line);font-size:12.5px;overflow-wrap:anywhere}',
860
+ '.ilp-spot-desc{font-size:13px;color:var(--ilp-ink2);overflow-wrap:anywhere}',
825
861
  '.ilp-card-acts{display:flex;align-items:center;flex-wrap:wrap;gap:8px;padding-top:2px}',
826
862
  '.ilp-status-note{font-size:12px;color:var(--ilp-ok);font-weight:500}',
827
863
 
828
- // Before/After comparison grid in learn-quiz (base 2-col -> 1-col AFTER in @container)
829
- '.ilp-compare-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;min-width:0}',
830
864
  '.ilp-code-box{border-radius:var(--ilp-r-sm);border:1px solid var(--ilp-line);background:var(--ilp-sub);padding:10px 12px;min-width:0;overflow:hidden}',
831
865
  '.ilp-code-label{font-size:11px;font-weight:600;color:var(--ilp-ink3);margin-bottom:4px}',
832
866
  '.ilp-code-pre{font:12px/1.45 var(--ilp-mono);white-space:pre-wrap;overflow-wrap:anywhere;color:var(--ilp-ink)}',
@@ -848,7 +882,7 @@ const ILP_CSS = [
848
882
  '.ilp-draft-guard-acts{display:flex;flex-wrap:wrap;gap:7px}',
849
883
 
850
884
  // Right Sidebar Drawer (`sidebar.right.pane.tab`)
851
- '.ilp-drawer{height:100%;display:flex;flex-direction:column;padding:16px;gap:14px;overflow-y:auto;background:var(--ilp-bg);min-width:0}',
885
+ '.ilp-drawer{height:100%;display:flex;flex-direction:column;padding:16px;gap:14px;overflow-y:auto;overscroll-behavior:contain;background:var(--ilp-bg);min-width:0}',
852
886
  '.ilp-drawer-box{border-radius:var(--ilp-r-md);border:1px solid var(--ilp-line);background:var(--ilp-panel);padding:14px;display:flex;flex-direction:column;gap:11px;min-width:0}',
853
887
  '.ilp-drawer-q{padding:10px 12px;border-radius:var(--ilp-r-sm);background:var(--ilp-sub);border:1px solid var(--ilp-line);font-size:13px;overflow-wrap:anywhere}',
854
888
  '.ilp-drawer-fb{padding:11px 12px;border-radius:var(--ilp-r-sm);border:1px solid var(--ilp-line);background:var(--ilp-sub);font-size:12.5px;display:flex;flex-direction:column;gap:6px;overflow-wrap:anywhere}',
@@ -858,69 +892,77 @@ const ILP_CSS = [
858
892
  '@media (hover:hover){.ilp-pill:hover{background:var(--ilp-hover);color:var(--ilp-ink)}}',
859
893
  '.ilp-tool{display:flex;align-items:center;gap:8px;font-size:12.5px;color:var(--ilp-ink2);padding:4px 0}',
860
894
 
861
- // Native <dialog closedby="any"> Modal (display scoped strictly to [open]; scroll-chain contained)
862
- 'dialog.ilp-dialog{margin:auto;padding:0;border:1px solid var(--ilp-line2);border-radius:var(--ilp-r-lg);background:var(--ilp-panel);color:var(--ilp-ink);width:min(560px,calc(100vw - 28px));max-height:min(84vh,680px);box-shadow:0 18px 48px rgba(0,0,0,.24)}',
895
+ // Native <dialog closedby="any"> Modal (display scoped strictly to [open]; scroll-chain contained; zero 100vw)
896
+ 'dialog.ilp-dialog{margin:auto;padding:0;border:1px solid var(--ilp-line2);border-radius:18px;background:var(--ilp-panel);color:var(--ilp-ink);inline-size:min(600px,calc(100dvw - 28px));max-block-size:min(84dvh,700px);box-shadow:0 24px 64px rgba(0,0,0,.28);overflow:hidden}',
863
897
  'dialog.ilp-dialog[open]{display:flex;flex-direction:column}',
864
898
  'dialog.ilp-dialog:modal{overscroll-behavior:contain}',
865
- 'dialog.ilp-dialog::backdrop{background:rgba(15,17,22,.46);backdrop-filter:blur(2px);overflow:hidden;overscroll-behavior:contain}',
866
- '.ilp-dlg-head{padding:16px 20px;border-bottom:1px solid var(--ilp-line);display:flex;align-items:center;justify-content:space-between;gap:12px}',
867
- '.ilp-dlg-title{font-weight:600;font-size:15.5px;overflow-wrap:anywhere}',
868
- '.ilp-dlg-body{padding:18px 20px;overflow-y:auto;display:flex;flex-direction:column;gap:12px;font-size:13px}',
869
- '.ilp-dlg-foot{padding:12px 20px;border-top:1px solid var(--ilp-line);display:flex;justify-content:flex-end;flex-wrap:wrap;gap:8px}',
870
-
871
- // Calm Neutral Toast (never solid --ilp-pri block)
872
- '.ilp-toast{position:sticky;bottom:14px;align-self:center;z-index:20;display:inline-flex;align-items:center;gap:9px;padding:8px 14px;border-radius:999px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);color:var(--ilp-ink);font-size:12px;font-weight:500;box-shadow:0 8px 24px rgba(0,0,0,.14)}',
899
+ 'dialog.ilp-dialog::backdrop{background:rgba(12,14,18,.56);backdrop-filter:blur(3px);overflow:hidden;overscroll-behavior:contain}',
900
+ '.ilp-dlg-head{padding:16px 20px 12px;border-block-end:1px solid var(--ilp-line);display:flex;align-items:flex-start;justify-content:space-between;gap:12px}',
901
+ '.ilp-dlg-title{font-weight:700;font-size:17px;line-height:1.3;overflow-wrap:anywhere}',
902
+ '.ilp-dlg-body{padding:16px 20px;overflow-y:auto;overscroll-behavior:contain;display:flex;flex-direction:column;gap:14px;font-size:13px}',
903
+ '.ilp-dlg-foot{padding:12px 20px;border-block-start:1px solid var(--ilp-line);background:color-mix(in oklab,var(--ilp-sub) 45%,var(--ilp-panel));display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px}',
904
+ '.ilp-dlg-foot-main{display:flex;gap:8px;flex-wrap:wrap}',
905
+
906
+ // Compact Non-Wrapping Undo Toast (fits 390px narrow screen cleanly)
907
+ '.ilp-toast{position:sticky;bottom:14px;align-self:center;z-index:20;display:inline-flex;align-items:center;flex-wrap:nowrap;gap:10px;padding:8px 14px;border-radius:12px;border:1px solid var(--ilp-line2);background:var(--ilp-panel);color:var(--ilp-ink);font-size:12.5px;font-weight:500;box-shadow:0 10px 28px rgba(0,0,0,.16);max-inline-size:calc(100dvw - 24px)}',
873
908
  '.ilp-toast-dot{width:7px;height:7px;border-radius:999px;background:var(--ilp-ok);flex:none}',
874
- '.ilp-toast button{color:var(--ilp-run);font-weight:600}',
909
+ '.ilp-toast-text{min-inline-size:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}',
910
+ '.ilp-toast button{flex:none;white-space:nowrap;color:var(--ilp-run);font-weight:600}',
875
911
 
876
912
  // Container Queries MUST come AFTER base grid declarations (equal cascade specificity!)
877
913
  '@container ilpwb (max-width:820px){',
878
- ' .ilp-wb-inner{padding:20px 18px 44px}',
879
- ' .ilp-story-grid{grid-template-columns:minmax(0,1fr) 20px minmax(0,1fr) 20px minmax(0,1fr);column-gap:4px}',
880
- ' .ilp-conn-badge{width:20px;height:20px}',
881
- ' .ilp-onb-step{padding:11px}',
914
+ ' .ilp-wb-inner{padding:20px 18px 48px;gap:16px}',
915
+ ' .ilp-story-grid{grid-template-columns:minmax(0,1fr) 18px minmax(0,1fr) 18px minmax(0,1fr);column-gap:4px}',
916
+ ' .ilp-conn-badge{width:18px;height:18px}',
917
+ ' .ilp-onb-step{padding:10px}',
882
918
  ' .ilp-scene{padding:7px 8px}',
883
919
  ' .ilp-wf-mini-btn{font-size:8.5px}',
884
- ' .ilp-wf-quiet{font-size:9.5px}',
920
+ ' .ilp-wf-quiet{display:none}',
885
921
  '}',
886
922
  '@container ilpwb (max-width:740px){',
887
- ' .ilp-wb-inner{padding:48px 18px 56px;gap:16px}',
923
+ ' .ilp-wb-inner{padding:48px 16px 56px;gap:15px}',
888
924
  ' .ilp-story-grid{grid-template-columns:minmax(0,1fr);grid-template-rows:auto;gap:10px}',
889
- ' .ilp-onb-step{grid-column:auto;grid-row:auto;grid-template-rows:auto}',
925
+ ' .ilp-onb-step{grid-column:auto;grid-row:auto;grid-template-rows:138px auto auto}',
890
926
  ' .ilp-step-connector{display:none}',
891
927
  ' .ilp-sim-mini-grid{grid-template-columns:minmax(0,1fr)}',
892
928
  ' .ilp-sim-arrow{transform:rotate(90deg)}',
893
929
  ' .ilp-sim-sep{display:none}',
894
- ' .ilp-spot-card{grid-template-columns:minmax(0,1fr);padding:18px}',
930
+ ' .ilp-spotlight{grid-template-columns:minmax(0,1fr);padding:15px}',
895
931
  ' .ilp-spot-acts{flex-direction:row;flex-wrap:wrap;min-width:0}',
896
- ' .ilp-direct-row{flex-direction:column;align-items:stretch}',
897
- ' .ilp-direct-input{flex:none;width:100%}',
898
- ' .ilp-direct-ws{max-width:none}',
899
- ' .ilp-course-grid{grid-template-columns:minmax(0,1fr)}',
932
+ ' .ilp-compare-grid{grid-template-columns:minmax(0,1fr)}',
933
+ ' .ilp-intent-main{flex-direction:column;align-items:stretch;padding:8px 10px}',
934
+ ' .ilp-intent-input{flex:none;width:100%}',
935
+ ' .ilp-intent-controls{display:flex;flex-wrap:wrap;justify-content:space-between}',
936
+ ' .ilp-ws-pill{flex:1 1 130px;max-width:none}',
900
937
  '}',
901
938
  '@media (pointer:coarse){',
902
- ' .ilp-direct-input,.ilp-direct-ws{font-size:16px}',
939
+ ' .ilp-intent-input,.ilp-ws-pill{font-size:16px}',
903
940
  '}',
904
- '@container ilpwb (max-width:660px){',
905
- ' .ilp-wb-inner{padding:48px 14px 48px}',
941
+ '@container ilpwb (max-width:560px){',
942
+ ' .ilp-row,.ilp-station{grid-template-columns:minmax(0,1fr)}',
943
+ ' .ilp-meter-col{flex-direction:row;align-items:center;gap:10px}',
906
944
  '}',
907
945
  '@container ilpwb (max-width:460px){',
908
946
  ' .ilp-wb-inner{padding:48px 12px 48px}',
909
947
  ' .ilp-h1{font-size:21px}',
910
948
  ' .ilp-hero-lead{font-size:18px}',
911
- ' .ilp-track-head{padding:12px 14px}',
912
- ' .ilp-item-row{padding:12px 14px}',
949
+ ' .ilp-row{padding:12px 14px}',
950
+ ' .ilp-overflow-bar{padding:10px 14px}',
951
+ ' .ilp-stage-track{grid-template-columns:repeat(2,minmax(0,1fr))}',
913
952
  '}',
914
953
  '@container ilpfence (max-width:540px){',
915
954
  ' .ilp-ps-archive{display:none}',
916
955
  ' .ilp-compare-grid{grid-template-columns:minmax(0,1fr)}',
917
956
  '}',
957
+ '@media (max-width:580px){',
958
+ ' dialog.ilp-dialog .ilp-compare-grid{grid-template-columns:minmax(0,1fr)}',
959
+ '}',
918
960
 
919
961
  // Forced Colors High-Contrast Fallbacks
920
962
  '@media (forced-colors:active){',
921
- ' .ilp-btn,.ilp-sim-btn,.ilp-quiet-btn,.ilp-source-badge,.ilp-badge-card,.ilp-tag,.ilp-onb-step,.ilp-sim-disclosure,.ilp-strip-details,.ilp-mini-win,.ilp-mini-embed,.ilp-toast,.ilp-direct-box,.ilp-direct-input,.ilp-direct-ws,.ilp-chip-btn,dialog.ilp-dialog{border:1px solid ButtonBorder}',
922
- ' .ilp-btn.solid{background:Highlight;color:HighlightText;border-color:Highlight}',
923
- ' .ilp-sim-btn[aria-pressed="true"],.ilp-quiet-btn[aria-pressed="true"]{outline:2px solid Highlight;outline-offset:1px}',
963
+ ' .ilp-btn,.ilp-sim-btn,.ilp-quiet-btn,.ilp-source-badge,.ilp-badge-card,.ilp-tag,.ilp-filter-pill,.ilp-track-pill,.ilp-chip,.ilp-onb-step,.ilp-sim-disclosure,.ilp-strip-details,.ilp-mini-win,.ilp-mini-embed,.ilp-toast,.ilp-intent-box,.ilp-intent-main,.ilp-ws-pill,.ilp-sheet,.ilp-inline-quiz,dialog.ilp-dialog{border:1px solid ButtonBorder}',
964
+ ' .ilp-btn.solid,.ilp-wb .ilp-filter-pill[aria-pressed="true"]{background:Highlight;color:HighlightText;border-color:Highlight}',
965
+ ' .ilp-sim-btn[aria-pressed="true"],.ilp-quiet-btn[aria-pressed="true"],.ilp-wb .ilp-track-pill[aria-pressed="true"]{outline:2px solid Highlight;outline-offset:1px}',
924
966
  ' .ilp-sim-sep{border-left-color:ButtonBorder}',
925
967
  '}',
926
968
  ].join('\n')
@@ -1080,9 +1122,10 @@ function createCoachSessionStore() {
1080
1122
  }
1081
1123
  }
1082
1124
 
1083
- function makeMasteryMeter(h, tier) {
1084
- var safeTier = clampTier(tier || 1)
1085
- var label = MASTERY_LABELS[safeTier] || MASTERY_LABELS[1]
1125
+ function makeMasteryMeter(h, tier, customLabel) {
1126
+ var isZero = tier === 0 || tier === '0'
1127
+ var safeTier = isZero ? 0 : clampTier(tier || 1)
1128
+ var label = customLabel || (isZero ? '0/4 新抓到 · 未看' : (MASTERY_LABELS[safeTier] || MASTERY_LABELS[1]))
1086
1129
  return h('span', { className: 'ilp-meter', 'data-tier': String(safeTier) },
1087
1130
  h('span', { className: 'ilp-bars', 'aria-hidden': 'true' },
1088
1131
  h('span', null),
@@ -1116,7 +1159,9 @@ function hashCardKey(parsed, fallbackSeed) {
1116
1159
  }
1117
1160
 
1118
1161
  function openDeepLearnSession(ctx, item, preferredWorkspaceId) {
1119
- var prompt = buildDeepLearnStarterPrompt(item)
1162
+ var prompt = (item && typeof item.promptOverride === 'string')
1163
+ ? item.promptOverride
1164
+ : buildDeepLearnStarterPrompt(item)
1120
1165
  return postLearnAction('ensure_practice_workspace', {}).then(function (res) {
1121
1166
  var wsId = preferredWorkspaceId || (res && res.workspace && res.workspace.workspaceId)
1122
1167
  var layout = getHostService(ctx, 'layout')
@@ -1182,7 +1227,7 @@ function makeIconComponent(React) {
1182
1227
  }
1183
1228
  }
1184
1229
 
1185
- // Native <dialog closedby="any"> Modal with fallback bounding-rect light-dismiss
1230
+ // Native <dialog closedby="any"> Modal #1: Experience Card Details & Evidence
1186
1231
  function makeEvidenceDialog(React) {
1187
1232
  return function EvidenceDialog(props) {
1188
1233
  var h = React.createElement
@@ -1209,7 +1254,7 @@ function makeEvidenceDialog(React) {
1209
1254
  var el = dlgRef.current
1210
1255
  if (!el || !item) return
1211
1256
  // Fallback light-dismiss only where browser lacks HTMLDialogElement closedBy support
1212
- if (!('closedBy' in HTMLDialogElement.prototype)) {
1257
+ if (typeof HTMLDialogElement !== 'undefined' && !('closedBy' in HTMLDialogElement.prototype)) {
1213
1258
  var rect = el.getBoundingClientRect()
1214
1259
  var inside = e.clientX >= rect.left && e.clientX <= rect.right &&
1215
1260
  e.clientY >= rect.top && e.clientY <= rect.bottom
@@ -1217,9 +1262,15 @@ function makeEvidenceDialog(React) {
1217
1262
  }
1218
1263
  }
1219
1264
 
1265
+ var stages = ['1/4 攒下了', '2/4 讲过一轮', '3/4 能复述', '4/4 能接住追问']
1266
+ var currTier = item ? clampTier(item.masteryTier || 1) : 1
1267
+ var trackTitle = (item && item.trackTitle) || ''
1268
+
1220
1269
  return h('dialog', {
1221
1270
  ref: dlgRef,
1271
+ id: 'ilp-skill-dialog',
1222
1272
  className: 'ilp-dialog',
1273
+ 'data-testid': 'ilp-skill-dialog',
1223
1274
  closedby: 'any',
1224
1275
  'aria-labelledby': item ? 'ilp-dlg-heading' : undefined,
1225
1276
  onClose: handleNativeClose,
@@ -1227,51 +1278,183 @@ function makeEvidenceDialog(React) {
1227
1278
  },
1228
1279
  item ? h(React.Fragment, null,
1229
1280
  h('div', { className: 'ilp-dlg-head' },
1230
- h('h2', { id: 'ilp-dlg-heading', className: 'ilp-dlg-title' }, item.title),
1281
+ h('div', null,
1282
+ h('div', { className: 'ilp-eyebrow' },
1283
+ (trackTitle ? (trackTitle + ' · ') : '') + '经验手卡',
1284
+ ),
1285
+ h('h2', { id: 'ilp-dlg-heading', className: 'ilp-dlg-title', style: { marginTop: '3px' } }, item.title),
1286
+ ),
1231
1287
  h('button', {
1232
1288
  type: 'button',
1233
1289
  className: 'ilp-btn ghost sm',
1290
+ 'data-testid': 'ilp-skill-dialog-x',
1234
1291
  onClick: function () { if (props.onClose) props.onClose() },
1235
1292
  }, '关闭'),
1236
1293
  ),
1237
1294
  h('div', { className: 'ilp-dlg-body' },
1238
- h('div', { className: 'ilp-item-badges' },
1295
+ h('div', { className: 'ilp-item-badges', style: { display: 'flex', flexWrap: 'wrap', alignItems: 'center', gap: '6px' } },
1239
1296
  sourceTag(h, item.source),
1240
1297
  epistemicTag(h, item.epistemic),
1241
1298
  makeMasteryMeter(h, item.masteryTier),
1242
1299
  ),
1243
- item.why ? h('div', null,
1244
- h('div', { className: 'ilp-shield-k' }, '为什么这么做'),
1245
- h('p', { style: { marginTop: '3px' } }, item.why),
1246
- ) : null,
1247
- item.rejected ? h('div', null,
1248
- h('div', { className: 'ilp-shield-k' }, '避开的坑'),
1249
- h('p', { style: { marginTop: '3px' } }, item.rejected),
1300
+ h('div', { className: 'ilp-stage-track' },
1301
+ stages.map(function (lbl, idx) {
1302
+ var n = idx + 1
1303
+ var cls = 'ilp-stage-node'
1304
+ if (n < currTier || (n === 4 && currTier >= 4)) cls += ' done'
1305
+ else if (n === currTier) cls += ' curr'
1306
+ return h('div', { key: String(n), className: cls }, lbl)
1307
+ }),
1308
+ ),
1309
+ (item.why || item.rejected) ? h('div', { className: 'ilp-compare-grid' },
1310
+ item.why ? h('div', { className: 'ilp-compare-card good' },
1311
+ h('div', { className: 'ilp-compare-k' }, '核心取舍'),
1312
+ item.why,
1313
+ ) : null,
1314
+ item.rejected ? h('div', { className: 'ilp-compare-card bad' },
1315
+ h('div', { className: 'ilp-compare-k' }, '被排除的坑'),
1316
+ item.rejected,
1317
+ ) : null,
1250
1318
  ) : null,
1251
- item.probe ? h('div', { className: 'ilp-shield-probe' },
1319
+ item.probe ? h('div', { className: 'ilp-drawer-q' },
1252
1320
  h('span', { className: 'ilp-shield-k', style: { marginRight: '6px' } }, '顺手想一下'),
1253
1321
  item.probe,
1254
1322
  ) : null,
1255
1323
  item.evidenceSummary ? h('div', { className: 'ilp-drawer-fb' },
1256
- h('div', { className: 'ilp-shield-k' }, '学习记录'),
1324
+ h('div', { className: 'ilp-shield-k' }, '学习与过关记录'),
1257
1325
  h('p', null, item.evidenceSummary),
1258
1326
  ) : null,
1259
1327
  ),
1260
1328
  h('div', { className: 'ilp-dlg-foot' },
1329
+ h('div', { className: 'ilp-dlg-foot-main' },
1330
+ h('button', {
1331
+ type: 'button',
1332
+ className: 'ilp-btn solid sm',
1333
+ 'data-testid': 'ilp-skill-dialog-drill',
1334
+ onClick: function () {
1335
+ var chosen = item
1336
+ if (props.onClose) props.onClose()
1337
+ if (props.onStartDrill) props.onStartDrill(chosen)
1338
+ },
1339
+ }, '去会话 1 对 1 闯关升级'),
1340
+ h('button', {
1341
+ type: 'button',
1342
+ className: 'ilp-btn ghost sm',
1343
+ 'data-testid': 'ilp-skill-dialog-copy',
1344
+ onClick: function () {
1345
+ var summaryText = [item.title, item.why ? ('核心取舍:' + item.why) : '', item.rejected ? ('避开的坑:' + item.rejected) : ''].filter(Boolean).join('\n')
1346
+ if (typeof navigator !== 'undefined' && navigator.clipboard && navigator.clipboard.writeText) {
1347
+ navigator.clipboard.writeText(summaryText).catch(function () {})
1348
+ }
1349
+ if (props.onCopied) props.onCopied(item.title)
1350
+ },
1351
+ }, '复制手卡摘要'),
1352
+ ),
1261
1353
  h('button', {
1262
1354
  type: 'button',
1263
1355
  className: 'ilp-btn line sm',
1356
+ 'data-testid': 'ilp-skill-dialog-close',
1264
1357
  onClick: function () { if (props.onClose) props.onClose() },
1265
- }, '先回列表'),
1358
+ }, '完成收起'),
1359
+ ),
1360
+ ) : null,
1361
+ )
1362
+ }
1363
+ }
1364
+
1365
+ // Native <dialog closedby="any"> Modal #2: 15-Minute Cross-Topic Sprint Action (replaces old separate Tab)
1366
+ function makeSprintDialog(React) {
1367
+ return function SprintDialog(props) {
1368
+ var h = React.createElement
1369
+ var dlgRef = React.useRef(null)
1370
+ var open = !!(props && props.open)
1371
+ var stations = (props && Array.isArray(props.stations)) ? props.stations : []
1372
+
1373
+ React.useEffect(function () {
1374
+ var el = dlgRef.current
1375
+ if (!el) return
1376
+ if (open && stations.length > 0) {
1377
+ if (!el.open && typeof el.showModal === 'function') {
1378
+ try { el.showModal() } catch (_e) {}
1379
+ }
1380
+ } else if (el.open && typeof el.close === 'function') {
1381
+ try { el.close() } catch (_e) {}
1382
+ }
1383
+ }, [open, stations.length])
1384
+
1385
+ function handleNativeClose() {
1386
+ if (props.onClose) props.onClose()
1387
+ }
1388
+
1389
+ function handleDialogClick(e) {
1390
+ var el = dlgRef.current
1391
+ if (!el || !open) return
1392
+ if (typeof HTMLDialogElement !== 'undefined' && !('closedBy' in HTMLDialogElement.prototype)) {
1393
+ var rect = el.getBoundingClientRect()
1394
+ var inside = e.clientX >= rect.left && e.clientX <= rect.right &&
1395
+ e.clientY >= rect.top && e.clientY <= rect.bottom
1396
+ if (!inside && props.onClose) props.onClose()
1397
+ }
1398
+ }
1399
+
1400
+ var totalMins = Math.max(5, stations.length * 5)
1401
+
1402
+ return h('dialog', {
1403
+ ref: dlgRef,
1404
+ id: 'ilp-sprint-dialog',
1405
+ className: 'ilp-dialog',
1406
+ 'data-testid': 'ilp-sprint-dialog',
1407
+ closedby: 'any',
1408
+ 'aria-labelledby': open ? 'ilp-sprint-heading' : undefined,
1409
+ onClose: handleNativeClose,
1410
+ onClick: handleDialogClick,
1411
+ },
1412
+ open && stations.length > 0 ? h(React.Fragment, null,
1413
+ h('div', { className: 'ilp-dlg-head' },
1414
+ h('div', null,
1415
+ h('div', { className: 'ilp-eyebrow' }, '动作化串联复盘 · 不单占标签页'),
1416
+ h('h2', { id: 'ilp-sprint-heading', className: 'ilp-dlg-title', style: { marginTop: '3px' } },
1417
+ '连抽 ' + stations.length + ' 条考考我(约 ' + totalMins + ' 分钟)',
1418
+ ),
1419
+ ),
1420
+ h('button', {
1421
+ type: 'button',
1422
+ className: 'ilp-btn ghost sm',
1423
+ onClick: function () { if (props.onClose) props.onClose() },
1424
+ }, '关闭'),
1425
+ ),
1426
+ h('div', { className: 'ilp-dlg-body' },
1427
+ h('p', { style: { fontSize: '13px', color: 'var(--ilp-ink2)' } },
1428
+ '系统按你当前的未吃透手账,自动抽了下面 ' + stations.length + ' 条组成连续闯关:',
1429
+ ),
1430
+ stations.map(function (st, idx) {
1431
+ return h('div', { key: String(st.itemId || idx), className: 'ilp-station' },
1432
+ h('div', { className: 'ilp-station-num' }, String(st.station || (idx + 1))),
1433
+ h('div', { style: { minWidth: 0 } },
1434
+ h('div', { style: { fontSize: '13.5px', fontWeight: 600, color: 'var(--ilp-ink)', overflowWrap: 'anywhere' } }, st.title),
1435
+ h('div', { className: 'ilp-row-sub' }, (st.masteryLabel || '') + ' · ' + (st.focus || '盲测澄清关键取舍')),
1436
+ ),
1437
+ h('span', { className: 'ilp-eyebrow' }, '约 ' + (st.durationMin || 5) + ' 分钟'),
1438
+ )
1439
+ }),
1440
+ ),
1441
+ h('div', { className: 'ilp-dlg-foot' },
1266
1442
  h('button', {
1267
1443
  type: 'button',
1268
1444
  className: 'ilp-btn solid sm',
1445
+ 'data-testid': 'ilp-sprint-start-btn',
1269
1446
  onClick: function () {
1270
- var chosen = item
1447
+ var picked = stations.slice()
1271
1448
  if (props.onClose) props.onClose()
1272
- if (props.onStartDrill) props.onStartDrill(chosen)
1449
+ if (props.onStartSprint) props.onStartSprint(picked)
1273
1450
  },
1274
- }, '去会话里展开练'),
1451
+ }, '去新会话连考这几条 ->'),
1452
+ h('button', {
1453
+ type: 'button',
1454
+ className: 'ilp-btn line sm',
1455
+ 'data-testid': 'ilp-sprint-close-btn',
1456
+ onClick: function () { if (props.onClose) props.onClose() },
1457
+ }, '先不考'),
1275
1458
  ),
1276
1459
  ) : null,
1277
1460
  )
@@ -1286,7 +1469,7 @@ function openStarterChatSession(ctx) {
1286
1469
  var uiWorkspace = getHostService(ctx, 'uiWorkspace')
1287
1470
  var sessions = getHostService(ctx, 'sessions')
1288
1471
  var conv = getHostService(ctx, 'conversation') || getHostService(ctx, 'conversations')
1289
- var starterPrompt = '帮我检查一下当前项目的结构与改动方案,如果遇到值得留心的工程、架构或前端设计经验,干完顺手附一张顺带学习卡。'
1472
+ var starterPrompt = '帮我检查一下当前项目的结构与改动方案,如果遇到值得留心的反直觉踩坑或架构设计取舍,干完顺手附一张顺带学习卡。'
1290
1473
  return postLearnAction('ensure_practice_workspace', {}).catch(function () { return null }).then(function (res) {
1291
1474
  var wsId = (res && res.workspace && res.workspace.workspaceId) || undefined
1292
1475
  if (uiWorkspace && typeof uiWorkspace.openWorkspace === 'function' && wsId) {
@@ -1309,49 +1492,49 @@ var SIM_OUTCOMES = {
1309
1492
  chatBadge: '放在那没点',
1310
1493
  chatBadgeClass: 'ilp-tag',
1311
1494
  collapsed: false,
1312
- wbTitle: '顺带私教里',
1313
- wbBadge: '后台自动存档 +1',
1495
+ wbTitle: '顺带私教 · 一本手账',
1496
+ wbBadge: '手账顶部 +1 · 新抓到未看',
1314
1497
  wbBadgeClass: 'ilp-tag wait',
1315
- wbHeading: '自动收进「后台自动存档」',
1316
- wbLine1: '不用手动保存,卡片已经在后台静默存好',
1317
- wbLine2: '忙完手头的事,随时点进来集中翻看和学习',
1318
- takeaway: '正忙着干活时完全不用管它,后台会自动帮你存档,一条都不会丢。',
1498
+ wbHeading: '直接铺进手账顶部(少点一次直达)',
1499
+ wbLine1: '严选确认属于反直觉踩坑或架构权衡后,自动放到唯一手账最顶部,左琥珀条标为「新抓到 · 未看」',
1500
+ wbLine2: '单会话限频防刷屏;如果以后积压超 3 条,第 4 条起自动收进一行折叠条,绝不淹没已学技能',
1501
+ takeaway: '平时正忙着干活时完全不用管它:高价值经验直接落进同一本手账顶部,闲下来不用跨页搬家,原地就能测。',
1319
1502
  },
1320
1503
  coach: {
1321
- chatBadge: '右侧展开学习',
1504
+ chatBadge: '右侧边聊边测',
1322
1505
  chatBadgeClass: 'ilp-tag run',
1323
1506
  collapsed: false,
1324
1507
  wbTitle: '对话右侧学习栏',
1325
- wbBadge: '不影响当前聊天',
1508
+ wbBadge: '原地升到 2/4 · 零打扰',
1326
1509
  wbBadgeClass: 'ilp-tag run',
1327
- wbHeading: '在右边顺手把这个知识点聊透',
1328
- wbLine1: '只在右侧划开独立小窗口展开讲,不打乱原来的对话',
1329
- wbLine2: '花一两分钟弄明白,直接沉淀进你的个人技能库',
1330
- takeaway: '手头刚好有空时点一下,在右边花一两分钟直接把这条经验学明白。',
1510
+ wbHeading: '在右边 1 分钟做道盲选题弄透',
1511
+ wbLine1: '只在右侧划开独立抽屉问一题,绝不覆写你底部正在打字的原生对话草稿',
1512
+ wbLine2: '答完自动标为「2/4 讲过一轮」,顺滑留在你的同一本手账里',
1513
+ takeaway: '手头刚好有空时点一下,直接在右侧抽屉 1 分钟摸底学透,不影响主对话流。',
1331
1514
  },
1332
1515
  save: {
1333
- chatBadge: '已存技能库',
1516
+ chatBadge: '已标优先留存',
1334
1517
  chatBadgeClass: 'ilp-tag run',
1335
1518
  collapsed: false,
1336
- wbTitle: '顺带私教里',
1337
- wbBadge: '已存进技能库',
1519
+ wbTitle: '顺带私教 · 一本手账',
1520
+ wbBadge: '计入 1/4 留存学习',
1338
1521
  wbBadgeClass: 'ilp-tag run',
1339
- wbHeading: '直接放进「个人技能库」',
1340
- wbLine1: '觉得这条经验很实用,先正式存进对应分类里',
1341
- wbLine2: '下次点进顺带私教时优先排在前面,方便随时开练',
1342
- takeaway: '适合眼下没空细看、但确定值得留下慢慢消化的实用经验。',
1522
+ wbHeading: '直接转正进手账「学习中」优先列',
1523
+ wbLine1: '不再只是自动抓的「未看」,直接作为你明确要学的技能排进「今日优先吃透」候选',
1524
+ wbLine2: '随时点「10 秒快测」或进新会话 1 对 1 闯关升级到 4/4',
1525
+ takeaway: '眼下赶工没空细读、但一眼认定必须学会的经验,点一下直接标成自己要学的正式项。',
1343
1526
  },
1344
1527
  dismiss: {
1345
- chatBadge: '已收起卡片',
1528
+ chatBadge: '已学会 · 折成窄条',
1346
1529
  chatBadgeClass: 'ilp-tag ok',
1347
1530
  collapsed: true,
1348
- wbTitle: '顺带私教里',
1349
- wbBadge: '不再重复存档',
1531
+ wbTitle: '顺带私教 · 一本手账',
1532
+ wbBadge: '写入防重抓名单',
1350
1533
  wbBadgeClass: 'ilp-tag ok',
1351
- wbHeading: '卡片折成窄条,后台也不再存它',
1352
- wbLine1: '对话里的卡片立刻折成一行,界面清清爽爽',
1353
- wbLine2: '说明这块你本来就会,以后同类问题不再重复提醒',
1354
- takeaway: '遇到你早就熟悉的内容点一下,当场收起不占地方,也不往存档里塞。',
1534
+ wbHeading: '从手账隐藏,以后同坑不再重复抓',
1535
+ wbLine1: '对话里的卡片立即折成一条细虚线,界面保持清清爽爽',
1536
+ wbLine2: 'cardKey 进入后台去重黑名单,后续对话也不会再反复提醒你早就熟的内容',
1537
+ takeaway: '早就驾轻就熟的东西点一下「已掌握」,当场收起,手账也不会越攒越乱。',
1355
1538
  },
1356
1539
  }
1357
1540
 
@@ -1443,20 +1626,20 @@ function makeVisualGuideComponent(React) {
1443
1626
  // Tier 1: Open Editorial Hero
1444
1627
  h('section', { className: 'ilp-hero' },
1445
1628
  h('div', { className: 'ilp-hero-top' },
1446
- h('span', { className: 'ilp-hero-kicker' }, isEmpty ? '刚装好 · 一眼看懂怎么用' : '使用说明 · 看完可随时收起'),
1629
+ h('span', { className: 'ilp-hero-kicker' }, isEmpty ? '刚装好 · 一眼看懂怎么用' : '工作原理图 · 看完可随时收起'),
1447
1630
  !isEmpty && props && props.onClose ? h('button', {
1448
1631
  type: 'button',
1449
1632
  className: 'ilp-btn ghost xs',
1450
1633
  'data-testid': 'ilp-close-guide-btn',
1451
1634
  onClick: props.onClose,
1452
- }, '收起说明') : null,
1635
+ }, '收起原理图') : null,
1453
1636
  ),
1454
- h('h2', { className: 'ilp-hero-lead' }, '平时跟 Agent 协作干活,顺带学点经验、沉淀自己的技能'),
1455
- h('p', { className: 'ilp-hero-sub' }, '不用专门抽空上课;你照常派活,遇到值得留心的经验,系统会顺手帮你攒下来。'),
1637
+ h('h2', { className: 'ilp-hero-lead' }, '平时跟 Agent 协作干活,顺手攒下关键经验、10 秒测成自己的本事'),
1638
+ h('p', { className: 'ilp-hero-sub' }, '不用专门抽空上课,也不用跨页搬卡片;严选门禁只在「反直觉踩坑 / 架构权衡」时附卡,直接落进同一本手账。'),
1456
1639
  h('div', { className: 'ilp-onb-cta' },
1457
1640
  h('button', {
1458
1641
  type: 'button',
1459
- className: isEmpty ? 'ilp-btn solid' : 'ilp-btn line',
1642
+ className: isEmpty ? 'ilp-btn solid sm' : 'ilp-btn line sm',
1460
1643
  'data-testid': 'ilp-start-chat-cta',
1461
1644
  onClick: function () { if (props && props.onStartChat) props.onStartChat() },
1462
1645
  },
@@ -1475,10 +1658,10 @@ function makeVisualGuideComponent(React) {
1475
1658
  ),
1476
1659
  isEmpty ? h('button', {
1477
1660
  type: 'button',
1478
- className: 'ilp-btn line',
1661
+ className: 'ilp-btn line sm',
1479
1662
  'data-testid': 'ilp-load-samples-btn',
1480
1663
  onClick: function () { if (props && props.onLoadSamples) props.onLoadSamples() },
1481
- }, '看看攒下卡片后长什么样') : null,
1664
+ }, '看看日常攒卡与防刷屏效果(不耗 Token)') : null,
1482
1665
  ),
1483
1666
  ),
1484
1667
 
@@ -1489,13 +1672,13 @@ function makeVisualGuideComponent(React) {
1489
1672
  h('div', { className: 'ilp-wf-user' },
1490
1673
  h('span', { className: 'ilp-wf-u-pill' },
1491
1674
  h('span', { className: 'ilp-wf-dot-role' }, '你'),
1492
- '帮修列表卡顿',
1675
+ '帮修列表滚动卡顿',
1493
1676
  ),
1494
- h('span', { className: 'ilp-wf-quiet' }, '普通杂活不打扰'),
1677
+ h('span', { className: 'ilp-wf-quiet' }, '普通杂活 0 打扰'),
1495
1678
  ),
1496
1679
  h('div', { className: 'ilp-wf-card' },
1497
1680
  h('div', { className: 'ilp-wf-card-head' },
1498
- h('span', null, '小学习卡'),
1681
+ h('span', null, '顺带学习卡 · 严选'),
1499
1682
  h('svg', {
1500
1683
  width: 11,
1501
1684
  height: 11,
@@ -1512,17 +1695,17 @@ function makeVisualGuideComponent(React) {
1512
1695
  h('span', { className: 'ilp-wf-skel w62' }),
1513
1696
  ),
1514
1697
  h('div', { className: 'ilp-wf-btn-row' },
1515
- h('span', { className: 'ilp-wf-mini-btn' }, '展开学习'),
1516
- h('span', { className: 'ilp-wf-mini-btn' }, '存技能库'),
1698
+ h('span', { className: 'ilp-wf-mini-btn' }, '边聊边测'),
1699
+ h('span', { className: 'ilp-wf-mini-btn' }, '存进手账'),
1517
1700
  h('span', { className: 'ilp-wf-mini-btn' }, '已掌握'),
1518
1701
  ),
1519
1702
  ),
1520
1703
  ),
1521
1704
  h('header', { className: 'ilp-step-head' },
1522
- h('span', { className: 'ilp-onb-num' }, '01 · 平时派活'),
1523
- h('h3', { className: 'ilp-onb-step-h' }, '对话末尾附张小学习卡'),
1705
+ h('span', { className: 'ilp-onb-num' }, '01 · 严选不刷屏'),
1706
+ h('h3', { className: 'ilp-onb-step-h' }, '回答末尾附张小学习卡'),
1524
1707
  ),
1525
- h('p', { className: 'ilp-onb-step-p' }, '日常派活照常进行,遇到值得学的经验才附一张小卡片。'),
1708
+ h('p', { className: 'ilp-onb-step-p' }, '只在遇到反直觉踩坑或跨项目取舍时附卡(单会话限频去重),日常改字查资料不打扰。'),
1526
1709
  ),
1527
1710
 
1528
1711
  makeConnectorSvg('ilp-conn-col-1'),
@@ -1531,7 +1714,7 @@ function makeVisualGuideComponent(React) {
1531
1714
  h('div', { className: 'ilp-scene', 'aria-hidden': 'true' },
1532
1715
  h('div', { className: 'ilp-branch-diag' },
1533
1716
  h('div', { className: 'ilp-branch-in' },
1534
- h('span', { className: 'ilp-branch-in-k' }, '看到卡片'),
1717
+ h('span', { className: 'ilp-branch-in-k' }, '看到小卡'),
1535
1718
  h('div', { className: 'ilp-branch-dots' },
1536
1719
  h('span', null),
1537
1720
  h('span', null),
@@ -1541,32 +1724,32 @@ function makeVisualGuideComponent(React) {
1541
1724
  h('svg', {
1542
1725
  className: 'ilp-branch-svg',
1543
1726
  width: 22,
1544
- height: 72,
1545
- viewBox: '0 0 22 72',
1727
+ height: 76,
1728
+ viewBox: '0 0 22 76',
1546
1729
  fill: 'none',
1547
1730
  },
1548
- h('path', { d: 'M0 36 C 9 36, 10 16, 20 16', stroke: 'var(--ilp-run)', strokeWidth: '1.5', strokeLinecap: 'round' }),
1549
- h('path', { d: 'M16.5 12.8 L20.5 16 L16.5 19.2', stroke: 'var(--ilp-run)', strokeWidth: '1.4', strokeLinecap: 'round', strokeLinejoin: 'round' }),
1550
- h('path', { d: 'M0 36 C 9 36, 10 56, 20 56', stroke: 'var(--ilp-wait)', strokeWidth: '1.6', strokeLinecap: 'round' }),
1551
- h('path', { d: 'M16.5 52.8 L20.5 56 L16.5 59.2', stroke: 'var(--ilp-wait)', strokeWidth: '1.5', strokeLinecap: 'round', strokeLinejoin: 'round' }),
1731
+ h('path', { d: 'M0 38 C 9 38, 10 17, 20 17', stroke: 'var(--ilp-run)', strokeWidth: '1.5', strokeLinecap: 'round' }),
1732
+ h('path', { d: 'M16.5 13.8 L20.5 17 L16.5 20.2', stroke: 'var(--ilp-run)', strokeWidth: '1.4', strokeLinecap: 'round', strokeLinejoin: 'round' }),
1733
+ h('path', { d: 'M0 38 C 9 38, 10 59, 20 59', stroke: 'var(--ilp-wait)', strokeWidth: '1.6', strokeLinecap: 'round' }),
1734
+ h('path', { d: 'M16.5 55.8 L20.5 59 L16.5 62.2', stroke: 'var(--ilp-wait)', strokeWidth: '1.5', strokeLinecap: 'round', strokeLinejoin: 'round' }),
1552
1735
  ),
1553
1736
  h('div', { className: 'ilp-branch-outs' },
1554
1737
  h('div', { className: 'ilp-branch-pill' },
1555
- h('b', null, '有空点一下'),
1556
- h('span', null, '当场展开学习'),
1738
+ h('b', null, '有空顺手点'),
1739
+ h('span', null, '右侧栏 1 分钟测透'),
1557
1740
  ),
1558
1741
  h('div', { className: 'ilp-branch-pill is-idle' },
1559
- h('b', null, '先放那不管'),
1560
- h('span', null, '后台自动存档 +1'),
1742
+ h('b', null, '正忙先不管'),
1743
+ h('span', null, '落入顶部 · 限铺 3'),
1561
1744
  ),
1562
1745
  ),
1563
1746
  ),
1564
1747
  ),
1565
1748
  h('header', { className: 'ilp-step-head' },
1566
- h('span', { className: 'ilp-onb-num' }, '02 · 忙时不点也没事'),
1567
- h('h3', { className: 'ilp-onb-step-h' }, '当场展开学,或先放着'),
1749
+ h('span', { className: 'ilp-onb-num' }, '02 · 一本手账零搬运'),
1750
+ h('h3', { className: 'ilp-onb-step-h' }, '直接落进同一列表顶栏'),
1568
1751
  ),
1569
- h('p', { className: 'ilp-onb-step-p' }, '有空就顺手点开看;正忙着干活不理它,后台也会自动存好。'),
1752
+ h('p', { className: 'ilp-onb-step-p' }, '不去第二个存档页来回倒腾;平时 1–3 张直接铺开少点一次,攒超 3 张自动折叠旧卡。'),
1570
1753
  ),
1571
1754
 
1572
1755
  makeConnectorSvg('ilp-conn-col-2'),
@@ -1594,13 +1777,10 @@ function makeVisualGuideComponent(React) {
1594
1777
  ),
1595
1778
  h('div', { className: 'ilp-delta-track' },
1596
1779
  h('div', { className: 'ilp-delta-node' },
1597
- h('span', { className: 'ilp-meter', 'data-tier': '1' },
1598
- h('span', { className: 'ilp-bars' }, h('span', null), h('span', null), h('span', null), h('span', null)),
1599
- h('span', { className: 'ilp-delta-tag wait' }, '1/4 自动存好'),
1600
- ),
1780
+ makeMasteryMeter(h, 0, '0/4 新抓到'),
1601
1781
  ),
1602
1782
  h('div', { className: 'ilp-delta-mid' },
1603
- h('span', null, '有空回来看'),
1783
+ h('span', null, '10s 快测'),
1604
1784
  h('svg', {
1605
1785
  width: 14,
1606
1786
  height: 10,
@@ -1616,18 +1796,15 @@ function makeVisualGuideComponent(React) {
1616
1796
  ),
1617
1797
  ),
1618
1798
  h('div', { className: 'ilp-delta-node' },
1619
- h('span', { className: 'ilp-meter', 'data-tier': '4' },
1620
- h('span', { className: 'ilp-bars' }, h('span', null), h('span', null), h('span', null), h('span', null)),
1621
- h('span', { className: 'ilp-delta-tag ok' }, '4/4 变成技能'),
1622
- ),
1799
+ makeMasteryMeter(h, 4, '4/4 已吃透'),
1623
1800
  ),
1624
1801
  ),
1625
1802
  ),
1626
1803
  h('header', { className: 'ilp-step-head' },
1627
- h('span', { className: 'ilp-onb-num' }, '03 · 随时回来看'),
1628
- h('h3', { className: 'ilp-onb-step-h' }, '集中翻看,沉淀成技能'),
1804
+ h('span', { className: 'ilp-onb-num' }, '03 · 测过才算数'),
1805
+ h('h3', { className: 'ilp-onb-step-h' }, '10 秒快测或 1 对 1 闯关'),
1629
1806
  ),
1630
- h('p', { className: 'ilp-onb-step-p' }, '各处攒下的卡片都收在这里,闲时集中看懂,变成自己的本事。'),
1807
+ h('p', { className: 'ilp-onb-step-p' }, '行内答对盲选题原地升 2/4;彻底吃透要靠新会话换项目追问过关。'),
1631
1808
  ),
1632
1809
  ),
1633
1810
 
@@ -1647,7 +1824,7 @@ function makeVisualGuideComponent(React) {
1647
1824
  strokeLinejoin: 'round',
1648
1825
  'aria-hidden': 'true',
1649
1826
  }, h('path', { d: 'M6 3.5l4.5 4.5-4.5 4.5' })),
1650
- h('span', null, '想先试试卡片上的按钮点完会怎样?(点开体验)'),
1827
+ h('span', null, '想先试试对话里那张小卡片点完会怎样?(点开体验)'),
1651
1828
  ),
1652
1829
  h('span', { className: 'ilp-tag' }, '点按实时预览'),
1653
1830
  ),
@@ -1661,12 +1838,12 @@ function makeVisualGuideComponent(React) {
1661
1838
  focusgroup: 'toolbar wrap',
1662
1839
  },
1663
1840
  h('div', { className: 'ilp-sim-group', role: 'group', 'aria-label': '学习卡操作按钮' },
1664
- makeSimToolbarButton('coach', '当场展开学', ''),
1665
- makeSimToolbarButton('save', '存进技能库', ''),
1841
+ makeSimToolbarButton('coach', '右侧边聊边测', ''),
1842
+ makeSimToolbarButton('save', '标为优先学', ''),
1666
1843
  makeSimToolbarButton('dismiss', '已掌握,收起', ''),
1667
1844
  ),
1668
1845
  h('span', { role: 'separator', 'aria-orientation': 'vertical', className: 'ilp-sim-sep' }),
1669
- makeSimToolbarButton('idle', '先放那不管(默认)', 'is-idle'),
1846
+ makeSimToolbarButton('idle', '正忙先不管(默认)', 'is-idle'),
1670
1847
  ),
1671
1848
  h('div', {
1672
1849
  id: 'ilp-sim-outcome-stage',
@@ -1682,7 +1859,7 @@ function makeVisualGuideComponent(React) {
1682
1859
  h('span', { className: activeSim.chatBadgeClass }, activeSim.chatBadge),
1683
1860
  ),
1684
1861
  h('div', { className: 'ilp-mini-win-body' },
1685
- h('div', { className: 'ilp-mini-prose' }, 'AI 回复:列表滚动卡顿已经修好了,主要补了一行容器规则。'),
1862
+ h('div', { className: 'ilp-mini-prose' }, 'AI 回复:列表滚动卡顿已修好,关键补了一行容器约束。'),
1686
1863
  h('div', { className: 'ilp-mini-embed', hidden: activeSim.collapsed },
1687
1864
  h('span', { className: 'ilp-mini-embed-title' }, 'flex:1 与 min-height:0 怎么配合才不卡'),
1688
1865
  h('div', { className: 'ilp-wf-lines' },
@@ -1690,8 +1867,8 @@ function makeVisualGuideComponent(React) {
1690
1867
  h('span', { className: 'ilp-wf-skel w62' }),
1691
1868
  ),
1692
1869
  h('div', { className: 'ilp-mini-embed-pills' },
1693
- h('span', { className: 'ilp-mini-pill' + (simMode === 'coach' ? ' is-hi' : '') }, '在右侧边聊边学'),
1694
- h('span', { className: 'ilp-mini-pill' + (simMode === 'save' ? ' is-hi' : '') }, '存进技能库'),
1870
+ h('span', { className: 'ilp-mini-pill' + (simMode === 'coach' ? ' is-hi' : '') }, '右侧边聊边测'),
1871
+ h('span', { className: 'ilp-mini-pill' + (simMode === 'save' ? ' is-hi' : '') }, '标为优先学'),
1695
1872
  h('span', { className: 'ilp-mini-pill' + (simMode === 'dismiss' ? ' is-hi' : '') }, '已掌握,收起'),
1696
1873
  ),
1697
1874
  ),
@@ -1738,9 +1915,10 @@ function makeVisualGuideComponent(React) {
1738
1915
  }
1739
1916
  }
1740
1917
 
1741
- // 2. Main Workbench (`main`, key: 'incidental-learn')
1918
+ // 2. Main Workbench (`main`, key: 'incidental-learn') — Plan A Unified Single-Ledger Workbench
1742
1919
  function makeWorkbenchComponent(React, ctx, bridge) {
1743
1920
  var EvidenceDialog = makeEvidenceDialog(React)
1921
+ var SprintDialog = makeSprintDialog(React)
1744
1922
  var VisualGuide = makeVisualGuideComponent(React)
1745
1923
 
1746
1924
  return function IncidentalLearnWorkbench() {
@@ -1749,14 +1927,6 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1749
1927
  var bridgeState = stateTuple[0]
1750
1928
  var setBridgeState = stateTuple[1]
1751
1929
 
1752
- var triageOpenTuple = React.useState(false)
1753
- var triageOpen = triageOpenTuple[0]
1754
- var setTriageOpen = triageOpenTuple[1]
1755
-
1756
- var expandedTrackTuple = React.useState({})
1757
- var expandedTracks = expandedTrackTuple[0]
1758
- var setExpandedTracks = expandedTrackTuple[1]
1759
-
1760
1930
  var directTopicTuple = React.useState('')
1761
1931
  var directTopic = directTopicTuple[0]
1762
1932
  var setDirectTopic = directTopicTuple[1]
@@ -1769,13 +1939,33 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1769
1939
  var startingDirect = startingDirectTuple[0]
1770
1940
  var setStartingDirect = startingDirectTuple[1]
1771
1941
 
1772
- var courseOpenTuple = React.useState(false)
1773
- var courseOpen = courseOpenTuple[0]
1774
- var setCourseOpen = courseOpenTuple[1]
1942
+ var statusFilterTuple = React.useState('all')
1943
+ var statusFilter = statusFilterTuple[0]
1944
+ var setStatusFilter = statusFilterTuple[1]
1945
+
1946
+ var trackFilterTuple = React.useState('all')
1947
+ var trackFilter = trackFilterTuple[0]
1948
+ var setTrackFilter = trackFilterTuple[1]
1775
1949
 
1776
- var activeCourseTuple = React.useState(null)
1777
- var activeCourse = activeCourseTuple[0]
1778
- var setActiveCourse = activeCourseTuple[1]
1950
+ var olderOpenTuple = React.useState(false)
1951
+ var olderUnreadOpen = olderOpenTuple[0]
1952
+ var setOlderUnreadOpen = olderOpenTuple[1]
1953
+
1954
+ var expandedQuizTuple = React.useState(null)
1955
+ var expandedQuizId = expandedQuizTuple[0]
1956
+ var setExpandedQuizId = expandedQuizTuple[1]
1957
+
1958
+ var quizAnsTuple = React.useState({})
1959
+ var quizAnswers = quizAnsTuple[0]
1960
+ var setQuizAnswers = quizAnsTuple[1]
1961
+
1962
+ var sprintOpenTuple = React.useState(false)
1963
+ var sprintOpen = sprintOpenTuple[0]
1964
+ var setSprintOpen = sprintOpenTuple[1]
1965
+
1966
+ var sprintStationsTuple = React.useState([])
1967
+ var sprintStations = sprintStationsTuple[0]
1968
+ var setSprintStations = sprintStationsTuple[1]
1779
1969
 
1780
1970
  var modalItemTuple = React.useState(null)
1781
1971
  var modalItem = modalItemTuple[0]
@@ -1797,7 +1987,7 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1797
1987
  var guideOpen = guideOpenTuple[0]
1798
1988
  var setGuideOpen = guideOpenTuple[1]
1799
1989
 
1800
- var autoOpenedTriageRef = React.useRef(false)
1990
+ var intentInputRef = React.useRef(null)
1801
1991
 
1802
1992
  React.useEffect(function () {
1803
1993
  ensureStyleInjected()
@@ -1812,44 +2002,18 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1812
2002
  }
1813
2003
  }, [])
1814
2004
 
1815
- var currentSnap = bridgeState.snapshot
1816
- var currentStats = (currentSnap && currentSnap.stats) || { totalItems: 0 }
1817
- var currentTriageLen = (currentSnap && currentSnap.triage && currentSnap.triage.length) || 0
1818
-
1819
- React.useEffect(function () {
1820
- if (currentStats.totalItems === 0 && currentTriageLen > 0) {
1821
- if (!autoOpenedTriageRef.current) {
1822
- autoOpenedTriageRef.current = true
1823
- setTriageOpen(true)
1824
- }
1825
- } else {
1826
- autoOpenedTriageRef.current = false
1827
- if (currentTriageLen === 0 && triageOpen) {
1828
- setTriageOpen(false)
1829
- }
1830
- }
1831
- }, [currentStats.totalItems, currentTriageLen, triageOpen])
1832
-
1833
2005
  function showToast(text, canUndo) {
1834
2006
  setToast({ text: text, canUndo: !!canUndo })
1835
2007
  }
1836
2008
 
1837
- function toggleTrack(id, currentlyOpen) {
1838
- setExpandedTracks(function (prev) {
1839
- var next = Object.assign({}, prev)
1840
- next[id] = !currentlyOpen
1841
- return next
1842
- })
1843
- }
1844
-
1845
2009
  var workspaces = Array.isArray(bridgeState.workspaces) ? bridgeState.workspaces : []
1846
2010
  var effectiveWsId = selectedWsId || (workspaces[0] && workspaces[0].id) || undefined
1847
2011
 
1848
2012
  var DIRECT_TOPICS = [
1849
- '复盘当前工作区刚改过的关键取舍',
1850
- '前端自适应布局与原生组件避坑',
1851
- '接口边界、并发写盘与架构取舍',
1852
- 'Agent 提示词省流与工具设计',
2013
+ '复盘刚才改过的关键取舍',
2014
+ 'CSS 容器查询与 Flex 避坑',
2015
+ '接口边界与并发写盘',
2016
+ 'Agent 提示词省流',
1853
2017
  ]
1854
2018
 
1855
2019
  function handleStartDirectStudy(e) {
@@ -1877,13 +2041,19 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1877
2041
  })
1878
2042
  }
1879
2043
 
1880
- function handleDrillTriage(cand) {
1881
- if (!cand) return
1882
- bridge.runAction('triage_item', { id: cand.id, decision: 'accept' }).then(function (res) {
1883
- var item = (res && res.item) || cand
1884
- return openDeepLearnSession(ctx, item, effectiveWsId)
1885
- }).catch(function (err) {
1886
- showToast('开启专心学习失败:' + err.message, false)
2044
+ function handleDrillRow(row) {
2045
+ if (!row) return
2046
+ if (row.kind === 'unread') {
2047
+ bridge.runAction('triage_item', { id: row.id, decision: 'accept' }).then(function (res) {
2048
+ var item = (res && res.item) || row.raw
2049
+ return openDeepLearnSession(ctx, item, effectiveWsId)
2050
+ }).catch(function (err) {
2051
+ showToast('开启专心学习失败:' + err.message, false)
2052
+ })
2053
+ return
2054
+ }
2055
+ openDeepLearnSession(ctx, row.raw, effectiveWsId).catch(function (err) {
2056
+ showToast('打开闯关会话失败:' + err.message, false)
1887
2057
  })
1888
2058
  }
1889
2059
 
@@ -1891,8 +2061,11 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1891
2061
  bridge.runAction('load_sample_pack', {}).then(function () {
1892
2062
  setIsPreviewSamples(true)
1893
2063
  setGuideOpen(false)
1894
- setTriageOpen(false)
1895
- showToast('已载入多 Agent 演示样本', true)
2064
+ setStatusFilter('all')
2065
+ setTrackFilter('all')
2066
+ setOlderUnreadOpen(false)
2067
+ setExpandedQuizId(null)
2068
+ showToast('已载入多 Agent 演示样本(含 6 条未看防刷屏示范)', true)
1896
2069
  }).catch(function (err) {
1897
2070
  showToast('加载失败:' + err.message, false)
1898
2071
  })
@@ -1902,53 +2075,83 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1902
2075
  bridge.runAction('reset_empty', {}).then(function () {
1903
2076
  setIsPreviewSamples(false)
1904
2077
  setGuideOpen(false)
1905
- setCourseOpen(false)
2078
+ setSprintOpen(false)
1906
2079
  setExportInfo(null)
1907
- setTriageOpen(false)
2080
+ setOlderUnreadOpen(false)
2081
+ setExpandedQuizId(null)
2082
+ setQuizAnswers({})
2083
+ setStatusFilter('all')
2084
+ setTrackFilter('all')
1908
2085
  setDirectTopic('')
1909
- setExpandedTracks({})
1910
- autoOpenedTriageRef.current = false
1911
2086
  showToast('已清空恢复空台账', true)
1912
2087
  }).catch(function () {})
1913
2088
  }
1914
2089
 
1915
- function handleStartDeepDrill(item) {
1916
- if (!item) return
1917
- openDeepLearnSession(ctx, item, effectiveWsId).catch(function (err) {
1918
- showToast('打开闯关会话失败:' + err.message, false)
2090
+ function handleDeleteUnread(row) {
2091
+ if (!row) return
2092
+ bridge.runAction('triage_item', { id: row.id, decision: 'skip' }).then(function (res) {
2093
+ if (expandedQuizId === row.id) setExpandedQuizId(null)
2094
+ showToast('已从手账删掉该条', !!(res && res.snapshot && res.snapshot.canUndo))
2095
+ }).catch(function (err) {
2096
+ showToast('删除失败:' + err.message, false)
1919
2097
  })
1920
2098
  }
1921
2099
 
1922
- function handleTriageOne(id, decision) {
1923
- bridge.runAction('triage_item', { id: id, decision: decision }).then(function (res) {
1924
- showToast(decision === 'accept' ? '已存进个人技能库' : '已删掉该存档', !!(res && res.snapshot && res.snapshot.canUndo))
2100
+ function handleClearAllUnread() {
2101
+ bridge.runAction('triage_batch', { mode: 'clear_all' }).then(function (res) {
2102
+ var count = (res && res.affected) || 0
2103
+ setStatusFilter('all')
2104
+ setOlderUnreadOpen(false)
2105
+ setExpandedQuizId(null)
2106
+ showToast('已清掉 ' + count + ' 条未看', true)
1925
2107
  }).catch(function (err) {
1926
- showToast('操作失败:' + err.message, false)
2108
+ showToast('清理失败:' + err.message, false)
1927
2109
  })
1928
2110
  }
1929
2111
 
1930
- function handleTriageBatch(mode) {
1931
- bridge.runAction('triage_batch', { mode: mode }).then(function (res) {
2112
+ function handleClearOlderUnread() {
2113
+ bridge.runAction('triage_batch', { mode: 'clear_older', keep: MAX_DIRECT_UNREAD }).then(function (res) {
1932
2114
  var count = (res && res.affected) || 0
1933
- var msg = mode === 'clear_all'
1934
- ? ('已清空 ' + count + ' 张自动存档')
1935
- : (mode === 'accept_all' ? ('已一键存进 ' + count + ' 条技能') : ('已清理 ' + count + ' 条低价值存档'))
1936
- showToast(msg, true)
2115
+ setOlderUnreadOpen(false)
2116
+ showToast('已清掉 ' + count + ' 条较早未看,保留最新 ' + MAX_DIRECT_UNREAD + ' 条', true)
1937
2117
  }).catch(function (err) {
1938
- showToast('批量处理失败:' + err.message, false)
2118
+ showToast('清理失败:' + err.message, false)
1939
2119
  })
1940
2120
  }
1941
2121
 
1942
- function handleBuildCourse() {
1943
- if (courseOpen) {
1944
- setCourseOpen(false)
1945
- return
1946
- }
2122
+ function handleUpgradeInlineQuiz(row, ans) {
2123
+ if (!row || !ans) return
2124
+ var note = '在手账行内 10 秒快测选出 ' + ans.key + ':' + (ans.fb || row.why || '已拆清核心取舍与避开的坑。')
2125
+ bridge.runAction('record_micro_drill', {
2126
+ candId: row.id,
2127
+ card: row.raw,
2128
+ correct: !!ans.ok,
2129
+ toTier: 2,
2130
+ selectedKey: ans.key,
2131
+ evidenceNote: note,
2132
+ }).then(function (res) {
2133
+ setExpandedQuizId(null)
2134
+ setQuizAnswers(function (prev) {
2135
+ var next = Object.assign({}, prev)
2136
+ delete next[row.id]
2137
+ return next
2138
+ })
2139
+ showToast('已原地记为 2/4 讲过一轮,零搬运', !!(res && res.snapshot && res.snapshot.canUndo))
2140
+ }).catch(function (err) {
2141
+ showToast('升级记录失败:' + err.message, false)
2142
+ })
2143
+ }
2144
+
2145
+ function handleOpenSprintModal() {
1947
2146
  bridge.runAction('build_course', {}).then(function (res) {
1948
- setActiveCourse((res && res.course) || null)
1949
- setCourseOpen(true)
2147
+ var course = res && res.course
2148
+ var stations = (course && Array.isArray(course.stations) && course.stations.length > 0)
2149
+ ? course.stations
2150
+ : []
2151
+ setSprintStations(stations)
2152
+ setSprintOpen(true)
1950
2153
  }).catch(function (err) {
1951
- showToast('编排失败:' + err.message, false)
2154
+ showToast('连抽生成失败:' + err.message, false)
1952
2155
  })
1953
2156
  }
1954
2157
 
@@ -1979,11 +2182,11 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1979
2182
  if (!snap) {
1980
2183
  return h('div', { className: 'ilp-wb' },
1981
2184
  h('div', { className: 'ilp-wb-inner' },
1982
- h('div', { className: 'ilp-eyebrow' }, '平时协作攒经验 · 个人技能库'),
2185
+ h('div', { className: 'ilp-eyebrow' }, '平时协作攒经验 · 一本手账零搬运'),
1983
2186
  h('h1', { className: 'ilp-h1' }, '顺带私教'),
1984
2187
  bridgeState.error
1985
2188
  ? h('div', { className: 'ilp-empty-card' },
1986
- h('p', null, '读取个人技能库失败:' + bridgeState.error),
2189
+ h('p', null, '读取个人技能手账失败:' + bridgeState.error),
1987
2190
  h('button', {
1988
2191
  type: 'button',
1989
2192
  className: 'ilp-btn line sm',
@@ -1995,109 +2198,351 @@ function makeWorkbenchComponent(React, ctx, bridge) {
1995
2198
  )
1996
2199
  }
1997
2200
 
1998
- var stats = snap.stats || { masteredItems: 0, totalItems: 0, trackCount: 4, triageCount: 0 }
1999
- var tracks = snap.tracks || []
2000
- var populatedTracks = tracks.filter(function (t) { return t.items && t.items.length > 0 })
2001
- var emptyTrackNames = tracks.filter(function (t) { return !t.items || t.items.length === 0 }).map(function (t) { return t.title })
2002
- var firstPopTrackId = populatedTracks[0] ? populatedTracks[0].id : ''
2003
- var triage = snap.triage || []
2004
- var spotlight = snap.spotlight
2005
- var isCompletelyEmpty = stats.totalItems === 0 && triage.length === 0
2201
+ var tracks = Array.isArray(snap.tracks) ? snap.tracks : DEFAULT_TRACKS
2202
+ var triage = Array.isArray(snap.triage) ? snap.triage : []
2203
+ var items = Array.isArray(snap.items) ? snap.items : []
2204
+
2205
+ var unreadRows = triage.map(function (c) {
2206
+ var trackObj = tracks.find(function (t) { return t.id === c.trackId })
2207
+ var srcMeta = SOURCE_META[normalizeSource(c.source)] || SOURCE_META.manual
2208
+ var safeQuiz = c.quiz || sanitizeQuizBlock(null, c.title, c.why, c.rejected, c.probe)
2209
+ return {
2210
+ id: c.id,
2211
+ kind: 'unread',
2212
+ raw: c,
2213
+ trackId: c.trackId,
2214
+ trackTitle: trackObj ? trackObj.title : '',
2215
+ source: c.source,
2216
+ epistemic: c.epistemic || 'inferred',
2217
+ sourceLabel: srcMeta.label + ' · 严选接住',
2218
+ masteryTier: 0,
2219
+ masteryLabel: '0/4 新抓到 · 未看',
2220
+ title: c.title,
2221
+ why: c.why,
2222
+ rejected: c.rejected,
2223
+ probe: c.probe,
2224
+ evidenceSummary: '对话中踩坑或做取舍时自动记下,等待 10 秒快测或 1 对 1 闯关。',
2225
+ quiz: safeQuiz,
2226
+ }
2227
+ })
2228
+
2229
+ var savedRows = items.map(function (it) {
2230
+ var tier = clampTier(it.masteryTier || 1)
2231
+ var trackObj = tracks.find(function (t) { return t.id === it.trackId })
2232
+ var srcMeta = SOURCE_META[normalizeSource(it.source)] || SOURCE_META.manual
2233
+ var epMeta = EPISTEMIC_META[normalizeEpistemic(it.epistemic)] || EPISTEMIC_META.explicit
2234
+ return {
2235
+ id: it.id,
2236
+ kind: 'saved',
2237
+ raw: it,
2238
+ trackId: it.trackId,
2239
+ trackTitle: trackObj ? trackObj.title : '',
2240
+ source: it.source,
2241
+ epistemic: it.epistemic || 'explicit',
2242
+ sourceLabel: srcMeta.label + ' · ' + epMeta.label,
2243
+ masteryTier: tier,
2244
+ masteryLabel: MASTERY_LABELS[tier] || MASTERY_LABELS[1],
2245
+ title: it.title,
2246
+ why: it.why,
2247
+ rejected: it.rejected,
2248
+ probe: it.probe,
2249
+ evidenceSummary: it.evidenceSummary,
2250
+ quiz: it.quiz,
2251
+ }
2252
+ })
2006
2253
 
2007
- function renderDirectStudyBox(isHero) {
2254
+ var allRows = unreadRows.concat(savedRows)
2255
+ var learningRows = savedRows.filter(function (r) { return r.masteryTier >= 1 && r.masteryTier < 4 })
2256
+ var masteredRows = savedRows.filter(function (r) { return r.masteryTier >= 4 })
2257
+ var sprintPool = (snap.sprint15m && Array.isArray(snap.sprint15m.stations)) ? snap.sprint15m.stations : []
2258
+ var isCompletelyEmpty = allRows.length === 0
2259
+
2260
+ var activeStatus = statusFilter
2261
+ if (activeStatus === 'unread' && unreadRows.length === 0) activeStatus = 'all'
2262
+ if (activeStatus === 'learning' && learningRows.length === 0) activeStatus = 'all'
2263
+ if (activeStatus === 'mastered' && masteredRows.length === 0) activeStatus = 'all'
2264
+
2265
+ var populatedTrackMeta = tracks.map(function (t) {
2266
+ return {
2267
+ id: t.id,
2268
+ title: t.title,
2269
+ count: allRows.filter(function (r) { return r.trackId === t.id }).length,
2270
+ }
2271
+ }).filter(function (t) { return t.count > 0 })
2272
+
2273
+ var activeTrack = (trackFilter !== 'all' && populatedTrackMeta.some(function (t) { return t.id === trackFilter }))
2274
+ ? trackFilter
2275
+ : 'all'
2276
+
2277
+ var filteredRows = allRows.filter(function (r) {
2278
+ if (activeStatus === 'unread' && r.masteryTier !== 0) return false
2279
+ if (activeStatus === 'learning' && !(r.masteryTier >= 1 && r.masteryTier < 4)) return false
2280
+ if (activeStatus === 'mastered' && r.masteryTier < 4) return false
2281
+ if (activeTrack !== 'all' && r.trackId !== activeTrack) return false
2282
+ return true
2283
+ })
2284
+
2285
+ var spotlight = (snap.spotlight && learningRows.length > 0)
2286
+ ? (learningRows.find(function (r) { return r.id === snap.spotlight.id }) || learningRows[0])
2287
+ : null
2288
+
2289
+ var statText = isCompletelyEmpty
2290
+ ? '手账 0 条 · 随时从下面发起 1 对 1 学习或先看三步原理图'
2291
+ : ('共 ' + allRows.length + ' 条(' + masteredRows.length + ' 已吃透 · ' + unreadRows.length + ' 条新抓到未看)')
2292
+
2293
+ function renderRowMarkup(row) {
2294
+ var isUnread = row.kind === 'unread'
2295
+ var isExp = expandedQuizId === row.id
2296
+ var ans = quizAnswers[row.id] || null
2297
+ var metaLine = [row.trackTitle, row.sourceLabel].filter(Boolean).join(' · ')
2298
+
2299
+ return h('div', { key: row.id, className: 'ilp-row-wrap', 'data-testid': 'ilp-row-wrap-' + row.id },
2300
+ h('div', {
2301
+ className: 'ilp-row' + (isUnread ? ' is-unread' : ''),
2302
+ 'data-testid': 'ilp-row-' + row.id,
2303
+ 'data-row-kind': row.kind,
2304
+ },
2305
+ h('div', { className: 'ilp-meter-col' },
2306
+ makeMasteryMeter(h, row.masteryTier, row.masteryLabel),
2307
+ ),
2308
+ h('div', { className: 'ilp-row-body' },
2309
+ h('button', {
2310
+ type: 'button',
2311
+ className: 'ilp-row-title-btn',
2312
+ 'data-testid': 'ilp-row-title-' + row.id,
2313
+ onClick: function () { setModalItem(row) },
2314
+ }, row.title),
2315
+ row.why ? h('div', { className: 'ilp-row-summary' }, row.why) : null,
2316
+ metaLine ? h('div', { className: 'ilp-row-sub' }, metaLine) : null,
2317
+ ),
2318
+ h('div', { className: 'ilp-row-acts' },
2319
+ isUnread ? h(React.Fragment, null,
2320
+ h('button', {
2321
+ type: 'button',
2322
+ className: 'ilp-btn line sm',
2323
+ 'data-testid': 'ilp-row-quiz-btn-' + row.id,
2324
+ 'aria-expanded': isExp ? 'true' : 'false',
2325
+ onClick: function () { setExpandedQuizId(isExp ? null : row.id) },
2326
+ }, isExp ? '收起快测' : '10 秒快测'),
2327
+ h('button', {
2328
+ type: 'button',
2329
+ className: 'ilp-btn ghost sm',
2330
+ 'data-testid': 'ilp-row-drill-' + row.id,
2331
+ onClick: function () { handleDrillRow(row) },
2332
+ }, '去闯关'),
2333
+ h('button', {
2334
+ type: 'button',
2335
+ className: 'ilp-btn ghost sm danger-text',
2336
+ 'data-testid': 'ilp-row-del-' + row.id,
2337
+ onClick: function () { handleDeleteUnread(row) },
2338
+ }, '删掉'),
2339
+ ) : h(React.Fragment, null,
2340
+ h('button', {
2341
+ type: 'button',
2342
+ className: 'ilp-btn line sm',
2343
+ 'data-testid': 'ilp-row-card-' + row.id,
2344
+ onClick: function () { setModalItem(row) },
2345
+ }, '看手卡'),
2346
+ h('button', {
2347
+ type: 'button',
2348
+ className: 'ilp-btn ghost sm',
2349
+ 'data-testid': 'ilp-row-drill-' + row.id,
2350
+ onClick: function () { handleDrillRow(row) },
2351
+ }, row.masteryTier >= 4 ? '换景复测' : '去闯关'),
2352
+ ),
2353
+ ),
2354
+ ),
2355
+ isUnread && isExp ? h('div', { className: 'ilp-inline-quiz', 'data-testid': 'ilp-inline-quiz-' + row.id },
2356
+ h('div', { className: 'ilp-compare-grid' },
2357
+ h('div', { className: 'ilp-compare-card good' },
2358
+ h('div', { className: 'ilp-compare-k' }, '核心取舍'),
2359
+ row.why || '已基于当前项目约束选择更稳妥方案。',
2360
+ ),
2361
+ h('div', { className: 'ilp-compare-card bad' },
2362
+ h('div', { className: 'ilp-compare-k' }, '避开的坑'),
2363
+ row.rejected || '已排除脆弱或高维护成本备选方案。',
2364
+ ),
2365
+ ),
2366
+ h('div', { className: 'ilp-quiz-q' }, row.quiz.question),
2367
+ h('div', { className: 'ilp-quiz-opts' },
2368
+ row.quiz.options.map(function (opt) {
2369
+ var cls = 'ilp-quiz-opt'
2370
+ if (ans && ans.key === opt.key) cls += opt.correct ? ' is-correct' : ' is-wrong'
2371
+ return h('button', {
2372
+ key: opt.key,
2373
+ type: 'button',
2374
+ className: cls,
2375
+ 'data-testid': 'ilp-inline-opt-' + row.id + '-' + opt.key,
2376
+ onClick: function () {
2377
+ var fb = opt.feedback || (opt.correct ? ('答对了:' + (row.why || '')) : ('再核对一下核心依据:' + (row.why || '')))
2378
+ setQuizAnswers(function (prev) {
2379
+ var next = Object.assign({}, prev)
2380
+ next[row.id] = { key: opt.key, ok: !!opt.correct, fb: fb }
2381
+ return next
2382
+ })
2383
+ },
2384
+ },
2385
+ h('span', { className: 'ilp-opt-key' }, opt.key),
2386
+ h('span', { className: 'ilp-opt-body' }, opt.label),
2387
+ )
2388
+ }),
2389
+ ),
2390
+ ans ? h('div', { className: 'ilp-quiz-fb', 'data-testid': 'ilp-inline-fb-' + row.id },
2391
+ h('span', { style: { flex: '1 1 200px' } }, ans.fb),
2392
+ h('button', {
2393
+ type: 'button',
2394
+ className: 'ilp-btn solid sm',
2395
+ 'data-testid': 'ilp-inline-upgrade-' + row.id,
2396
+ onClick: function () { handleUpgradeInlineQuiz(row, ans) },
2397
+ }, '原地记为 2/4 讲过一轮'),
2398
+ ) : null,
2399
+ ) : null,
2400
+ )
2401
+ }
2402
+
2403
+ function renderOverflowBar(extraCount) {
2404
+ return h('div', { className: 'ilp-overflow-bar', 'data-testid': 'ilp-overflow-bar' },
2405
+ h('div', { className: 'ilp-overflow-msg' },
2406
+ h('span', { className: 'ilp-amber-dot', 'aria-hidden': 'true' }),
2407
+ h('span', null,
2408
+ '还有 ',
2409
+ h('strong', null, String(extraCount) + ' 条'),
2410
+ ' 更早顺手抓到的未看(已自动收起,避免把下方已学技能挤出首屏)',
2411
+ ),
2412
+ ),
2413
+ h('div', { style: { display: 'flex', gap: '6px', flexWrap: 'wrap' } },
2414
+ h('button', {
2415
+ type: 'button',
2416
+ className: 'ilp-btn line sm',
2417
+ 'data-testid': 'ilp-toggle-older-unread',
2418
+ 'aria-expanded': olderUnreadOpen ? 'true' : 'false',
2419
+ onClick: function () { setOlderUnreadOpen(function (v) { return !v }) },
2420
+ }, olderUnreadOpen ? ('收起较早的 ' + extraCount + ' 条未看') : ('展开其余 ' + extraCount + ' 条')),
2421
+ h('button', {
2422
+ type: 'button',
2423
+ className: 'ilp-btn ghost sm danger-text',
2424
+ 'data-testid': 'ilp-clear-older-unread',
2425
+ onClick: handleClearOlderUnread,
2426
+ }, '清掉这 ' + extraCount + ' 条旧未看'),
2427
+ ),
2428
+ )
2429
+ }
2430
+
2431
+ function renderDirectStudyBox() {
2008
2432
  return h('form', {
2009
- className: 'ilp-direct-box' + (isHero ? ' is-hero' : ''),
2433
+ className: 'ilp-intent-box',
2010
2434
  'data-testid': 'ilp-direct-study',
2011
2435
  onSubmit: handleStartDirectStudy,
2012
2436
  },
2013
- h('div', { className: 'ilp-direct-head' },
2014
- h('span', { className: 'ilp-direct-title' }, '直接开启专心学习(1 对 1 闯关对话)'),
2015
- h('span', { className: 'ilp-direct-sub' }, '不必先挑旧存档;填一个现在想弄懂的问题或直接点选下方主题,一键跳进专心学习对话。'),
2437
+ h('div', { className: 'ilp-intent-top' },
2438
+ h('span', { className: 'ilp-intent-label' }, '直接开启 1 对 1 专心学习'),
2439
+ h('span', { className: 'ilp-intent-hint' }, '不必挑卡片,第 1 轮先出 1 道盲选题摸底'),
2016
2440
  ),
2017
- h('div', { className: 'ilp-direct-row' },
2441
+ h('div', { className: 'ilp-intent-main' },
2018
2442
  h('input', {
2443
+ ref: intentInputRef,
2019
2444
  type: 'text',
2020
- className: 'ilp-direct-input',
2445
+ className: 'ilp-intent-input',
2021
2446
  'data-testid': 'ilp-direct-topic-input',
2022
2447
  'aria-label': '输入想专心学习的主题',
2023
- placeholder: '例如:复盘当前项目刚改的权限边界 / CSS 容器查询先后顺序(留空也可直接开练)',
2448
+ placeholder: '想顺手弄懂什么?填个问题或点下方主题…',
2024
2449
  value: directTopic,
2025
2450
  onChange: function (e) { setDirectTopic(e.target.value) },
2026
2451
  }),
2027
- workspaces.length > 0 ? h('select', {
2028
- className: 'ilp-direct-ws',
2029
- 'data-testid': 'ilp-direct-ws-select',
2030
- 'aria-label': '选择学习关联的工作区',
2031
- value: effectiveWsId || '',
2032
- onChange: function (e) { setSelectedWsId(e.target.value) },
2033
- },
2034
- workspaces.map(function (ws) {
2035
- return h('option', { key: ws.id, value: ws.id }, ws.name || ws.id)
2036
- }),
2037
- ) : null,
2038
- h('button', {
2039
- type: 'submit',
2040
- className: 'ilp-btn ' + (isHero ? 'solid' : 'line'),
2041
- 'data-testid': 'ilp-direct-start-btn',
2042
- disabled: startingDirect,
2043
- }, startingDirect ? '正在开启…' : '开始专心学'),
2452
+ h('div', { className: 'ilp-intent-controls' },
2453
+ workspaces.length > 0 ? h('select', {
2454
+ className: 'ilp-ws-pill',
2455
+ 'data-testid': 'ilp-direct-ws-select',
2456
+ 'aria-label': '选择学习关联的工作区',
2457
+ value: effectiveWsId || '',
2458
+ onChange: function (e) { setSelectedWsId(e.target.value) },
2459
+ },
2460
+ workspaces.map(function (ws) {
2461
+ return h('option', { key: ws.id, value: ws.id }, ws.name || ws.id)
2462
+ }),
2463
+ ) : null,
2464
+ h('button', {
2465
+ type: 'submit',
2466
+ className: 'ilp-btn solid',
2467
+ 'data-testid': 'ilp-direct-start-btn',
2468
+ disabled: startingDirect,
2469
+ }, startingDirect ? '正在开启…' : '开启专心闯关 ->'),
2470
+ ),
2044
2471
  ),
2045
- h('div', { className: 'ilp-direct-chips' },
2472
+ h('div', { className: 'ilp-chip-row' },
2046
2473
  DIRECT_TOPICS.map(function (chip, idx) {
2047
2474
  return h('button', {
2048
2475
  key: String(idx),
2049
2476
  type: 'button',
2050
- className: 'ilp-chip-btn',
2477
+ className: 'ilp-chip',
2051
2478
  'data-testid': 'ilp-direct-chip-' + idx,
2052
- onClick: function () { setDirectTopic(chip) },
2479
+ onClick: function () {
2480
+ setDirectTopic(chip)
2481
+ if (intentInputRef.current && typeof intentInputRef.current.focus === 'function') {
2482
+ intentInputRef.current.focus()
2483
+ }
2484
+ },
2053
2485
  }, chip)
2054
2486
  }),
2055
2487
  ),
2056
2488
  )
2057
2489
  }
2058
2490
 
2491
+ var sheetChildren = []
2492
+ if (activeStatus === 'all') {
2493
+ var unreadFiltered = filteredRows.filter(function (r) { return r.kind === 'unread' })
2494
+ var savedFiltered = filteredRows.filter(function (r) { return r.kind === 'saved' })
2495
+ if (unreadFiltered.length > MAX_DIRECT_UNREAD) {
2496
+ unreadFiltered.slice(0, MAX_DIRECT_UNREAD).forEach(function (r) { sheetChildren.push(renderRowMarkup(r)) })
2497
+ var extraUnread = unreadFiltered.slice(MAX_DIRECT_UNREAD)
2498
+ if (olderUnreadOpen) {
2499
+ extraUnread.forEach(function (r) { sheetChildren.push(renderRowMarkup(r)) })
2500
+ }
2501
+ sheetChildren.push(renderOverflowBar(extraUnread.length))
2502
+ } else {
2503
+ unreadFiltered.forEach(function (r) { sheetChildren.push(renderRowMarkup(r)) })
2504
+ }
2505
+ savedFiltered.forEach(function (r) { sheetChildren.push(renderRowMarkup(r)) })
2506
+ } else {
2507
+ filteredRows.forEach(function (r) { sheetChildren.push(renderRowMarkup(r)) })
2508
+ }
2509
+
2059
2510
  return h('div', { className: 'ilp-wb', 'data-testid': 'ilp-workbench' },
2060
2511
  h('div', { className: 'ilp-wb-inner' },
2061
2512
  // Calm Header
2062
2513
  h('header', { className: 'ilp-header' },
2063
2514
  h('div', { className: 'ilp-toprow' },
2064
- h('span', { className: 'ilp-eyebrow' }, '平时协作攒经验 · 个人技能库'),
2515
+ h('span', { className: 'ilp-eyebrow' }, '平时协作攒经验 · 一本手账零搬运'),
2065
2516
  h('div', { className: 'ilp-header-acts' },
2066
- stats.totalItems > 0 ? h('button', {
2517
+ savedRows.length > 0 ? h('button', {
2067
2518
  type: 'button',
2068
- className: 'ilp-btn line sm',
2069
- 'data-testid': 'ilp-course-toggle-btn',
2070
- onClick: handleBuildCourse,
2071
- }, courseOpen ? '收起 15 分钟集中学' : '15 分钟集中学') : null,
2072
- stats.totalItems > 0 ? h('button', {
2073
- type: 'button',
2074
- className: 'ilp-btn line sm',
2519
+ className: 'ilp-btn ghost sm',
2520
+ 'data-testid': 'ilp-export-notes-btn',
2075
2521
  onClick: handleExportNotes,
2076
2522
  }, '导出学习笔记') : null,
2077
2523
  !isCompletelyEmpty ? h('button', {
2078
2524
  type: 'button',
2079
2525
  className: 'ilp-btn ghost sm',
2526
+ 'data-testid': 'ilp-reset-empty-btn',
2080
2527
  onClick: handleResetEmpty,
2081
2528
  }, '清空') : null,
2082
2529
  ),
2083
2530
  ),
2084
2531
  h('div', { className: 'ilp-title-row' },
2085
2532
  h('h1', { className: 'ilp-h1' }, '顺带私教'),
2086
- h('span', { className: 'ilp-summary' },
2087
- '已掌握 ' + stats.masteredItems + ' / ' + stats.totalItems + ' 项 · ' + stats.trackCount + ' 类技能 · 后台自动存档 ' + stats.triageCount + ' 张',
2088
- ),
2533
+ h('span', { className: 'ilp-summary', 'data-testid': 'ilp-summary-line' }, statText),
2089
2534
  !isCompletelyEmpty ? h('button', {
2090
2535
  type: 'button',
2091
2536
  className: guideOpen ? 'ilp-btn line xs' : 'ilp-btn soft xs',
2092
2537
  'data-testid': 'ilp-toggle-guide-btn',
2093
2538
  'aria-expanded': guideOpen ? 'true' : 'false',
2094
2539
  onClick: function () { setGuideOpen(function (v) { return !v }) },
2095
- }, guideOpen ? '收起说明' : '使用说明') : null,
2540
+ }, guideOpen ? '收起原理图' : '工作原理图') : null,
2096
2541
  ),
2097
2542
  ),
2098
2543
 
2099
- isPreviewSamples && stats.totalItems > 0 ? h('div', { className: 'ilp-preview-banner', 'data-testid': 'ilp-preview-banner' },
2100
- h('span', null, '当前展示的是示例效果(不耗 Token)。看完可随时恢复初始空页面,再在平时对话里慢慢攒自己的技能库。'),
2544
+ isPreviewSamples && allRows.length > 0 ? h('div', { className: 'ilp-preview-banner', 'data-testid': 'ilp-preview-banner' },
2545
+ h('span', null, '当前展示的是示例效果(不耗 Token)。看完可随时恢复初始空页面,再在平时对话里慢慢攒自己的手账。'),
2101
2546
  h('button', {
2102
2547
  type: 'button',
2103
2548
  className: 'ilp-btn line xs',
@@ -2106,7 +2551,10 @@ function makeWorkbenchComponent(React, ctx, bridge) {
2106
2551
  }, '恢复初始空页面'),
2107
2552
  ) : null,
2108
2553
 
2109
- // Visual Onboarding / On-Demand Usage Guide
2554
+ // Unified Top 1-on-1 Study Intent Box (never blocked by unread cards)
2555
+ renderDirectStudyBox(),
2556
+
2557
+ // Visual Onboarding / On-Demand Principle Diagram
2110
2558
  (isCompletelyEmpty || guideOpen)
2111
2559
  ? (isCompletelyEmpty
2112
2560
  ? h('div', { 'data-testid': 'ilp-empty-onboarding' },
@@ -2131,150 +2579,83 @@ function makeWorkbenchComponent(React, ctx, bridge) {
2131
2579
  }))
2132
2580
  : null,
2133
2581
 
2134
- // Single Spotlight Hero Card (when accumulated items > 0) vs Direct Study Hero (when 0 items)
2135
- spotlight ? h('section', { className: 'ilp-spot-card', 'data-testid': 'ilp-spotlight' },
2136
- h('div', { className: 'ilp-spot-main' },
2137
- h('div', { className: 'ilp-spot-eyebrow' },
2138
- h('span', { className: 'ilp-tag wait' }, '优先待学'),
2139
- sourceTag(h, spotlight.source),
2140
- epistemicTag(h, spotlight.epistemic),
2141
- makeMasteryMeter(h, spotlight.masteryTier),
2142
- ),
2143
- h('div', { className: 'ilp-spot-title' }, spotlight.title),
2144
- spotlight.why ? h('p', { className: 'ilp-spot-desc' }, spotlight.why) : null,
2145
- spotlight.probe ? h('div', { className: 'ilp-spot-probe' },
2146
- h('span', { className: 'ilp-shield-k', style: { marginRight: '6px' } }, '顺手想一下'),
2147
- spotlight.probe,
2148
- ) : null,
2149
- ),
2150
- h('div', { className: 'ilp-spot-acts' },
2582
+ // Plan A Unique Spotlight Card (when learning items exist under 'all' view)
2583
+ (allRows.length > 0 && spotlight && activeStatus === 'all' && activeTrack === 'all')
2584
+ ? h('section', { className: 'ilp-spotlight', 'data-testid': 'ilp-spotlight' },
2585
+ h('div', { style: { minWidth: 0 } },
2586
+ h('div', { className: 'ilp-spot-meta' },
2587
+ h('span', null, '今日优先吃透'),
2588
+ h('span', null, '·'),
2589
+ makeMasteryMeter(h, spotlight.masteryTier, spotlight.masteryLabel),
2590
+ ),
2591
+ h('h2', { className: 'ilp-spot-title' }, spotlight.title),
2592
+ spotlight.why ? h('p', { className: 'ilp-spot-why' }, spotlight.why) : null,
2593
+ ),
2594
+ h('div', { className: 'ilp-spot-acts' },
2595
+ h('button', {
2596
+ type: 'button',
2597
+ className: 'ilp-btn solid sm',
2598
+ 'data-testid': 'ilp-start-deep-learn',
2599
+ onClick: function () { handleDrillRow(spotlight) },
2600
+ }, '3 分钟闯关升级'),
2601
+ h('button', {
2602
+ type: 'button',
2603
+ className: 'ilp-btn line sm',
2604
+ 'data-testid': 'ilp-open-evidence-modal',
2605
+ onClick: function () { setModalItem(spotlight) },
2606
+ }, '看经验手卡'),
2607
+ ),
2608
+ )
2609
+ : null,
2610
+
2611
+ // Plan A Toolbar (Filter Pills + Action Triggers, NO parallel tabs)
2612
+ allRows.length > 0 ? h('div', { className: 'ilp-toolbar', 'data-testid': 'ilp-toolbar' },
2613
+ h('div', { className: 'ilp-filter-row', role: 'group', 'aria-label': '按状态筛选' },
2151
2614
  h('button', {
2152
2615
  type: 'button',
2153
- className: 'ilp-btn solid',
2154
- 'data-testid': 'ilp-start-deep-learn',
2155
- onClick: function () { handleStartDeepDrill(spotlight) },
2156
- }, '开始 3 分钟展开学'),
2157
- h('button', {
2616
+ className: 'ilp-filter-pill',
2617
+ 'data-testid': 'ilp-filter-all',
2618
+ 'aria-pressed': activeStatus === 'all' ? 'true' : 'false',
2619
+ onClick: function () { setStatusFilter('all') },
2620
+ }, '全部 · ' + allRows.length),
2621
+ unreadRows.length > 0 ? h('button', {
2158
2622
  type: 'button',
2159
- className: 'ilp-btn line sm',
2160
- 'data-testid': 'ilp-open-evidence-modal',
2161
- onClick: function () { setModalItem(spotlight) },
2162
- }, '看卡片解析'),
2163
- ),
2164
- ) : null,
2165
-
2166
- renderDirectStudyBox(!isCompletelyEmpty && !spotlight),
2167
-
2168
- // 1-Line Default-Collapsed Background Auto-Archive
2169
- triage.length > 0 ? h('section', { className: 'ilp-triage-box', 'data-testid': 'ilp-triage-box' },
2170
- h('button', {
2171
- type: 'button',
2172
- className: 'ilp-triage-head',
2173
- 'aria-expanded': triageOpen ? 'true' : 'false',
2174
- 'data-testid': 'ilp-triage-toggle',
2175
- onClick: function () { setTriageOpen(!triageOpen) },
2176
- },
2177
- h('span', { className: 'ilp-triage-head-left' },
2178
- h('span', { className: 'ilp-tag ' + (snap.triageOverCap ? 'wait' : 'outline') }, '后台自动存档 · ' + triage.length + ' 张'),
2179
- h('span', { className: 'ilp-summary' }, snap.triageOverCap ? '待看卡片超过 5 张,可批量清理、全部存进技能库或一键清空' : '平时对话先放着没点的卡片;想练直接点「拿这张去练」,不要的可点「删掉」'),
2180
- ),
2181
- h('span', { className: 'ilp-btn ghost xs' }, triageOpen ? '收起' : '展开查看'),
2182
- ),
2183
- triageOpen ? h('div', { className: 'ilp-triage-body' },
2184
- triage.length > 5
2185
- ? h('div', { className: 'ilp-triage-batch', 'data-testid': 'ilp-triage-batch' },
2186
- h('span', { style: { fontSize: '12px', fontWeight: 600 } }, '整理提醒:后台共自动存了 ' + triage.length + ' 张待看卡片'),
2187
- h('div', { style: { display: 'flex', gap: '6px', flexWrap: 'wrap' } },
2188
- h('button', {
2189
- type: 'button',
2190
- className: 'ilp-btn line xs',
2191
- 'data-testid': 'ilp-batch-sweep-low',
2192
- onClick: function () { handleTriageBatch('sweep_low_value') },
2193
- }, '清理细碎卡片'),
2194
- h('button', {
2195
- type: 'button',
2196
- className: 'ilp-btn solid xs',
2197
- 'data-testid': 'ilp-batch-accept-all',
2198
- onClick: function () { handleTriageBatch('accept_all') },
2199
- }, '全部存进技能库'),
2200
- h('button', {
2201
- type: 'button',
2202
- className: 'ilp-btn ghost xs',
2203
- 'data-testid': 'ilp-triage-clear-all',
2204
- onClick: function () { handleTriageBatch('clear_all') },
2205
- }, '一键清空存档'),
2206
- ),
2207
- )
2208
- : h('div', { className: 'ilp-triage-subbar' },
2209
- h('span', null, '点「拿这张去练」直接新开一对一闯关对话;不想留的存档可直接删掉或一键清空。'),
2210
- h('button', {
2211
- type: 'button',
2212
- className: 'ilp-btn ghost xs',
2213
- 'data-testid': 'ilp-triage-clear-all',
2214
- onClick: function () { handleTriageBatch('clear_all') },
2215
- }, '一键清空存档'),
2216
- ),
2217
- triage.map(function (cand) {
2218
- return h('div', { key: cand.id, className: 'ilp-triage-row', 'data-testid': 'ilp-triage-row-' + cand.id },
2219
- h('div', { className: 'ilp-triage-info' },
2220
- h('div', { className: 'ilp-item-badges' },
2221
- sourceTag(h, cand.source),
2222
- epistemicTag(h, cand.epistemic),
2223
- cand.lowValue ? h('span', { className: 'ilp-tag outline' }, '细碎小修') : null,
2224
- ),
2225
- h('div', { className: 'ilp-triage-title' }, cand.title),
2226
- cand.why ? h('div', { className: 'ilp-triage-why' }, cand.why) : null,
2227
- ),
2228
- h('div', { className: 'ilp-triage-acts' },
2229
- h('button', {
2230
- type: 'button',
2231
- className: 'ilp-btn soft xs',
2232
- 'data-testid': 'ilp-triage-drill-' + cand.id,
2233
- onClick: function () { handleDrillTriage(cand) },
2234
- }, '拿这张去练'),
2235
- h('button', {
2236
- type: 'button',
2237
- className: 'ilp-btn line xs',
2238
- 'data-testid': 'ilp-triage-accept-' + cand.id,
2239
- onClick: function () { handleTriageOne(cand.id, 'accept') },
2240
- }, '先存着'),
2241
- h('button', {
2242
- type: 'button',
2243
- className: 'ilp-btn ghost xs',
2244
- 'data-testid': 'ilp-triage-skip-' + cand.id,
2245
- onClick: function () { handleTriageOne(cand.id, 'skip') },
2246
- }, '删掉'),
2247
- ),
2248
- )
2249
- }),
2250
- ) : null,
2251
- ) : null,
2252
-
2253
- // Optional 15-Minute Focus Study View
2254
- courseOpen && activeCourse ? h('section', { className: 'ilp-course-box', 'data-testid': 'ilp-course-box' },
2255
- h('div', { className: 'ilp-toprow' },
2256
- h('div', null,
2257
- h('span', { className: 'ilp-tag run' }, '15 分钟集中学'),
2258
- h('span', { style: { fontWeight: 600, marginLeft: '8px' } }, activeCourse.trackTitle + ' · 3 站串联'),
2259
- ),
2260
- activeCourse.stations && activeCourse.stations[0] ? h('button', {
2623
+ className: 'ilp-filter-pill',
2624
+ 'data-testid': 'ilp-filter-unread',
2625
+ 'aria-pressed': activeStatus === 'unread' ? 'true' : 'false',
2626
+ onClick: function () { setStatusFilter('unread') },
2627
+ },
2628
+ h('span', { className: 'ilp-amber-dot', 'aria-hidden': 'true' }),
2629
+ '新抓到未看 · ' + unreadRows.length,
2630
+ ) : null,
2631
+ learningRows.length > 0 ? h('button', {
2261
2632
  type: 'button',
2262
- className: 'ilp-btn solid xs',
2263
- onClick: function () {
2264
- var targetId = activeCourse.stations[0].itemId
2265
- var found = (snap.items || []).find(function (x) { return x.id === targetId }) || spotlight
2266
- if (found) handleStartDeepDrill(found)
2267
- },
2268
- }, '从第 1 站开练') : null,
2633
+ className: 'ilp-filter-pill',
2634
+ 'data-testid': 'ilp-filter-learning',
2635
+ 'aria-pressed': activeStatus === 'learning' ? 'true' : 'false',
2636
+ onClick: function () { setStatusFilter('learning') },
2637
+ }, '学习中 · ' + learningRows.length) : null,
2638
+ masteredRows.length > 0 ? h('button', {
2639
+ type: 'button',
2640
+ className: 'ilp-filter-pill',
2641
+ 'data-testid': 'ilp-filter-mastered',
2642
+ 'aria-pressed': activeStatus === 'mastered' ? 'true' : 'false',
2643
+ onClick: function () { setStatusFilter('mastered') },
2644
+ }, '已吃透 · ' + masteredRows.length) : null,
2269
2645
  ),
2270
- h('div', { className: 'ilp-course-grid' },
2271
- (activeCourse.stations || []).map(function (st) {
2272
- return h('div', { key: String(st.station), className: 'ilp-station' },
2273
- h('div', { className: 'ilp-tag outline' }, '第 ' + st.station + ' 站 · ' + st.durationMin + ' 分钟'),
2274
- h('div', { style: { fontWeight: 600, fontSize: '13px' } }, st.title),
2275
- h('div', { style: { fontSize: '12px', color: 'var(--ilp-ink2)' } }, st.focus + ' · ' + st.masteryLabel),
2276
- )
2277
- }),
2646
+ h('div', { className: 'ilp-toolbar-acts' },
2647
+ unreadRows.length > 0 ? h('button', {
2648
+ type: 'button',
2649
+ className: 'ilp-btn ghost sm danger-text',
2650
+ 'data-testid': 'ilp-triage-clear-all',
2651
+ onClick: handleClearAllUnread,
2652
+ }, '清掉全部未看 (' + unreadRows.length + ')') : null,
2653
+ sprintPool.length >= 2 ? h('button', {
2654
+ type: 'button',
2655
+ className: 'ilp-btn indigo-line sm',
2656
+ 'data-testid': 'ilp-sprint-open-btn',
2657
+ onClick: handleOpenSprintModal,
2658
+ }, '连抽 ' + sprintPool.length + ' 条考考我 · 15m') : null,
2278
2659
  ),
2279
2660
  ) : null,
2280
2661
 
@@ -2291,75 +2672,40 @@ function makeWorkbenchComponent(React, ctx, bridge) {
2291
2672
  h('pre', { className: 'ilp-code-pre', style: { maxHeight: '160px', overflowY: 'auto' } }, exportInfo.markdown),
2292
2673
  ) : null,
2293
2674
 
2294
- // Populated Skill Categories ONLY (never render empty 0/0 clickable shells!)
2295
- populatedTracks.length > 0 ? h('section', { className: 'ilp-tracks', 'data-testid': 'ilp-tracks' },
2296
- h('div', { className: 'ilp-section-label' }, '沉淀下来的技能分类(可随时查看学习记录)'),
2297
- populatedTracks.map(function (track) {
2298
- var isOpen = Object.prototype.hasOwnProperty.call(expandedTracks, track.id)
2299
- ? !!expandedTracks[track.id]
2300
- : (track.id === firstPopTrackId)
2301
- return h('div', { key: track.id, className: 'ilp-track', 'data-testid': 'ilp-track-' + track.id },
2302
- h('button', {
2675
+ // Unified Single Ledger Sheet (Unread at Top + >3 Overflow Fold + Saved Items Below; ZERO 0/0 empty shells!)
2676
+ allRows.length > 0 ? h('section', { className: 'ilp-sheet', 'data-testid': 'ilp-sheet', 'aria-label': '一本手账列表' },
2677
+ h('div', { className: 'ilp-sheet-head' },
2678
+ h('span', { className: 'ilp-sheet-title' }, '一本手账(AI 严选抓回的排最上;平时直铺,超 ' + MAX_DIRECT_UNREAD + ' 条自动折叠旧未看)'),
2679
+ h('span', { className: 'ilp-guard-pill' }, '严选门禁:单会话限频 · 未看封顶 ' + MAX_AUTO_TRIAGE + ' 条'),
2680
+ ),
2681
+ populatedTrackMeta.length >= 2 ? h('div', { className: 'ilp-track-pills', role: 'group', 'aria-label': '按能力分类筛选' },
2682
+ h('button', {
2683
+ type: 'button',
2684
+ className: 'ilp-track-pill',
2685
+ 'data-testid': 'ilp-track-pill-all',
2686
+ 'aria-pressed': activeTrack === 'all' ? 'true' : 'false',
2687
+ onClick: function () { setTrackFilter('all') },
2688
+ }, '全部分类'),
2689
+ populatedTrackMeta.map(function (tr) {
2690
+ return h('button', {
2691
+ key: tr.id,
2303
2692
  type: 'button',
2304
- className: 'ilp-track-head',
2305
- 'aria-expanded': isOpen ? 'true' : 'false',
2306
- onClick: function () { toggleTrack(track.id, isOpen) },
2307
- },
2308
- h('div', { className: 'ilp-track-meta' },
2309
- h('span', { className: 'ilp-track-title' }, track.title),
2310
- track.subtitle ? h('span', { className: 'ilp-track-sub' }, track.subtitle) : null,
2311
- ),
2312
- h('div', { className: 'ilp-track-right' },
2313
- h('span', { className: 'ilp-tag ' + (track.masteredCount >= track.totalCount && track.totalCount > 0 ? 'ok' : 'outline') },
2314
- track.masteredCount + ' / ' + track.totalCount + ' 已掌握',
2315
- ),
2316
- h('span', { style: { fontSize: '12px', color: 'var(--ilp-ink3)' } }, isOpen ? '收起' : '展开'),
2317
- ),
2318
- ),
2319
- isOpen ? h('div', { className: 'ilp-track-list' },
2320
- track.items.map(function (item) {
2321
- return h('div', { key: item.id, className: 'ilp-item-row', 'data-testid': 'ilp-item-' + item.id },
2322
- h('div', { className: 'ilp-item-main' },
2323
- h('div', { className: 'ilp-item-badges' },
2324
- sourceTag(h, item.source),
2325
- epistemicTag(h, item.epistemic),
2326
- makeMasteryMeter(h, item.masteryTier),
2327
- ),
2328
- h('button', {
2329
- type: 'button',
2330
- className: 'ilp-item-title',
2331
- onClick: function () { setModalItem(item) },
2332
- }, item.title),
2333
- item.evidenceSummary ? h('p', { className: 'ilp-item-evidence' }, item.evidenceSummary) : null,
2334
- ),
2335
- h('div', { className: 'ilp-item-acts' },
2336
- h('button', {
2337
- type: 'button',
2338
- className: 'ilp-btn line xs',
2339
- onClick: function () { setModalItem(item) },
2340
- }, '学习记录'),
2341
- h('button', {
2342
- type: 'button',
2343
- className: 'ilp-btn soft xs',
2344
- onClick: function () { handleStartDeepDrill(item) },
2345
- }, '展开学'),
2346
- ),
2347
- )
2348
- }),
2349
- ) : null,
2350
- )
2351
- }),
2352
- emptyTrackNames.length > 0 ? h('p', { className: 'ilp-empty-tracks-note', 'data-testid': 'ilp-empty-tracks-note' },
2353
- '其余待积累分类:' + emptyTrackNames.join(' · '),
2693
+ className: 'ilp-track-pill',
2694
+ 'data-testid': 'ilp-track-pill-' + tr.id,
2695
+ 'aria-pressed': activeTrack === tr.id ? 'true' : 'false',
2696
+ onClick: function () { setTrackFilter(tr.id) },
2697
+ }, tr.title + ' (' + tr.count + ')')
2698
+ }),
2354
2699
  ) : null,
2355
- ) : (!isCompletelyEmpty ? h('p', { className: 'ilp-empty-tracks-note', 'data-testid': 'ilp-empty-tracks-note' },
2356
- '练过或存下的内容会自动按分类归档到这里;目前还没有已存记录。',
2357
- ) : null),
2700
+ sheetChildren.length > 0
2701
+ ? sheetChildren
2702
+ : h('div', { className: 'ilp-empty-sheet' }, '当前筛选条件下暂无条目。'),
2703
+ ) : null,
2358
2704
 
2359
- // Undo Toast (calm panel surface + green dot)
2360
- toast ? h('div', { className: 'ilp-toast', role: 'status', 'data-testid': 'ilp-toast' },
2705
+ // Compact Non-Wrapping Undo Toast
2706
+ toast ? h('div', { className: 'ilp-toast', role: 'status', 'aria-live': 'polite', 'data-testid': 'ilp-toast' },
2361
2707
  h('span', { className: 'ilp-toast-dot', 'aria-hidden': 'true' }),
2362
- h('span', null, toast.text),
2708
+ h('span', { className: 'ilp-toast-text' }, toast.text),
2363
2709
  toast.canUndo ? h('button', {
2364
2710
  type: 'button',
2365
2711
  'data-testid': 'ilp-toast-undo',
@@ -2376,7 +2722,20 @@ function makeWorkbenchComponent(React, ctx, bridge) {
2376
2722
  h(EvidenceDialog, {
2377
2723
  item: modalItem,
2378
2724
  onClose: function () { setModalItem(null) },
2379
- onStartDrill: handleStartDeepDrill,
2725
+ onStartDrill: handleDrillRow,
2726
+ onCopied: function (title) { showToast('已复制手卡摘要:' + String(title || '').slice(0, 14), false) },
2727
+ }),
2728
+
2729
+ h(SprintDialog, {
2730
+ open: sprintOpen,
2731
+ stations: sprintStations,
2732
+ onClose: function () { setSprintOpen(false) },
2733
+ onStartSprint: function (picked) {
2734
+ var promptText = buildSprintStarterPrompt(picked)
2735
+ openDeepLearnSession(ctx, { promptOverride: promptText }, effectiveWsId).catch(function (err) {
2736
+ showToast('开启连续闯关失败:' + err.message, false)
2737
+ })
2738
+ },
2380
2739
  }),
2381
2740
  )
2382
2741
  }
@@ -2491,7 +2850,7 @@ function makeShieldFenceComponent(React, ctx, bridge, coachStore) {
2491
2850
  var psHeader = h('div', { className: 'ilp-ps-head' },
2492
2851
  h('span', { className: 'ilp-ps-label' }, '附 · 顺带补充(非本轮主回复)'),
2493
2852
  h('span', { className: 'ilp-ps-line', 'aria-hidden': 'true' }),
2494
- h('span', { className: 'ilp-ps-archive' }, '后台已自动存档,忙时不用管'),
2853
+ h('span', { className: 'ilp-ps-archive' }, '已直接落进手账顶部,忙时不用管'),
2495
2854
  )
2496
2855
 
2497
2856
  if (isStreaming) {
@@ -2549,9 +2908,9 @@ function makeShieldFenceComponent(React, ctx, bridge, coachStore) {
2549
2908
  }).then(function (res) {
2550
2909
  setSavedLocal(true)
2551
2910
  if (res && res.created === false) {
2552
- setFeedback('已在技能库中')
2911
+ setFeedback('已在技能手账中')
2553
2912
  } else {
2554
- setFeedback('已存进个人技能库,去顺带私教可随时开练')
2913
+ setFeedback('已存进顺带私教手账,随时可开练')
2555
2914
  }
2556
2915
  }).catch(function (err) {
2557
2916
  setFeedback('保存失败:' + err.message)
@@ -2704,7 +3063,7 @@ function makeLearnQuizFenceComponent(React) {
2704
3063
  h('article', { className: 'ilp-card', 'data-testid': 'ilp-learn-quiz-card' },
2705
3064
  h('div', { className: 'ilp-card-head' },
2706
3065
  h('span', { className: 'ilp-card-title' }, quiz.title),
2707
- h('div', { className: 'ilp-item-badges' },
3066
+ h('div', { className: 'ilp-item-badges', style: { display: 'flex', gap: '6px', flexWrap: 'wrap' } },
2708
3067
  h('span', { className: 'ilp-tag run' }, '第 ' + quiz.step + ' / ' + quiz.totalSteps + ' 关 · 先探后讲'),
2709
3068
  h('span', { className: 'ilp-tag outline' }, quiz.trackTitle),
2710
3069
  ),
@@ -2805,7 +3164,7 @@ function makeLearnPassFenceComponent(React, ctx, bridge) {
2805
3164
  h('span', { className: 'ilp-card-title' }, pass.title),
2806
3165
  h('span', { className: 'ilp-tag ok' }, '学懂过关 · 掌握度提升'),
2807
3166
  ),
2808
- h('div', { className: 'ilp-item-badges' },
3167
+ h('div', { style: { display: 'flex', flexWrap: 'wrap', alignItems: 'center', gap: '8px' } },
2809
3168
  h('span', { className: 'ilp-tag outline' }, pass.trackTitle),
2810
3169
  h('span', { className: 'ilp-summary' },
2811
3170
  (MASTERY_LABELS[pass.fromTier] || '') + ' -> ' + (MASTERY_LABELS[pass.toTier] || ''),
@@ -2827,7 +3186,7 @@ function makeLearnPassFenceComponent(React, ctx, bridge) {
2827
3186
  layout.selectPanel(PANEL_KEY)
2828
3187
  }
2829
3188
  },
2830
- }, '回个人技能库'),
3189
+ }, '回顺带私教手账'),
2831
3190
  h('button', {
2832
3191
  type: 'button',
2833
3192
  className: 'ilp-btn line sm',
@@ -2952,7 +3311,7 @@ function makeCoachDrawerComponent(React, ctx, bridge, coachStore) {
2952
3311
  }),
2953
3312
  ),
2954
3313
  drillResult ? h('div', { className: 'ilp-drawer-fb', 'data-testid': 'ilp-drawer-feedback' },
2955
- h('div', { className: 'ilp-item-badges' },
3314
+ h('div', { style: { display: 'flex', flexWrap: 'wrap', alignItems: 'center', gap: '8px' } },
2956
3315
  h('span', { className: 'ilp-tag ' + (drillResult.correct ? 'ok' : 'wait') },
2957
3316
  drillResult.correct ? '答对了' : '再看一眼关键点',
2958
3317
  ),
@@ -2972,7 +3331,7 @@ function makeCoachDrawerComponent(React, ctx, bridge, coachStore) {
2972
3331
  var layout = getHostService(ctx, 'layout')
2973
3332
  if (layout && typeof layout.selectPanel === 'function') layout.selectPanel(PANEL_KEY)
2974
3333
  },
2975
- }, '回个人技能库'),
3334
+ }, '回顺带私教手账'),
2976
3335
  ),
2977
3336
  ) : null,
2978
3337
  ),
@@ -3116,9 +3475,9 @@ exports.apply = function apply(ctx) {
3116
3475
 
3117
3476
  // 5. Register Tool Call Receipts (`tool.call.toolview`)
3118
3477
  var toolSpecs = [
3119
- ['learn_save', { preparing: '准备保存盲区…', start: '正在记入顺带私教…', result: '已明存进个人能力路线' }],
3478
+ ['learn_save', { preparing: '准备保存盲区…', start: '正在记入顺带私教…', result: '已明存进顺带私教手账' }],
3120
3479
  ['learn_checkpoint', { preparing: '准备归档过关证据…', start: '正在记录过关掌握度…', result: '过关证据与掌握度已写入账本' }],
3121
- ['learn_triage', { preparing: '准备整理候选收件箱…', start: '正在分诊待消化候选…', result: '待分诊队列已更新' }],
3480
+ ['learn_triage', { preparing: '准备整理手账未看…', start: '正在处理未看条目…', result: '手账列表已更新' }],
3122
3481
  ]
3123
3482
  toolSpecs.forEach(function (pair) {
3124
3483
  var offTool = ctx.slots.inject('tool.call.toolview', function () {