dsh-workspace-status 0.3.2 → 0.3.4
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 +21 -0
- package/client.js +61 -14
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,27 @@ adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.3.4] - 2026-12-05
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
|
|
13
|
+
- When the shell no longer exposes the sidebar region the pinned section is
|
|
14
|
+
portaled into, the section now renders inline in the sidebar footer and logs
|
|
15
|
+
one console warning naming the fallback. A future layout change therefore
|
|
16
|
+
looks wrong and stays reachable instead of looking like the feature was never
|
|
17
|
+
installed.
|
|
18
|
+
|
|
19
|
+
## [0.3.3] - 2026-12-05
|
|
20
|
+
|
|
21
|
+
### Fixed
|
|
22
|
+
|
|
23
|
+
- The pinned section is visible again on DeepSeek Harness 0.2.2. The sidebar
|
|
24
|
+
scroll area became a four-row CSS grid whose panel list and workspaces region
|
|
25
|
+
claim explicit cells (2/2 and 4/2), so the injected section was auto-placed
|
|
26
|
+
into the 4px gutter and rendered as an invisible sliver — pins looked like
|
|
27
|
+
they did nothing and no notification could ever be raised. The host now
|
|
28
|
+
claims the spacer row and widens it to its own height.
|
|
29
|
+
|
|
9
30
|
## [0.3.2] - 2026-10-28
|
|
10
31
|
|
|
11
32
|
### Changed
|
package/client.js
CHANGED
|
@@ -746,6 +746,8 @@ window.__ModuleLoader__.load({
|
|
|
746
746
|
'--dsh-scrollbar-thumb:var(--dsw-alias-scrollbar-bg-l2);',
|
|
747
747
|
'--dsh-scrollbar-thumb-hover:var(--dsw-alias-scrollbar-hover-l2)}',
|
|
748
748
|
'.dsws-pinned[data-rail="true"],.dsws-pinned:empty{display:none}',
|
|
749
|
+
'.dsws-pinned-fallback{max-height:min(30vh,220px);margin:0 0 4px;padding-top:4px;',
|
|
750
|
+
'border-top:0.5px solid var(--dsw-alias-border-l2)}',
|
|
749
751
|
'.dsws-pinned-headerrow{display:flex;align-items:center;gap:2px;margin:0;padding:0 2px 0 0}',
|
|
750
752
|
'.dsws-pinned-header{display:flex;align-items:center;gap:6px;box-sizing:border-box;flex:1;min-width:0;height:30px;',
|
|
751
753
|
'margin:0;padding:0 8px;border:0;border-radius:var(--dsw-radius-md);background:none;',
|
|
@@ -1018,6 +1020,20 @@ window.__ModuleLoader__.load({
|
|
|
1018
1020
|
if (host.parentElement !== current.parentElement || host.nextElementSibling !== current) {
|
|
1019
1021
|
current.parentElement.insertBefore(host, current)
|
|
1020
1022
|
}
|
|
1023
|
+
// DSH 0.2.2 lays the sidebar scroll area out as a grid with fixed rows,
|
|
1024
|
+
// and the panel list (2/2) plus the workspaces region (4/2) claim their
|
|
1025
|
+
// cells explicitly. A bare sibling is auto-placed into the 4px gutter
|
|
1026
|
+
// and disappears, so claim the spacer row and let it size to content.
|
|
1027
|
+
const area = current.parentElement
|
|
1028
|
+
const laid = typeof window === 'undefined' ? undefined : window.getComputedStyle(area)
|
|
1029
|
+
if (laid !== undefined && laid.display === 'grid') {
|
|
1030
|
+
host.style.gridColumn = '2'
|
|
1031
|
+
host.style.gridRow = '3'
|
|
1032
|
+
const tracks = (laid.gridTemplateRows ?? '').split(' ').filter(Boolean)
|
|
1033
|
+
if (tracks.length === 4 && parseFloat(tracks[2]) < 6) {
|
|
1034
|
+
area.style.gridTemplateRows = `${tracks[0]} max-content max-content max-content`
|
|
1035
|
+
}
|
|
1036
|
+
}
|
|
1021
1037
|
const collapsed = Array.from(current.parentElement.classList ?? [])
|
|
1022
1038
|
.some((token) => token.endsWith('_collapsed'))
|
|
1023
1039
|
if (host.getAttribute('data-rail') !== String(collapsed)) {
|
|
@@ -1471,10 +1487,33 @@ window.__ModuleLoader__.load({
|
|
|
1471
1487
|
const markerRef = React.useRef(null)
|
|
1472
1488
|
const [portalHost, setPortalHost] = React.useState(undefined)
|
|
1473
1489
|
React.useEffect(() => {
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1490
|
+
// The shell may commit the sidebar region after this slot's subtree, so
|
|
1491
|
+
// keep looking for a few frames instead of giving up on the first pass.
|
|
1492
|
+
let attached = attachPinnedHost(markerRef.current)
|
|
1493
|
+
let frame = 0
|
|
1494
|
+
let raf = 0
|
|
1495
|
+
const retry = () => {
|
|
1496
|
+
attached = attachPinnedHost(markerRef.current)
|
|
1497
|
+
if (attached !== null) {
|
|
1498
|
+
setPortalHost(attached.host)
|
|
1499
|
+
return
|
|
1500
|
+
}
|
|
1501
|
+
if (++frame < 120) {
|
|
1502
|
+
raf = window.requestAnimationFrame(retry)
|
|
1503
|
+
return
|
|
1504
|
+
}
|
|
1505
|
+
// Give the fallback a voice: without a host the section still renders
|
|
1506
|
+
// inline, and this line is what a bug report can be searched for.
|
|
1507
|
+
if (typeof console !== 'undefined' && typeof console.warn === 'function') {
|
|
1508
|
+
console.warn('dsh-workspace-status: sidebar region not found; the pinned section falls back to the footer slot')
|
|
1509
|
+
}
|
|
1510
|
+
}
|
|
1511
|
+
if (attached !== null) setPortalHost(attached.host)
|
|
1512
|
+
else if (typeof window !== 'undefined' && typeof window.requestAnimationFrame === 'function') raf = window.requestAnimationFrame(retry)
|
|
1513
|
+
return () => {
|
|
1514
|
+
if (raf !== 0) window.cancelAnimationFrame(raf)
|
|
1515
|
+
if (attached !== null) attached.dispose()
|
|
1516
|
+
}
|
|
1478
1517
|
}, [])
|
|
1479
1518
|
|
|
1480
1519
|
|
|
@@ -1492,16 +1531,24 @@ window.__ModuleLoader__.load({
|
|
|
1492
1531
|
key: 'anchor', ref: markerRef, className: 'dsws-anchor', 'aria-hidden': 'true',
|
|
1493
1532
|
}))
|
|
1494
1533
|
|
|
1495
|
-
if (
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
portalHost,
|
|
1503
|
-
|
|
1504
|
-
|
|
1534
|
+
if (pinnedModel.total > 0) {
|
|
1535
|
+
const section = h(PinnedSection, {
|
|
1536
|
+
model: pinnedModel,
|
|
1537
|
+
openSession: typeof externalOpenSession === 'function' ? externalOpenSession : noop,
|
|
1538
|
+
unpinSession: typeof externalUnpinSession === 'function' ? externalUnpinSession : noopAsync,
|
|
1539
|
+
})
|
|
1540
|
+
if (portalHost !== undefined) {
|
|
1541
|
+
children.push(ReactDOM.createPortal(section, portalHost, ENTRY_ID))
|
|
1542
|
+
} else {
|
|
1543
|
+
// The sidebar region is absent or never appeared. Keep the section
|
|
1544
|
+
// reachable in the footer slot instead of dropping it silently: a
|
|
1545
|
+
// future shell layout change must look odd, not disappear.
|
|
1546
|
+
children.push(h('div', {
|
|
1547
|
+
key: 'pinned-fallback',
|
|
1548
|
+
className: 'dsws-pinned dsws-pinned-fallback',
|
|
1549
|
+
'data-fallback': 'true',
|
|
1550
|
+
}, section))
|
|
1551
|
+
}
|
|
1505
1552
|
}
|
|
1506
1553
|
|
|
1507
1554
|
return h(React.Fragment, null, children)
|
package/package.json
CHANGED