[AnalyticalTable]: useF2CellEdit inserts "undefined" into grid-cell aria-label
維護者通常 1 天內回覆
評估
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 新手友好度
- 74/100
- Issue 類型
- 缺陷
- 描述清晰度
- 描述清楚
- 活躍度
- 活躍
- 技術堆疊
- react, typescript
研究方向
錯誤的標籤是在 packages/main/src/components/AnalyticalTable/pluginHooks/useF2CellEdit.ts 第 82 行附近組出來的,此處儲存格的 aria-label 是由一個可能缺漏的標籤串接而成。從這裡開始,追蹤在未傳入 cellLabel 回呼時標籤文字的來源。完成標準是:沒有明確標籤的儲存格,其 aria-label 中不再出現字面值 "undefined",且現有的 AnalyticalTable F2 儲存格編輯測試仍然通過。
由索引模型根據 Issue 內容生成。
描述
Describe the bug
When AnalyticalTable uses useF2CellEdit with a custom link cell and no explicit cellLabel, the hook generates:
aria-label="Includes Link undefined"
The cell contains a valid, populated link title. The literal undefined comes from concatenating a missing aria-label, rather than missing application data.
This can produce an incorrect screen-reader announcement and obscure the actual cell content.
Isolated Example
No response
Reproduction steps
import {
AnalyticalTable,
AnalyticalTableHooks,
Link,
ThemeProvider
} from "@ui5/webcomponents-react";
import type {
AnalyticalTableCellInstance,
AnalyticalTableColumnDefinition
} from "@ui5/webcomponents-react";
const { useF2CellEdit } = AnalyticalTableHooks;
function TitleCell(props: AnalyticalTableCellInstance) {
const ref = useF2CellEdit.useCallbackRef(props);
return (
<Link href="#review" ref={ref}>
{props.value}
</Link>
);
}
const columns: AnalyticalTableColumnDefinition[] = [
{
id: "title",
Header: "Title",
accessor: "title",
Cell: TitleCell,
interactiveElementName: "Link"
}
];
export default function App() {
return (
<ThemeProvider>
<AnalyticalTable
columns={columns}
data={[{ title: "Annual Review" }]}
tableHooks={[useF2CellEdit]}
/>
</ThemeProvider>
);
}
- Render the table above without a cellLabel callback.
- Inspect the first body cell with role="gridcell".
- Observe aria-label="Includes Link undefined".
Expected Behaviour
Missing optional labels should not become the literal string undefined.
Screenshots or Videos
No response
UI5 Web Components for React Version
2.28.2
UI5 Web Components Version
2.28.1
Browser
Edge
Operating System
No response
Additional Context
No response
Relevant log output
Organization
SF
Declaration
- I’m not disclosing any internal or sensitive information.
- 主要語言
- TypeScript
- 星號
- 544
- 分支
- 113
- 平均合併
- 1 天 16 小時
- 30 天內合併 PR
- 34
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
UI5/webcomponents-react 的其他 Issue
-
難度 2/5 1-3 小時 新手友好度 82/100
UI5/webcomponents-react#9181 ·
維護者通常 1 天內回覆
-
[ObjectPage]: Scrollbar jumps to the focused section once go out and come back to the browser tab可能已有人在做 @Lukas742 於 11 天前認領。 未關閉SAP SF
難度 3/5 1-2 天 新手友好度 57/100
UI5/webcomponents-react#9161 · 1 則留言 ·
維護者通常 1 天內回覆
-
[ObjectPage]: page will twitch when the header height reaching the threshold of expansion and collapse可能已有人在做 @Lukas742 於 8 天前認領。 未關閉
難度 3/5 半天 新手友好度 55/100
UI5/webcomponents-react#9128 · 9 則留言 ·
維護者通常 1 天內回覆
-
難度 5/5 一週以上 新手友好度 20/100
UI5/webcomponents-react#8529 ·
維護者通常 1 天內回覆
-
Design Pending SAP SF
難度 3/5 1-2 天 新手友好度 45/100
UI5/webcomponents-react#8158 · 1 則留言 · 1 個 reaction ·
維護者通常 1 天內回覆
查看 UI5/webcomponents-react 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆
-
platform:windows provider:antigravity-cli providers setup triaged wontfix
難度 2/5 1-3 小時 新手友好度 78/100
can1357/oh-my-pi#21349 · 1 則留言 ·
維護者通常 1 天內回覆
-
enhancement
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 2 天內回覆
-
agentic-workflows
難度 2/5 1-3 小時 新手友好度 72/100
ohcnetwork/care_fe#17474 ·
維護者通常 1 天內回覆
-
enhancement good first issue
難度 2/5 1-3 小時 新手友好度 90/100