@youtyan/code-viewer 0.4.1 → 0.5.1
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/README.md +7 -0
- package/dist/code-viewer.js +4769 -3868
- package/package.json +1 -1
- package/web/app.js +373 -22
- package/web/index.html +3 -0
- package/web/style.css +197 -0
package/web/style.css
CHANGED
|
@@ -9699,3 +9699,200 @@ body.db-resizing {
|
|
|
9699
9699
|
.gdp-blame-error {
|
|
9700
9700
|
color: var(--danger, #c33);
|
|
9701
9701
|
}
|
|
9702
|
+
|
|
9703
|
+
/* ===== Doctor sheet (right-side drawer) ===== */
|
|
9704
|
+
.doctor-sheet {
|
|
9705
|
+
position: fixed;
|
|
9706
|
+
top: 0;
|
|
9707
|
+
right: 0;
|
|
9708
|
+
bottom: 0;
|
|
9709
|
+
width: min(560px, 92vw);
|
|
9710
|
+
max-width: 100vw;
|
|
9711
|
+
background: var(--bg, #fff);
|
|
9712
|
+
border-left: 1px solid var(--border, #d0d7de);
|
|
9713
|
+
box-shadow: -8px 0 24px rgba(0, 0, 0, 0.18);
|
|
9714
|
+
z-index: 60;
|
|
9715
|
+
overflow-y: auto;
|
|
9716
|
+
padding: 16px 20px 32px;
|
|
9717
|
+
box-sizing: border-box;
|
|
9718
|
+
transform: translateX(100%);
|
|
9719
|
+
transition: transform 200ms ease;
|
|
9720
|
+
}
|
|
9721
|
+
.doctor-sheet:not([hidden]) {
|
|
9722
|
+
transform: translateX(0);
|
|
9723
|
+
}
|
|
9724
|
+
.doctor-sheet[hidden] {
|
|
9725
|
+
display: block;
|
|
9726
|
+
pointer-events: none;
|
|
9727
|
+
}
|
|
9728
|
+
.doctor-sheet-overlay {
|
|
9729
|
+
position: fixed;
|
|
9730
|
+
inset: 0;
|
|
9731
|
+
background: rgba(0, 0, 0, 0.28);
|
|
9732
|
+
z-index: 55;
|
|
9733
|
+
opacity: 0;
|
|
9734
|
+
transition: opacity 200ms ease;
|
|
9735
|
+
pointer-events: none;
|
|
9736
|
+
}
|
|
9737
|
+
.doctor-sheet-overlay:not([hidden]) {
|
|
9738
|
+
opacity: 1;
|
|
9739
|
+
pointer-events: auto;
|
|
9740
|
+
}
|
|
9741
|
+
.doctor-sheet-overlay[hidden] {
|
|
9742
|
+
display: block;
|
|
9743
|
+
opacity: 0;
|
|
9744
|
+
pointer-events: none;
|
|
9745
|
+
}
|
|
9746
|
+
.doctor-header {
|
|
9747
|
+
display: flex;
|
|
9748
|
+
align-items: center;
|
|
9749
|
+
gap: 12px;
|
|
9750
|
+
padding: 8px 0 16px;
|
|
9751
|
+
border-bottom: 1px solid var(--border, #d0d7de);
|
|
9752
|
+
margin-bottom: 16px;
|
|
9753
|
+
}
|
|
9754
|
+
.doctor-close {
|
|
9755
|
+
font: inherit;
|
|
9756
|
+
font-size: 18px;
|
|
9757
|
+
line-height: 1;
|
|
9758
|
+
width: 28px;
|
|
9759
|
+
height: 28px;
|
|
9760
|
+
border-radius: 6px;
|
|
9761
|
+
border: 1px solid transparent;
|
|
9762
|
+
background: transparent;
|
|
9763
|
+
color: var(--fg-muted, #57606a);
|
|
9764
|
+
cursor: pointer;
|
|
9765
|
+
}
|
|
9766
|
+
.doctor-close:hover {
|
|
9767
|
+
background: var(--bg-mute, #eaeef2);
|
|
9768
|
+
color: var(--fg, #1f2328);
|
|
9769
|
+
}
|
|
9770
|
+
.doctor-header h1 {
|
|
9771
|
+
font-size: 18px;
|
|
9772
|
+
margin: 0;
|
|
9773
|
+
flex: 1;
|
|
9774
|
+
}
|
|
9775
|
+
.doctor-refresh {
|
|
9776
|
+
font: inherit;
|
|
9777
|
+
font-size: 12px;
|
|
9778
|
+
padding: 4px 12px;
|
|
9779
|
+
border-radius: 6px;
|
|
9780
|
+
border: 1px solid var(--border, #d0d7de);
|
|
9781
|
+
background: var(--bg-soft, #f6f8fa);
|
|
9782
|
+
color: var(--fg);
|
|
9783
|
+
cursor: pointer;
|
|
9784
|
+
}
|
|
9785
|
+
.doctor-refresh:hover {
|
|
9786
|
+
background: var(--bg-mute, #eaeef2);
|
|
9787
|
+
}
|
|
9788
|
+
.doctor-refresh[disabled] {
|
|
9789
|
+
cursor: progress;
|
|
9790
|
+
opacity: 0.6;
|
|
9791
|
+
}
|
|
9792
|
+
.doctor-summary {
|
|
9793
|
+
font-size: 12px;
|
|
9794
|
+
color: var(--fg-muted);
|
|
9795
|
+
margin-bottom: 16px;
|
|
9796
|
+
}
|
|
9797
|
+
.doctor-group {
|
|
9798
|
+
border: 1px solid var(--border, #d0d7de);
|
|
9799
|
+
border-radius: 8px;
|
|
9800
|
+
padding: 12px 16px;
|
|
9801
|
+
margin-bottom: 12px;
|
|
9802
|
+
background: var(--bg, #fff);
|
|
9803
|
+
}
|
|
9804
|
+
.doctor-group-title {
|
|
9805
|
+
font-size: 13px;
|
|
9806
|
+
font-weight: 600;
|
|
9807
|
+
margin: 0 0 8px 0;
|
|
9808
|
+
color: var(--fg-muted);
|
|
9809
|
+
text-transform: uppercase;
|
|
9810
|
+
letter-spacing: 0.04em;
|
|
9811
|
+
}
|
|
9812
|
+
.doctor-row {
|
|
9813
|
+
display: grid;
|
|
9814
|
+
grid-template-columns: 90px 1fr;
|
|
9815
|
+
gap: 12px;
|
|
9816
|
+
padding: 8px 0;
|
|
9817
|
+
border-top: 1px solid var(--bg-mute, #eaeef2);
|
|
9818
|
+
align-items: start;
|
|
9819
|
+
}
|
|
9820
|
+
.doctor-row:first-of-type {
|
|
9821
|
+
border-top: 0;
|
|
9822
|
+
}
|
|
9823
|
+
.doctor-row-pill {
|
|
9824
|
+
font-size: 10px;
|
|
9825
|
+
font-weight: 700;
|
|
9826
|
+
text-transform: uppercase;
|
|
9827
|
+
letter-spacing: 0.06em;
|
|
9828
|
+
padding: 2px 8px;
|
|
9829
|
+
border-radius: 999px;
|
|
9830
|
+
border: 1px solid transparent;
|
|
9831
|
+
text-align: center;
|
|
9832
|
+
align-self: start;
|
|
9833
|
+
min-width: 56px;
|
|
9834
|
+
}
|
|
9835
|
+
.doctor-row-pill-ok {
|
|
9836
|
+
background: rgba(46, 160, 67, 0.15);
|
|
9837
|
+
border-color: rgba(46, 160, 67, 0.4);
|
|
9838
|
+
color: var(--success, #2da44e);
|
|
9839
|
+
}
|
|
9840
|
+
.doctor-row-pill-warn {
|
|
9841
|
+
background: rgba(212, 167, 44, 0.18);
|
|
9842
|
+
border-color: rgba(212, 167, 44, 0.45);
|
|
9843
|
+
color: var(--attn, #9a6700);
|
|
9844
|
+
}
|
|
9845
|
+
.doctor-row-pill-error {
|
|
9846
|
+
background: rgba(207, 34, 46, 0.15);
|
|
9847
|
+
border-color: rgba(207, 34, 46, 0.4);
|
|
9848
|
+
color: var(--danger, #cf222e);
|
|
9849
|
+
}
|
|
9850
|
+
.doctor-row-body {
|
|
9851
|
+
display: flex;
|
|
9852
|
+
flex-direction: column;
|
|
9853
|
+
gap: 4px;
|
|
9854
|
+
min-width: 0;
|
|
9855
|
+
}
|
|
9856
|
+
.doctor-row-title {
|
|
9857
|
+
font-weight: 600;
|
|
9858
|
+
font-size: 13px;
|
|
9859
|
+
color: var(--fg);
|
|
9860
|
+
}
|
|
9861
|
+
.doctor-row-detail {
|
|
9862
|
+
font-size: 12px;
|
|
9863
|
+
color: var(--fg-muted);
|
|
9864
|
+
word-break: break-word;
|
|
9865
|
+
white-space: pre-wrap;
|
|
9866
|
+
}
|
|
9867
|
+
.doctor-row-hint {
|
|
9868
|
+
font-size: 12px;
|
|
9869
|
+
color: var(--fg);
|
|
9870
|
+
background: rgba(151, 119, 0, 0.08);
|
|
9871
|
+
border-left: 3px solid var(--attn, #9a6700);
|
|
9872
|
+
padding: 8px 10px;
|
|
9873
|
+
border-radius: 4px;
|
|
9874
|
+
margin-top: 4px;
|
|
9875
|
+
white-space: pre-wrap;
|
|
9876
|
+
word-break: break-word;
|
|
9877
|
+
}
|
|
9878
|
+
.doctor-row-pill-error ~ .doctor-row-body .doctor-row-hint {
|
|
9879
|
+
background: rgba(207, 34, 46, 0.08);
|
|
9880
|
+
border-left-color: var(--danger, #cf222e);
|
|
9881
|
+
}
|
|
9882
|
+
.doctor-empty {
|
|
9883
|
+
padding: 32px;
|
|
9884
|
+
text-align: center;
|
|
9885
|
+
color: var(--fg-muted);
|
|
9886
|
+
font-size: 13px;
|
|
9887
|
+
}
|
|
9888
|
+
.doctor-badge {
|
|
9889
|
+
display: inline-flex;
|
|
9890
|
+
margin-left: 4px;
|
|
9891
|
+
width: 8px;
|
|
9892
|
+
height: 8px;
|
|
9893
|
+
border-radius: 50%;
|
|
9894
|
+
background: var(--danger, #cf222e);
|
|
9895
|
+
}
|
|
9896
|
+
.doctor-badge[data-level="warn"] {
|
|
9897
|
+
background: var(--attn, #9a6700);
|
|
9898
|
+
}
|