-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathschema_doc_compact.css
More file actions
109 lines (95 loc) · 3 KB
/
Copy pathschema_doc_compact.css
File metadata and controls
109 lines (95 loc) · 3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
/* Compact overrides for json-schema-for-humans flat template */
body {
padding: 20px;
font-size: 14px;
line-height: 1.4;
}
h1 { font-size: 1.6rem; margin-bottom: 0.5rem; }
/* Tighter cards */
.card { margin-bottom: 0.4rem; }
.card-header { padding: 0.4rem 0.75rem; }
.card-header h2 { font-size: 0.95rem; margin: 0; }
.card-body { padding: 0.5rem 0.75rem; }
/* Smaller badges */
.badge { font-size: 80%; margin: 0.15rem 0; }
.badge.value-type, .badge.no-additional, .badge.default-value {
font-size: 90%;
margin-right: 4px;
margin-bottom: 4px;
}
.badge.required-property, .badge.deprecated-property, .badge.pattern-property {
font-size: 55%;
margin-left: 6px;
}
.badge.restriction { margin: 0; }
/* Type badge + description inline: hide the <br/> between them */
.badge.value-type + br { display: none; }
.badge.value-type + br + p,
.badge.value-type ~ p:first-of-type {
display: inline;
margin-left: 6px;
}
/* Example badge + content closer: hide surrounding <br/> tags */
.badge.badge-secondary + br { display: none; }
br + .badge.badge-secondary { display: inline; }
/* Compact examples */
.jumbotron.examples, .highlight.jumbotron {
padding: 0.4rem 0.6rem !important;
margin-top: 0.2rem;
margin-bottom: 0.3rem;
}
.examples pre { margin-bottom: 0; font-size: 0.85rem; }
.badge.badge-secondary { margin-bottom: 0.1rem; }
/* Tighter description */
p { margin-bottom: 0.3rem; }
/* Remove excessive br spacing */
br + br { display: none; }
/* Property name slightly larger than body text */
.property-name { font-size: 1.05em; font-weight: 600; }
/* "Option 1" / "Option 2" headings — reduce from h3 to small text */
.any-of-value h3 { font-size: 0.9rem; margin: 0.3rem 0; }
/* "Each item of this array must be:" — reduce h4 to regular text */
h4 { font-size: 0.9rem; font-weight: normal; margin: 0.3rem 0; }
/* Nested cards (sub-properties) */
.card .card { margin-bottom: 0.3rem; }
.card .card .card-header { padding: 0.3rem 0.6rem; }
.card .card .card-body { padding: 0.4rem 0.6rem; }
/* ── anyOf / oneOf: compact inline row ── */
.any-of-value {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: 0.25rem;
margin: 0.2rem 0;
}
/* "Any of" heading inline as a small label */
.any-of-value > a { display: contents; }
.any-of-value h2.handle {
font-size: 0.85rem;
margin: 0 0.2rem 0 0;
padding: 0;
white-space: nowrap;
}
.any-of-value h2.handle label { margin: 0; cursor: default; }
/* Option cards: borderless, just inline badge containers */
.any-of-value > .card {
display: inline-flex;
align-items: center;
margin: 0;
padding: 0;
border: none;
background: none;
box-shadow: none;
}
/* Hide "Option 1" / "Option 2" headings entirely */
.any-of-value > .card > h3 { display: none; }
.any-of-value > .card > .card-body {
display: inline-flex;
align-items: center;
padding: 0;
margin: 0;
}
/* Hide stray <br/> inside anyOf option card bodies */
.any-of-value .card-body br { display: none; }
/* Type badge inside option: keep it snug */
.any-of-value .badge { margin: 0; }