Comparing develop...fix/moeext/tag-search · ModelEngine-Group/nexent · GitHub
Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: ModelEngine-Group/nexent
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: develop
Choose a base ref
...
head repository: ModelEngine-Group/nexent
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: fix/moeext/tag-search
Choose a head ref
Checking mergeability… Don’t worry, you can still create the pull request.
  • 4 commits
  • 11 files changed
  • 1 contributor

Commits on Oct 21, 2026

  1. fix(frontend): 修复标签管理搜索无法按译名和显示值匹配

    标签管理弹窗的搜索此前只比对后端原始字段 definition_name 与 definition_key,而表格名称列渲染的是 i18n 译名(keywords -> 关键词),标签值(显示值 / 规范化值)完全不参与匹配,因此输入“关键”或某个值的文本都搜不到。
    
    - 在 lib/systemTagLabels.ts 抽出共用的文本匹配逻辑,新增 getMatchingTagDefinitionIds 返回命中定义 id
    - TagDefinitionManagementPanel 改用该 helper,空白输入仍不过滤
    - 搜不到结果时区分“没有匹配的标签定义”与“暂无标签”
    - 搜索框提示补充可按显示值搜索
    - 新增 tagDefinitionSearch 组件回归测试,覆盖译名、标识、显示值、规范化值、禁用值、空白输入与空态文案
    
    验证:tagDefinitionSearch / tagLibraryManagement / knowledgeCatalog 共 26 项组件测试通过(旧过滤逻辑下该 spec 有 3 项失败,确认能捕捉缺陷);改动文件 eslint、prettier 与版权头校验通过。
    MoeexT committed Oct 21, 2026
    Configuration menu
    Copy the full SHA
    1f2b6cd View commit details
    Browse the repository at this point in the history
  2. fix(frontend): 标签管理搜索按“命中来源”区分高亮与展开

    上一提交让搜索能命中译名与标签值,但命中后只是过滤出行,既不指出命中位置,也无法呈现“值命中”这种行内看不到的结果。若一律展开,搜 key 反而会把大量无关 value 摊开。
    
    改为让命中来源决定呈现方式:
    
    - 新增 components/common/HighlightedText,把命中片段包进 <mark>;名称列、标识列与内层显示值列统一复用
    - getMatchingTagDefinitionIds 改为 getTagSearchMatches,返回每个定义的命中来源(definitionMatched 与 matchedValueIds);值匹配仍覆盖全部值(含禁用值),维持既有语义
    - 名称 / 译名 / 标识命中:不展开,只在行内高亮命中片段
    - 仅值命中:自动展开该行,内层只列命中的值并提示“仅显示匹配搜索的标签值”,搜 key 不会摊开整列 value
    - 自动展开的行由 autoExpandedKeysRef 单独追踪,只在集合变化时增删,不会重开用户手动收起的行
    - 清空搜索后自动展开与内层值过滤一并复原
    - 新增 tagManagement.hint.matchedValues 中英文案
    - tagDefinitionSearch 由 7 项扩到 12 项,覆盖自动展开、内层过滤、高亮片段、清空复原与手动收起
    
    验证:tagDefinitionSearch / tagLibraryManagement / resourceTagManagement / resourceTagFilter 共 26 项组件测试通过;改动文件 eslint、prettier 与版权头校验通过。
    MoeexT committed Oct 21, 2026
    Configuration menu
    Copy the full SHA
    16d00c5 View commit details
    Browse the repository at this point in the history
  3. fix(frontend): 搜索时固定标签管理弹窗高度

    表格滚动体只有 max-height(来自 scroll.y),行数一变高度就跟着变:搜索把行过滤掉、空态文案切换,都会让弹窗在每次输入时上下跳,而弹窗是 centered 的,跳动尤其明显。
    
    - TagDefinitionManagementPanel 新增可选 stableTableHeight,为真时把表格滚动体钉在 scroll.y 已经要求的 500px(新增 TagDefinitionManagementPanel.module.css)
    - 只有 TagDefinitionManagementModal 传这个开关;资源管理页内嵌同一个面板,保持随行数自然增长
    - tagDefinitionSearch 增到 14 项,覆盖开关两侧行为
    
    验证:tagDefinitionSearch 14 项组件测试通过;改动文件 eslint、prettier 与版权头校验通过。jsdom 不做布局,实际高度表现待真机确认。
    MoeexT committed Oct 21, 2026
    Configuration menu
    Copy the full SHA
    17de158 View commit details
    Browse the repository at this point in the history
  4. test(e2e): 记录标签管理搜索缺陷并补充搜索契约

    补充 TAG-DEFINITION-SEARCH-20261021 缺陷变更记录与轻量设计说明:说明搜索按本地化译名、原始标识与值显示文本匹配,只有值命中才自动展开并只列出命中的值,弹窗高度在搜索期间保持稳定。
    
    Feature RESOURCE-TAG-MANAGEMENT 新增 RULE-006 记录该搜索语义;无正式 Case 引用该 Feature,行为由前端组件 UT 覆盖,故不新增 D1-D5。
    
    验证:validate_test_assets.py --phase implementation --generate --require-ut-change TAG-DEFINITION-SEARCH-20261021 与只读全量校验均通过;tagDefinitionSearch/tagLibraryManagement/resourceTagManagement/resourceTagFilter 共 28 项组件测试通过。
    MoeexT committed Oct 21, 2026
    Configuration menu
    Copy the full SHA
    a5b6f5a View commit details
    Browse the repository at this point in the history
Loading