Skip to content

Commit dd234ad

Browse files
committed
fix: change cursor style from 'grab' to 'pointer' for better user experience
1 parent 8a7d484 commit dd234ad

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

src/renderer/src/components/layout/tabs/TabsArea.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@
126126

127127
/* 拖拽相关样式 - VSCode 风格 */
128128
.tab-label-content {
129-
cursor: grab;
129+
cursor: pointer;
130130
user-select: none;
131131
}
132132

src/renderer/src/components/layout/tabs/TabsArea.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ const SortableTabLabel: React.FC<SortableTabLabelProps> = ({
103103
// 不应用 transform,让标签保持在原位
104104
transform: isDragging ? 'none' : undefined,
105105
opacity: isDragging ? 0 : 1, // 拖拽时完全透明,因为会显示在 DragOverlay 中
106-
cursor: 'grab',
106+
cursor: 'pointer',
107107
position: 'relative'
108108
}
109109

@@ -681,12 +681,13 @@ export default function TabsArea() {
681681
activeKey={activeTabId || undefined}
682682
onChange={handleTabChange}
683683
onEdit={(targetKey, action) => {
684-
if (action === 'remove' && typeof targetKey === 'string') {
684+
if (action === 'add') {
685+
handleCreateChat()
686+
} else if (action === 'remove' && typeof targetKey === 'string') {
685687
handleTabClose(targetKey)
686688
}
687689
}}
688690
items={tabItems}
689-
hideAdd
690691
size="small"
691692
style={
692693
{

0 commit comments

Comments
 (0)