@kontourai/survey 0.4.10 → 0.4.11

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.
@@ -233,13 +233,13 @@
233
233
  z-index: 1;
234
234
  container-type: inline-size;
235
235
  min-height: 100vh;
236
- padding: 30px 26px 60px;
236
+ padding: 22px 22px 50px;
237
237
  }
238
238
 
239
239
  .survey-workbench-embed .workbench-shell{
240
240
  display: grid;
241
241
  grid-template-rows: auto minmax(0, 1fr);
242
- gap: 22px;
242
+ gap: 16px;
243
243
  max-width: 1360px;
244
244
  margin: 0 auto;
245
245
  }
@@ -274,10 +274,10 @@
274
274
 
275
275
  .survey-workbench-embed .topbar{
276
276
  display: grid;
277
- grid-template-columns: minmax(0, 1fr) minmax(0, 520px);
278
- gap: 26px;
277
+ grid-template-columns: minmax(0, 1fr);
278
+ gap: 12px;
279
279
  align-items: center;
280
- padding: 22px 26px;
280
+ padding: 15px 17px;
281
281
  border: 1px solid var(--line-strong);
282
282
  border-radius: var(--radius);
283
283
  background:
@@ -297,12 +297,12 @@
297
297
  }
298
298
 
299
299
  .survey-workbench-embed h1{
300
- margin-top: 8px;
300
+ margin-top: 6px;
301
301
  font-family: "Fraunces", Georgia, "Times New Roman", serif;
302
302
  font-optical-sizing: auto;
303
303
  font-weight: 600;
304
- font-size: clamp(26px, 3.4vw, 38px);
305
- line-height: 1.04;
304
+ font-size: clamp(21px, 2vw, 27px);
305
+ line-height: 1.08;
306
306
  letter-spacing: -0.01em;
307
307
  overflow-wrap: anywhere;
308
308
  color: var(--paper);
@@ -310,10 +310,10 @@
310
310
 
311
311
  .survey-workbench-embed .review-question{
312
312
  max-width: 720px;
313
- margin-top: 10px;
313
+ margin-top: 7px;
314
314
  color: var(--paper-dim);
315
- font-size: 15px;
316
- line-height: 1.45;
315
+ font-size: 13px;
316
+ line-height: 1.4;
317
317
  }
318
318
 
319
319
  .survey-workbench-embed .review-question strong{
@@ -323,7 +323,7 @@
323
323
  }
324
324
 
325
325
  .survey-workbench-embed .meta-grid{
326
- display: grid;
326
+ display: none;
327
327
  grid-template-columns: repeat(4, minmax(110px, 1fr));
328
328
  gap: 10px;
329
329
  width: 100%;
@@ -361,13 +361,13 @@
361
361
  .survey-workbench-embed .queue-layout{
362
362
  display: grid;
363
363
  grid-template-columns: 280px minmax(0, 1fr);
364
- gap: 22px;
364
+ gap: 16px;
365
365
  align-items: start;
366
366
  }
367
367
 
368
368
  .survey-workbench-embed .queue-panel{
369
369
  display: grid;
370
- gap: 18px;
370
+ gap: 14px;
371
371
  position: sticky;
372
372
  top: 18px;
373
373
  }
@@ -382,7 +382,7 @@
382
382
  border: 1px solid var(--line);
383
383
  border-radius: var(--radius);
384
384
  background: linear-gradient(180deg, var(--ink-800), var(--ink-850));
385
- padding: 18px;
385
+ padding: 14px;
386
386
  box-shadow: 0 22px 50px -38px rgba(0, 0, 0, 0.9);
387
387
  animation: rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
388
388
  animation-delay: 0.05s;
@@ -401,7 +401,7 @@
401
401
  .survey-workbench-embed .session-audit h2{
402
402
  font-family: "Fraunces", Georgia, serif;
403
403
  font-weight: 600;
404
- font-size: 18px;
404
+ font-size: 16px;
405
405
  line-height: 1.1;
406
406
  letter-spacing: -0.01em;
407
407
  }
@@ -414,12 +414,12 @@
414
414
  gap: 10px;
415
415
  align-items: center;
416
416
  width: 100%;
417
- min-height: 60px;
417
+ min-height: 54px;
418
418
  border: 1px solid var(--line);
419
419
  border-left: 3px solid var(--paper-faint);
420
420
  border-radius: var(--radius-sm);
421
- margin-top: 9px;
422
- padding: 11px 12px;
421
+ margin-top: 8px;
422
+ padding: 9px 10px;
423
423
  background: rgba(8, 12, 18, 0.5);
424
424
  color: var(--paper);
425
425
  cursor: pointer;
@@ -521,13 +521,13 @@
521
521
  .survey-workbench-embed .summary-grid .meta-item{
522
522
  display: grid;
523
523
  gap: 2px;
524
- padding: 12px;
524
+ padding: 10px;
525
525
  background: rgba(8, 12, 18, 0.6);
526
526
  }
527
527
 
528
528
  .survey-workbench-embed .summary-grid .meta-value{
529
529
  font-family: "Fraunces", Georgia, serif;
530
- font-size: 28px;
530
+ font-size: 20px;
531
531
  font-weight: 700;
532
532
  line-height: 1;
533
533
  color: var(--paper);
@@ -544,7 +544,7 @@
544
544
  .survey-workbench-embed .session-audit-head{
545
545
  display: grid;
546
546
  grid-template-columns: minmax(0, 1fr) auto;
547
- gap: 10px;
547
+ gap: 8px;
548
548
  align-items: start;
549
549
  }
550
550
 
@@ -559,8 +559,8 @@
559
559
 
560
560
  .survey-workbench-embed .audit-grid .meta-value{
561
561
  font-family: "IBM Plex Mono", ui-monospace, monospace;
562
- font-size: 12px;
563
- line-height: 1.35;
562
+ font-size: 11px;
563
+ line-height: 1.3;
564
564
  }
565
565
 
566
566
  .survey-workbench-embed .session-event-list{
@@ -573,20 +573,20 @@
573
573
 
574
574
  .survey-workbench-embed .session-event-list li{
575
575
  display: grid;
576
- grid-template-columns: 30px minmax(0, 1fr);
577
- gap: 9px;
576
+ grid-template-columns: 24px minmax(0, 1fr);
577
+ gap: 8px;
578
578
  min-width: 0;
579
579
  border: 1px solid var(--line);
580
580
  border-radius: var(--radius-sm);
581
- padding: 9px 10px;
581
+ padding: 8px;
582
582
  background: rgba(6, 9, 13, 0.45);
583
583
  }
584
584
 
585
585
  .survey-workbench-embed .event-sequence{
586
586
  display: grid;
587
587
  place-items: center;
588
- width: 28px;
589
- height: 28px;
588
+ width: 24px;
589
+ height: 24px;
590
590
  border: 1px solid var(--line-strong);
591
591
  border-radius: 999px;
592
592
  color: var(--accent);
@@ -605,13 +605,13 @@
605
605
  .survey-workbench-embed .session-event-list strong{
606
606
  color: var(--paper);
607
607
  font-family: "IBM Plex Mono", ui-monospace, monospace;
608
- font-size: 12px;
608
+ font-size: 11px;
609
609
  }
610
610
 
611
611
  .survey-workbench-embed .session-event-list small{
612
612
  margin-top: 3px;
613
613
  color: var(--paper-faint);
614
- font-size: 11.5px;
614
+ font-size: 10.5px;
615
615
  line-height: 1.35;
616
616
  }
617
617
 
@@ -642,13 +642,13 @@
642
642
  "focus"
643
643
  "decision"
644
644
  "candidates";
645
- gap: 22px;
645
+ gap: 14px;
646
646
  align-items: start;
647
647
  }
648
648
 
649
649
  .survey-workbench-embed .review-main{
650
650
  display: grid;
651
- gap: 18px;
651
+ gap: 14px;
652
652
  min-width: 0;
653
653
  }
654
654
 
@@ -657,11 +657,11 @@
657
657
  .survey-workbench-embed .review-focus{
658
658
  grid-area: focus;
659
659
  display: grid;
660
- gap: 16px;
660
+ gap: 12px;
661
661
  min-width: 0;
662
662
  border: 1px solid rgba(92, 224, 198, 0.28);
663
663
  border-radius: var(--radius);
664
- padding: 18px;
664
+ padding: 14px;
665
665
  background:
666
666
  linear-gradient(135deg, rgba(92, 224, 198, 0.12), transparent 34%),
667
667
  linear-gradient(180deg, var(--ink-800), var(--ink-850));
@@ -671,7 +671,7 @@
671
671
  .survey-workbench-embed .focus-head,
672
672
  .survey-workbench-embed .focus-values{
673
673
  display: grid;
674
- gap: 12px;
674
+ gap: 10px;
675
675
  }
676
676
 
677
677
  .survey-workbench-embed .focus-head{
@@ -687,23 +687,23 @@
687
687
  min-width: 0;
688
688
  border: 1px solid var(--line);
689
689
  border-radius: var(--radius-sm);
690
- padding: 13px 14px;
690
+ padding: 10px 12px;
691
691
  background: rgba(6, 9, 13, 0.56);
692
692
  }
693
693
 
694
694
  .survey-workbench-embed .focus-value strong{
695
695
  display: block;
696
- margin-top: 8px;
696
+ margin-top: 6px;
697
697
  color: var(--paper);
698
698
  font-family: "IBM Plex Mono", ui-monospace, monospace;
699
- font-size: clamp(22px, 3vw, 34px);
700
- line-height: 1.05;
699
+ font-size: clamp(18px, 1.8vw, 25px);
700
+ line-height: 1.14;
701
701
  overflow-wrap: anywhere;
702
702
  }
703
703
 
704
704
  .survey-workbench-embed .focus-value span:last-child{
705
705
  display: block;
706
- margin-top: 8px;
706
+ margin-top: 6px;
707
707
  color: var(--paper-faint);
708
708
  font-family: "IBM Plex Mono", ui-monospace, monospace;
709
709
  font-size: 11px;
@@ -721,13 +721,13 @@
721
721
  .survey-workbench-embed .focus-evidence{
722
722
  display: grid;
723
723
  grid-template-columns: minmax(110px, 0.65fr) minmax(0, 1.2fr) minmax(0, 1.4fr);
724
- gap: 12px;
724
+ gap: 10px;
725
725
  margin: 0;
726
726
  }
727
727
 
728
728
  .survey-workbench-embed .focus-evidence .field{
729
729
  border-top: 1px solid var(--line);
730
- padding-top: 12px;
730
+ padding-top: 10px;
731
731
  }
732
732
 
733
733
  /* ---- Candidate comparison: the hero of the console -------------------- */
@@ -736,7 +736,7 @@
736
736
  grid-area: candidates;
737
737
  display: grid;
738
738
  grid-template-columns: repeat(2, minmax(0, 1fr));
739
- gap: 18px;
739
+ gap: 12px;
740
740
  position: relative;
741
741
  }
742
742
 
@@ -744,12 +744,12 @@
744
744
  .survey-workbench-embed .candidate-grid::before{
745
745
  content: "vs";
746
746
  position: absolute;
747
- top: 26px;
747
+ top: 18px;
748
748
  left: 50%;
749
749
  transform: translateX(-50%);
750
750
  z-index: 3;
751
- width: 38px;
752
- height: 38px;
751
+ width: 30px;
752
+ height: 30px;
753
753
  display: grid;
754
754
  place-items: center;
755
755
  border-radius: 999px;
@@ -758,7 +758,7 @@
758
758
  color: var(--paper-faint);
759
759
  font-family: "Fraunces", Georgia, serif;
760
760
  font-style: italic;
761
- font-size: 15px;
761
+ font-size: 13px;
762
762
  box-shadow: 0 10px 26px -12px rgba(0, 0, 0, 0.9);
763
763
  }
764
764
 
@@ -775,9 +775,9 @@
775
775
  .survey-workbench-embed .candidate-card{
776
776
  display: grid;
777
777
  grid-template-rows: auto auto minmax(0, 1fr);
778
- gap: 16px;
779
- min-height: 460px;
780
- padding: 20px;
778
+ gap: 11px;
779
+ min-height: auto;
780
+ padding: 14px;
781
781
  position: relative;
782
782
  overflow: hidden;
783
783
  animation: rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
@@ -809,7 +809,7 @@
809
809
 
810
810
  .survey-workbench-embed .card-head{
811
811
  display: flex;
812
- gap: 12px;
812
+ gap: 10px;
813
813
  justify-content: space-between;
814
814
  align-items: flex-start;
815
815
  position: relative;
@@ -826,10 +826,10 @@
826
826
  }
827
827
 
828
828
  .survey-workbench-embed .role{
829
- margin-top: 4px;
829
+ margin-top: 3px;
830
830
  font-family: "Fraunces", Georgia, serif;
831
831
  font-weight: 600;
832
- font-size: 22px;
832
+ font-size: 18px;
833
833
  letter-spacing: -0.01em;
834
834
  color: var(--paper);
835
835
  }
@@ -849,16 +849,16 @@
849
849
  position: relative;
850
850
  z-index: 1;
851
851
  border-block: 1px solid var(--line);
852
- padding: 18px 0;
852
+ padding: 10px 0;
853
853
  }
854
854
 
855
855
  .survey-workbench-embed .candidate-value .field-value{
856
- margin-top: 10px;
856
+ margin-top: 7px;
857
857
  font-family: "IBM Plex Mono", ui-monospace, monospace;
858
- font-size: clamp(26px, 3vw, 40px);
858
+ font-size: clamp(16px, 1.35vw, 20px);
859
859
  font-weight: 600;
860
- line-height: 1.05;
861
- letter-spacing: -0.02em;
860
+ line-height: 1.22;
861
+ letter-spacing: 0;
862
862
  color: var(--paper);
863
863
  }
864
864
 
@@ -872,34 +872,34 @@
872
872
 
873
873
  .survey-workbench-embed .field-stack{
874
874
  display: grid;
875
- gap: 14px;
875
+ gap: 9px;
876
876
  position: relative;
877
877
  z-index: 1;
878
878
  align-content: start;
879
879
  }
880
880
 
881
881
  .survey-workbench-embed .field-value{
882
- margin-top: 5px;
883
- font-size: 14px;
882
+ margin-top: 4px;
883
+ font-size: 12.5px;
884
884
  }
885
885
 
886
886
  /* Source refs / locators / ids read as data. */
887
887
  .survey-workbench-embed .candidate-card .field-stack .field-value{
888
888
  font-family: "IBM Plex Mono", ui-monospace, monospace;
889
- font-size: 12.5px;
889
+ font-size: 11.5px;
890
890
  color: var(--paper-dim);
891
891
  }
892
892
 
893
893
  /* Highlight extraction confidence (5th field in the stack) as a chip. */
894
894
  .survey-workbench-embed .candidate-card .field-stack > .field:nth-child(5) .field-value{
895
895
  display: inline-block;
896
- margin-top: 6px;
897
- padding: 5px 11px;
896
+ margin-top: 5px;
897
+ padding: 4px 9px;
898
898
  border: 1px solid rgba(92, 224, 198, 0.35);
899
899
  border-radius: 999px;
900
900
  background: rgba(92, 224, 198, 0.1);
901
901
  color: var(--accent);
902
- font-size: 13px;
902
+ font-size: 11.5px;
903
903
  font-weight: 600;
904
904
  }
905
905
 
@@ -919,7 +919,7 @@
919
919
  grid-area: decision;
920
920
  display: grid;
921
921
  grid-template-columns: minmax(0, 1fr);
922
- gap: 18px;
922
+ gap: 12px;
923
923
  animation: rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
924
924
  animation-delay: 0.15s;
925
925
  }
@@ -927,22 +927,22 @@
927
927
  .survey-workbench-embed .decision-row,
928
928
  .survey-workbench-embed .payload-panel,
929
929
  .survey-workbench-embed .surface-preview{
930
- padding: 20px;
930
+ padding: 14px;
931
931
  }
932
932
 
933
933
  .survey-workbench-embed textarea{
934
934
  display: block;
935
935
  width: 100%;
936
- min-height: 104px;
937
- margin-top: 10px;
936
+ min-height: 74px;
937
+ margin-top: 8px;
938
938
  resize: vertical;
939
939
  border: 1px solid var(--line-strong);
940
940
  border-radius: var(--radius-sm);
941
- padding: 12px;
941
+ padding: 10px;
942
942
  color: var(--paper);
943
943
  background: rgba(6, 9, 13, 0.7);
944
944
  font-family: "IBM Plex Mono", ui-monospace, monospace;
945
- font-size: 13px;
945
+ font-size: 12px;
946
946
  line-height: 1.5;
947
947
  }
948
948
 
@@ -960,19 +960,19 @@
960
960
  .survey-workbench-embed .decision-buttons{
961
961
  display: grid;
962
962
  grid-template-columns: repeat(3, minmax(0, 1fr));
963
- gap: 10px;
964
- margin-top: 16px;
963
+ gap: 8px;
964
+ margin-top: 0;
965
965
  }
966
966
 
967
967
  .survey-workbench-embed .decision-button{
968
- min-height: 50px;
968
+ min-height: 42px;
969
969
  border: 1px solid var(--line-strong);
970
970
  border-radius: var(--radius-sm);
971
971
  background: rgba(8, 12, 18, 0.6);
972
972
  color: var(--paper);
973
973
  cursor: pointer;
974
974
  font-weight: 700;
975
- font-size: 13px;
975
+ font-size: 12px;
976
976
  letter-spacing: 0.01em;
977
977
  transition: transform 0.14s ease, border-color 0.14s ease, background 0.14s ease, box-shadow 0.14s ease;
978
978
  }
@@ -999,23 +999,23 @@
999
999
  .survey-workbench-embed .effect{
1000
1000
  display: grid;
1001
1001
  gap: 7px;
1002
- margin-top: 16px;
1002
+ margin-top: 12px;
1003
1003
  border-top: 1px solid var(--line);
1004
- padding-top: 14px;
1004
+ padding-top: 11px;
1005
1005
  }
1006
1006
 
1007
1007
  .survey-workbench-embed .effect .field-value{
1008
- font-size: 14px;
1009
- line-height: 1.5;
1008
+ font-size: 12.5px;
1009
+ line-height: 1.45;
1010
1010
  color: var(--paper-dim);
1011
1011
  }
1012
1012
 
1013
1013
  .survey-workbench-embed .feedback-tags{
1014
1014
  display: grid;
1015
- gap: 9px;
1016
- margin-top: 16px;
1015
+ gap: 8px;
1016
+ margin-top: 12px;
1017
1017
  border-top: 1px solid var(--line);
1018
- padding-top: 14px;
1018
+ padding-top: 11px;
1019
1019
  }
1020
1020
 
1021
1021
  .survey-workbench-embed .tag-row{
@@ -1044,7 +1044,7 @@
1044
1044
 
1045
1045
  .survey-workbench-embed .surface-preview{
1046
1046
  display: grid;
1047
- gap: 14px;
1047
+ gap: 11px;
1048
1048
  }
1049
1049
 
1050
1050
  .survey-workbench-embed .surface-head{
@@ -1057,7 +1057,7 @@
1057
1057
  .survey-workbench-embed .surface-head h2{
1058
1058
  font-family: "Fraunces", Georgia, serif;
1059
1059
  font-weight: 600;
1060
- font-size: 19px;
1060
+ font-size: 16px;
1061
1061
  letter-spacing: -0.01em;
1062
1062
  }
1063
1063
 
@@ -1072,22 +1072,22 @@
1072
1072
  .survey-workbench-embed .preview-section-grid{
1073
1073
  display: grid;
1074
1074
  grid-template-columns: repeat(2, minmax(0, 1fr));
1075
- gap: 10px;
1075
+ gap: 8px;
1076
1076
  }
1077
1077
 
1078
1078
  .survey-workbench-embed .preview-section{
1079
1079
  min-width: 0;
1080
1080
  border: 1px solid var(--line);
1081
1081
  border-radius: var(--radius-sm);
1082
- padding: 13px 14px;
1082
+ padding: 10px 11px;
1083
1083
  background: rgba(6, 9, 13, 0.55);
1084
1084
  }
1085
1085
 
1086
1086
  .survey-workbench-embed .preview-section h3{
1087
- margin-bottom: 10px;
1087
+ margin-bottom: 7px;
1088
1088
  color: var(--accent);
1089
1089
  font-family: "IBM Plex Mono", ui-monospace, monospace;
1090
- font-size: 11px;
1090
+ font-size: 10px;
1091
1091
  font-weight: 600;
1092
1092
  letter-spacing: 0.1em;
1093
1093
  text-transform: uppercase;
@@ -1119,22 +1119,31 @@
1119
1119
  background: linear-gradient(180deg, var(--ink-850), var(--ink-900));
1120
1120
  }
1121
1121
 
1122
- .survey-workbench-embed .payload-panel h2.field-label::before{
1122
+ .survey-workbench-embed .payload-panel summary.field-label{
1123
+ cursor: pointer;
1124
+ list-style: none;
1125
+ }
1126
+
1127
+ .survey-workbench-embed .payload-panel summary.field-label::-webkit-details-marker{
1128
+ display: none;
1129
+ }
1130
+
1131
+ .survey-workbench-embed .payload-panel summary.field-label::before{
1123
1132
  content: "› ";
1124
1133
  color: var(--verify);
1125
1134
  }
1126
1135
 
1127
1136
  .survey-workbench-embed pre{
1128
- max-height: 460px;
1137
+ max-height: 280px;
1129
1138
  margin: 12px 0 0;
1130
1139
  overflow: auto;
1131
1140
  border: 1px solid var(--line);
1132
1141
  border-radius: var(--radius-sm);
1133
1142
  background: var(--ink-1000);
1134
- padding: 14px;
1143
+ padding: 11px;
1135
1144
  color: #b6f3df;
1136
1145
  font-family: "IBM Plex Mono", ui-monospace, monospace;
1137
- font-size: 11.5px;
1146
+ font-size: 11px;
1138
1147
  line-height: 1.55;
1139
1148
  white-space: pre-wrap;
1140
1149
  word-break: break-word;
@@ -221,8 +221,8 @@ export function renderReviewWorkbenchHtml(state, events) {
221
221
  ${renderWorkbenchHeader(state)}
222
222
  <div class="content-grid">
223
223
  ${renderReviewFocus(state)}
224
- ${renderCandidateComparison(state)}
225
224
  ${renderDecisionColumn(state)}
225
+ ${renderCandidateComparison(state)}
226
226
  </div>
227
227
  </section>
228
228
  `;
@@ -242,8 +242,8 @@ function renderReviewQueueSessionHtml(session, events) {
242
242
  </aside>
243
243
  <div class="content-grid">
244
244
  ${renderReviewFocus(state)}
245
- ${renderCandidateComparison(state)}
246
245
  ${renderDecisionColumn(state)}
246
+ ${renderCandidateComparison(state)}
247
247
  </div>
248
248
  </div>
249
249
  </section>
@@ -363,9 +363,6 @@ function renderActiveReviewStrip(session, state) {
363
363
  <span class="state-label">${escapeHtml(status)}</span>
364
364
  <button class="next-button" type="button" data-testid="active-next-unresolved">Next unresolved</button>
365
365
  </div>
366
- <div class="active-review-decisions" aria-label="Quick review decision">
367
- ${renderDecisionButtons(state)}
368
- </div>
369
366
  </section>
370
367
  `;
371
368
  }
@@ -451,10 +448,6 @@ function renderDecisionControls(state) {
451
448
  const activeDefinition = state.decision ? workbenchDecisionDefinitions[state.decision] : undefined;
452
449
  return `
453
450
  <section class="decision-row">
454
- <label class="field">
455
- <span class="field-label">Reviewer note</span>
456
- <textarea id="reviewer-note" data-testid="reviewer-note">${escapeHtml(state.note)}</textarea>
457
- </label>
458
451
  <div class="decision-buttons">
459
452
  ${renderDecisionButtons(state)}
460
453
  </div>
@@ -462,6 +455,10 @@ function renderDecisionControls(state) {
462
455
  <span class="field-label">Decision effect</span>
463
456
  <span class="field-value">${escapeHtml(activeDefinition?.effect ?? "No decision selected.")}</span>
464
457
  </div>
458
+ <label class="field">
459
+ <span class="field-label">Reviewer note</span>
460
+ <textarea id="reviewer-note" data-testid="reviewer-note">${escapeHtml(state.note)}</textarea>
461
+ </label>
465
462
  ${renderFeedbackTags(state)}
466
463
  </section>
467
464
  `;
@@ -487,10 +484,10 @@ function renderDecisionButtons(state) {
487
484
  function renderDecisionPayload(state) {
488
485
  const decision = buildReviewDecision(state);
489
486
  return `
490
- <section class="payload-panel">
491
- <h2 class="field-label">ReviewDecision payload</h2>
487
+ <details class="payload-panel">
488
+ <summary class="field-label">ReviewDecision payload</summary>
492
489
  <pre data-testid="decision-payload">${escapeHtml(JSON.stringify(decision ?? null, null, 2))}</pre>
493
- </section>
490
+ </details>
494
491
  `;
495
492
  }
496
493
  function renderSurfacePreview(state) {
@@ -80,13 +80,13 @@ p {
80
80
  z-index: 1;
81
81
  container-type: inline-size;
82
82
  min-height: 100vh;
83
- padding: 30px 26px 60px;
83
+ padding: 22px 22px 50px;
84
84
  }
85
85
 
86
86
  .workbench-shell {
87
87
  display: grid;
88
88
  grid-template-rows: auto minmax(0, 1fr);
89
- gap: 22px;
89
+ gap: 16px;
90
90
  max-width: 1360px;
91
91
  margin: 0 auto;
92
92
  }
@@ -121,10 +121,10 @@ p {
121
121
 
122
122
  .topbar {
123
123
  display: grid;
124
- grid-template-columns: minmax(0, 1fr) minmax(0, 520px);
125
- gap: 26px;
124
+ grid-template-columns: minmax(0, 1fr);
125
+ gap: 12px;
126
126
  align-items: center;
127
- padding: 22px 26px;
127
+ padding: 15px 17px;
128
128
  border: 1px solid var(--line-strong);
129
129
  border-radius: var(--radius);
130
130
  background:
@@ -144,12 +144,12 @@ p {
144
144
  }
145
145
 
146
146
  h1 {
147
- margin-top: 8px;
147
+ margin-top: 6px;
148
148
  font-family: "Fraunces", Georgia, "Times New Roman", serif;
149
149
  font-optical-sizing: auto;
150
150
  font-weight: 600;
151
- font-size: clamp(26px, 3.4vw, 38px);
152
- line-height: 1.04;
151
+ font-size: clamp(21px, 2vw, 27px);
152
+ line-height: 1.08;
153
153
  letter-spacing: -0.01em;
154
154
  overflow-wrap: anywhere;
155
155
  color: var(--paper);
@@ -157,10 +157,10 @@ h1 {
157
157
 
158
158
  .review-question {
159
159
  max-width: 720px;
160
- margin-top: 10px;
160
+ margin-top: 7px;
161
161
  color: var(--paper-dim);
162
- font-size: 15px;
163
- line-height: 1.45;
162
+ font-size: 13px;
163
+ line-height: 1.4;
164
164
  }
165
165
 
166
166
  .review-question strong {
@@ -170,7 +170,7 @@ h1 {
170
170
  }
171
171
 
172
172
  .meta-grid {
173
- display: grid;
173
+ display: none;
174
174
  grid-template-columns: repeat(4, minmax(110px, 1fr));
175
175
  gap: 10px;
176
176
  width: 100%;
@@ -208,13 +208,13 @@ h1 {
208
208
  .queue-layout {
209
209
  display: grid;
210
210
  grid-template-columns: 280px minmax(0, 1fr);
211
- gap: 22px;
211
+ gap: 16px;
212
212
  align-items: start;
213
213
  }
214
214
 
215
215
  .queue-panel {
216
216
  display: grid;
217
- gap: 18px;
217
+ gap: 14px;
218
218
  position: sticky;
219
219
  top: 18px;
220
220
  }
@@ -229,7 +229,7 @@ h1 {
229
229
  border: 1px solid var(--line);
230
230
  border-radius: var(--radius);
231
231
  background: linear-gradient(180deg, var(--ink-800), var(--ink-850));
232
- padding: 18px;
232
+ padding: 14px;
233
233
  box-shadow: 0 22px 50px -38px rgba(0, 0, 0, 0.9);
234
234
  animation: rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
235
235
  animation-delay: 0.05s;
@@ -248,7 +248,7 @@ h1 {
248
248
  .session-audit h2 {
249
249
  font-family: "Fraunces", Georgia, serif;
250
250
  font-weight: 600;
251
- font-size: 18px;
251
+ font-size: 16px;
252
252
  line-height: 1.1;
253
253
  letter-spacing: -0.01em;
254
254
  }
@@ -261,12 +261,12 @@ h1 {
261
261
  gap: 10px;
262
262
  align-items: center;
263
263
  width: 100%;
264
- min-height: 60px;
264
+ min-height: 54px;
265
265
  border: 1px solid var(--line);
266
266
  border-left: 3px solid var(--paper-faint);
267
267
  border-radius: var(--radius-sm);
268
- margin-top: 9px;
269
- padding: 11px 12px;
268
+ margin-top: 8px;
269
+ padding: 9px 10px;
270
270
  background: rgba(8, 12, 18, 0.5);
271
271
  color: var(--paper);
272
272
  cursor: pointer;
@@ -368,13 +368,13 @@ h1 {
368
368
  .summary-grid .meta-item {
369
369
  display: grid;
370
370
  gap: 2px;
371
- padding: 12px;
371
+ padding: 10px;
372
372
  background: rgba(8, 12, 18, 0.6);
373
373
  }
374
374
 
375
375
  .summary-grid .meta-value {
376
376
  font-family: "Fraunces", Georgia, serif;
377
- font-size: 28px;
377
+ font-size: 20px;
378
378
  font-weight: 700;
379
379
  line-height: 1;
380
380
  color: var(--paper);
@@ -391,7 +391,7 @@ h1 {
391
391
  .session-audit-head {
392
392
  display: grid;
393
393
  grid-template-columns: minmax(0, 1fr) auto;
394
- gap: 10px;
394
+ gap: 8px;
395
395
  align-items: start;
396
396
  }
397
397
 
@@ -406,8 +406,8 @@ h1 {
406
406
 
407
407
  .audit-grid .meta-value {
408
408
  font-family: "IBM Plex Mono", ui-monospace, monospace;
409
- font-size: 12px;
410
- line-height: 1.35;
409
+ font-size: 11px;
410
+ line-height: 1.3;
411
411
  }
412
412
 
413
413
  .session-event-list {
@@ -420,20 +420,20 @@ h1 {
420
420
 
421
421
  .session-event-list li {
422
422
  display: grid;
423
- grid-template-columns: 30px minmax(0, 1fr);
424
- gap: 9px;
423
+ grid-template-columns: 24px minmax(0, 1fr);
424
+ gap: 8px;
425
425
  min-width: 0;
426
426
  border: 1px solid var(--line);
427
427
  border-radius: var(--radius-sm);
428
- padding: 9px 10px;
428
+ padding: 8px;
429
429
  background: rgba(6, 9, 13, 0.45);
430
430
  }
431
431
 
432
432
  .event-sequence {
433
433
  display: grid;
434
434
  place-items: center;
435
- width: 28px;
436
- height: 28px;
435
+ width: 24px;
436
+ height: 24px;
437
437
  border: 1px solid var(--line-strong);
438
438
  border-radius: 999px;
439
439
  color: var(--accent);
@@ -452,13 +452,13 @@ h1 {
452
452
  .session-event-list strong {
453
453
  color: var(--paper);
454
454
  font-family: "IBM Plex Mono", ui-monospace, monospace;
455
- font-size: 12px;
455
+ font-size: 11px;
456
456
  }
457
457
 
458
458
  .session-event-list small {
459
459
  margin-top: 3px;
460
460
  color: var(--paper-faint);
461
- font-size: 11.5px;
461
+ font-size: 10.5px;
462
462
  line-height: 1.35;
463
463
  }
464
464
 
@@ -489,13 +489,13 @@ h1 {
489
489
  "focus"
490
490
  "decision"
491
491
  "candidates";
492
- gap: 22px;
492
+ gap: 14px;
493
493
  align-items: start;
494
494
  }
495
495
 
496
496
  .review-main {
497
497
  display: grid;
498
- gap: 18px;
498
+ gap: 14px;
499
499
  min-width: 0;
500
500
  }
501
501
 
@@ -504,11 +504,11 @@ h1 {
504
504
  .review-focus {
505
505
  grid-area: focus;
506
506
  display: grid;
507
- gap: 16px;
507
+ gap: 12px;
508
508
  min-width: 0;
509
509
  border: 1px solid rgba(92, 224, 198, 0.28);
510
510
  border-radius: var(--radius);
511
- padding: 18px;
511
+ padding: 14px;
512
512
  background:
513
513
  linear-gradient(135deg, rgba(92, 224, 198, 0.12), transparent 34%),
514
514
  linear-gradient(180deg, var(--ink-800), var(--ink-850));
@@ -518,7 +518,7 @@ h1 {
518
518
  .focus-head,
519
519
  .focus-values {
520
520
  display: grid;
521
- gap: 12px;
521
+ gap: 10px;
522
522
  }
523
523
 
524
524
  .focus-head {
@@ -534,23 +534,23 @@ h1 {
534
534
  min-width: 0;
535
535
  border: 1px solid var(--line);
536
536
  border-radius: var(--radius-sm);
537
- padding: 13px 14px;
537
+ padding: 10px 12px;
538
538
  background: rgba(6, 9, 13, 0.56);
539
539
  }
540
540
 
541
541
  .focus-value strong {
542
542
  display: block;
543
- margin-top: 8px;
543
+ margin-top: 6px;
544
544
  color: var(--paper);
545
545
  font-family: "IBM Plex Mono", ui-monospace, monospace;
546
- font-size: clamp(22px, 3vw, 34px);
547
- line-height: 1.05;
546
+ font-size: clamp(18px, 1.8vw, 25px);
547
+ line-height: 1.14;
548
548
  overflow-wrap: anywhere;
549
549
  }
550
550
 
551
551
  .focus-value span:last-child {
552
552
  display: block;
553
- margin-top: 8px;
553
+ margin-top: 6px;
554
554
  color: var(--paper-faint);
555
555
  font-family: "IBM Plex Mono", ui-monospace, monospace;
556
556
  font-size: 11px;
@@ -568,13 +568,13 @@ h1 {
568
568
  .focus-evidence {
569
569
  display: grid;
570
570
  grid-template-columns: minmax(110px, 0.65fr) minmax(0, 1.2fr) minmax(0, 1.4fr);
571
- gap: 12px;
571
+ gap: 10px;
572
572
  margin: 0;
573
573
  }
574
574
 
575
575
  .focus-evidence .field {
576
576
  border-top: 1px solid var(--line);
577
- padding-top: 12px;
577
+ padding-top: 10px;
578
578
  }
579
579
 
580
580
  /* ---- Candidate comparison: the hero of the console -------------------- */
@@ -583,7 +583,7 @@ h1 {
583
583
  grid-area: candidates;
584
584
  display: grid;
585
585
  grid-template-columns: repeat(2, minmax(0, 1fr));
586
- gap: 18px;
586
+ gap: 12px;
587
587
  position: relative;
588
588
  }
589
589
 
@@ -591,12 +591,12 @@ h1 {
591
591
  .candidate-grid::before {
592
592
  content: "vs";
593
593
  position: absolute;
594
- top: 26px;
594
+ top: 18px;
595
595
  left: 50%;
596
596
  transform: translateX(-50%);
597
597
  z-index: 3;
598
- width: 38px;
599
- height: 38px;
598
+ width: 30px;
599
+ height: 30px;
600
600
  display: grid;
601
601
  place-items: center;
602
602
  border-radius: 999px;
@@ -605,7 +605,7 @@ h1 {
605
605
  color: var(--paper-faint);
606
606
  font-family: "Fraunces", Georgia, serif;
607
607
  font-style: italic;
608
- font-size: 15px;
608
+ font-size: 13px;
609
609
  box-shadow: 0 10px 26px -12px rgba(0, 0, 0, 0.9);
610
610
  }
611
611
 
@@ -622,9 +622,9 @@ h1 {
622
622
  .candidate-card {
623
623
  display: grid;
624
624
  grid-template-rows: auto auto minmax(0, 1fr);
625
- gap: 16px;
626
- min-height: 460px;
627
- padding: 20px;
625
+ gap: 11px;
626
+ min-height: auto;
627
+ padding: 14px;
628
628
  position: relative;
629
629
  overflow: hidden;
630
630
  animation: rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
@@ -656,7 +656,7 @@ h1 {
656
656
 
657
657
  .card-head {
658
658
  display: flex;
659
- gap: 12px;
659
+ gap: 10px;
660
660
  justify-content: space-between;
661
661
  align-items: flex-start;
662
662
  position: relative;
@@ -673,10 +673,10 @@ h1 {
673
673
  }
674
674
 
675
675
  .role {
676
- margin-top: 4px;
676
+ margin-top: 3px;
677
677
  font-family: "Fraunces", Georgia, serif;
678
678
  font-weight: 600;
679
- font-size: 22px;
679
+ font-size: 18px;
680
680
  letter-spacing: -0.01em;
681
681
  color: var(--paper);
682
682
  }
@@ -696,16 +696,16 @@ h1 {
696
696
  position: relative;
697
697
  z-index: 1;
698
698
  border-block: 1px solid var(--line);
699
- padding: 18px 0;
699
+ padding: 10px 0;
700
700
  }
701
701
 
702
702
  .candidate-value .field-value {
703
- margin-top: 10px;
703
+ margin-top: 7px;
704
704
  font-family: "IBM Plex Mono", ui-monospace, monospace;
705
- font-size: clamp(26px, 3vw, 40px);
705
+ font-size: clamp(16px, 1.35vw, 20px);
706
706
  font-weight: 600;
707
- line-height: 1.05;
708
- letter-spacing: -0.02em;
707
+ line-height: 1.22;
708
+ letter-spacing: 0;
709
709
  color: var(--paper);
710
710
  }
711
711
 
@@ -719,34 +719,34 @@ h1 {
719
719
 
720
720
  .field-stack {
721
721
  display: grid;
722
- gap: 14px;
722
+ gap: 9px;
723
723
  position: relative;
724
724
  z-index: 1;
725
725
  align-content: start;
726
726
  }
727
727
 
728
728
  .field-value {
729
- margin-top: 5px;
730
- font-size: 14px;
729
+ margin-top: 4px;
730
+ font-size: 12.5px;
731
731
  }
732
732
 
733
733
  /* Source refs / locators / ids read as data. */
734
734
  .candidate-card .field-stack .field-value {
735
735
  font-family: "IBM Plex Mono", ui-monospace, monospace;
736
- font-size: 12.5px;
736
+ font-size: 11.5px;
737
737
  color: var(--paper-dim);
738
738
  }
739
739
 
740
740
  /* Highlight extraction confidence (5th field in the stack) as a chip. */
741
741
  .candidate-card .field-stack > .field:nth-child(5) .field-value {
742
742
  display: inline-block;
743
- margin-top: 6px;
744
- padding: 5px 11px;
743
+ margin-top: 5px;
744
+ padding: 4px 9px;
745
745
  border: 1px solid rgba(92, 224, 198, 0.35);
746
746
  border-radius: 999px;
747
747
  background: rgba(92, 224, 198, 0.1);
748
748
  color: var(--accent);
749
- font-size: 13px;
749
+ font-size: 11.5px;
750
750
  font-weight: 600;
751
751
  }
752
752
 
@@ -766,7 +766,7 @@ h1 {
766
766
  grid-area: decision;
767
767
  display: grid;
768
768
  grid-template-columns: minmax(0, 1fr);
769
- gap: 18px;
769
+ gap: 12px;
770
770
  animation: rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
771
771
  animation-delay: 0.15s;
772
772
  }
@@ -774,22 +774,22 @@ h1 {
774
774
  .decision-row,
775
775
  .payload-panel,
776
776
  .surface-preview {
777
- padding: 20px;
777
+ padding: 14px;
778
778
  }
779
779
 
780
780
  textarea {
781
781
  display: block;
782
782
  width: 100%;
783
- min-height: 104px;
784
- margin-top: 10px;
783
+ min-height: 74px;
784
+ margin-top: 8px;
785
785
  resize: vertical;
786
786
  border: 1px solid var(--line-strong);
787
787
  border-radius: var(--radius-sm);
788
- padding: 12px;
788
+ padding: 10px;
789
789
  color: var(--paper);
790
790
  background: rgba(6, 9, 13, 0.7);
791
791
  font-family: "IBM Plex Mono", ui-monospace, monospace;
792
- font-size: 13px;
792
+ font-size: 12px;
793
793
  line-height: 1.5;
794
794
  }
795
795
 
@@ -807,19 +807,19 @@ textarea:focus {
807
807
  .decision-buttons {
808
808
  display: grid;
809
809
  grid-template-columns: repeat(3, minmax(0, 1fr));
810
- gap: 10px;
811
- margin-top: 16px;
810
+ gap: 8px;
811
+ margin-top: 0;
812
812
  }
813
813
 
814
814
  .decision-button {
815
- min-height: 50px;
815
+ min-height: 42px;
816
816
  border: 1px solid var(--line-strong);
817
817
  border-radius: var(--radius-sm);
818
818
  background: rgba(8, 12, 18, 0.6);
819
819
  color: var(--paper);
820
820
  cursor: pointer;
821
821
  font-weight: 700;
822
- font-size: 13px;
822
+ font-size: 12px;
823
823
  letter-spacing: 0.01em;
824
824
  transition: transform 0.14s ease, border-color 0.14s ease, background 0.14s ease, box-shadow 0.14s ease;
825
825
  }
@@ -846,23 +846,23 @@ textarea:focus {
846
846
  .effect {
847
847
  display: grid;
848
848
  gap: 7px;
849
- margin-top: 16px;
849
+ margin-top: 12px;
850
850
  border-top: 1px solid var(--line);
851
- padding-top: 14px;
851
+ padding-top: 11px;
852
852
  }
853
853
 
854
854
  .effect .field-value {
855
- font-size: 14px;
856
- line-height: 1.5;
855
+ font-size: 12.5px;
856
+ line-height: 1.45;
857
857
  color: var(--paper-dim);
858
858
  }
859
859
 
860
860
  .feedback-tags {
861
861
  display: grid;
862
- gap: 9px;
863
- margin-top: 16px;
862
+ gap: 8px;
863
+ margin-top: 12px;
864
864
  border-top: 1px solid var(--line);
865
- padding-top: 14px;
865
+ padding-top: 11px;
866
866
  }
867
867
 
868
868
  .tag-row {
@@ -891,7 +891,7 @@ textarea:focus {
891
891
 
892
892
  .surface-preview {
893
893
  display: grid;
894
- gap: 14px;
894
+ gap: 11px;
895
895
  }
896
896
 
897
897
  .surface-head {
@@ -904,7 +904,7 @@ textarea:focus {
904
904
  .surface-head h2 {
905
905
  font-family: "Fraunces", Georgia, serif;
906
906
  font-weight: 600;
907
- font-size: 19px;
907
+ font-size: 16px;
908
908
  letter-spacing: -0.01em;
909
909
  }
910
910
 
@@ -919,22 +919,22 @@ textarea:focus {
919
919
  .preview-section-grid {
920
920
  display: grid;
921
921
  grid-template-columns: repeat(2, minmax(0, 1fr));
922
- gap: 10px;
922
+ gap: 8px;
923
923
  }
924
924
 
925
925
  .preview-section {
926
926
  min-width: 0;
927
927
  border: 1px solid var(--line);
928
928
  border-radius: var(--radius-sm);
929
- padding: 13px 14px;
929
+ padding: 10px 11px;
930
930
  background: rgba(6, 9, 13, 0.55);
931
931
  }
932
932
 
933
933
  .preview-section h3 {
934
- margin-bottom: 10px;
934
+ margin-bottom: 7px;
935
935
  color: var(--accent);
936
936
  font-family: "IBM Plex Mono", ui-monospace, monospace;
937
- font-size: 11px;
937
+ font-size: 10px;
938
938
  font-weight: 600;
939
939
  letter-spacing: 0.1em;
940
940
  text-transform: uppercase;
@@ -966,22 +966,31 @@ textarea:focus {
966
966
  background: linear-gradient(180deg, var(--ink-850), var(--ink-900));
967
967
  }
968
968
 
969
- .payload-panel h2.field-label::before {
969
+ .payload-panel summary.field-label {
970
+ cursor: pointer;
971
+ list-style: none;
972
+ }
973
+
974
+ .payload-panel summary.field-label::-webkit-details-marker {
975
+ display: none;
976
+ }
977
+
978
+ .payload-panel summary.field-label::before {
970
979
  content: "› ";
971
980
  color: var(--verify);
972
981
  }
973
982
 
974
983
  pre {
975
- max-height: 460px;
984
+ max-height: 280px;
976
985
  margin: 12px 0 0;
977
986
  overflow: auto;
978
987
  border: 1px solid var(--line);
979
988
  border-radius: var(--radius-sm);
980
989
  background: var(--ink-1000);
981
- padding: 14px;
990
+ padding: 11px;
982
991
  color: #b6f3df;
983
992
  font-family: "IBM Plex Mono", ui-monospace, monospace;
984
- font-size: 11.5px;
993
+ font-size: 11px;
985
994
  line-height: 1.55;
986
995
  white-space: pre-wrap;
987
996
  word-break: break-word;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kontourai/survey",
3
- "version": "0.4.10",
3
+ "version": "0.4.11",
4
4
  "description": "Producer-side source, extraction, candidate, and review contracts for projecting verified claims into Surface.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",