@qzsy/dsh-yunxiao-panel 1.3.1 → 1.4.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 CHANGED
@@ -45,6 +45,7 @@ and a repository chip row for its merge requests.
45
45
  full-width swipe page and a tap opens the detail pane instead,
46
46
  - merge requests waiting for review (all open ones in organization scope), with
47
47
  a direct link to Yunxiao when the list is empty.
48
+ - **Detail sheet** — opening a work item slides in a right-hand sheet (up to 820 px wide, always on top of a dimmed panel) so descriptions, images, comments and the footer actions get room; Esc, the close button or a click on the dimmed area dismisses it, and it stays full-width on phones.
48
49
  - **Change status from the detail pane** — the pane shows the current status, a
49
50
  dropdown of the whole workflow for that work item type, and a **标记完成**
50
51
  button that picks the type's own done status (缺陷 → 已修复, 需求 → 已完成, else
package/dist/client.js CHANGED
@@ -203,7 +203,20 @@ window.__ModuleLoader__.load({
203
203
 
204
204
  const NS = 'yunxiao'
205
205
  const PANEL_ID = 'yunxiao'
206
- const API = '/api/yunxiao'
206
+ /**
207
+ * Facade base path. Locally DSH serves the app from the origin root, but
208
+ * remote access mounts the same app under a tunnel sub-path and the page
209
+ * carries `<base href="./">`. Resolve against document.baseURI so the
210
+ * panel calls /<sub-path>/api/yunxiao instead of leaving the mount point
211
+ * and hitting the tunnel root (which returns no data at all).
212
+ */
213
+ const API = (() => {
214
+ try {
215
+ return new URL('api/yunxiao', document.baseURI).pathname.replace(/\/+$/, '')
216
+ } catch {
217
+ return '/api/yunxiao'
218
+ }
219
+ })()
207
220
  const REPO_STORAGE_KEY = 'dsh.yunxiao.repo'
208
221
  const PROJECT_STORAGE_KEY = 'dsh.yunxiao.projectMap'
209
222
  /** Remembered DSH workspace per Yunxiao project: { [projectId]: workspaceId, __last: workspaceId }. */
@@ -665,7 +678,7 @@ window.__ModuleLoader__.load({
665
678
  .yx-badge--button{cursor:pointer;font:inherit;font-size:11px}
666
679
  .yx-badge--button:hover{border-color:var(--dsw-alias-border-l4);color:var(--dsw-alias-label-primary)}
667
680
  .yx-footer{padding:8px 14px;border-top:1px solid var(--dsw-alias-border-l1);color:var(--dsw-alias-label-tertiary);font-size:11px;display:flex;justify-content:space-between;gap:8px}
668
- .yx-main{flex:1;min-width:0;display:flex;flex-direction:column;min-height:0}
681
+ .yx-main{flex:1;min-width:0;display:flex;flex-direction:column;min-height:0;position:relative}
669
682
  .yx-head{display:flex;align-items:center;gap:10px;padding:14px 20px 10px;border-bottom:1px solid var(--dsw-alias-border-l1);flex-wrap:wrap}
670
683
  .yx-head-main{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
671
684
  .yx-head-name{font-size:16px;font-weight:600;line-height:22px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
@@ -708,10 +721,15 @@ window.__ModuleLoader__.load({
708
721
  .yx-btn[data-primary="true"]{background:var(--dsw-alias-button-primary-fill,var(--dsw-alias-brand-primary));border-color:transparent;color:var(--dsw-alias-label-primary-foreground,#fff)}
709
722
  .yx-btn[data-primary="true"]:hover{background:var(--dsw-alias-button-primary-hover,var(--dsw-alias-brand-primary))}
710
723
  .yx-btn:disabled{opacity:.55;cursor:default}
711
- .yx-detail{width:420px;flex:0 0 420px;display:flex;flex-direction:column;min-height:0;border-left:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-layer-1)}
712
- .yx-detail-head{display:flex;align-items:flex-start;gap:10px;padding:14px 16px 10px;border-bottom:1px solid var(--dsw-alias-border-l1)}
724
+ .yx-detail{position:absolute;top:0;right:0;bottom:0;z-index:30;width:min(820px,80vw);max-width:none;display:flex;flex-direction:column;min-height:0;border-left:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-layer-1);box-shadow:-18px 0 44px rgba(0,0,0,.18);animation:yx-sheet-in .22s cubic-bezier(.2,.8,.2,1)}
725
+ @keyframes yx-sheet-in{from{transform:translateX(30px);opacity:0}to{transform:none;opacity:1}}
726
+ .yx-sheet-scrim{position:absolute;inset:0;z-index:29;background:rgba(0,0,0,.26);animation:yx-fade-in .18s ease}
727
+ @keyframes yx-fade-in{from{opacity:0}to{opacity:1}}
728
+ .yx-detail-facts{margin:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 20px}
729
+ @media (prefers-reduced-motion:reduce){.yx-detail,.yx-sheet-scrim{animation:none}}
730
+ .yx-detail-head{display:flex;align-items:flex-start;gap:10px;padding:16px 22px 12px;border-bottom:1px solid var(--dsw-alias-border-l1)}
713
731
  .yx-detail-title{flex:1;min-width:0;font-size:14px;font-weight:600;line-height:20px;overflow-wrap:anywhere}
714
- .yx-detail-body{flex:1;min-height:0;overflow:auto;padding:12px 16px 24px;display:flex;flex-direction:column;gap:14px}
732
+ .yx-detail-body{flex:1;min-height:0;overflow:auto;padding:16px 22px 28px;display:flex;flex-direction:column;gap:14px}
715
733
  .yx-fact{display:flex;gap:10px;font-size:12px;line-height:18px}
716
734
  .yx-fact dt{color:var(--dsw-alias-label-tertiary);width:64px;flex:none}
717
735
  .yx-fact dd{margin:0;min-width:0;overflow-wrap:anywhere}
@@ -720,7 +738,7 @@ window.__ModuleLoader__.load({
720
738
  .yx-comment{border-top:1px solid var(--dsw-alias-border-l2);padding-top:8px;display:flex;flex-direction:column;gap:4px}
721
739
  .yx-comment-head{display:flex;gap:8px;font-size:11.5px;color:var(--dsw-alias-label-tertiary)}
722
740
  .yx-comment-body{white-space:pre-wrap;overflow-wrap:anywhere;font-size:12.5px;line-height:19px}
723
- .yx-detail-foot{display:flex;gap:8px;padding:10px 16px 14px;border-top:1px solid var(--dsw-alias-border-l1);flex-wrap:wrap}
741
+ .yx-detail-foot{display:flex;gap:8px;padding:12px 22px 16px;background:var(--dsw-alias-bg-layer-1);border-top:1px solid var(--dsw-alias-border-l1);flex-wrap:wrap}
724
742
  .yx-pop{position:absolute;top:30px;right:0;z-index:40;width:280px;max-height:320px;overflow:auto;background:var(--dsw-alias-bg-overlay);border:1px solid var(--dsw-alias-border-l2);border-radius:10px;box-shadow:var(--dsw-elevation-prominent,0 8px 28px rgba(0,0,0,.18));padding:6px}
725
743
  .yx-pop-item{display:flex;flex-direction:column;gap:2px;width:100%;border:0;background:transparent;color:inherit;text-align:left;border-radius:7px;padding:7px 9px;cursor:pointer;font:inherit}
726
744
  .yx-pop-item:hover{background:var(--dsw-alias-interactive-bg-hover)}
@@ -1104,7 +1122,7 @@ button.yx-bar-row:hover{background:var(--dsw-alias-interactive-bg-hover)}
1104
1122
  .yx-charts{grid-template-columns:1fr}
1105
1123
  .yx-work-lists{grid-template-columns:1fr}
1106
1124
  .yx-work-list{max-height:340px}
1107
- .yx-detail{width:100%;flex-basis:auto;left:0;right:0}
1125
+ .yx-detail{width:100%;max-width:none;left:0;right:0}.yx-detail-facts{grid-template-columns:1fr}
1108
1126
  .yx-modal{padding:12px}
1109
1127
  .yx-modal-card{width:100%;max-width:100%;max-height:88vh;overflow:auto}
1110
1128
  .yx-md table{display:block;overflow-x:auto}
@@ -4019,7 +4037,7 @@ button.yx-bar-row:hover{background:var(--dsw-alias-interactive-bg-hover)}
4019
4037
  isIssue
4020
4038
  ? h(
4021
4039
  'dl',
4022
- { key: 'facts', style: { margin: 0, display: 'flex', flexDirection: 'column', gap: '6px' } },
4040
+ { key: 'facts', className: 'yx-detail-facts' },
4023
4041
  h('div', { className: 'yx-fact' }, h('dt', null, t('project')), h('dd', null, detailProject ? `${projectCode(detailProject)} ${detailProject.name}` : t('unbound'))),
4024
4042
  h('div', { className: 'yx-fact' }, h('dt', null, t('promptType')), h('dd', null, full.workitemType || full.categoryId || '-')),
4025
4043
  h('div', { className: 'yx-fact' }, h('dt', null, t('promptStatus')), h('dd', null, full.status || '-')),
@@ -4029,7 +4047,7 @@ button.yx-bar-row:hover{background:var(--dsw-alias-interactive-bg-hover)}
4029
4047
  )
4030
4048
  : h(
4031
4049
  'dl',
4032
- { key: 'facts', style: { margin: 0, display: 'flex', flexDirection: 'column', gap: '6px' } },
4050
+ { key: 'facts', className: 'yx-detail-facts' },
4033
4051
  h('div', { className: 'yx-fact' }, h('dt', null, t('promptStatus')), h('dd', null, statusLabel(t, full.state))),
4034
4052
  h('div', { className: 'yx-fact' }, h('dt', null, t('author')), h('dd', null, full.author || '-')),
4035
4053
  h('div', { className: 'yx-fact' }, h('dt', null, t('branches')), h('dd', { className: 'yx-branch' }, `${full.sourceBranch} → ${full.targetBranch}`)),
@@ -5439,6 +5457,7 @@ button.yx-bar-row:hover{background:var(--dsw-alias-interactive-bg-hover)}
5439
5457
  h('div', { className: 'yx-empty-body' }, t('selectProjectHint')),
5440
5458
  ),
5441
5459
  ),
5460
+ detail ? h('div', { className: 'yx-sheet-scrim', onClick: () => setDetail(null) }) : null,
5442
5461
  renderDetail(),
5443
5462
  convert ? renderConvert() : null,
5444
5463
  renderBinding(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qzsy/dsh-yunxiao-panel",
3
- "version": "1.3.1",
3
+ "version": "1.4.1",
4
4
  "type": "module",
5
5
  "description": "Yunxiao (阿里云云效) panel for the DeepSeek Harness Web client: a cross-project workbench with charts, project/repository navigation, Projex work items, Codeup commits and merge requests.",
6
6
  "license": "MIT",