pi-studio 0.5.50 → 0.5.52
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/CHANGELOG.md +25 -0
- package/README.md +2 -1
- package/client/studio-client.js +811 -92
- package/client/studio.css +98 -29
- package/index.ts +26 -1
- package/package.json +1 -1
package/client/studio.css
CHANGED
|
@@ -227,13 +227,15 @@
|
|
|
227
227
|
|
|
228
228
|
#scratchpadBtn.has-content,
|
|
229
229
|
#reviewNotesBtn.has-content,
|
|
230
|
-
#reviewNotesBtn.is-active
|
|
230
|
+
#reviewNotesBtn.is-active,
|
|
231
|
+
#outlineBtn.is-active {
|
|
231
232
|
border-color: var(--accent);
|
|
232
233
|
color: var(--accent);
|
|
233
234
|
font-weight: 600;
|
|
234
235
|
}
|
|
235
236
|
|
|
236
|
-
#reviewNotesBtn.is-active
|
|
237
|
+
#reviewNotesBtn.is-active,
|
|
238
|
+
#outlineBtn.is-active {
|
|
237
239
|
background: var(--accent-soft);
|
|
238
240
|
}
|
|
239
241
|
|
|
@@ -336,7 +338,8 @@
|
|
|
336
338
|
gap: 8px;
|
|
337
339
|
}
|
|
338
340
|
|
|
339
|
-
.review-notes-dock-wrap
|
|
341
|
+
.review-notes-dock-wrap,
|
|
342
|
+
.outline-dock-wrap {
|
|
340
343
|
flex: 0 0 clamp(300px, 34%, 420px);
|
|
341
344
|
min-width: 280px;
|
|
342
345
|
min-height: 0;
|
|
@@ -348,11 +351,13 @@
|
|
|
348
351
|
overflow: hidden;
|
|
349
352
|
}
|
|
350
353
|
|
|
351
|
-
.review-notes-dock-wrap[hidden]
|
|
354
|
+
.review-notes-dock-wrap[hidden],
|
|
355
|
+
.outline-dock-wrap[hidden] {
|
|
352
356
|
display: none !important;
|
|
353
357
|
}
|
|
354
358
|
|
|
355
|
-
.review-notes-dock
|
|
359
|
+
.review-notes-dock,
|
|
360
|
+
.outline-dock {
|
|
356
361
|
width: 100%;
|
|
357
362
|
min-height: 0;
|
|
358
363
|
display: flex;
|
|
@@ -661,11 +666,17 @@
|
|
|
661
666
|
-webkit-text-fill-color: transparent;
|
|
662
667
|
}
|
|
663
668
|
|
|
664
|
-
.editor-selection-
|
|
669
|
+
.editor-selection-actions {
|
|
665
670
|
position: absolute;
|
|
666
671
|
top: 12px;
|
|
667
672
|
right: 12px;
|
|
668
673
|
z-index: 4;
|
|
674
|
+
display: inline-flex;
|
|
675
|
+
align-items: center;
|
|
676
|
+
gap: 8px;
|
|
677
|
+
}
|
|
678
|
+
|
|
679
|
+
.editor-selection-action-btn {
|
|
669
680
|
min-height: 24px;
|
|
670
681
|
border-radius: 999px;
|
|
671
682
|
padding: 0 10px;
|
|
@@ -677,13 +688,22 @@
|
|
|
677
688
|
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
|
|
678
689
|
}
|
|
679
690
|
|
|
680
|
-
.editor-selection-
|
|
681
|
-
.editor-selection-
|
|
691
|
+
.editor-selection-action-btn:hover,
|
|
692
|
+
.editor-selection-action-btn:focus-visible {
|
|
682
693
|
background: var(--accent-soft-strong);
|
|
683
694
|
color: var(--accent);
|
|
684
695
|
border-color: var(--accent);
|
|
685
696
|
}
|
|
686
697
|
|
|
698
|
+
.editor-selection-actions[hidden],
|
|
699
|
+
.editor-selection-action-btn[hidden],
|
|
700
|
+
.preview-selection-actions[hidden],
|
|
701
|
+
.preview-comment-add[hidden],
|
|
702
|
+
.preview-comment-jump[hidden],
|
|
703
|
+
.preview-comment-summary[hidden] {
|
|
704
|
+
display: none !important;
|
|
705
|
+
}
|
|
706
|
+
|
|
687
707
|
.hl-heading {
|
|
688
708
|
color: var(--md-heading);
|
|
689
709
|
font-weight: 700;
|
|
@@ -916,15 +936,16 @@
|
|
|
916
936
|
overflow-wrap: inherit;
|
|
917
937
|
}
|
|
918
938
|
|
|
919
|
-
.preview-
|
|
920
|
-
position:
|
|
921
|
-
top:
|
|
922
|
-
right: 0;
|
|
939
|
+
.preview-selection-actions {
|
|
940
|
+
position: sticky;
|
|
941
|
+
top: 12px;
|
|
923
942
|
z-index: 6;
|
|
924
|
-
|
|
925
|
-
|
|
943
|
+
height: 0;
|
|
944
|
+
display: flex;
|
|
945
|
+
justify-content: flex-end;
|
|
946
|
+
align-items: flex-start;
|
|
926
947
|
gap: 8px;
|
|
927
|
-
|
|
948
|
+
pointer-events: none;
|
|
928
949
|
}
|
|
929
950
|
|
|
930
951
|
.preview-comment-summary {
|
|
@@ -941,21 +962,11 @@
|
|
|
941
962
|
padding: 0 10px;
|
|
942
963
|
font-size: 12px;
|
|
943
964
|
line-height: 1;
|
|
944
|
-
opacity: 0;
|
|
945
|
-
pointer-events: none;
|
|
946
|
-
transform: translateY(-2px);
|
|
947
|
-
transition: opacity 120ms ease, transform 120ms ease, color 120ms ease, border-color 120ms ease, background-color 120ms ease;
|
|
948
965
|
background: var(--accent-soft);
|
|
949
966
|
border-color: var(--accent);
|
|
950
967
|
color: var(--accent);
|
|
951
968
|
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
|
|
952
|
-
}
|
|
953
|
-
|
|
954
|
-
.preview-comment-block.has-selection .preview-comment-add,
|
|
955
|
-
.preview-comment-block.has-selection .preview-comment-jump {
|
|
956
|
-
opacity: 1;
|
|
957
969
|
pointer-events: auto;
|
|
958
|
-
transform: translateY(0);
|
|
959
970
|
}
|
|
960
971
|
|
|
961
972
|
.preview-comment-add:hover,
|
|
@@ -1818,15 +1829,18 @@
|
|
|
1818
1829
|
filter: brightness(0.95);
|
|
1819
1830
|
}
|
|
1820
1831
|
|
|
1821
|
-
.review-notes-dock .scratchpad-header
|
|
1832
|
+
.review-notes-dock .scratchpad-header,
|
|
1833
|
+
.outline-dock .scratchpad-header {
|
|
1822
1834
|
padding: 12px 14px 10px;
|
|
1823
1835
|
}
|
|
1824
1836
|
|
|
1825
|
-
.review-notes-dock .scratchpad-header h2
|
|
1837
|
+
.review-notes-dock .scratchpad-header h2,
|
|
1838
|
+
.outline-dock .scratchpad-header h2 {
|
|
1826
1839
|
font-size: 15px;
|
|
1827
1840
|
}
|
|
1828
1841
|
|
|
1829
|
-
.review-notes-dock .scratchpad-description
|
|
1842
|
+
.review-notes-dock .scratchpad-description,
|
|
1843
|
+
.outline-dock .scratchpad-description {
|
|
1830
1844
|
font-size: 11px;
|
|
1831
1845
|
line-height: 1.4;
|
|
1832
1846
|
word-break: normal;
|
|
@@ -1889,6 +1903,60 @@
|
|
|
1889
1903
|
justify-content: space-between;
|
|
1890
1904
|
}
|
|
1891
1905
|
|
|
1906
|
+
.outline-list {
|
|
1907
|
+
display: flex;
|
|
1908
|
+
flex: 1 1 auto;
|
|
1909
|
+
min-height: 0;
|
|
1910
|
+
flex-direction: column;
|
|
1911
|
+
gap: 6px;
|
|
1912
|
+
padding: 14px;
|
|
1913
|
+
overflow: auto;
|
|
1914
|
+
background: var(--panel);
|
|
1915
|
+
}
|
|
1916
|
+
|
|
1917
|
+
.outline-entry {
|
|
1918
|
+
width: 100%;
|
|
1919
|
+
display: grid;
|
|
1920
|
+
grid-template-columns: auto 1fr auto;
|
|
1921
|
+
align-items: baseline;
|
|
1922
|
+
gap: 8px;
|
|
1923
|
+
text-align: left;
|
|
1924
|
+
border-radius: 10px;
|
|
1925
|
+
padding: 8px 10px;
|
|
1926
|
+
background: var(--panel-2);
|
|
1927
|
+
border: 1px solid var(--border-muted);
|
|
1928
|
+
}
|
|
1929
|
+
|
|
1930
|
+
.outline-entry:hover,
|
|
1931
|
+
.outline-entry:focus-visible {
|
|
1932
|
+
border-color: var(--accent);
|
|
1933
|
+
background: var(--accent-soft);
|
|
1934
|
+
}
|
|
1935
|
+
|
|
1936
|
+
.outline-entry-kind {
|
|
1937
|
+
font-size: 11px;
|
|
1938
|
+
font-weight: 700;
|
|
1939
|
+
letter-spacing: 0.03em;
|
|
1940
|
+
text-transform: uppercase;
|
|
1941
|
+
color: var(--accent);
|
|
1942
|
+
white-space: nowrap;
|
|
1943
|
+
}
|
|
1944
|
+
|
|
1945
|
+
.outline-entry-title {
|
|
1946
|
+
min-width: 0;
|
|
1947
|
+
font-size: 13px;
|
|
1948
|
+
line-height: 1.35;
|
|
1949
|
+
color: var(--text);
|
|
1950
|
+
overflow-wrap: anywhere;
|
|
1951
|
+
}
|
|
1952
|
+
|
|
1953
|
+
.outline-entry-meta {
|
|
1954
|
+
font-size: 11px;
|
|
1955
|
+
color: var(--muted);
|
|
1956
|
+
white-space: nowrap;
|
|
1957
|
+
font-variant-numeric: tabular-nums;
|
|
1958
|
+
}
|
|
1959
|
+
|
|
1892
1960
|
.review-note-card {
|
|
1893
1961
|
border: 1px solid var(--border-muted);
|
|
1894
1962
|
border-radius: 12px;
|
|
@@ -1996,7 +2064,8 @@
|
|
|
1996
2064
|
flex-direction: column;
|
|
1997
2065
|
}
|
|
1998
2066
|
|
|
1999
|
-
.review-notes-dock-wrap
|
|
2067
|
+
.review-notes-dock-wrap,
|
|
2068
|
+
.outline-dock-wrap {
|
|
2000
2069
|
flex: 0 0 auto;
|
|
2001
2070
|
min-width: 0;
|
|
2002
2071
|
max-height: min(42vh, 420px);
|
package/index.ts
CHANGED
|
@@ -6010,6 +6010,7 @@ ${cssVarsBlock}
|
|
|
6010
6010
|
<div class="section-header-actions">
|
|
6011
6011
|
<button id="leftFocusBtn" class="pane-focus-btn" type="button" title="Show only the editor pane. Shortcut: F10 or Cmd/Ctrl+Esc.">Focus pane</button>
|
|
6012
6012
|
<button id="reviewNotesBtn" type="button" title="Toggle local comments beside the current editor document or draft. Comments stay outside the document text and can later be converted into [an: ...] annotations.">Comments</button>
|
|
6013
|
+
<button id="outlineBtn" type="button" title="Toggle document outline for the current editor text. Outline entries can jump between raw editor and preview.">Outline</button>
|
|
6013
6014
|
<button id="scratchpadBtn" type="button" title="Open a local persistent scratchpad for the current editor document or draft. Scratchpad text is never run, critiqued, or exported unless you explicitly insert it into the editor.">Scratchpad</button>
|
|
6014
6015
|
</div>
|
|
6015
6016
|
</div>
|
|
@@ -6095,10 +6096,34 @@ ${cssVarsBlock}
|
|
|
6095
6096
|
<div id="lineNumberMeasure" class="editor-line-number-measure" aria-hidden="true"></div>
|
|
6096
6097
|
<pre id="sourceHighlight" class="editor-highlight" aria-hidden="true"></pre>
|
|
6097
6098
|
<textarea id="sourceText" placeholder="Paste or edit text here.">${initialText}</textarea>
|
|
6098
|
-
<
|
|
6099
|
+
<div id="editorSelectionActions" class="editor-selection-actions" hidden>
|
|
6100
|
+
<button id="editorSelectionCommentBtn" type="button" class="editor-selection-action-btn" hidden title="Create a new local comment from the current editor selection.">Comment</button>
|
|
6101
|
+
<button id="editorSelectionJumpBtn" type="button" class="editor-selection-action-btn" hidden title="Jump to the current editor selection in the preview.">Jump</button>
|
|
6102
|
+
</div>
|
|
6099
6103
|
</div>
|
|
6100
6104
|
<div id="sourcePreview" class="panel-scroll rendered-markdown" hidden><pre class="plain-markdown"></pre></div>
|
|
6101
6105
|
</div>
|
|
6106
|
+
<aside id="outlineOverlay" class="outline-dock-wrap" hidden>
|
|
6107
|
+
<div id="outlineDialog" class="outline-dock" role="complementary" aria-labelledby="outlineTitle">
|
|
6108
|
+
<div class="scratchpad-header">
|
|
6109
|
+
<div>
|
|
6110
|
+
<h2 id="outlineTitle">Outline</h2>
|
|
6111
|
+
<p class="scratchpad-description">Document structure for the current editor text. Click an entry to jump in the raw editor and, when available, reveal the matching preview location.</p>
|
|
6112
|
+
</div>
|
|
6113
|
+
<button id="outlineCloseBtn" type="button" class="scratchpad-close-btn" aria-label="Hide outline" title="Hide outline">✕</button>
|
|
6114
|
+
</div>
|
|
6115
|
+
<div class="review-notes-toolbar">
|
|
6116
|
+
<span id="outlineMeta" class="scratchpad-meta">No outline entries</span>
|
|
6117
|
+
</div>
|
|
6118
|
+
<div id="outlineEmptyState" class="review-notes-empty">No outline available yet for this document or syntax mode.</div>
|
|
6119
|
+
<div id="outlineList" class="outline-list" aria-live="polite"></div>
|
|
6120
|
+
<div class="review-notes-dock-footer">
|
|
6121
|
+
<div class="scratchpad-actions">
|
|
6122
|
+
<button id="outlineDoneBtn" type="button" title="Hide the outline rail.">Hide</button>
|
|
6123
|
+
</div>
|
|
6124
|
+
</div>
|
|
6125
|
+
</div>
|
|
6126
|
+
</aside>
|
|
6102
6127
|
<aside id="reviewNotesOverlay" class="review-notes-dock-wrap" hidden>
|
|
6103
6128
|
<div id="reviewNotesDialog" class="review-notes-dock" role="complementary" aria-labelledby="reviewNotesTitle">
|
|
6104
6129
|
<div class="scratchpad-header">
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-studio",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.52",
|
|
4
4
|
"description": "Two-pane browser workspace for pi with prompt/response editing, annotations, critiques, prompt/response history, and live Markdown/LaTeX/code preview",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|