fix(governance): 穩定 P1-002 盤點頁文字換行
This commit is contained in:
@@ -65,6 +65,9 @@ function SmallLabel({ children }: { children: ReactNode }) {
|
||||
color: '#87867f',
|
||||
textTransform: 'uppercase',
|
||||
letterSpacing: '0.5px',
|
||||
lineHeight: 1.25,
|
||||
minWidth: 0,
|
||||
overflowWrap: 'anywhere',
|
||||
}}>
|
||||
{children}
|
||||
</span>
|
||||
@@ -86,9 +89,10 @@ function Chip({ value, muted = false }: { value: string; muted?: boolean }) {
|
||||
fontSize: 10,
|
||||
lineHeight: 1.3,
|
||||
maxWidth: '100%',
|
||||
overflowX: 'auto',
|
||||
overflowY: 'hidden',
|
||||
whiteSpace: 'nowrap',
|
||||
minWidth: 0,
|
||||
overflowWrap: 'anywhere',
|
||||
wordBreak: 'break-word',
|
||||
whiteSpace: 'normal',
|
||||
}}>
|
||||
{value}
|
||||
</span>
|
||||
@@ -491,7 +495,7 @@ export function AutomationInventoryTab() {
|
||||
}
|
||||
|
||||
return (
|
||||
<div style={{ padding: 20, display: 'flex', flexDirection: 'column', gap: 16 }}>
|
||||
<div className="automation-inventory-tab-root" style={{ padding: 20, display: 'flex', flexDirection: 'column', gap: 16, minWidth: 0 }}>
|
||||
<GlassCard variant="subtle" padding="md">
|
||||
<div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between', gap: 12, flexWrap: 'wrap' }}>
|
||||
<div style={{ display: 'flex', alignItems: 'center', gap: 10, minWidth: 0 }}>
|
||||
@@ -1246,6 +1250,20 @@ export function AutomationInventoryTab() {
|
||||
</div>
|
||||
|
||||
<style jsx global>{`
|
||||
.automation-inventory-tab-root,
|
||||
.automation-inventory-tab-root * {
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.automation-inventory-tab-root span,
|
||||
.automation-inventory-tab-root div {
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
.automation-inventory-tab-root span {
|
||||
white-space: normal !important;
|
||||
}
|
||||
|
||||
@media (max-width: 900px) {
|
||||
.automation-inventory-kpi-grid,
|
||||
.automation-inventory-progress-kpi-grid,
|
||||
|
||||
@@ -51,7 +51,9 @@
|
||||
- 前端 typecheck 通過。
|
||||
- `git diff --check`、`source-control-owner-response-guard.py`、`security-mirror-progress-guard.py` 通過。
|
||||
- 本地 API readback 通過:`GET /api/v1/agents/gitea-workflow-runner-health` 回 `gitea_workflow_runner_health_v1`、current `P1-002`、next `P1-003`、workflows `9`。
|
||||
- 本機 Next production build 與 browser smoke:受本機磁碟 `99-100%` 與 `.next` cache / chunk 缺檔阻擋;編譯階段曾到 `Compiled successfully`,但 page-data / dev runtime 受殘留 chunk `194.js`、`@swc/helpers` 與 `server-development/0.pack.gz` 缺檔影響。正式 build 與頁面驗證改由 Gitea CD / production smoke 判定。
|
||||
- 本機磁碟曾降到 `124MiB` 可用並造成 `.next` half-written cache;已清本機 build cache,空間回到約 `3.9GiB+`,重新 build 通過。
|
||||
- Next production build 通過;以 standalone server 驗證 `/zh-TW/governance?tab=automation-inventory` desktop `1440x1200` 與 mobile `390x1200` smoke 通過,四個 agents API 皆 `200`,`Gitea 工作流程 / Runner 健康合約`、`P1-002`、`P1-003`、`9`、`8`、`不可誤讀合約` 可見;`horizontalOverflow=false`、overflowing elements `0`、禁止操作按鈕 `0`。
|
||||
- 本地截圖:`/tmp/awoooi-p1-002-gitea-health-local-desktop.png`、`/tmp/awoooi-p1-002-gitea-health-local-mobile.png`。
|
||||
- 正式環境 deploy 與 production smoke:待推送後執行。
|
||||
|
||||
**邊界**:
|
||||
|
||||
@@ -1077,9 +1077,9 @@ UI:
|
||||
狀態變更:待辦 -> 完成。
|
||||
證據:gitea_workflow_runner_health_v1 schema / snapshot;GET /api/v1/agents/gitea-workflow-runner-health;治理頁 Gitea 工作流程 / Runner 健康合約區塊;automation backlog 78%;inventory tasks 28。
|
||||
目前數字:Gitea workflows 9;schedule 2;workflow_dispatch 7;notify bridge 6;actionable/failure quiet workflows 2;runner contracts 4;runner contract action_required 1;仍需 runner owner attestation 的 workflow 8;notification contracts 6;quiet success contracts 2;backlog done 18/23;overall 78%;P1 86%。
|
||||
驗證:JSON parse 通過;gitea workflow runner health / inventory / backlog 目標 pytest 23 passed;Python py_compile 通過;zh-TW / en i18n key 差異 0;web typecheck 通過;source-control-owner-response guard、security-mirror-progress guard、git diff --check 通過;本地 API readback 回 `gitea_workflow_runner_health_v1`、current `P1-002`、next `P1-003`、workflows `9`。
|
||||
正式驗證:待 push 後補 Gitea code-review / CD run、production API readback 與 production desktop / mobile smoke;本機 Next build / browser smoke 受磁碟 `99-100%` 與 `.next` cache / chunk 缺檔阻擋,改以 Gitea CD 乾淨環境作 build 判定。
|
||||
阻擋:本機磁碟空間與 `.next` cache 不完整只阻擋 local build / browser smoke;workflow modification、runner restart / stop、runner label change、runner registration、Secret payload read、notification send、schedule change、Gitea write、deploy / migration trigger 仍全部禁止。
|
||||
驗證:JSON parse 通過;gitea workflow runner health / inventory / backlog 目標 pytest 23 passed;Python py_compile 通過;zh-TW / en i18n key 差異 0;web typecheck 通過;Next production build 通過;source-control-owner-response guard、security-mirror-progress guard、git diff --check 通過;本地 API readback 回 `gitea_workflow_runner_health_v1`、current `P1-002`、next `P1-003`、workflows `9`;本地 standalone desktop `1440x1200` 與 mobile `390x1200` smoke 通過,四個 agents API 皆 `200`,`horizontalOverflow=false`,overflowing elements `0`,禁止操作按鈕 `0`。
|
||||
正式驗證:待 push 後補 Gitea code-review / CD run、production API readback 與 production desktop / mobile smoke。
|
||||
阻擋:正式環境尚未推送;workflow modification、runner restart / stop、runner label change、runner registration、Secret payload read、notification send、schedule change、Gitea write、deploy / migration trigger 仍全部禁止。
|
||||
下一步:P1-003 盤點監控合約與降噪機會。
|
||||
```
|
||||
|
||||
|
||||
@@ -3508,8 +3508,8 @@ Phase 6 完成後
|
||||
- P1-002:新增 `GET /api/v1/agents/gitea-workflow-runner-health` 只讀 API 與 service guard,強制拒絕把 snapshot 誤讀成 workflow 修改、runner restart / stop、Secret payload、Telegram 測試通知、排程變更、Gitea write token、deploy / migration workflow 觸發授權。
|
||||
- P1-002:治理頁 `/zh-TW/governance?tab=automation-inventory` 新增 Gitea 工作流程 / Runner 健康合約區塊;不新增任何執行、部署、通知、workflow 或 runner 操作按鈕。
|
||||
- 目前數字:Gitea workflows `9`;schedule `2`;workflow_dispatch `7`;notify bridge `6`;actionable / failure quiet workflows `2`;runner contracts `4`;runner contract action_required `1`;仍需 runner owner attestation 的 workflow `8`;notification contracts `6`;quiet success contracts `2`;automation backlog done `18/23`、overall `78%`、P1 `86%`;inventory tasks `28`。
|
||||
- 本地驗證:JSON parse 通過;Gitea workflow / runner health、automation inventory、automation backlog 目標 pytest `23 passed`;Python py_compile 通過;zh-TW / en i18n key 差異 `0`;web typecheck 通過;`source-control-owner-response-guard.py`、`security-mirror-progress-guard.py`、`git diff --check` 通過;本地 API readback 回 `gitea_workflow_runner_health_v1`、current `P1-002`、next `P1-003`、workflows `9`。
|
||||
- 本機 Web build / browser smoke:受本機磁碟 `99-100%` 與 `.next` cache / chunk 缺檔阻擋;編譯階段曾到 `Compiled successfully`,但 page-data / dev runtime 受殘留 chunk `194.js`、`@swc/helpers` 與 `server-development/0.pack.gz` 缺檔影響。正式 build 與頁面驗證改由 Gitea CD / production smoke 判定。
|
||||
- 本地驗證:JSON parse 通過;Gitea workflow / runner health、automation inventory、automation backlog 目標 pytest `23 passed`;Python py_compile 通過;zh-TW / en i18n key 差異 `0`;web typecheck 通過;Next production build 通過;`source-control-owner-response-guard.py`、`security-mirror-progress-guard.py`、`git diff --check` 通過;本地 API readback 回 `gitea_workflow_runner_health_v1`、current `P1-002`、next `P1-003`、workflows `9`。
|
||||
- 本機 Web build / browser smoke:本機磁碟曾只剩 `124MiB`,導致 `.next` cache / chunk 半寫入;已清 build cache 並重新 build。以 standalone server 驗證 `/zh-TW/governance?tab=automation-inventory` desktop `1440x1200` 與 mobile `390x1200` smoke 通過,四個 agents API 皆 `200`,`Gitea 工作流程 / Runner 健康合約`、`P1-002`、`P1-003`、`9`、`8`、`不可誤讀合約` 可見;`horizontalOverflow=false`、overflowing elements `0`、禁止操作按鈕 `0`;截圖:`/tmp/awoooi-p1-002-gitea-health-local-desktop.png`、`/tmp/awoooi-p1-002-gitea-health-local-mobile.png`。
|
||||
|
||||
**下一步:**
|
||||
1. 推 Gitea main,等待 code-review / CD 乾淨環境驗證,再補 production API readback 與 desktop / mobile smoke。
|
||||
|
||||
Reference in New Issue
Block a user