فهرست منبع

feat(web): 重设计待办工作台和工单预览

sy 2 روز پیش
والد
کامیت
3a71c2c4e8

+ 124 - 62
web-scaffold/src/pages/WorkOrderMinePage.tsx

@@ -14,10 +14,9 @@
  * 一次最多取 100 张(服务端 `page_norm` 上限),实际还有更多时在页脚说明展示范围。
  */
 import { useDetailLinkState, type DetailLinkState } from "../lib/detail-navigation";
-import { Link, Navigate, useLocation } from "react-router";
-import { PageIntro } from "../components/PageIntro";
-import { useState } from "react";
-import { ArrowRight, ClipboardCheck, ClipboardList, Clock3, Hourglass, LoaderCircle, TriangleAlert, Wrench } from "lucide-react";
+import { Link, Navigate, useLocation, useNavigate } from "react-router";
+import { useRef, useState } from "react";
+import { ArrowRight, CalendarDays, ClipboardCheck, ClipboardList, Hourglass, LoaderCircle, PanelRight, TriangleAlert, Wrench } from "lucide-react";
 import { OpsTableColumns } from "../components/OperationsKit";
 import { TicketState } from "../components/ticketState";
 import { TicketStatusTag, TicketTypeTag } from "../components/work-order/TicketBadges";
@@ -52,6 +51,7 @@ const MINE_QUEUES = [
   { id: "waiting", label: "待对方确认", icon: Hourglass },
 ] as const;
 type MineView = "all" | TodoGroupId;
+const WORK_DATE_FORMAT = new Intl.DateTimeFormat("zh-CN", { month: "long", day: "numeric", weekday: "long" });
 
 export function WorkOrderMinePage() {
   const identity = useDemoIdentity();
@@ -62,6 +62,8 @@ export function WorkOrderMinePage() {
 function WorkOrderMineInner() {
   const linkState = useDetailLinkState();
   const location = useLocation();
+  const navigate = useNavigate();
+  const preview = useRef<HTMLElement>(null);
   const params = new URLSearchParams(location.search);
   const activeQueue = MINE_QUEUES.find(({ id }) => id === params.get("view")) ?? MINE_QUEUES[0];
 
@@ -73,117 +75,137 @@ function WorkOrderMineInner() {
   const today = businessToday();
   const groups = groupTodoRows(rows, today);
   const displayedGroups = activeQueue.id === "all" ? groups : groups.filter(({ id }) => id === activeQueue.id);
-  const truncated = total > rows.length;
+  const displayedRows = displayedGroups.flatMap((group) => group.rows);
   const loaded = !list.loading && !fail;
+  const selection = params.get("selected");
+  const selected = loaded ? displayedRows.find((row) => row.ticket_id === selection) ?? displayedRows[0] : undefined;
 
   // 开通类计划执行日当天可以执行,是否超期以服务端字段为准。
   const overdue = rows.filter((row) => row.status !== "completed" && row.overdue_7d === true).length;
   const counts = { all: rows.length, due: 0, rest: 0, waiting: 0 };
   for (const group of groups) counts[group.id] = group.rows.length;
-
   const metrics = [
-    { label: "当前待办", value: rows.length, icon: ClipboardList, tone: "primary" },
-    { label: "已超期", value: overdue, icon: Clock3, tone: overdue > 0 ? "warning" : undefined },
-    { label: "待对方确认", value: counts.waiting, icon: Hourglass },
+    { label: "当前待办", value: rows.length },
+    { label: "已超期", value: overdue, warning: overdue > 0 },
+    { label: "待对方确认", value: counts.waiting },
   ];
 
+  function locationWith(next: URLSearchParams) {
+    return { pathname: location.pathname, search: next.toString(), hash: location.hash };
+  }
+
   function queueUrl(view: MineView) {
     const next = new URLSearchParams(params);
     if (view === "all") next.delete("view");
     else next.set("view", view);
-    return { pathname: location.pathname, search: next.toString(), hash: location.hash };
+    if (view !== activeQueue.id) next.delete("selected");
+    return locationWith(next);
+  }
+
+  function selectTicket(id: string) {
+    const next = new URLSearchParams(params);
+    next.set("selected", id);
+    navigate(locationWith(next), { replace: true, state: location.state, preventScrollReset: true });
+    if (window.matchMedia?.("(max-width: 1170px)")?.matches) preview.current?.scrollIntoView?.({ block: "nearest" });
   }
 
   return <section className="order-page work-order-mine-page">
-    <header className="order-heading work-order-mine-heading">
-      <div>
+    <header className="work-order-mine-hero">
+      <div className="work-order-mine-hero-copy">
+        <time dateTime={today}><CalendarDays size={15} aria-hidden="true" />{WORK_DATE_FORMAT.format(new Date(today + "T12:00:00"))}</time>
         <h1>我的待办</h1>
-        <PageIntro>查看分派给你的工单,按期限安排处理和跟进。</PageIntro>
+        <p>查看分派给你的工单,安排处理与跟进。</p>
       </div>
+      <dl className="work-order-mine-summary" aria-label="当前待办统计">
+        {metrics.map(({ label, value, warning }) => <div key={label} data-warning={warning || undefined}>
+          <dt>{label}</dt>
+          <dd>{list.loading ? "…" : fail ? "—" : value.toLocaleString("zh-CN")}</dd>
+        </div>)}
+      </dl>
+    </header>
+
+    <div className="work-order-mine-toolbar">
+      <nav className="work-order-mine-views" aria-label="待办分组">
+        {MINE_QUEUES.map(({ id, label, icon: Icon }) => <Link key={id} to={queueUrl(id)} replace state={location.state}
+          aria-current={activeQueue.id === id ? "page" : undefined}>
+          <Icon size={16} aria-hidden="true" />
+          <span>{label}</span>
+          {loaded && <small className="work-order-mine-view-count" data-priority={id === "due" && counts[id] > 0}>{counts[id]}</small>}
+        </Link>)}
+      </nav>
       <div className="work-order-mine-links">
         <MobileEntryHint />
         <Link className="work-order-mine-all" to="/work-orders">全部工单<ArrowRight size={15} aria-hidden="true" /></Link>
       </div>
-    </header>
-
-    <dl className="work-order-mine-summary" aria-label="当前待办统计">
-      {metrics.map(({ label, value, icon: Icon, tone }) => <div key={label} data-tone={tone}>
-        <dt><span className="work-order-mine-metric-icon" aria-hidden="true"><Icon size={17} /></span>{label}</dt>
-        <dd>{list.loading ? "…" : fail ? "—" : value.toLocaleString("zh-CN")}</dd>
-      </div>)}
-    </dl>
+    </div>
 
     <div className="work-order-mine-desk">
-      <nav className="work-order-mine-nav" aria-label="待办分组">
-        <h2>任务队列</h2>
-        <div className="work-order-mine-views">
-          {MINE_QUEUES.map(({ id, label, icon: Icon }) => <Link key={id} to={queueUrl(id)} replace state={location.state}
-            aria-current={activeQueue.id === id ? "page" : undefined}>
-            <Icon size={16} aria-hidden="true" />
-            <span>{label}</span>
-            {loaded && <small className="work-order-mine-view-count" data-priority={id === "due" && counts[id] > 0}>{counts[id]}</small>}
-          </Link>)}
-        </div>
-      </nav>
-
       <section className="order-list-shell work-order-mine-queue" aria-label={activeQueue.label}>
         {list.loading ? <div className="order-empty work-order-mine-empty" role="status">
           <LoaderCircle size={23} className="work-order-mine-loading" aria-hidden="true" />正在读取待办…
         </div> : fail ? <TicketState fail={fail} onRetry={list.reload} />
-          : !displayedGroups.length ? <div className="order-empty work-order-mine-empty">
-            <ClipboardCheck size={26} aria-hidden="true" />
+          : !displayedRows.length ? <div className="order-empty work-order-mine-empty">
+            <ClipboardCheck size={27} aria-hidden="true" />
             <h3>{rows.length ? "这一组暂无工单" : "暂无待办工单"}</h3>
             {!rows.length && <p>分派给你的工单会出现在这里。</p>}
           </div> : <div className="ops-table-wrap work-order-mine-scroll" role="region" aria-label="待办工单清单" tabIndex={0}>
             <table className="ops-table work-order-mine-table" aria-label="我的待办工单">
-              <OpsTableColumns widths={[370, 205, 155, 270]} />
+              <OpsTableColumns widths={[345, 205, 180, 270]} />
               <thead><tr>
-                <th scope="col">工单事项</th>
-                <th scope="col">类型 / 状态</th>
-                <th scope="col">执行 / 期限</th>
-                <th scope="col">下一步</th>
+                <th scope="col">工单 / 客户</th>
+                <th scope="col">进度</th>
+                <th scope="col">期限</th>
+                <th scope="col">办理</th>
               </tr></thead>
               {displayedGroups.map((group) => <tbody key={group.id}>
                 {activeQueue.id === "all" && <tr className="work-order-mine-group" data-tone={group.tone}>
-                  <th colSpan={4} scope="rowgroup">
-                    <span className="work-order-mine-group-label" title={group.hint}>
-                      {group.id === "due" ? <TriangleAlert size={14} aria-hidden="true" /> : group.id === "waiting"
-                        ? <Hourglass size={14} aria-hidden="true" /> : <ClipboardList size={14} aria-hidden="true" />}
+                  <th colSpan={4} scope="rowgroup" title={group.hint}>
+                    <span className="work-order-mine-group-label">
                       {MINE_QUEUES.find(({ id }) => id === group.id)?.label}
                     </span>
-                    {group.id === "due" && <span className="work-order-mine-group-hint">{group.hint}</span>}
+                    <span className="work-order-mine-group-count">{group.rows.length}</span>
                   </th>
                 </tr>}
-                {group.rows.map((row) => <MineQueueRow key={row.ticket_id} row={row} today={today} linkState={linkState} onUrged={list.reload} />)}
+                {group.rows.map((row) => <MineQueueRow key={row.ticket_id} row={row} today={today} linkState={linkState}
+                  selected={selected?.ticket_id === row.ticket_id} onSelect={() => selectTicket(row.ticket_id)} onUrged={list.reload} />)}
               </tbody>)}
             </table>
           </div>}
-        {loaded && truncated && <footer className="work-order-mine-footer">
+        {loaded && total > rows.length && <footer className="work-order-mine-footer">
           <span>展示前 {rows.length} 张待办,共 {total.toLocaleString("zh-CN")} 张。各分组按当前展示的工单统计。</span>
           <Link className="ops-table-action" to="/work-orders">去全部工单<ArrowRight size={14} aria-hidden="true" /></Link>
         </footer>}
       </section>
+      {selected && <aside className="work-order-mine-preview" id="mine-preview" aria-label="工单预览" ref={preview}>
+        <MineTicketPreview row={selected} today={today} linkState={linkState} />
+      </aside>}
     </div>
   </section>;
 }
 
-function MineQueueRow({ row, today, linkState, onUrged }: {
-  row: TicketListItem; today: string; linkState: DetailLinkState; onUrged: () => void;
+function mineDeadline(row: TicketListItem, today: string) {
+  const { date, kind } = todoRowDeadline(row);
+  const planned = kind === "planned";
+  const left = row.status === "completed" ? null : daysUntil(date, today);
+  const label = kind === "deferred" ? "已延期至" : planned ? "计划执行" : "期限";
+  const relative = left === null ? null : left < 0 ? `已超 ${-left} 天` : left === 0
+    ? (planned ? "今天必须执行" : "今天到期") : `还剩 ${left} 天`;
+  const shortLabel = kind === "deferred" ? "延期" : planned ? "计划" : null;
+  return { date, label, shortLabel, relative, late: left !== null && left < (planned ? 0 : 1) };
+}
+
+function MineQueueRow({ row, today, selected, onSelect, linkState, onUrged }: {
+  row: TicketListItem; today: string; selected: boolean; onSelect: () => void; linkState: DetailLinkState; onUrged: () => void;
 }) {
   const summary = todoRowSummary(row);
   const step = nextStepOf(row);
-  const deadline = todoRowDeadline(row);
+  const deadline = mineDeadline(row, today);
   const ticketPath = `/work-orders/${encodeURIComponent(row.ticket_id)}`;
-  const planned = deadline.kind === "planned";
-  const left = row.status === "completed" ? null : daysUntil(deadline.date, today);
-  const dateLabel = deadline.kind === "deferred" ? "已延期至" : planned ? "计划执行" : "期限";
-  const relative = left === null ? null : left < 0 ? `已超 ${-left} 天` : left === 0
-    ? (planned ? "今天必须执行" : "今天到期") : `还剩 ${left} 天`;
-  const late = left !== null && left < (planned ? 0 : 1);
 
-  return <tr className="work-order-mine-row">
+  return <tr className="work-order-mine-row" data-selected={selected || undefined}>
     <td>
-      <Link to={ticketPath} state={linkState} className="table-cell-title" title={summary.title}>{summary.title}</Link>
+      <button type="button" className="work-order-mine-ticket-button" onClick={onSelect} title={summary.title}
+        aria-controls="mine-preview" aria-pressed={selected}>{summary.title}</button>
       {summary.meta && <small className="work-order-mine-meta" title={summary.meta}>{summary.meta}</small>}
     </td>
     <td><div className="work-order-mine-badges">
@@ -193,7 +215,9 @@ function MineQueueRow({ row, today, linkState, onUrged }: {
     <td className="work-order-mine-date">
       {deadline.date ? <>
         <time dateTime={deadline.date}>{fmtDate(deadline.date)}</time>
-        <small className={late ? "is-late" : undefined}>{dateLabel}{relative && ` · ${relative}`}</small>
+        <small className={deadline.late ? "is-late" : undefined}>
+          {deadline.relative ? [deadline.shortLabel, deadline.relative].filter(Boolean).join(" · ") : deadline.label}
+        </small>
       </> : <span className="table-placeholder">按 SLA</span>}
     </td>
     <td>
@@ -201,16 +225,54 @@ function MineQueueRow({ row, today, linkState, onUrged }: {
         {step.label
           ? <Link className={`work-order-next-step tone-${step.tone}`}
               to={step.action ? `${ticketPath}?act=${step.action}` : ticketPath} state={linkState}>
-              {step.label}<ArrowRight size={14} aria-hidden="true" />
+              {step.label}<ArrowRight size={13} aria-hidden="true" />
             </Link>
-          : <span className={`work-order-next-step is-passive tone-${step.tone}`}>{passiveParts(step)}</span>}
+          : <span className="work-order-mine-passive">{passiveParts(step)}</span>}
         <UrgeControl row={row} onSent={onUrged} />
       </div>
-      {step.hint && <small>{step.hint}</small>}
     </td>
   </tr>;
 }
 
+function MineTicketPreview({ row, today, linkState }: { row: TicketListItem; today: string; linkState: DetailLinkState }) {
+  const { title } = todoRowSummary(row);
+  const deadline = mineDeadline(row, today);
+  const step = nextStepOf(row);
+  const ticketPath = `/work-orders/${encodeURIComponent(row.ticket_id)}`;
+  return <>
+    <div className="work-order-mine-preview-head">
+      <span><PanelRight size={16} aria-hidden="true" />工单预览</span>
+      <Link to={ticketPath} state={linkState}>查看详情<ArrowRight size={14} aria-hidden="true" /></Link>
+    </div>
+    <div className="work-order-mine-preview-body">
+      <div className="work-order-mine-preview-heading">
+        {row.ticket_no && <p className="work-order-mine-number">{row.ticket_no}</p>}
+        <h2 aria-live="polite">{title}</h2>
+        <div className="work-order-mine-badges"><TicketTypeTag type={row.ticket_type} /><TicketStatusTag status={row.status} type={row.ticket_type} /></div>
+      </div>
+      <dl className="work-order-mine-facts">
+        {row.customer_name && <div><dt>客户</dt><dd>{row.customer_name}</dd></div>}
+        <div>
+          <dt>{deadline.label}</dt>
+          <dd className={deadline.late ? "is-late" : undefined}>
+            {deadline.date ? <time dateTime={deadline.date}>{fmtDate(deadline.date)}</time> : "按 SLA"}
+            {deadline.relative && <small>{deadline.relative}</small>}
+          </dd>
+        </div>
+      </dl>
+      <div className="work-order-mine-inspect-next" data-tone={step.tone}>
+        <p>下一步</p>
+        {step.label
+          ? <Link to={step.action ? `${ticketPath}?act=${step.action}` : ticketPath} state={linkState} className="work-order-mine-preview-action">
+              {step.label}<ArrowRight size={15} aria-hidden="true" />
+            </Link>
+          : <div className="work-order-mine-passive">{passiveParts(step)}</div>}
+        {step.hint && <small>{step.hint}</small>}
+      </div>
+    </div>
+  </>;
+}
+
 /**
  * 只读态文案的渲染片段:把对家**人名**套一层 `<strong>`(业主 2026-11-18 裁定:人名要加粗)。
  *

+ 22 - 6
web-scaffold/src/pages/__tests__/work-order-mine.test.tsx

@@ -55,20 +55,36 @@ it("切换优先队列后可直接办理,返回时恢复队列筛选", async (
   vi.mocked(ticketList).mockResolvedValue(results([fault, planned, awaiting]));
   const queues = renderMine();
   const table = await screen.findByRole("table", { name: "我的待办工单" });
-  expect(within(table).getAllByRole("link", { name: /排查线路掉包|安排专线开通|核对接入配置/ }).map((link) => link.textContent))
+  expect(within(table).getAllByRole("button", { name: /排查线路掉包|安排专线开通|核对接入配置/ }).map((button) => button.textContent))
     .toEqual(["排查线路掉包", "安排专线开通", "核对接入配置"]);
   expect(ticketList).toHaveBeenCalledWith(expect.objectContaining({ assignee: "me", page: 1, page_size: 100 }));
 
   fireEvent.click(queues.getByRole("link", { name: /优先处理/ }));
-  expect(screen.queryByRole("link", { name: "安排专线开通" })).toBeNull();
-  fireEvent.click(screen.getByRole("link", { name: "标记完成" }));
+  expect(screen.queryByRole("button", { name: "安排专线开通" })).toBeNull();
+  fireEvent.click(within(screen.getByRole("table", { name: "我的待办工单" })).getByRole("link", { name: "标记完成" }));
   expect(screen.getByLabelText("工单动作").textContent).toBe("?act=mark_done");
   const back = screen.getByRole("link", { name: "返回我的待办" });
   expect(back.getAttribute("href")).toBe("/work-orders/mine?view=due");
   fireEvent.click(back);
   expect((await screen.findByRole("link", { name: /优先处理/ })).getAttribute("aria-current")).toBe("page");
-  expect(await screen.findByRole("link", { name: "排查线路掉包" })).toBeTruthy();
-  expect(screen.queryByRole("link", { name: "核对接入配置" })).toBeNull();
+  expect(await screen.findByRole("button", { name: "排查线路掉包" })).toBeTruthy();
+  expect(screen.queryByRole("button", { name: "核对接入配置" })).toBeNull();
+});
+
+it("在列表选中工单后更新预览,从详情返回时保留选中项", async () => {
+  vi.mocked(ticketList).mockResolvedValue(results([fault, planned]));
+  renderMine();
+  const other = await screen.findByRole("button", { name: "安排专线开通" });
+  fireEvent.click(other);
+  expect(other.getAttribute("aria-pressed")).toBe("true");
+  const preview = within(screen.getByRole("complementary", { name: "工单预览" }));
+  expect(preview.getByRole("heading", { name: "安排专线开通" })).toBeTruthy();
+  expect(preview.getByText("未到执行日")).toBeTruthy();
+  fireEvent.click(preview.getByRole("link", { name: "查看详情" }));
+  const back = screen.getByRole("link", { name: "返回我的待办" });
+  expect(back.getAttribute("href")).toBe("/work-orders/mine?selected=W-2");
+  fireEvent.click(back);
+  expect((await screen.findByRole("button", { name: "安排专线开通" })).getAttribute("aria-pressed")).toBe("true");
 });
 
 it("待确认队列保留对家与催办,并在发送后刷新状态", async () => {
@@ -78,7 +94,7 @@ it("待确认队列保留对家与催办,并在发送后刷新状态", async (
   const queues = renderMine();
   await screen.findByRole("table", { name: "我的待办工单" });
   fireEvent.click(queues.getByRole("link", { name: /待对方确认/ }));
-  expect(screen.getByText("李经理")).toBeTruthy();
+  expect(within(screen.getByRole("table", { name: "我的待办工单" })).getByText("李经理")).toBeTruthy();
   fireEvent.click(screen.getByRole("button", { name: "催办" }));
   expect(await screen.findByText("今日已催")).toBeTruthy();
   expect(ticketUrge).toHaveBeenCalledWith({ ticket_id: "W-3" });

+ 194 - 106
web-scaffold/src/styles/work-order-mine.css

@@ -2,86 +2,84 @@
   display: grid;
   align-content: start;
   min-width: 0;
-  gap: 14px;
+  gap: 16px;
+  padding-bottom: 24px;
 }
-.work-order-mine-heading { margin: 0; }
-.work-order-mine-links, .work-order-mine-all { display: flex; align-items: center; gap: 8px; }
-.work-order-mine-links { flex-wrap: wrap; justify-content: flex-end; gap: 9px 16px; }
-.work-order-mine-links .wo-m-desktop-hint { align-items: center; gap: 5px; margin: 0; padding: 0; background: transparent; }
-.work-order-mine-links .wo-m-desktop-hint > svg { margin: 0; }
-.work-order-mine-all {
-  min-height: 36px;
-  padding: 0 12px;
-  border: 1px solid var(--border);
-  border-radius: var(--radius-control);
-  background: var(--card);
-  color: var(--text-secondary);
-  font-size: var(--type-body);
-  font-weight: 550;
-  white-space: nowrap;
-}
-.work-order-mine-all:hover { border-color: var(--primary-border); color: var(--primary); }
-.work-order-mine-all:focus-visible, .work-order-mine-views a:focus-visible, .work-order-mine-scroll:focus-visible { outline: 2px solid var(--ring); outline-offset: -2px; }
 
+.work-order-mine-hero {
+  position: relative;
+  isolation: isolate;
+  display: grid;
+  grid-template-columns: minmax(240px, 1fr) minmax(320px, .95fr);
+  align-items: center;
+  gap: 22px;
+  min-height: 172px;
+  overflow: hidden;
+  padding: 23px 26px;
+  border: 1px solid #23514f;
+  border-radius: 14px;
+  background: linear-gradient(108deg, #12272c 15%, #153b3d 73%, #1b514d);
+  color: #f4fcfa;
+  box-shadow: 0 7px 24px rgb(17 45 48 / 12%);
+}
+.work-order-mine-hero::after {
+  position: absolute;
+  z-index: -1;
+  inset: 0;
+  background:
+    radial-gradient(ellipse at 87% 2%, rgb(116 228 206 / 13%), transparent 44%),
+    repeating-radial-gradient(ellipse at 100% 2%, transparent 0 32px, rgb(188 248 234 / 8%) 33px 34px, transparent 35px 60px);
+  mask-image: linear-gradient(90deg, transparent 38%, #000 86%);
+  pointer-events: none;
+  content: "";
+}
+.work-order-mine-hero-copy { min-width: 0; }
+.work-order-mine-hero-copy time { display: flex; align-items: center; gap: 6px; color: #b8dcd6; font-size: 12px; font-weight: 550; }
+.work-order-mine-hero-copy h1 { margin: 8px 0 5px; font-size: clamp(29px, 3vw, 39px); font-weight: 680; letter-spacing: -.04em; line-height: 1.12; }
+.work-order-mine-hero-copy p { margin: 0; color: #c1dad7; font-size: var(--type-support); }
 .work-order-mine-summary {
   display: grid;
   grid-template-columns: repeat(3, minmax(0, 1fr));
-  gap: 1px;
+  min-width: 0;
   margin: 0;
   overflow: hidden;
-  border: 1px solid var(--border);
-  border-radius: var(--radius-card);
-  background: var(--border-subtle);
-  box-shadow: var(--shadow-card);
+  border: 1px solid rgb(213 250 244 / 22%);
+  border-radius: 10px;
+  background: rgb(9 33 36 / 28%);
 }
-.work-order-mine-summary > div {
-  display: flex;
-  align-items: center;
-  justify-content: space-between;
-  min-width: 0;
-  gap: 8px 14px;
-  padding: 13px 16px;
-  background: var(--card);
+.work-order-mine-summary > div { min-width: 0; padding: 13px 17px 12px; }
+.work-order-mine-summary > div + div { border-inline-start: 1px solid rgb(213 250 244 / 17%); }
+.work-order-mine-summary dt { color: #c3e1dc; font-size: var(--type-support); }
+.work-order-mine-summary dd {
+  margin: 4px 0 0;
+  color: #f4fcfa;
+  font: 580 clamp(24px, 2.6vw, 34px)/1.1 var(--font-mono);
+  letter-spacing: -.045em;
+  font-variant-numeric: tabular-nums;
 }
-.work-order-mine-summary dt { display: flex; align-items: center; gap: 9px; color: var(--text-secondary); font-size: var(--type-support); }
-.work-order-mine-metric-icon {
-  display: grid;
-  width: 34px;
-  height: 34px;
-  flex: none;
-  place-items: center;
-  border-radius: var(--radius-control);
-  background: var(--surface-subtle);
-  color: var(--icon);
-}
-.work-order-mine-summary dd { margin: 0; color: var(--foreground); font: 600 24px/1.2 var(--font-mono); font-variant-numeric: tabular-nums; }
-.work-order-mine-summary > [data-tone="primary"] { background: var(--primary-soft); }
-.work-order-mine-summary > [data-tone="primary"] :is(dd, .work-order-mine-metric-icon) { color: var(--primary-soft-foreground); }
-.work-order-mine-summary > [data-tone="primary"] .work-order-mine-metric-icon { background: var(--card); }
-.work-order-mine-summary > [data-tone="warning"] :is(dd, .work-order-mine-metric-icon) { color: var(--warning); }
-.work-order-mine-summary > [data-tone="warning"] .work-order-mine-metric-icon { background: var(--warning-soft); }
+.work-order-mine-summary [data-warning] dd { color: #ffd49b; }
 
-.work-order-mine-desk { display: grid; grid-template-columns: 188px minmax(0, 1fr); align-items: start; gap: 14px; min-width: 0; }
-.work-order-mine-nav {
-  position: sticky;
-  top: calc(4rem + 14px);
+.work-order-mine-toolbar, .work-order-mine-links { display: flex; align-items: center; flex-wrap: wrap; justify-content: space-between; gap: 9px 12px; min-width: 0; }
+.work-order-mine-views {
+  display: flex;
+  gap: 4px;
   min-width: 0;
-  padding: 12px 9px 9px;
+  max-width: 100%;
+  overflow-x: auto;
+  padding: 4px;
   border: 1px solid var(--border);
-  border-radius: var(--radius-card);
+  border-radius: 10px;
   background: var(--card);
-  box-shadow: var(--shadow-card);
+  scrollbar-width: thin;
 }
-.work-order-mine-nav h2 { margin: 0 9px 8px; color: var(--muted-foreground); font-size: var(--type-support); font-weight: 550; }
-.work-order-mine-views { display: grid; gap: 3px; }
 .work-order-mine-views > a {
-  display: grid;
-  grid-template-columns: auto minmax(0, 1fr) auto;
+  display: flex;
+  flex: none;
   align-items: center;
-  min-height: 40px;
-  gap: 8px;
-  padding: 4px 9px;
-  border-radius: var(--radius-control);
+  gap: 7px;
+  min-height: 35px;
+  padding: 4px 10px;
+  border-radius: 6px;
   color: var(--text-secondary);
   font-size: var(--type-body);
   white-space: nowrap;
@@ -89,59 +87,149 @@
 }
 .work-order-mine-views > a:hover { background: var(--surface-subtle); color: var(--foreground); }
 .work-order-mine-views > a[aria-current="page"] { background: var(--primary-soft); color: var(--primary-soft-foreground); font-weight: 600; }
-.work-order-mine-view-count { min-width: 21px; padding: 1px 4px; border-radius: 5px; background: var(--surface-subtle); color: var(--text-secondary); font: 550 var(--type-meta)/1.5 var(--font-mono); text-align: center; }
+.work-order-mine-view-count, .work-order-mine-group-count {
+  min-width: 20px;
+  padding: 1px 4px;
+  border-radius: 5px;
+  background: var(--surface-subtle);
+  color: var(--text-secondary);
+  font: 550 var(--type-meta)/1.5 var(--font-mono);
+  text-align: center;
+}
 .work-order-mine-views > a[aria-current="page"] .work-order-mine-view-count { background: var(--card); color: var(--primary-soft-foreground); }
 .work-order-mine-views > a .work-order-mine-view-count[data-priority="true"] { background: var(--warning-soft); color: var(--warning); }
+.work-order-mine-links { justify-content: flex-end; }
+.work-order-mine-links .wo-m-desktop-hint { align-items: center; gap: 5px; margin: 0; padding: 0; background: transparent; }
+.work-order-mine-links .wo-m-desktop-hint > svg { margin: 0; }
+.work-order-mine-all { display: inline-flex; align-items: center; gap: 8px; color: var(--text-secondary); font-size: var(--type-body); font-weight: 550; white-space: nowrap; }
+.work-order-mine-all:hover { color: var(--primary); }
+.work-order-mine-page :is(a, button, .work-order-mine-scroll):focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; }
+
+.work-order-mine-desk { display: grid; grid-template-columns: minmax(0, 1fr); align-items: start; gap: 16px; min-width: 0; }
+.work-order-mine-desk:has(> .work-order-mine-preview) { grid-template-columns: minmax(0, 1fr) minmax(276px, 29%); }
 .work-order-mine-queue { min-width: 0; }
 .work-order-mine-scroll { overflow: auto; overscroll-behavior-x: contain; }
-.ops-table.work-order-mine-table { min-width: 700px; table-layout: fixed; }
-.work-order-mine-table :is(th, td) { padding: 9px 16px; }
-.work-order-mine-table thead th { border-top: 0; }
-.work-order-mine-table :is(th, td):is(:first-child, :last-child) { padding-inline: 20px; }
-.work-order-mine-group > th { border-block: 1px solid var(--border-subtle); background: var(--surface-subtle); }
-.work-order-mine-group-label { display: inline-flex; align-items: center; gap: 6px; color: var(--foreground); font-size: var(--type-support); font-weight: 600; }
-.work-order-mine-group-label > svg { color: var(--icon); }
-.work-order-mine-group[data-tone="urgent"] .work-order-mine-group-label > svg { color: var(--warning); }
-.work-order-mine-group-hint { margin-inline-start: 10px; color: var(--muted-foreground); font-size: var(--type-meta); font-weight: 400; }
-.work-order-mine-row :is(.table-cell-title, .work-order-mine-meta) { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
-.work-order-mine-row .table-cell-title:hover { color: var(--primary); text-decoration: underline; }
-.work-order-mine-row small { display: block; margin-top: 3px; color: var(--muted-foreground); font-size: var(--type-meta); line-height: 1.4; white-space: normal; overflow-wrap: anywhere; }
-.work-order-mine-badges, .work-order-mine-next { display: flex; flex-wrap: wrap; align-items: center; gap: 5px 7px; }
-.work-order-mine-badges :is(.work-order-status, .work-order-type) { padding: 3px 8px; font-size: var(--type-meta); font-weight: 500; line-height: 1.5; }
-.work-order-mine-date time { color: var(--foreground); font-size: var(--type-body); font-weight: 500; font-variant-numeric: tabular-nums; }
-.work-order-mine-date .is-late { color: var(--warning); }
-.work-order-mine-next .is-passive { display: inline; min-height: 0; padding: 0; border: 0; white-space: normal; overflow-wrap: anywhere; }
-.work-order-mine-next .work-order-waiting-name { display: inline; font-size: inherit; line-height: inherit; }
+.work-order-mine-scroll:focus-visible { outline-offset: -2px; }
+.ops-table.work-order-mine-table { min-width: 598px; table-layout: fixed; }
+.work-order-mine-table :is(th, td) { padding: 10px 12px; }
+.work-order-mine-table thead th { border-top: 0; background: var(--card); }
+.work-order-mine-table :is(th, td):is(:first-child, :last-child) { padding-inline: 16px; }
+.work-order-mine-table .work-order-mine-group > th { padding-block: 7px; background: var(--surface-subtle); }
+.work-order-mine-group-label { color: var(--text-secondary); font-size: var(--type-support); font-weight: 650; vertical-align: middle; }
+.work-order-mine-group[data-tone="urgent"] .work-order-mine-group-label { color: var(--warning); }
+.work-order-mine-group-count { display: inline-block; margin-inline-start: 7px; background: var(--card); vertical-align: middle; }
+.work-order-mine-ticket-button, .work-order-mine-meta { display: block; min-width: 0; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
+.work-order-mine-ticket-button { width: 100%; min-height: 22px; padding: 0; color: var(--foreground); font: inherit; font-weight: 560; text-align: start; cursor: pointer; }
+.work-order-mine-ticket-button:hover { color: var(--primary); text-decoration: underline; }
+.work-order-mine-row td small { margin-top: 3px; color: var(--muted-foreground); font-size: var(--type-meta); line-height: 1.4; }
+.work-order-mine-badges, .work-order-mine-next { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
+.work-order-mine-badges :is(.work-order-status, .work-order-type) { padding: 2px 7px; font-size: var(--type-meta); font-weight: 500; line-height: 1.5; }
+.work-order-mine-date time { color: var(--foreground); font-size: var(--type-support); font-weight: 550; font-variant-numeric: tabular-nums; }
+.work-order-mine-date .is-late, .work-order-mine-facts .is-late { color: var(--warning); }
+.work-order-mine-passive { color: var(--text-secondary); font-size: var(--type-support); white-space: normal; overflow-wrap: anywhere; }
+.work-order-mine-page .work-order-mine-passive .work-order-waiting-name { display: inline; color: var(--foreground); font-size: inherit; font-weight: 650; line-height: inherit; }
 .work-order-mine-next .work-order-next-step > svg { flex: none; }
-.work-order-mine-next .is-error { flex-basis: 100%; color: var(--destructive); }
-.work-order-mine-row:last-child td { border-bottom: 0; }
-.work-order-mine-row:focus-within td { background: var(--surface-subtle); }
+.work-order-mine-next .is-error { flex-basis: 100%; color: var(--destructive); white-space: normal; }
+.work-order-mine-row[data-selected] td { background: var(--primary-soft); }
+.work-order-mine-row[data-selected] td:first-child { box-shadow: inset 3px 0 var(--primary); }
+.work-order-mine-row[data-selected] .work-order-mine-ticket-button { color: var(--primary-soft-foreground); }
+.work-order-mine-row:focus-within:not([data-selected]) td { background: var(--surface-subtle); }
+
+.work-order-mine-preview {
+  position: sticky;
+  top: calc(4rem + 16px);
+  min-width: 0;
+  overflow: hidden;
+  border: 1px solid var(--border);
+  border-radius: var(--radius-card);
+  background: var(--card);
+  box-shadow: var(--shadow-card);
+  scroll-margin-top: calc(4rem + 12px);
+}
+.work-order-mine-preview-head {
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  flex-wrap: wrap;
+  gap: 8px;
+  padding: 13px 16px;
+  border-bottom: 1px solid var(--border-subtle);
+  background: var(--surface-subtle);
+  color: var(--text-secondary);
+  font-size: var(--type-support);
+}
+.work-order-mine-preview-head :is(span, a) { display: inline-flex; align-items: center; gap: 6px; }
+.work-order-mine-preview-head span { font-weight: 600; }
+.work-order-mine-preview-head a { color: var(--primary); font-size: var(--type-meta); font-weight: 550; }
+.work-order-mine-preview-head a:hover { text-decoration: underline; }
+.work-order-mine-preview-body { display: grid; gap: 16px; padding: 17px 16px 16px; min-width: 0; }
+.work-order-mine-preview-heading, .work-order-mine-facts { min-width: 0; }
+.work-order-mine-number { margin: 0; color: var(--primary); font: 550 12px/1.5 var(--font-mono); overflow-wrap: anywhere; }
+.work-order-mine-preview-heading h2 { margin: 4px 0 9px; font-size: 19px; font-weight: 680; letter-spacing: -.02em; line-height: 1.35; overflow-wrap: anywhere; }
+.work-order-mine-facts { display: grid; gap: 0; margin: 0; }
+.work-order-mine-facts > div {
+  display: grid;
+  grid-template-columns: minmax(4.4em, auto) minmax(0, 1fr);
+  align-items: baseline;
+  gap: 8px;
+  padding: 9px 0;
+  border-top: 1px solid var(--border-subtle);
+  font-size: var(--type-support);
+}
+.work-order-mine-facts dt { color: var(--muted-foreground); }
+.work-order-mine-facts dd { margin: 0; color: var(--foreground); font-weight: 540; text-align: end; overflow-wrap: anywhere; }
+.work-order-mine-facts small { display: block; margin-top: 2px; font-size: var(--type-meta); font-weight: 400; }
+.work-order-mine-inspect-next {
+  display: grid;
+  align-content: start;
+  gap: 6px;
+  padding: 11px 12px;
+  border: 1px solid var(--border-subtle);
+  border-radius: 9px;
+  background: var(--surface-subtle);
+}
+.work-order-mine-inspect-next > p { margin: 0; color: var(--muted-foreground); font-size: var(--type-meta); }
+.work-order-mine-inspect-next[data-tone="urgent"] { border-color: var(--warning-border); }
+.work-order-mine-inspect-next > small { color: var(--text-secondary); font-size: var(--type-meta); }
+.work-order-mine-preview-action {
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  gap: 7px;
+  min-height: 34px;
+  padding: 4px 9px;
+  border-radius: 6px;
+  background: var(--primary);
+  color: var(--primary-foreground);
+  font-size: var(--type-support);
+  font-weight: 600;
+}
+.work-order-mine-preview-action:hover { background: var(--primary-hover); }
 
-.work-order-mine-empty { gap: 8px; padding-block: 48px; }
+.work-order-mine-empty { gap: 8px; padding-block: 54px; }
 .work-order-mine-empty h3, .work-order-mine-empty p { margin: 0; }
 .work-order-mine-empty[role="status"] { color: var(--muted-foreground); font-size: var(--type-body); }
-.work-order-mine-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: 9px 20px; border-top: 1px solid var(--border-subtle); color: var(--muted-foreground); font-size: var(--type-support); }
+.work-order-mine-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: 9px 16px; border-top: 1px solid var(--border-subtle); color: var(--muted-foreground); font-size: var(--type-support); }
 
 @media (prefers-reduced-motion: no-preference) {
   .work-order-mine-loading { animation: work-order-mine-spin 1s linear infinite; }
   @keyframes work-order-mine-spin { to { rotate: 360deg; } }
 }
-@media (max-width: 1200px) {
-  .work-order-mine-desk { grid-template-columns: minmax(0, 1fr); gap: 10px; }
-  .work-order-mine-nav { position: static; padding: 6px; }
-  .work-order-mine-nav h2 { display: none; }
-  .work-order-mine-views { display: flex; overflow-x: auto; scrollbar-width: thin; }
-  .work-order-mine-views > a { flex: none; min-height: 36px; }
-}
-@media (max-width: 900px) {
-  .work-order-mine-heading { align-items: flex-start; flex-wrap: wrap; gap: 8px 14px; }
-  .work-order-mine-links { justify-content: flex-start; }
-}
-@media (max-width: 600px) {
-  .work-order-mine-summary > div { align-items: flex-start; flex-direction: column; gap: 7px; padding: 10px; }
-  .work-order-mine-summary dt { gap: 5px; }
-  .work-order-mine-metric-icon { width: 24px; height: 24px; }
-  .work-order-mine-metric-icon > svg { width: 14px; height: 14px; }
-  .work-order-mine-summary dd { font-size: 20px; }
-  .work-order-mine-footer { padding-inline: 14px; }
+@media (max-width: 1170px) {
+  .work-order-mine-desk:has(> .work-order-mine-preview) { grid-template-columns: minmax(0, 1fr); }
+  .work-order-mine-preview { position: static; grid-row: 1; }
+  .work-order-mine-preview-body { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) minmax(0, 1fr); align-items: start; }
+}
+@media (max-width: 720px) {
+  .work-order-mine-hero { grid-template-columns: minmax(0, 1fr); gap: 16px; padding: 19px 17px; }
+  .work-order-mine-summary > div { padding: 10px 8px; }
+  .work-order-mine-summary dt { font-size: 11px; }
+  .work-order-mine-preview-body { grid-template-columns: repeat(2, minmax(0, 1fr)); }
+  .work-order-mine-inspect-next { grid-column: 1 / -1; }
+}
+@media (max-width: 480px) {
+  .work-order-mine-page, .work-order-mine-desk { gap: 12px; }
+  .work-order-mine-preview-body { grid-template-columns: minmax(0, 1fr); gap: 11px; }
+  .work-order-mine-views > a { padding-inline: 7px; }
+  .work-order-mine-views > a > svg { display: none; }
 }