Файли
openidea/src/features/analysis/Analysis.module.css
T
l0ng-ai ca778e2382 fix(search): improve structural template layout (#5298)
- Put the language picker in the Search template header and keep each label next to its template.
- Give both templates 150 px of editing space in a standard window. Tighten the editors on shorter screens and keep the dialog footer accessible.
- Use the configured editor font, size, and line height in both templates.
2026-11-23 12:08:57 +08:00

421 рядки
7.3 KiB
CSS

.view {
height: 100%;
display: flex;
flex-direction: column;
min-height: 0;
}
.body {
flex: 1;
min-height: 0;
display: flex;
flex-direction: column;
}
.body > * {
flex: 1;
min-height: 0;
}
.status {
flex: none;
display: flex;
align-items: center;
gap: var(--space-2);
height: var(--h-row);
padding: 0 10px;
border-bottom: 1px solid var(--border);
color: var(--fg-secondary);
font-size: var(--fs-small);
white-space: nowrap;
}
.statusText {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
}
.progress {
width: 160px;
flex: none;
margin-left: auto;
}
.row {
display: flex;
align-items: center;
gap: var(--space-1-5);
min-width: 0;
flex: 1;
white-space: nowrap;
}
.strong {
color: var(--fg-strong);
}
.muted {
flex: none;
color: var(--fg-subtle);
}
.count {
color: var(--fg-subtle);
margin-left: 4px;
}
.fileIcon {
flex: none;
color: var(--fg-muted);
}
.message {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
color: var(--fg);
}
.sev-error {
flex: none;
color: var(--danger);
}
.sev-warning {
flex: none;
color: var(--warning);
}
.sev-info {
flex: none;
color: var(--info);
}
/* Duplicates: groups on the left, fragments side by side on the right. */
.split {
flex: 1;
min-height: 0;
display: flex;
}
.groups {
width: 40%;
min-width: 200px;
display: flex;
flex-direction: column;
border-right: 1px solid var(--border);
}
.groups > * {
flex: 1;
min-height: 0;
}
.fragments {
flex: 1;
min-width: 0;
display: flex;
overflow-x: auto;
}
.fragment {
flex: 1 0 280px;
min-width: 0;
display: flex;
flex-direction: column;
border-right: 1px solid var(--border);
}
.fragment:last-child {
border-right: 0;
}
.fragmentHeader {
flex: none;
display: flex;
align-items: center;
gap: var(--space-1-5);
width: 100%;
height: var(--h-row);
padding: 0 8px;
border: 0;
border-bottom: 1px solid var(--border);
background: var(--bg-elev);
color: var(--fg);
font: inherit;
text-align: left;
white-space: nowrap;
overflow: hidden;
cursor: default;
}
.fragmentHeader:hover {
background: var(--bg-hover);
}
.code {
flex: 1;
min-height: 0;
margin: 0;
padding: 6px 8px;
overflow: auto;
font-family: var(--font-mono);
font-size: var(--fs-small);
line-height: 18px;
color: var(--fg-editor);
white-space: pre;
}
.lineNo {
display: inline-block;
width: 4ch;
margin-right: 1ch;
text-align: right;
color: var(--fg-line-number);
user-select: none;
}
/* Dialogs */
.form {
display: flex;
flex-direction: column;
gap: 10px;
padding: 14px;
}
.scope {
container: analysis-scope / inline-size;
min-inline-size: 0;
margin: 0;
padding: 0;
border: 0;
}
.scopeOptions {
display: grid;
grid-template-columns: fit-content(45%) minmax(0, 1fr);
align-items: center;
gap: var(--space-0-5) var(--space-2);
}
.fieldLabel {
padding: 0 0 4px;
color: var(--fg-secondary);
font-size: var(--fs-small);
}
.radioRow {
grid-column: 1 / -1;
min-width: 0;
padding-block: var(--space-0-5);
overflow-wrap: anywhere;
}
.scopeWithField {
grid-column: 1;
}
.scopeControl {
grid-column: 2;
display: flex;
align-items: center;
gap: var(--space-1-5);
min-width: 0;
}
.scopeControl > button:last-child {
flex: none;
}
@container analysis-scope (max-width: 336px) {
.scopeOptions {
grid-template-columns: minmax(0, 1fr);
}
.scopeControl {
grid-column: 1;
padding-inline-start: calc(16px + var(--space-2));
margin-block-end: var(--space-1);
}
}
.grow {
flex: 1;
min-width: 0;
}
.fieldRow {
display: flex;
align-items: center;
gap: var(--space-2);
}
.reformatSubject {
overflow-wrap: anywhere;
font-size: var(--fs-ui);
font-weight: 600;
}
.reformatMask {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: var(--space-2);
}
.reformatMaskInput {
flex: 1 1 12ch;
min-width: 0;
}
.templateSection {
display: flex;
flex-direction: column;
gap: var(--space-1);
color: var(--fg);
font-size: var(--fs-ui);
}
.templateHeader {
display: flex;
align-items: center;
justify-content: space-between;
gap: var(--space-2);
}
.languageSelect {
max-width: 50%;
}
.template {
width: 100%;
height: clamp(96px, 24vh, 150px);
min-height: 50px;
resize: vertical;
padding: var(--space-1-5) var(--space-2);
border: 1px solid var(--border-strong);
border-radius: var(--radius-control);
background: var(--bg-editor);
color: var(--fg-editor);
font-family: var(--font-mono);
font-size: var(--fs-code);
line-height: var(--lh-code);
}
.replaceForm .template {
/* Leave room for the scope and dialog controls when both templates are shown. */
height: clamp(96px, calc(50vh - 205px), 150px);
}
.template:focus {
outline: none;
border-color: var(--accent);
}
.hint {
color: var(--fg-subtle);
font-size: var(--fs-small);
line-height: 1.5;
}
.error {
color: var(--danger);
font-size: var(--fs-small);
}
.number {
width: 80px;
}
/* Replace preview */
.previewList {
max-height: 360px;
overflow: auto;
margin: 14px;
padding: 0;
list-style: none;
border: 1px solid var(--border);
border-radius: var(--radius-small);
}
.previewItem {
display: flex;
align-items: flex-start;
gap: var(--space-2);
padding: 4px 8px;
border-bottom: 1px solid var(--border);
}
.previewItem:last-child {
border-bottom: 0;
}
.previewBody {
min-width: 0;
flex: 1;
display: flex;
flex-direction: column;
gap: var(--space-0-5);
}
.previewWhere {
color: var(--fg-subtle);
font-size: var(--fs-small);
}
.previewOld,
.previewNew {
margin: 0;
font-family: var(--font-mono);
font-size: var(--fs-small);
white-space: pre-wrap;
word-break: break-all;
}
.previewOld {
color: var(--fg-muted);
text-decoration: line-through;
}
.previewNew {
color: var(--vcs-added);
}
/* Inspection Results: tree on the left, problem details on the right. */
.panel {
display: flex;
flex-direction: column;
min-width: 0;
min-height: 0;
font-size: var(--fs-ui);
}
.panel > * {
flex: 1;
min-height: 0;
}
.resultLabel,
.resultDirectory {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
}
.resultMeta {
flex: none;
color: var(--fg-subtle);
font-size: var(--fs-small);
}
.resultDirectory {
flex-shrink: 1;
max-width: 35%;
}
.excluded .message,
.excluded .strong {
opacity: 0.5;
text-decoration: line-through;
}
.details {
display: flex;
flex-direction: column;
}
.detailsBody {
flex: 1;
min-height: 0;
display: flex;
flex-direction: column;
gap: var(--space-2);
padding: var(--space-2) var(--space-3);
overflow: auto;
overflow-wrap: anywhere;
}
.detailsEmpty {
flex: 1;
display: flex;
align-items: center;
justify-content: center;
padding: var(--space-3);
color: var(--fg-faint);
text-align: center;
}
.detailsTitle {
display: flex;
align-items: baseline;
gap: var(--space-1-5);
color: var(--fg-strong);
}
.detailsLocation {
color: var(--fg-subtle);
font-size: var(--fs-small);
}
.detailsCoordinates {
white-space: nowrap;
}
.detailsMessage {
margin: 0;
white-space: pre-wrap;
color: var(--fg);
}
.detailsActions {
flex: none;
display: flex;
flex-wrap: wrap;
gap: var(--space-1-5);
padding: var(--space-1) var(--space-3);
border-bottom: 1px solid var(--border);
}
.detailAction {
max-width: 100%;
height: auto;
min-height: var(--h-control);
white-space: normal;
line-height: 1.25;
overflow-wrap: anywhere;
}