dify/web/app/components/workflow/skill/hooks
yyh 8486c675c8
refactor(skill): extract hooks from skill-doc-editor for better separation
Extract business logic into dedicated hooks to reduce component complexity:
- useFileTypeInfo: file type detection (markdown, code, image, video, etc.)
- useSkillFileData: data fetching with conditional API calls
- useSkillFileSave: save logic with Ctrl+S keyboard shortcut

Also fix Vercel best practice: use ternary instead of && for conditional rendering.
2026-01-19 23:25:48 +08:00
..
use-create-operations.ts refactor(skill): split file operations hook and extract TreeNodeIcon component 2026-01-19 19:13:09 +08:00
use-delayed-click.ts fix(skill): address code review issues for tab management 2026-01-16 11:20:49 +08:00
use-file-drop.ts refactor(skill): unify root/blank constants and eliminate magic strings 2026-01-19 23:07:49 +08:00
use-file-operations.ts refactor(skill): unify root/blank constants and eliminate magic strings 2026-01-19 23:07:49 +08:00
use-file-type-info.ts refactor(skill): extract hooks from skill-doc-editor for better separation 2026-01-19 23:25:48 +08:00
use-folder-file-drop.ts refactor(skill): split file operations hook and extract TreeNodeIcon component 2026-01-19 19:13:09 +08:00
use-inline-create-node.ts feat: auto pin created editable files 2026-01-19 13:51:08 +08:00
use-modify-operations.ts refactor(skill): split file operations hook and extract TreeNodeIcon component 2026-01-19 19:13:09 +08:00
use-root-file-drop.ts refactor(skill): split file operations hook and extract TreeNodeIcon component 2026-01-19 19:13:09 +08:00
use-skill-asset-tree.ts refactor(skill): centralize asset tree data fetching with custom hooks 2026-01-15 19:45:33 +08:00
use-skill-file-data.ts refactor(skill): extract hooks from skill-doc-editor for better separation 2026-01-19 23:25:48 +08:00
use-skill-file-save.ts refactor(skill): extract hooks from skill-doc-editor for better separation 2026-01-19 23:25:48 +08:00
use-sync-tree-with-active-tab.ts feat: sync tree selection with active tab 2026-01-19 14:05:46 +08:00
use-tree-node-handlers.ts refactor(skill): unify tree selection with VSCode-style single state 2026-01-19 22:36:04 +08:00