Skip to content

Fix file browser root label for resource types#386

Merged
yama merged 2 commits intodevfrom
codex/fix-folder-tree-display-issue
Feb 4, 2026
Merged

Fix file browser root label for resource types#386
yama merged 2 commits intodevfrom
codex/fix-folder-tree-display-issue

Conversation

@yama
Copy link
Copy Markdown
Member

@yama yama commented Jan 22, 2026

Motivation

  • MCPUK の File Browser で左上のリソース種別を切り替えてもフォルダーツリーの最上位ラベルが常に Images のまま表示されていたため、選択中のリソース種別に応じて正しいラベルを表示するようにするための修正です。

Description

  • manager/media/browser/mcpuk/frmfolders.htmlRender 処理でルートラベルをハードコードの 'images' から getResourceTypeLabel(oConnector.ResourceType) に置き換え、getResourceTypeLabel ヘルパーを追加して files/media/images に対応する表示名を返すようにしました。

Testing

  • 自動化されたテストは実行しておらず、該当変更に対する自動テストはありません。

Codex Task

Copilot AI review requested due to automatic review settings January 22, 2026 10:22
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a bug in the MCPUK File Browser where the root folder label in the tree view always displayed "Images" regardless of which resource type was selected from the dropdown menu. The fix adds a helper function to dynamically determine the correct label based on the active resource type.

Changes:

  • Added getResourceTypeLabel function to map resource type values ('files', 'media', 'images') to their display labels
  • Updated the root node creation to use the dynamic label instead of the hardcoded 'images' value

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@yama yama changed the base branch from main to dev February 4, 2026 11:48
@yama yama merged commit edf6677 into dev Feb 4, 2026
1 check passed
@yama yama deleted the codex/fix-folder-tree-display-issue branch April 29, 2026 08:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants