Skip to content

[P2] ListView 杂项属性实现(description/allowPrinting/rowHeight 补全) #749

@hotlong

Description

@hotlong

背景

Parent Issue: #736

以下属性已有类型但缺少 UI 渲染:

  1. description:视图描述文本渲染
  2. allowPrinting:打印按钮
  3. rowHeight enum 补全:shortextra_tall 未映射
  4. sort legacy string format:"field desc" 格式未解析
  5. filterableFields:FilterBuilder 未限制字段白名单

目标

  • description 在 toolbar 下方渲染描述文本(受 appearance.showDescription 控制)
  • allowPrinting 在 toolbar 渲染打印按钮
  • rowHeight 补全 short/extra_tall 映射
  • sort 支持 legacy string 解析
  • filterableFields 限制 FilterBuilder 字段列表

改动范围

  • packages/plugin-list/src/ListView.tsx — description UI + print button + sort normalize + filterableFields
  • packages/react/src/spec-bridge/bridges/list-view.ts L106-115 — rowHeight mapDensity 补全

验收标准

  • schema.description + appearance.showDescription: true 渲染描述文本
  • allowPrinting: true 渲染打印按钮,调用 window.print()
  • rowHeight: 'short''extra_tall' 正确映射
  • sort: 'name desc' legacy string 格式正确解析
  • filterableFields 限制 FilterBuilder 字段选项
  • 所有新增代码有对应单元测试
  • pnpm test 全部通过

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions