mirror of
https://github.com/zh-xx/rosypilot.git
synced 2026-07-22 06:06:43 +00:00
616 lines
13 KiB
CSS
616 lines
13 KiB
CSS
/************************************************************/
|
|
/* Utilities */
|
|
/************************************************************/
|
|
|
|
.rosypilot-clipboard-helper {
|
|
position: fixed;
|
|
opacity: 0;
|
|
pointer-events: none;
|
|
}
|
|
|
|
/************************************************************/
|
|
/* Inline completions */
|
|
/************************************************************/
|
|
|
|
/* Show inline completions text with less opacity */
|
|
.rosypilot-completions {
|
|
opacity: 0.5;
|
|
}
|
|
|
|
/* Keyboard shortcut hint shown after ghost text */
|
|
.rosypilot-completions-hint {
|
|
display: inline-block;
|
|
margin-left: 4px;
|
|
font-size: 0.75em;
|
|
opacity: 0.75;
|
|
vertical-align: middle;
|
|
}
|
|
|
|
.rosypilot-completions-hint-divider {
|
|
margin-right: 6px;
|
|
opacity: 0.4;
|
|
}
|
|
|
|
.rosypilot-completions-hint-accept {
|
|
color: var(--color-green);
|
|
}
|
|
|
|
.rosypilot-completions-hint-reject {
|
|
color: var(--color-red);
|
|
}
|
|
|
|
/************************************************************/
|
|
/* Usage progress bar */
|
|
/************************************************************/
|
|
|
|
.rosypilot-usage-progress-wrap {
|
|
margin: 4px var(--size-4-3) 12px;
|
|
}
|
|
|
|
.rosypilot-usage-progress-bar {
|
|
height: 6px;
|
|
border-radius: 3px;
|
|
background: var(--background-modifier-border);
|
|
overflow: hidden;
|
|
margin-bottom: 6px;
|
|
}
|
|
|
|
.rosypilot-usage-progress-fill {
|
|
height: 100%;
|
|
border-radius: 3px;
|
|
background: var(--interactive-accent);
|
|
transition: width 0.3s ease;
|
|
}
|
|
|
|
.rosypilot-usage-progress-label {
|
|
font-size: 0.8em;
|
|
opacity: 0.65;
|
|
}
|
|
|
|
/************************************************************/
|
|
/* About card */
|
|
/************************************************************/
|
|
|
|
.rosypilot-about {
|
|
margin: 4px var(--size-4-3) 12px;
|
|
padding: 10px 14px;
|
|
border: 1px solid var(--background-modifier-border);
|
|
border-radius: 6px;
|
|
background: var(--background-secondary);
|
|
line-height: 1.6;
|
|
}
|
|
|
|
.rosypilot-about-title {
|
|
font-weight: 600;
|
|
font-size: 0.95em;
|
|
}
|
|
|
|
.rosypilot-about-meta {
|
|
font-size: 0.85em;
|
|
opacity: 0.75;
|
|
}
|
|
|
|
.rosypilot-about-copy {
|
|
font-size: 0.8em;
|
|
opacity: 0.5;
|
|
}
|
|
|
|
/************************************************************/
|
|
/* Debug panel */
|
|
/************************************************************/
|
|
|
|
.rosypilot-debug-toolbar {
|
|
display: flex;
|
|
justify-content: flex-end;
|
|
padding: 6px 8px;
|
|
border-bottom: 1px solid var(--background-modifier-border);
|
|
background: var(--background-secondary);
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.rosypilot-debug-clear-btn {
|
|
padding: 2px 10px;
|
|
font-size: 11px;
|
|
cursor: pointer;
|
|
border-radius: 4px;
|
|
border: 1px solid var(--background-modifier-border);
|
|
background: var(--background-secondary);
|
|
}
|
|
|
|
.rosypilot-debug-clear-btn:hover {
|
|
background: var(--background-modifier-hover);
|
|
}
|
|
|
|
.rosypilot-debug-container {
|
|
padding: 8px;
|
|
font-size: 12px;
|
|
overflow-y: auto;
|
|
flex: 1;
|
|
min-height: 0;
|
|
}
|
|
|
|
.rosypilot-debug-card {
|
|
border: 1px solid var(--background-modifier-border);
|
|
border-radius: 6px;
|
|
margin-bottom: 8px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.rosypilot-debug-card-open {
|
|
border-color: var(--interactive-accent);
|
|
}
|
|
|
|
.rosypilot-debug-card-header {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
padding: 8px 10px;
|
|
cursor: pointer;
|
|
user-select: none;
|
|
background: var(--background-secondary);
|
|
}
|
|
|
|
.rosypilot-debug-card-header:hover {
|
|
background: var(--background-modifier-hover);
|
|
}
|
|
|
|
.rosypilot-debug-card-context {
|
|
font-weight: bold;
|
|
font-size: 12px;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.rosypilot-debug-card-preview {
|
|
font-size: 11px;
|
|
opacity: 0.6;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
flex: 1;
|
|
min-width: 0;
|
|
}
|
|
|
|
.rosypilot-debug-card-actions {
|
|
display: flex;
|
|
gap: 4px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.rosypilot-debug-toggle-btn {
|
|
padding: 0 4px;
|
|
font-size: 12px;
|
|
cursor: pointer;
|
|
border: none;
|
|
background: none;
|
|
line-height: 1;
|
|
}
|
|
|
|
.rosypilot-debug-copy-btn {
|
|
padding: 2px 8px;
|
|
font-size: 10px;
|
|
cursor: pointer;
|
|
border-radius: 4px;
|
|
border: 1px solid var(--background-modifier-border);
|
|
background: var(--background-secondary);
|
|
}
|
|
|
|
.rosypilot-debug-copy-btn:hover {
|
|
background: var(--background-modifier-hover);
|
|
}
|
|
|
|
.rosypilot-debug-card-body {
|
|
padding: 8px 10px;
|
|
border-top: 1px solid var(--background-modifier-border);
|
|
}
|
|
|
|
.rosypilot-debug-summary {
|
|
margin-bottom: 10px;
|
|
}
|
|
|
|
.rosypilot-debug-summary strong {
|
|
display: block;
|
|
font-size: 10px;
|
|
text-transform: uppercase;
|
|
opacity: 0.5;
|
|
margin-bottom: 4px;
|
|
letter-spacing: 0.5px;
|
|
}
|
|
|
|
.rosypilot-debug-summary-grid {
|
|
display: grid;
|
|
gap: 3px;
|
|
padding: 6px 8px;
|
|
background: var(--background-secondary);
|
|
border-radius: 4px;
|
|
}
|
|
|
|
.rosypilot-debug-summary-row {
|
|
display: grid;
|
|
grid-template-columns: 82px minmax(0, 1fr);
|
|
gap: 8px;
|
|
}
|
|
|
|
.rosypilot-debug-summary-label {
|
|
color: var(--text-muted);
|
|
}
|
|
|
|
.rosypilot-debug-summary-value {
|
|
word-break: break-word;
|
|
}
|
|
|
|
.rosypilot-debug-section {
|
|
margin-bottom: 8px;
|
|
}
|
|
|
|
.rosypilot-debug-section:last-child {
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
.rosypilot-debug-section strong {
|
|
display: block;
|
|
font-size: 10px;
|
|
text-transform: uppercase;
|
|
opacity: 0.5;
|
|
margin-bottom: 2px;
|
|
letter-spacing: 0.5px;
|
|
}
|
|
|
|
.rosypilot-debug-section pre {
|
|
margin: 0;
|
|
padding: 4px 8px;
|
|
background-color: var(--background-secondary);
|
|
border-radius: 4px;
|
|
font-size: 11px;
|
|
white-space: pre-wrap;
|
|
word-break: break-all;
|
|
max-height: 200px;
|
|
overflow-y: auto;
|
|
}
|
|
|
|
.rosypilot-debug-message {
|
|
margin-bottom: 4px;
|
|
}
|
|
|
|
.rosypilot-debug-message code {
|
|
font-size: 10px;
|
|
text-transform: uppercase;
|
|
opacity: 0.7;
|
|
}
|
|
|
|
.rosypilot-debug-message pre {
|
|
margin: 2px 0 0 0;
|
|
}
|
|
|
|
.rosypilot-hidden {
|
|
display: none;
|
|
}
|
|
|
|
/************************************************************/
|
|
/* Legal panel */
|
|
/************************************************************/
|
|
|
|
.rosypilot-legal-panel {
|
|
padding: 8px;
|
|
overflow-y: auto;
|
|
height: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.rosypilot-legal-status {
|
|
padding: 12px 4px;
|
|
font-size: 0.85em;
|
|
opacity: 0.6;
|
|
}
|
|
|
|
.rosypilot-legal-label {
|
|
font-size: 10px;
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.5px;
|
|
opacity: 0.5;
|
|
margin-bottom: 6px;
|
|
padding: 0 2px;
|
|
}
|
|
|
|
.rosypilot-legal-item {
|
|
border: 1px solid var(--background-modifier-border);
|
|
border-radius: 6px;
|
|
padding: 10px 12px;
|
|
margin-bottom: 8px;
|
|
background: var(--background-secondary);
|
|
}
|
|
|
|
.rosypilot-legal-item-trusted {
|
|
border-color: var(--interactive-accent);
|
|
}
|
|
|
|
.rosypilot-legal-item-title {
|
|
font-weight: 600;
|
|
font-size: 0.9em;
|
|
margin-bottom: 6px;
|
|
line-height: 1.4;
|
|
}
|
|
|
|
.rosypilot-legal-source-badge {
|
|
display: inline-block;
|
|
width: fit-content;
|
|
padding: 1px 6px;
|
|
border-radius: 4px;
|
|
font-size: 10px;
|
|
line-height: 1.5;
|
|
margin-bottom: 4px;
|
|
border: 1px solid var(--background-modifier-border);
|
|
color: var(--text-muted);
|
|
}
|
|
|
|
.rosypilot-legal-source-badge-trusted {
|
|
color: var(--interactive-accent);
|
|
border-color: var(--interactive-accent);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-legal-source-badge-web {
|
|
color: var(--text-muted);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-legal-source-url {
|
|
font-size: 0.75em;
|
|
margin-bottom: 6px;
|
|
opacity: 0.7;
|
|
}
|
|
|
|
.rosypilot-legal-source-label {
|
|
color: var(--text-muted);
|
|
}
|
|
|
|
.rosypilot-legal-domain-link {
|
|
color: var(--text-accent);
|
|
text-decoration: none;
|
|
}
|
|
|
|
.rosypilot-legal-domain-link:hover {
|
|
text-decoration: underline;
|
|
}
|
|
|
|
.rosypilot-legal-item-content {
|
|
font-size: 0.85em;
|
|
line-height: 1.6;
|
|
white-space: pre-wrap;
|
|
margin-bottom: 6px;
|
|
}
|
|
|
|
.rosypilot-legal-item-meta {
|
|
font-size: 0.75em;
|
|
opacity: 0.55;
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
gap: 2px 8px;
|
|
line-height: 1.45;
|
|
}
|
|
|
|
.rosypilot-legal-meta-row {
|
|
display: inline-flex;
|
|
min-width: 0;
|
|
}
|
|
|
|
.rosypilot-legal-meta-label {
|
|
color: var(--text-muted);
|
|
}
|
|
|
|
.rosypilot-legal-meta-value {
|
|
word-break: break-word;
|
|
}
|
|
|
|
.rosypilot-legal-item-actions {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
align-items: center;
|
|
gap: 6px;
|
|
margin-top: 8px;
|
|
}
|
|
|
|
.rosypilot-legal-insert-group {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
flex-wrap: wrap;
|
|
gap: 4px;
|
|
}
|
|
|
|
.rosypilot-legal-action-label {
|
|
font-size: 0.8em;
|
|
color: var(--text-muted);
|
|
margin-right: 2px;
|
|
}
|
|
|
|
.rosypilot-legal-btn {
|
|
font-size: 0.8em;
|
|
padding: 2px 10px;
|
|
border-radius: 4px;
|
|
border: 1px solid var(--interactive-accent);
|
|
color: var(--interactive-accent);
|
|
background: transparent;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.rosypilot-legal-segment-btn {
|
|
font-size: 0.78em;
|
|
padding: 2px 8px;
|
|
border-radius: 999px;
|
|
border: 1px solid var(--background-modifier-border);
|
|
color: var(--text-normal);
|
|
background: var(--background-primary);
|
|
cursor: pointer;
|
|
}
|
|
|
|
.rosypilot-legal-segment-btn:hover {
|
|
border-color: var(--interactive-accent);
|
|
color: var(--interactive-accent);
|
|
background: var(--background-modifier-hover);
|
|
}
|
|
|
|
.rosypilot-legal-link-btn {
|
|
border: 1px solid var(--background-modifier-border);
|
|
border-radius: 999px;
|
|
background: var(--background-primary);
|
|
color: var(--text-accent);
|
|
padding: 1px 8px;
|
|
font-size: 0.75em;
|
|
line-height: 1.6;
|
|
cursor: pointer;
|
|
margin: -2px 0 8px;
|
|
}
|
|
|
|
.rosypilot-legal-link-btn:hover {
|
|
background: var(--background-modifier-hover);
|
|
border-color: var(--text-accent);
|
|
}
|
|
|
|
.rosypilot-legal-btn:hover {
|
|
background: var(--interactive-accent);
|
|
color: var(--text-on-accent);
|
|
}
|
|
|
|
.rosypilot-legal-btn-spinner {
|
|
display: inline-block;
|
|
width: 11px;
|
|
height: 11px;
|
|
border: 2px solid currentColor;
|
|
border-top-color: transparent;
|
|
border-radius: 50%;
|
|
animation: rosypilot-spin 0.6s linear infinite;
|
|
}
|
|
|
|
@keyframes rosypilot-spin {
|
|
to { transform: rotate(360deg); }
|
|
}
|
|
|
|
/************************************************************/
|
|
/* Hallucination verdict badges */
|
|
/************************************************************/
|
|
|
|
.rosypilot-legal-verdict-consistent {
|
|
color: var(--color-green);
|
|
border-color: var(--color-green);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-legal-verdict-inconsistent {
|
|
color: var(--color-red);
|
|
border-color: var(--color-red);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-legal-verdict-unknown {
|
|
color: var(--text-muted);
|
|
border-color: var(--background-modifier-border);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
/************************************************************/
|
|
/* Hallucination card enhancements */
|
|
/************************************************************/
|
|
|
|
.rosypilot-hallucination-header {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 6px;
|
|
flex-wrap: wrap;
|
|
margin-bottom: 2px;
|
|
}
|
|
|
|
.rosypilot-hallucination-type {
|
|
display: inline-block;
|
|
padding: 1px 6px;
|
|
border-radius: 4px;
|
|
font-size: 10px;
|
|
line-height: 1.5;
|
|
border: 1px solid transparent;
|
|
font-weight: 500;
|
|
}
|
|
|
|
.rosypilot-hallucination-type-fabricated {
|
|
color: var(--color-red);
|
|
border-color: var(--color-red);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-hallucination-type-clause-missing {
|
|
color: var(--color-orange);
|
|
border-color: var(--color-orange);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-hallucination-type-severe {
|
|
color: var(--color-red);
|
|
border-color: var(--color-red);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-hallucination-type-misunderstanding {
|
|
color: var(--color-yellow);
|
|
border-color: var(--color-yellow);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-hallucination-type-consistent {
|
|
color: var(--color-green);
|
|
border-color: var(--color-green);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-hallucination-type-unknown {
|
|
color: var(--text-muted);
|
|
border-color: var(--background-modifier-border);
|
|
background: var(--background-primary);
|
|
}
|
|
|
|
.rosypilot-legal-section-label {
|
|
font-size: 0.72em;
|
|
font-weight: 600;
|
|
color: var(--text-muted);
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.04em;
|
|
margin: 8px 0 3px;
|
|
}
|
|
|
|
.rosypilot-legal-key-points {
|
|
margin: 0 0 6px 0;
|
|
padding-left: 16px;
|
|
font-size: 0.82em;
|
|
line-height: 1.6;
|
|
}
|
|
|
|
.rosypilot-legal-key-points li {
|
|
margin-bottom: 2px;
|
|
}
|
|
|
|
.rosypilot-legal-analysis-section {
|
|
margin-top: 6px;
|
|
}
|
|
|
|
.rosypilot-legal-analysis-text {
|
|
font-size: 0.85em;
|
|
line-height: 1.65;
|
|
color: var(--text-normal);
|
|
background: var(--background-primary);
|
|
border-left: 2px solid var(--interactive-accent);
|
|
padding: 6px 10px;
|
|
border-radius: 0 4px 4px 0;
|
|
white-space: pre-wrap;
|
|
}
|
|
|
|
.rosypilot-legal-analysis-error {
|
|
border-left-color: var(--color-red);
|
|
color: var(--color-red);
|
|
}
|
|
|
|
/************************************************************/
|
|
/* Hallucination editor highlight mark */
|
|
/************************************************************/
|
|
|
|
.rosypilot-hallucination-highlight {
|
|
background: rgba(255, 193, 7, 0.28);
|
|
border-radius: 2px;
|
|
outline: 1.5px solid rgba(255, 193, 7, 0.55);
|
|
outline-offset: -1px;
|
|
}
|