feat(vscode-ide-companion): 增加代码编辑功能和文件操作支持

- 实现了与 Claude Code 类似的代码编辑功能
- 添加了文件打开、保存等操作的支持
- 优化了消息显示,增加了代码高亮和文件路径点击功能
- 改进了用户界面,增加了编辑模式切换和思考模式功能
This commit is contained in:
yiliang114
2025-11-20 01:04:11 +08:00
parent e81255e589
commit 6286b8b6e8
13 changed files with 1096 additions and 188 deletions

View File

@@ -6,14 +6,15 @@
/**
* PlanDisplay.css - Styles for the task plan component
* Simple, clean timeline-style design
*/
.plan-display {
background-color: rgba(100, 150, 255, 0.05);
border: 1px solid rgba(100, 150, 255, 0.3);
border-radius: 8px;
background: var(--app-secondary-background);
border: 1px solid var(--app-transparent-inner-border);
border-radius: var(--corner-radius-medium);
padding: 16px;
margin: 8px 0;
margin: 12px 0;
animation: fadeIn 0.3s ease-in;
}
@@ -21,92 +22,111 @@
display: flex;
align-items: center;
gap: 8px;
margin-bottom: 12px;
padding-bottom: 8px;
border-bottom: 1px solid rgba(255, 255, 255, 0.1);
margin-bottom: 16px;
color: var(--app-primary-foreground);
}
.plan-icon {
font-size: 18px;
.plan-header-icon {
flex-shrink: 0;
opacity: 0.8;
}
.plan-title {
font-size: 14px;
font-weight: 600;
color: rgba(150, 180, 255, 1);
color: var(--app-primary-foreground);
}
.plan-entries {
display: flex;
flex-direction: column;
gap: 8px;
gap: 0;
position: relative;
}
.plan-entry {
display: flex;
align-items: flex-start;
gap: 12px;
padding: 8px 0;
position: relative;
}
/* Vertical line on the left */
.plan-entry-line {
position: absolute;
left: 7px;
top: 24px;
bottom: -8px;
width: 2px;
background: var(--app-qwen-clay-button-orange);
opacity: 0.3;
}
.plan-entry:last-child .plan-entry-line {
display: none;
}
/* Icon container */
.plan-entry-icon {
flex-shrink: 0;
display: flex;
align-items: center;
justify-content: center;
width: 16px;
height: 16px;
position: relative;
z-index: 1;
}
.plan-icon {
display: block;
}
/* Content */
.plan-entry-content {
flex: 1;
display: flex;
align-items: flex-start;
gap: 8px;
padding: 8px;
background-color: var(--vscode-input-background);
border-radius: 4px;
border-left: 3px solid transparent;
transition: all 0.2s ease;
min-height: 24px;
padding-top: 1px;
}
.plan-entry[data-priority="high"] {
border-left-color: #ff6b6b;
.plan-entry-number {
font-size: 13px;
font-weight: 500;
color: var(--app-secondary-foreground);
flex-shrink: 0;
min-width: 24px;
}
.plan-entry[data-priority="medium"] {
border-left-color: #ffd93d;
.plan-entry-text {
flex: 1;
font-size: 13px;
line-height: 1.6;
color: var(--app-primary-foreground);
}
.plan-entry[data-priority="low"] {
border-left-color: #6bcf7f;
}
.plan-entry.completed {
/* Status-specific styles */
.plan-entry.completed .plan-entry-text {
opacity: 0.6;
}
.plan-entry.completed .plan-entry-content {
text-decoration: line-through;
}
.plan-entry.in_progress {
background-color: rgba(100, 150, 255, 0.1);
border-left-width: 4px;
.plan-entry.in_progress .plan-entry-text {
font-weight: 500;
}
.plan-entry-header {
display: flex;
align-items: center;
gap: 6px;
flex-shrink: 0;
}
.plan-entry-status,
.plan-entry-priority {
font-size: 14px;
}
.plan-entry-index {
font-size: 12px;
.plan-entry.in_progress .plan-entry-number {
color: var(--app-qwen-orange);
font-weight: 600;
color: var(--vscode-descriptionForeground);
min-width: 20px;
}
.plan-entry-content {
flex: 1;
font-size: 13px;
line-height: 1.5;
color: var(--vscode-foreground);
}
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(-10px);
transform: translateY(-8px);
}
to {
opacity: 1;