Refine codex app controls and message navigation

This commit is contained in:
shiyue
2026-06-13 23:55:11 +08:00
parent 4a1c988990
commit 382c5accb7
7 changed files with 876 additions and 26 deletions

View File

@@ -887,10 +887,19 @@ body.session-loading-active {
padding: 0 16px;
border-bottom: 1px solid var(--border-color);
background: var(--bg-secondary);
gap: 10px;
gap: 8px;
flex-shrink: 0;
position: relative;
}
.chat-controls {
position: relative;
display: flex;
align-items: center;
gap: 8px;
flex-wrap: wrap;
max-width: 800px;
margin: 0 auto 8px;
}
.menu-btn {
display: none;
background: none;
@@ -919,7 +928,7 @@ body.session-loading-active {
.chat-title:hover { background: var(--bg-tertiary); }
.chat-session-id-btn {
appearance: none;
max-width: 112px;
max-width: 120px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
@@ -937,6 +946,19 @@ body.session-loading-active {
background: rgba(91, 126, 161, 0.16);
border-color: rgba(91, 126, 161, 0.34);
}
.chat-session-id-btn:disabled,
.chat-agent-btn:disabled,
.chat-cwd:disabled,
.mode-select:disabled,
.user-outline-btn:disabled {
opacity: 0.5;
cursor: default;
}
.chat-agent-picker {
position: relative;
display: inline-flex;
flex-shrink: 0;
}
.chat-agent-btn {
appearance: none;
font-size: 11px;
@@ -964,8 +986,8 @@ body.session-loading-active {
}
.chat-agent-menu {
position: absolute;
top: calc(100% - 6px);
right: 16px;
top: calc(100% + 6px);
left: 0;
min-width: 148px;
padding: 8px;
border: 1px solid var(--border-color);
@@ -1027,6 +1049,78 @@ body.session-loading-active {
display: none !important;
}
.cost-display:empty { display: none; }
.user-outline-btn {
appearance: none;
border: 1px solid rgba(91, 126, 161, 0.22);
border-radius: 999px;
background: rgba(91, 126, 161, 0.08);
color: var(--info);
padding: 4px 10px;
font: inherit;
font-size: 11px;
font-weight: 800;
cursor: pointer;
flex-shrink: 0;
}
.user-outline-anchor {
position: relative;
display: inline-flex;
flex-shrink: 0;
}
.user-outline-btn:hover {
background: rgba(91, 126, 161, 0.16);
border-color: rgba(91, 126, 161, 0.34);
}
.user-outline-panel {
position: absolute;
right: 0;
bottom: calc(100% + 8px);
width: min(360px, calc(100vw - 24px));
max-height: min(48vh, 360px);
padding: 8px;
border: 1px solid var(--border-color);
border-radius: 14px;
background: rgba(255, 252, 248, 0.98);
box-shadow: 0 12px 28px rgba(45, 31, 20, 0.08);
overflow-y: auto;
z-index: 70;
}
.user-outline-empty {
padding: 8px 10px;
color: var(--text-muted);
font-size: 12px;
}
.user-outline-item {
width: 100%;
display: grid;
grid-template-columns: 24px minmax(0, 1fr);
align-items: start;
gap: 8px;
padding: 8px 10px;
border: none;
border-radius: 10px;
background: transparent;
color: var(--text-primary);
text-align: left;
cursor: pointer;
}
.user-outline-item:hover {
background: var(--accent-light);
}
.user-outline-index {
color: var(--text-muted);
font-size: 11px;
font-weight: 800;
line-height: 1.6;
}
.user-outline-text {
min-width: 0;
font-size: 13px;
line-height: 1.45;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
/* Mode selector */
.mode-select {
@@ -1203,6 +1297,7 @@ body.session-loading-active {
}
.msg-bubble {
position: relative;
padding: 12px 16px;
border-radius: 16px;
line-height: 1.65;
@@ -1334,6 +1429,32 @@ body.session-loading-active {
background: var(--bg-bubble-user);
color: #fff;
border-bottom-right-radius: 4px;
padding-right: 42px;
}
.msg-copy-btn {
position: absolute;
top: 8px;
right: 8px;
width: 26px;
height: 26px;
display: inline-flex;
align-items: center;
justify-content: center;
border: 1px solid rgba(255, 255, 255, 0.16);
border-radius: 8px;
background: rgba(255, 255, 255, 0.12);
color: rgba(255, 255, 255, 0.86);
cursor: pointer;
opacity: 0;
transition: opacity 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.msg.user:hover .msg-copy-btn,
.msg.user:focus-within .msg-copy-btn {
opacity: 1;
}
.msg-copy-btn:hover {
background: rgba(255, 255, 255, 0.2);
border-color: rgba(255, 255, 255, 0.28);
}
.msg.user.cross-conversation .msg-avatar {
background: var(--info);
@@ -1625,6 +1746,11 @@ body.session-loading-active {
.tool-call.codex-file-change {
border-color: rgba(93, 138, 84, 0.24);
}
.tool-call.codex-collab-agent-tool-call {
border-color: rgba(91, 126, 161, 0.28);
background:
linear-gradient(180deg, rgba(255, 255, 255, 0.66), rgba(91, 126, 161, 0.04));
}
.tool-call summary {
padding: 8px 12px;
cursor: pointer;
@@ -1729,6 +1855,14 @@ body.session-loading-active {
white-space: normal;
word-break: normal;
}
.tool-call-content.collab-agent-content {
font-family: inherit;
white-space: normal;
word-break: normal;
background:
linear-gradient(180deg, rgba(252, 253, 255, 0.96), rgba(242, 247, 252, 0.98));
color: var(--text-primary);
}
.tool-call-content.todo-list-content .todo-list-container {
margin: 0;
}
@@ -2354,13 +2488,17 @@ body.session-loading-active {
.option-picker { left: 10px; right: 10px; transform: none; min-width: auto; bottom: 72px; }
.chat-header {
padding: 0 10px;
gap: 6px;
gap: 5px;
}
.chat-title {
font-size: 13px;
}
.chat-controls {
gap: 6px;
margin-bottom: 6px;
}
.chat-session-id-btn {
max-width: 82px;
max-width: 92px;
padding-left: 7px;
padding-right: 7px;
font-size: 10px;
@@ -2369,7 +2507,7 @@ body.session-loading-active {
grid-template-columns: 1fr;
}
.chat-agent-menu {
right: 10px;
left: 0;
min-width: 138px;
}
.chat-runtime-state {
@@ -2377,13 +2515,24 @@ body.session-loading-active {
font-size: 10px;
}
.chat-cwd {
max-width: 92px;
max-width: 98px;
flex-shrink: 1;
}
.mode-select {
padding: 4px 20px 4px 8px;
font-size: 11px;
}
.user-outline-btn {
padding: 4px 8px;
font-size: 10px;
}
.user-outline-text {
font-size: 12px;
}
.user-outline-panel {
right: 0;
width: min(320px, calc(100vw - 20px));
}
}
@media (max-width: 480px) {
@@ -2406,10 +2555,55 @@ body.session-loading-active {
.new-chat-arrow { min-height: 44px; }
.new-chat-arrow { width: 48px; }
.chat-cwd {
max-width: 76px;
padding-left: 6px;
padding-right: 6px;
}
.chat-controls {
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
align-items: stretch;
}
.chat-cwd,
.mode-select,
.user-outline-btn,
.chat-runtime-state {
width: 100%;
max-width: none;
justify-content: center;
}
.chat-header {
gap: 4px;
}
.chat-title {
min-width: 0;
}
.chat-session-id-btn {
max-width: 72px;
padding-left: 6px;
padding-right: 6px;
}
.chat-agent-btn {
max-width: 96px;
padding-left: 8px;
padding-right: 20px;
}
.chat-agent-menu {
left: 0;
right: auto;
}
.user-outline-panel {
left: 0;
right: 0;
width: auto;
max-height: min(44vh, 300px);
bottom: calc(100% + 6px);
}
.msg-copy-btn {
opacity: 1;
width: 24px;
height: 24px;
}
}
/* === Utility === */
@@ -3360,6 +3554,150 @@ html[data-theme='coolvibe'] .settings-back:hover {
transition: background 0.2s;
}
.collab-agent-stack {
display: flex;
flex-direction: column;
gap: 10px;
}
.collab-agent-header {
display: flex;
align-items: flex-start;
justify-content: space-between;
gap: 10px;
}
.collab-agent-title-wrap {
min-width: 0;
display: flex;
flex-direction: column;
gap: 2px;
}
.collab-agent-kicker {
font-size: 10px;
font-weight: 800;
letter-spacing: 0.08em;
text-transform: uppercase;
color: var(--info);
}
.collab-agent-title {
font-size: 14px;
font-weight: 700;
line-height: 1.35;
color: var(--text-primary);
}
.collab-agent-meta {
font-size: 11px;
color: var(--text-muted);
}
.collab-agent-overall-status,
.collab-agent-item-status {
display: inline-flex;
align-items: center;
justify-content: center;
min-height: 24px;
padding: 0 9px;
border-radius: 999px;
font-size: 10px;
font-weight: 800;
line-height: 1;
white-space: nowrap;
}
.collab-agent-overall-status.running,
.collab-agent-item-status.running {
background: rgba(232, 190, 92, 0.16);
color: #9a6f14;
}
.collab-agent-overall-status.done,
.collab-agent-item-status.done {
background: rgba(93, 138, 84, 0.14);
color: var(--success);
}
.collab-agent-overall-status.error,
.collab-agent-item-status.error {
background: rgba(192, 85, 58, 0.14);
color: var(--danger);
}
.collab-agent-overall-status.pending,
.collab-agent-item-status.pending {
background: rgba(91, 126, 161, 0.12);
color: var(--info);
}
.collab-agent-prompt {
padding: 10px 12px;
border: 1px solid rgba(91, 126, 161, 0.16);
border-radius: 10px;
background: rgba(255, 255, 255, 0.72);
color: var(--text-secondary);
font-size: 12px;
line-height: 1.6;
}
.collab-agent-list {
display: flex;
flex-direction: column;
gap: 8px;
}
.collab-agent-item {
display: flex;
flex-direction: column;
gap: 6px;
padding: 10px 12px;
border: 1px solid rgba(91, 126, 161, 0.14);
border-radius: 10px;
background: rgba(255, 255, 255, 0.74);
}
.collab-agent-item-row {
display: flex;
align-items: center;
justify-content: space-between;
gap: 8px;
}
.collab-agent-item-label {
min-width: 0;
flex: 1;
font-size: 13px;
font-weight: 700;
color: var(--text-primary);
line-height: 1.35;
}
.collab-agent-item-role {
font-size: 11px;
color: var(--info);
font-weight: 700;
}
.collab-agent-item-detail {
font-size: 12px;
color: var(--text-secondary);
line-height: 1.55;
}
.collab-agent-item-footer {
align-self: flex-start;
font-size: 11px;
color: var(--text-muted);
cursor: pointer;
}
.collab-agent-item-footer:hover {
color: var(--info);
}
.collab-agent-threads {
display: flex;
flex-wrap: wrap;
gap: 6px;
}
.collab-agent-thread-chip {
appearance: none;
border: 1px solid rgba(91, 126, 161, 0.18);
border-radius: 999px;
background: rgba(255, 255, 255, 0.8);
color: var(--info);
padding: 4px 10px;
font: inherit;
font-size: 11px;
font-weight: 700;
cursor: pointer;
}
.collab-agent-thread-chip:hover {
background: rgba(91, 126, 161, 0.1);
}
/* Todo List */
.todo-list-container {
margin: 12px 0;
@@ -3400,6 +3738,13 @@ html[data-theme='coolvibe'] .settings-back:hover {
color: var(--text-muted);
opacity: 0.6;
}
@media (max-width: 640px) {
.collab-agent-header,
.collab-agent-item-row {
flex-direction: column;
align-items: flex-start;
}
}
.import-item-btn:hover { background: var(--accent-hover); }
/* === File Browser === */