feat(w05): 数据工单第四轮九连改 —— 笔↔软盘卡角编辑、只选不建、浅蓝题头、镜像修数字

2026-08-31 用户一次点齐九件,逐条落:
① 两行编辑闸退役 → 卡右上角笔(开当前这一面的编辑)↔ 软盘(保存)+ 叉(放弃);
  按钮就是平台的 data-edit-open/save/cancel 触发器,快照/取消机制原样,按面显隐全在样式表。
② 保存一瞬间下拉变数字 → ui-kit mirrorTwins:下拉镜像**选项文案**不镜 value,并把
  selected 属性拨到人选的那一项(守卫 CSS 与取消回显都认它)。2 测。
③ 参数输入框占位提示 → 渲染器 twinInputs 认 data-ph 落成 placeholder(平台小扩面,1 测);
  值格「规格书上的值 · 查不到留空」,说明格「补充说明 · 选填」。
④ 参数说明空着不再摆「建议」→ 什么都不摆(连兜底破折号一起收)。
⑤ 区序对调:芯片档案在前,比对基准在后。
⑥ **新建芯片类型整条路移除**(只能选已有类型):抽屉与两张编辑表(种子行/Critical-1
  修法/thead 回归网)退役,S1 配方 ②③ 自投影删除(八笔→六笔),gateLedgers 收窄到
  profile+parameter,writes 同步,gate_reason 与指导书改口「只选不建」;样例改名
  「候选缺库·建档定型」;e2e 案例 0 改走选既有 type_1(type_id=90 那套绕坑法随路退役)。
  退役面的七条钉测按仓例 it.skip 留墓志铭(钉的是已移除的路径,不是放松断言)。
⑦ 题头回浅蓝渐变(原目标件那条 120°),深色夜景只留验收两件。
⑧ 对话区执行卡不再摆「参考信息」板块(basis 数据照旧随卡走,详情/归档仍有)。
⑨ 比对基准降噪:字段收成丸(名+硬软徽+单位),说明藏进悬浮气泡指上即看;
  类型说明一行截断、悬浮展开。

测:ui-kit 33(mirror 2 新)+ 渲染器 61(ph 1 新)+ 包内 104(38 steps 重排)+ 2525 全仓
四门绿;2.10.0 装库 SQL 六探针全中(hd-light/软盘/data-ph/零表格/无 chip_type 编辑面/
gateLedgers 两张);:8787 已重启载入 data-ph 渲染器。

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LKMZDwMbyKzjw6Hembwvet
This commit is contained in:
xcs
2026-08-31 16:41:14 +08:00
co-authored by Claude Fable 5
parent f6c8dccb4f
commit 51914292dc
12 changed files with 259 additions and 389 deletions
@@ -542,3 +542,17 @@ describe('data-options:下拉的选项从台账现读', () => {
expect(out).toContain('<option value="2" selected>LDO 线性稳压器</option>');
});
});
describe('孪生件占位提示:data-ph 落成 input 的 placeholder(2026-08-31,W05 参数瓷贴)', () => {
it('带 data-ph 的可改格,孪生 input 有 placeholder;不带的没有', () => {
const html =
'<div data-rows="mine:parts.parameter" data-edit="parts.parameter"><p>' +
'<span class="jc-vcell" data-slot="param_value" data-col="param_value" data-ph="规格书上的值,查不到留空" data-blank></span>' +
'<span class="jc-vcell" data-slot="param_note" data-col="param_note" data-blank></span>' +
'</p></div>';
const out = renderView(html, { 'mine:parts.parameter': [{ param_value: '', param_note: '' }] });
expect(out).toContain('placeholder="规格书上的值,查不到留空"');
const notePart = out.slice(out.indexOf('data-col="param_note"'));
expect(notePart.slice(0, notePart.indexOf('/>'))).not.toContain('placeholder=');
});
});
@@ -263,7 +263,9 @@ function twinInputs(inner: string, rowIndex: number): string {
.split(/\s+/)
.filter((c) => c === 'mono' || c === 'num')
.join(' ');
const input = `<input class="jc-cell${style === '' ? '' : ` ${style}`}" data-col="${col}" data-row="${rowIndex}" data-slot="${slot}" data-value/>`;
/* `data-ph`:模版给这一格的输入孪生件配一句占位提示(2026-08-31,W05 参数瓷贴要「短短一句说清这格填什么」) */
const ph = /\bdata-ph\s*=\s*"([^"]*)"/.exec(attrs)?.[1];
const input = `<input class="jc-cell${style === '' ? '' : ` ${style}`}" data-col="${col}" data-row="${rowIndex}" data-slot="${slot}"${ph === undefined || ph === '' ? '' : ` placeholder="${ph}"`} data-value/>`;
// 只读那一份把 `data-col` 交出去 —— 它的活已经干完(告诉这里是哪一列),留着只是噪音
return `${all.replace(/\s*\bdata-col\s*=\s*"[^"]*"/, '')}${input}`;
});
@@ -1051,7 +1051,8 @@ function ExecForm({ order, onReplyOrder, onLocate, orderValues, onField, face =
</button>
<p className="jc-fc-q">{order.ask}</p>
<Guide steps={order.steps} standard={order.standard} />
{order.basis.length > 0 && <Kv items={order.basis} />}
{/* 参考信息不再上卡(2026-08-31 用户定:「派发的工单参考信息这个板块不要显示」)——
basis 数据照旧随卡走(工单详情 / 归档件仍有),只是对话区这张卡不摆 */}
{order.fields.map((f) => (
<label key={f.key} className="jc-fc-fld">
<span>