mirror of
https://github.com/Ed1s0nZ/CyberStrikeAI.git
synced 2026-06-06 06:13:58 +02:00
Add files via upload
This commit is contained in:
+35
-14
@@ -1217,13 +1217,6 @@ header {
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.hitl-sidebar-header-actions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.hitl-sidebar-body {
|
||||
overflow: hidden;
|
||||
max-height: 500px;
|
||||
@@ -1238,10 +1231,6 @@ header {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.hitl-sidebar-collapsed .hitl-apply-btn {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.hitl-sidebar-heading {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -1359,6 +1348,14 @@ header {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.hitl-config-actions {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
margin-top: 14px;
|
||||
padding-top: 12px;
|
||||
border-top: 1px solid rgba(15, 23, 42, 0.06);
|
||||
}
|
||||
|
||||
.hitl-config-label {
|
||||
display: block;
|
||||
font-size: 12px;
|
||||
@@ -2532,8 +2529,8 @@ header {
|
||||
.conversation-reasoning-card-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
gap: 0;
|
||||
justify-content: space-between;
|
||||
gap: 8px;
|
||||
width: 100%;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
@@ -2548,10 +2545,34 @@ header {
|
||||
border-radius: 0;
|
||||
}
|
||||
|
||||
.conversation-reasoning-card-header:hover .conversation-reasoning-title {
|
||||
.conversation-reasoning-card-header:hover .conversation-reasoning-title,
|
||||
.hitl-sidebar-card-header:hover .hitl-sidebar-title {
|
||||
color: var(--accent-color);
|
||||
}
|
||||
|
||||
.sidebar-card-chevron {
|
||||
flex-shrink: 0;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: var(--text-secondary);
|
||||
transition: transform 0.2s ease, color 0.2s ease;
|
||||
}
|
||||
|
||||
.sidebar-card-chevron svg {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.conversation-reasoning-card-header:hover .sidebar-card-chevron,
|
||||
.hitl-sidebar-card-header:hover .sidebar-card-chevron {
|
||||
color: var(--accent-color);
|
||||
}
|
||||
|
||||
.conversation-reasoning-card:not(.conversation-reasoning-collapsed) .conversation-reasoning-chevron,
|
||||
.hitl-sidebar-card:not(.hitl-sidebar-collapsed) .hitl-sidebar-chevron {
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
|
||||
.conversation-reasoning-heading {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
@@ -423,10 +423,18 @@ if (typeof window !== 'undefined') {
|
||||
window.updateHitlStatusUI = updateHitlStatusUI;
|
||||
}
|
||||
|
||||
function syncHitlSidebarAriaExpanded() {
|
||||
var card = document.getElementById('hitl-sidebar-card');
|
||||
var toggle = document.getElementById('hitl-sidebar-toggle');
|
||||
if (!card || !toggle) return;
|
||||
toggle.setAttribute('aria-expanded', card.classList.contains('hitl-sidebar-collapsed') ? 'false' : 'true');
|
||||
}
|
||||
|
||||
function toggleHitlSidebarCard() {
|
||||
var card = document.getElementById('hitl-sidebar-card');
|
||||
if (!card) return;
|
||||
card.classList.toggle('hitl-sidebar-collapsed');
|
||||
syncHitlSidebarAriaExpanded();
|
||||
try {
|
||||
localStorage.setItem('hitl-sidebar-collapsed', card.classList.contains('hitl-sidebar-collapsed') ? '1' : '0');
|
||||
} catch (e) {}
|
||||
@@ -438,6 +446,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
if (card && localStorage.getItem('hitl-sidebar-collapsed') === '0') {
|
||||
card.classList.remove('hitl-sidebar-collapsed');
|
||||
}
|
||||
syncHitlSidebarAriaExpanded();
|
||||
});
|
||||
|
||||
function getAgentModeLabelForValue(mode) {
|
||||
|
||||
@@ -831,6 +831,11 @@
|
||||
<span id="chat-reasoning-summary" class="conversation-reasoning-summary"></span>
|
||||
</div>
|
||||
</div>
|
||||
<span class="sidebar-card-chevron conversation-reasoning-chevron" aria-hidden="true">
|
||||
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M9 18l6-6-6-6" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
</span>
|
||||
</button>
|
||||
<div id="conversation-reasoning-body" class="conversation-reasoning-body" role="region">
|
||||
<p class="chat-reasoning-panel-hint" data-i18n="chat.reasoningPanelHint">仅 Eino 请求生效,与系统设置中的默认值合并。</p>
|
||||
@@ -859,7 +864,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="hitl-sidebar-card hitl-sidebar-collapsed" id="hitl-sidebar-card">
|
||||
<div class="hitl-sidebar-card-header" onclick="toggleHitlSidebarCard()">
|
||||
<div class="hitl-sidebar-card-header" id="hitl-sidebar-toggle" role="button" tabindex="0" aria-expanded="false" aria-controls="hitl-sidebar-body" onclick="toggleHitlSidebarCard()" onkeydown="if (event.key === 'Enter' || event.key === ' ') { event.preventDefault(); toggleHitlSidebarCard(); }">
|
||||
<div class="hitl-sidebar-heading">
|
||||
<span class="hitl-sidebar-icon" aria-hidden="true">
|
||||
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
@@ -872,11 +877,11 @@
|
||||
<span class="hitl-sidebar-subtitle" data-i18n="chat.hitlCardSubtitle">审批与白名单</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="hitl-sidebar-header-actions">
|
||||
<button type="button" class="hitl-apply-btn" id="hitl-apply-btn" onclick="event.stopPropagation(); window.applyHitlSidebarConfig && window.applyHitlSidebarConfig()">
|
||||
<span data-i18n="chat.hitlApply">应用</span>
|
||||
</button>
|
||||
</div>
|
||||
<span class="sidebar-card-chevron hitl-sidebar-chevron" aria-hidden="true">
|
||||
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M9 18l6-6-6-6" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
</svg>
|
||||
</span>
|
||||
</div>
|
||||
<div class="hitl-sidebar-body" id="hitl-sidebar-body">
|
||||
<div id="hitl-apply-feedback" class="hitl-apply-feedback" role="status" aria-live="polite"></div>
|
||||
@@ -894,6 +899,11 @@
|
||||
<textarea id="hitl-sensitive-tools" class="hitl-config-textarea" rows="3" spellcheck="false" autocomplete="off" data-i18n="chat.hitlWhitelistPlaceholder" data-i18n-attr="placeholder" placeholder=""></textarea>
|
||||
<p class="hitl-config-hint" data-i18n="chat.hitlWhitelistHint">每行一个或逗号分隔;与 config 中全局白名单合并展示。</p>
|
||||
</div>
|
||||
<div class="hitl-config-actions">
|
||||
<button type="button" class="hitl-apply-btn" id="hitl-apply-btn" onclick="window.applyHitlSidebarConfig && window.applyHitlSidebarConfig()">
|
||||
<span data-i18n="chat.hitlApply">应用</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user