2025-04-10 12:15:20 +01:00

566 lines
12 KiB
CSS

/* Table styles for HTTP Messages section */
.http-messages-table {
width: 100%;
border-collapse: separate;
border-spacing: 0;
margin-bottom: 25px;
background-color: var(--bg-secondary);
border-radius: 10px;
overflow: hidden;
border: 1px solid var(--border-color);
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}
.http-messages-table thead th {
background-color: var(--accent-color);
color: white;
font-weight: 600;
text-align: left;
padding: 14px 18px;
border-bottom: 2px solid rgba(255, 255, 255, 0.1);
position: relative;
}
/* Add subtle highlight to table header */
.http-messages-table thead:after {
content: '';
position: absolute;
left: 0;
right: 0;
bottom: 0;
height: 1px;
background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.3), transparent);
}
.http-messages-table tbody tr {
border-bottom: 1px solid var(--border-color);
transition: background-color 0.2s ease;
cursor: pointer;
}
.http-messages-table tbody tr:hover {
background-color: var(--bg-tertiary);
}
.http-messages-table tbody tr.selected {
background-color: var(--bg-tertiary);
border-left: 4px solid var(--accent-color);
}
.http-messages-table tbody tr:last-child {
border-bottom: none;
}
.http-messages-table td {
padding: 14px 18px;
vertical-align: middle;
transition: all 0.25s ease;
}
.http-messages-table tbody tr:hover td {
color: var(--text-primary);
}
.http-messages-table .sender-cell {
max-width: 200px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-family: 'Consolas', 'Courier New', monospace;
color: var(--text-secondary);
background-color: rgba(0, 0, 0, 0.02);
transition: all 0.25s ease;
}
.http-messages-table tr:hover .sender-cell {
color: var(--accent-color);
}
.http-messages-table .time-cell {
white-space: nowrap;
color: var(--text-tertiary);
font-size: 0.9em;
}
.http-messages-table .event-id-cell {
font-family: 'Consolas', 'Courier New', monospace;
color: var(--accent-color);
font-size: 0.9em;
font-weight: 500;
padding: 6px 8px;
background-color: rgba(var(--accent-color-rgb, 13, 110, 253), 0.05);
border-radius: 4px;
display: inline-block;
}
.http-messages-table .response-cell {
text-align: center;
width: 80px;
}
.response-indicator {
display: inline-flex;
align-items: center;
justify-content: center;
font-size: 14px;
width: 24px;
height: 24px;
line-height: 1;
text-align: center;
border-radius: 50%;
transition: all 0.3s ease;
}
.response-indicator.has-response {
color: white;
background-color: var(--accent-color);
font-weight: bold;
box-shadow: 0 2px 5px rgba(var(--accent-color-rgb, 13, 110, 253), 0.4);
}
.response-indicator.no-response {
color: var(--text-tertiary);
opacity: 0.7;
background-color: var(--bg-tertiary);
border: 1px solid var(--border-color);
}
.http-messages-table tr:hover .response-indicator.has-response {
transform: scale(1.1);
}
/* Expandable content styles */
.expandable-content {
display: none;
padding: 0;
background-color: var(--bg-tertiary);
border-top: 1px solid var(--border-color);
box-shadow: inset 0 4px 6px rgba(0, 0, 0, 0.05);
transition: all 0.3s ease;
}
.expandable-content.expanded {
display: table-row;
animation: expandFade 0.3s ease-in-out;
}
@keyframes expandFade {
from {
opacity: 0;
transform: translateY(-10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
.expandable-cell {
padding: 0 !important;
}
.expandable-inner {
padding: 20px;
}
/* Tab styles inside expandable content */
.details-tabs {
border-bottom: 1px solid var(--border-color);
display: flex;
padding: 10px 20px 0;
background-color: var(--bg-tertiary);
flex-wrap: wrap;
gap: 5px;
}
.details-tab {
padding: 10px 15px;
cursor: pointer;
border: 1px solid var(--border-color);
border-bottom: none;
margin-right: 5px;
transition: all 0.3s ease;
border-radius: 4px 4px 0 0;
background-color: var(--bg-secondary);
font-weight: 500;
position: relative;
bottom: -1px;
outline: none;
}
.details-tab:hover {
color: var(--accent-color);
background-color: var(--bg-tertiary);
}
.details-tab.active {
color: var(--accent-color);
border-bottom-color: var(--bg-tertiary);
background-color: var(--bg-tertiary);
z-index: 2;
}
.details-tab-content {
display: none;
padding: 20px;
border-top: 1px solid var(--border-color);
background-color: var(--bg-tertiary);
}
.details-tab-content.active {
display: block;
}
/* Styling for the HTTP Response and Request tabs */
.details-tab-content h3 {
margin-top: 0;
color: var(--accent-color);
margin-bottom: 15px;
padding-bottom: 10px;
border-bottom: 1px solid var(--border-color);
}
.details-tab-content pre {
background-color: var(--bg-secondary);
padding: 18px;
border-radius: 6px;
max-height: 300px;
overflow-y: auto;
border: 1px solid var(--border-color);
font-family: 'Consolas', 'Courier New', monospace;
font-size: 14px;
line-height: 1.5;
color: var(--text-primary);
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
}
/* Loading indicator and no responses message */
.loading-response, .no-responses {
padding: 20px;
text-align: center;
color: var(--text-tertiary);
background-color: var(--bg-secondary);
border-radius: 8px;
border: 1px solid var(--border-color);
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
font-style: italic;
}
/* Empty state */
.table-empty-state {
padding: 30px;
text-align: center;
color: var(--text-tertiary);
font-style: italic;
}
/* Responsive adjustments */
@media (max-width: 768px) {
.http-messages-table {
display: block;
overflow-x: auto;
}
.http-messages-table td.event-id-cell {
max-width: 100px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
}
/* Modal styles */
.http-messages-modal {
display: none;
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.5);
z-index: 1000;
overflow: auto;
}
.modal-content {
position: relative;
background-color: var(--bg-secondary);
margin: 5% auto;
padding: 0;
width: 90%;
max-width: 1000px;
border-radius: 8px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
max-height: 85vh;
display: flex;
flex-direction: column;
}
.modal-close-button {
position: absolute;
top: 10px;
right: 15px;
font-size: 24px;
font-weight: bold;
color: var(--text-tertiary);
background: none;
border: none;
cursor: pointer;
z-index: 2;
}
.modal-close-button:hover {
color: var(--accent-color);
}
/* Modal tabs */
.modal-tabs {
display: flex;
padding: 15px 15px 0;
border-bottom: 1px solid var(--border-color);
background-color: var(--bg-tertiary);
border-radius: 8px 8px 0 0;
flex-wrap: wrap;
gap: 5px;
}
.modal-tab {
padding: 10px 15px;
cursor: pointer;
border: 1px solid var(--border-color);
border-bottom: none;
margin-right: 5px;
transition: all 0.3s ease;
border-radius: 4px 4px 0 0;
background-color: var(--bg-secondary);
color: var(--text-primary);
font-weight: 500;
position: relative;
bottom: -1px;
outline: none;
}
.modal-tab:hover {
color: var(--accent-color);
background-color: var(--bg-tertiary);
}
.modal-tab.active {
color: var(--accent-color);
border-bottom-color: var(--bg-tertiary);
background-color: var(--bg-tertiary);
z-index: 2;
}
/* Modal tab contents */
.modal-tab-contents {
padding: 20px;
background-color: var(--bg-tertiary);
overflow-y: auto;
flex: 1;
border-radius: 0 0 8px 8px;
}
.modal-tab-content {
display: none;
max-height: 60vh;
overflow-y: auto;
}
.modal-tab-content pre {
background-color: var(--bg-secondary);
padding: 15px;
border-radius: 4px;
overflow-x: auto;
border: 1px solid var(--border-color);
margin: 0;
}
.json-content {
font-family: 'Consolas', 'Courier New', monospace;
font-size: 14px;
white-space: pre-wrap;
line-height: 1.5;
color: var(--text-primary);
}
/* Add syntax highlighting for JSON content */
.json-content .string { color: #25c2a0; }
.json-content .number { color: #f5a623; }
.json-content .boolean { color: #7e57c2; }
.json-content .null { color: #bc4749; }
.json-content .key { color: #0088cc; font-weight: 500; }
/* Modal update notification */
.modal-update-notification {
position: absolute;
top: 15px;
left: 50%;
transform: translateX(-50%);
background-color: var(--accent-color);
color: white;
padding: 8px 16px;
border-radius: 4px;
font-weight: 500;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
z-index: 3;
animation: fadeInOut 3s ease-in-out;
}
@keyframes fadeInOut {
0% { opacity: 0; transform: translateX(-50%) translateY(-10px); }
15% { opacity: 1; transform: translateX(-50%) translateY(0); }
85% { opacity: 1; transform: translateX(-50%) translateY(0); }
100% { opacity: 0; transform: translateX(-50%) translateY(-10px); }
}
.no-response {
padding: 15px;
text-align: center;
color: var(--text-tertiary);
background-color: var(--bg-secondary);
border-radius: 4px;
border: 1px solid var(--border-color);
margin: 20px 0;
}
/* HTTP content formatting - Enhanced */
.http-first-line {
font-weight: bold;
margin-bottom: 12px;
padding: 12px 15px;
border-bottom: 1px solid var(--border-color);
background-color: rgba(var(--accent-color-rgb, 13, 110, 253), 0.05);
border-radius: 6px 6px 0 0;
}
.http-method {
color: #0088cc;
font-weight: bold;
margin-right: 12px;
background-color: rgba(0, 136, 204, 0.1);
padding: 2px 8px;
border-radius: 4px;
}
.http-path {
color: var(--text-primary);
margin-right: 12px;
font-family: 'Consolas', 'Courier New', monospace;
}
.http-version {
color: var(--text-tertiary);
background-color: var(--bg-tertiary);
padding: 2px 6px;
border-radius: 4px;
font-size: 0.9em;
}
.http-status {
padding: 3px 8px;
border-radius: 6px;
margin: 0 12px;
font-weight: 600;
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}
.http-status.success {
background-color: rgba(40, 167, 69, 0.9);
color: white;
}
.http-status.error {
background-color: rgba(220, 53, 69, 0.9);
color: white;
}
.http-status.redirect {
background-color: rgba(253, 126, 20, 0.9);
color: white;
}
.http-status-text {
color: var(--text-primary);
font-weight: 500;
}
.http-headers {
margin-bottom: 20px;
padding: 15px;
border-bottom: 1px dashed var(--border-color);
background-color: var(--bg-secondary);
border-radius: 4px;
}
.http-header {
margin-bottom: 8px;
padding-bottom: 8px;
border-bottom: 1px dotted rgba(var(--border-color-rgb, 222, 226, 230), 0.5);
display: flex;
flex-wrap: wrap;
}
.http-header:last-child {
margin-bottom: 0;
padding-bottom: 0;
border-bottom: none;
}
.http-header-name {
color: #0088cc;
font-weight: 600;
margin-right: 10px;
min-width: 120px;
font-family: 'Consolas', 'Courier New', monospace;
}
.http-header-value {
color: var(--text-primary);
flex: 1;
font-family: 'Consolas', 'Courier New', monospace;
word-break: break-all;
}
.http-body {
font-family: 'Consolas', 'Courier New', monospace;
white-space: pre-wrap;
word-break: break-all;
padding: 15px;
background-color: var(--bg-secondary);
border-radius: 4px;
border: 1px solid var(--border-color);
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
}
.http-body.json {
color: var(--accent-color);
}
/* Add a label before the body content */
.http-body-label {
display: block;
margin-bottom: 10px;
font-weight: 600;
color: var(--text-secondary);
border-bottom: 1px dotted var(--border-color);
padding-bottom: 8px;
}
/* Responsive modal */
@media (max-width: 768px) {
.modal-content {
width: 95%;
margin: 10% auto;
}
.modal-tabs {
flex-direction: column;
padding: 10px 10px 0;
}
.modal-tab {
margin-bottom: 5px;
width: 100%;
text-align: left;
}
}