@scalar/api-reference 0.1.28 → 0.1.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/style.css CHANGED
@@ -1,4 +1,4 @@
1
- .cm-scroller,
1
+ @import url('https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap');@import url('https://fonts.googleapis.com/css?family=JetBrains%20Mono');@import 'node_modules/modern-normalize/modern-normalize.css';@import 'node_modules/modern-normalize/modern-normalize.css';.cm-scroller,
2
2
  .custom-scroll {
3
3
  overflow-y: scroll;
4
4
  scrollbar-color: transparent transparent;
@@ -66,7 +66,7 @@
66
66
  }
67
67
  }
68
68
 
69
- .sidebar-search[data-v-5005eb5e] {
69
+ .sidebar-search[data-v-f87e89f2] {
70
70
  display: flex;
71
71
  align-items: center;
72
72
  position: relative;
@@ -74,9 +74,9 @@
74
74
  --margin-x: 12px;
75
75
  width: calc(100% - 2 * var(--margin-x));
76
76
  margin: 12px var(--margin-x) 6px var(--margin-x);
77
- padding: 0 12px;
77
+ padding: 0 3px 0 12px;
78
78
 
79
- color: var(--theme-color-3);
79
+ color: var(--sidebar-color-2, var(--theme-color-2));
80
80
  outline: none;
81
81
  border-radius: var(--theme-radius-lg);
82
82
  border: 1px solid var(--theme-border-color);
@@ -85,17 +85,30 @@
85
85
  cursor: pointer;
86
86
  appearance: none;
87
87
  }
88
- .sidebar-search-input[data-v-5005eb5e] {
88
+ .sidebar-search-input[data-v-f87e89f2] {
89
89
  font-size: var(--theme-small);
90
90
  font-weight: var(--theme-semibold);
91
- line-height: 31px;
91
+ height: 31px;
92
92
 
93
93
  user-select: none;
94
94
  z-index: 10;
95
95
  position: relative;
96
- display: block;
96
+ display: flex;
97
+ width: 100%;
98
+ justify-content: space-between;
99
+ align-items: center;
97
100
  }
98
- .search-icon[data-v-5005eb5e] {
101
+ .sidebar-search-shortcut[data-v-f87e89f2] {
102
+ text-transform: uppercase;
103
+ }
104
+ .sidebar-search-key[data-v-f87e89f2] {
105
+ background-color: var(--theme-background-2);
106
+ padding: 3px 5px;
107
+ margin: 2px;
108
+ border-radius: var(--theme-radius);
109
+ color: var(--theme-color-3);
110
+ }
111
+ .search-icon[data-v-f87e89f2] {
99
112
  padding: 0;
100
113
  margin-right: 9px;
101
114
  width: 12px;
@@ -1400,6 +1413,156 @@ to {
1400
1413
  margin-bottom: 24px;
1401
1414
  }
1402
1415
  }
1416
+
1417
+ .modal-layout[data-v-3f4ab567] {
1418
+ position: fixed;
1419
+ width: 100vw;
1420
+ height: 100vh;
1421
+ top: 0;
1422
+ left: 0;
1423
+ z-index: 1001;
1424
+ background: rgba(0, 0, 0, 0.44);
1425
+ padding: 20px;
1426
+ opacity: 0;
1427
+ animation: modal-fade-3f4ab567 0.2s forwards;
1428
+ }
1429
+ .modal-body[data-v-3f4ab567] {
1430
+ padding: 24px 12px 18px 24px;
1431
+ max-height: calc(100vh - 240px);
1432
+ background: var(--theme-background-1);
1433
+ border-radius: var(--theme-radius-lg);
1434
+ font-family: var(--theme-font);
1435
+ }
1436
+ .modal[data-v-3f4ab567] {
1437
+ margin: 80px auto 0;
1438
+ position: relative;
1439
+ background: var(--theme-background-2);
1440
+ border-radius: var(--theme-radius-lg);
1441
+ color: var(--theme-color-1);
1442
+ width: 100%;
1443
+ text-align: left;
1444
+ line-height: 1.4;
1445
+ opacity: 0;
1446
+ transform: scale(0.98);
1447
+ animation: modal-pop-3f4ab567 0.15s 0.15s forwards;
1448
+ display: flex;
1449
+ flex-direction: column;
1450
+ }
1451
+ .modal-content-large[data-v-3f4ab567] {
1452
+ max-width: 800px;
1453
+ }
1454
+ .modal-content-normal[data-v-3f4ab567] {
1455
+ max-width: 640px;
1456
+ }
1457
+ .modal-content-small[data-v-3f4ab567] {
1458
+ max-width: 480px;
1459
+ }
1460
+ @keyframes modal-fade-3f4ab567 {
1461
+ from {
1462
+ opacity: 0;
1463
+ }
1464
+ to {
1465
+ opacity: 1;
1466
+ }
1467
+ }
1468
+ @keyframes modal-pop-3f4ab567 {
1469
+ 0% {
1470
+ opacity: 0;
1471
+ }
1472
+ 100% {
1473
+ opacity: 1;
1474
+ transform: scale(1);
1475
+ }
1476
+ }
1477
+ .modal-header[data-v-3f4ab567] {
1478
+ padding: 12px 24px;
1479
+ color: var(--theme-color-1);
1480
+ font-size: var(--theme-font-size-4);
1481
+ text-align: left;
1482
+ font-weight: 600;
1483
+ border-radius: var(--theme-radius-lg) var(--theme-radius-lg) 0 0;
1484
+ }
1485
+
1486
+ /** Input */
1487
+ .ref-search-input[data-v-bee36e88] {
1488
+ width: 100%;
1489
+ background: transparent;
1490
+ padding: 12px;
1491
+ font-size: 13px;
1492
+ outline: none;
1493
+ border: 1px solid var(--theme-border-color);
1494
+ border-radius: var(--theme-radius);
1495
+ color: var(--theme-color-1);
1496
+ font-weight: var(--theme-semibold);
1497
+ font-size: var(--theme-font-size-3);
1498
+ appearance: none;
1499
+ margin-bottom: 12px;
1500
+ }
1501
+ .ref-search-input[data-v-bee36e88]::-webkit-input-placeholder,
1502
+ .ref-search-input[data-v-bee36e88]::placeholder {
1503
+ color: var(--theme-color-3);
1504
+ font-family: var(--theme-font);
1505
+ font-weight: var(--theme-regular);
1506
+ }
1507
+ /** Results */
1508
+ .item-entry[data-v-bee36e88] {
1509
+ appearance: none;
1510
+ background: transparent;
1511
+ border: none;
1512
+ outline: none;
1513
+ padding: 6px 12px;
1514
+ width: 100%;
1515
+ font-size: var(--theme-font-size-3);
1516
+ text-align: left;
1517
+ border-radius: var(--theme-radius);
1518
+ display: flex;
1519
+ flex-direction: column;
1520
+ gap: 6px;
1521
+ }
1522
+ .item-entry--active[data-v-bee36e88] {
1523
+ background: var(--theme-background-2);
1524
+ box-shadow: 0 0 0 1px var(--theme-background-2);
1525
+ }
1526
+ .item-entry[data-v-bee36e88]:hover {
1527
+ background: var(--theme-background-2);
1528
+ box-shadow: 0 0 0 1px var(--theme-background-2);
1529
+ }
1530
+ .item-entry-title[data-v-bee36e88] {
1531
+ font-weight: var(--theme-semibold);
1532
+ }
1533
+ .item-entry-request[data-v-bee36e88] {
1534
+ display: flex;
1535
+ gap: 3px;
1536
+ font-family: var(--theme-font-code);
1537
+ }
1538
+ .item-entry-http-verb[data-v-bee36e88] {
1539
+ text-transform: uppercase;
1540
+ }
1541
+ .item-entry-http-verb--post[data-v-bee36e88] {
1542
+ color: var(--theme-post-color);
1543
+ }
1544
+ .item-entry-http-verb--patch[data-v-bee36e88] {
1545
+ color: var(--theme-patch-color);
1546
+ }
1547
+ .item-entry-http-verb--get[data-v-bee36e88] {
1548
+ color: var(--theme-get-color);
1549
+ }
1550
+ .item-entry-http-verb--delete[data-v-bee36e88] {
1551
+ color: var(--theme-delete-color);
1552
+ }
1553
+ .item-entry-http-verb--put[data-v-bee36e88] {
1554
+ color: var(--theme-put-color);
1555
+ }
1556
+ .item-entry-path[data-v-bee36e88] {
1557
+ color: var(--theme-color-3);
1558
+ }
1559
+
1560
+
1561
+ * {
1562
+ text-rendering: optimizeLegibility;
1563
+ -webkit-font-smoothing: antialiased;
1564
+ -moz-osx-font-smoothing: grayscale;
1565
+ }
1403
1566
  /* fonts */
1404
1567
  :root {
1405
1568
  --app-header-height: 50px;
@@ -1568,6 +1731,17 @@ to {
1568
1731
  --scalar-brand: #8b7256;
1569
1732
  }
1570
1733
 
1734
+ /** CSS Normalize */
1735
+ .scalar-api-reference {
1736
+
1737
+ }
1738
+ .scalar-api-reference ul,
1739
+ .scalar-api-reference ol {
1740
+ padding: 0;
1741
+ }
1742
+ .scalar-api-reference p {
1743
+ margin: 0;
1744
+ }
1571
1745
  /** Utilities, how do we deal with them? */
1572
1746
  .flex {
1573
1747
  display: flex;
@@ -1590,7 +1764,6 @@ to {
1590
1764
  clip: rect(0, 0, 0, 0);
1591
1765
  border: 0;
1592
1766
  }
1593
-
1594
1767
  /** TODO: Move to components */
1595
1768
  .codemenu-topbar {
1596
1769
  background: var(--theme-background-2);
@@ -1732,7 +1905,6 @@ to {
1732
1905
  .endpoint-response__headers + .endpoint-response {
1733
1906
  border-top: none;
1734
1907
  }
1735
-
1736
1908
  /* ----------------------------------------------------- */
1737
1909
  .reference {
1738
1910
  position: relative;
@@ -1772,7 +1944,6 @@ to {
1772
1944
  color: var(--theme-color-1);
1773
1945
  text-decoration: underline;
1774
1946
  }
1775
-
1776
1947
  /* ----------------------------------------------------- */
1777
1948
  /* Responsive styles for narrow reference container (900px) */
1778
1949
  .references-narrow .reference {
@@ -1798,7 +1969,6 @@ to {
1798
1969
  color: var(--theme-color-1);
1799
1970
  line-height: 1.45;
1800
1971
  }
1801
-
1802
1972
  /** Layout */
1803
1973
  /* ----------------------------------------------------- */
1804
1974
  /* Document Layouts */
@@ -1869,7 +2039,6 @@ to {
1869
2039
  background: var(--theme-background-1);
1870
2040
  display: flex;
1871
2041
  }
1872
-
1873
2042
  /* Measures the visible viewport of the editor */
1874
2043
  .layout-content-viewport {
1875
2044
  position: fixed;
@@ -1903,7 +2072,6 @@ to {
1903
2072
  .layout-footer {
1904
2073
  grid-area: footer;
1905
2074
  }
1906
-
1907
2075
  /* ----------------------------------------------------- */
1908
2076
  /* Document layout modified for references */
1909
2077
  .document.layout-swagger-editor {
@@ -1967,7 +2135,468 @@ to {
1967
2135
  --col-width-2: 50%;
1968
2136
  --col-width-3: 50%;
1969
2137
  }
2138
+ /* ----------------------------------------------------- */
2139
+ /* Responsive styles */
2140
+ @media (max-width: 1150px) {
2141
+ .document.layout-swagger-editor {
2142
+ --col-width-3: 0;
2143
+ --col-width-2: auto;
2144
+ }
2145
+ }
2146
+ @media (max-width: 1000px) {
2147
+ .document,
2148
+ .document.layout-swagger-editor {
2149
+ /** Content area heights are restricted using just the template row defs */
2150
+ grid-template-rows:
2151
+ var(--scalar-api-reference-theme-header-height)
2152
+ auto
2153
+ auto
2154
+ auto;
2155
+
2156
+ grid-template-columns: 100%;
2157
+
2158
+ grid-template-areas:
2159
+ 'sidebar'
2160
+ 'content'
2161
+ 'aside'
2162
+ 'footer';
2163
+ }
2164
+ .layout-aside-left,
2165
+ .layout-aside-right,
2166
+ .layout-aside-content {
2167
+ position: static;
2168
+ max-height: unset;
2169
+ }
2170
+ .layout-aside-left {
2171
+ position: sticky;
2172
+ top: 0;
2173
+ height: var(--scalar-api-reference-theme-header-height);
2174
+ border-bottom: 1px solid var(--theme-border-color);
2175
+
2176
+ width: 100%;
2177
+ z-index: 10;
2178
+ border-right: none;
2179
+ }
2180
+ .layout-aside-left .layout-aside-content {
2181
+ position: absolute;
2182
+
2183
+ /* Offset by 1px to avoid gap */
2184
+ top: calc(100% - 1px);
2185
+ left: 0;
2186
+ width: 100%;
2187
+
2188
+ /* Offset by 2px to fill screen and compensate for gap */
2189
+ height: calc(var(--scalar-api-reference-document-height) + 2px);
2190
+
2191
+ border-top: 1px solid var(--theme-border-color);
2192
+ display: flex;
2193
+ flex-direction: column;
2194
+ }
2195
+ }
2196
+
2197
+ /** CSS Normalize */
2198
+ .scalar-api-reference {
1970
2199
 
2200
+ }
2201
+ .scalar-api-reference ul,
2202
+ .scalar-api-reference ol {
2203
+ padding: 0;
2204
+ }
2205
+ .scalar-api-reference p {
2206
+ margin: 0;
2207
+ }
2208
+ /** Utilities, how do we deal with them? */
2209
+ .flex {
2210
+ display: flex;
2211
+ }
2212
+ .flex-col {
2213
+ display: flex;
2214
+ min-height: 0;
2215
+ flex-direction: column;
2216
+ }
2217
+ .gap-1 {
2218
+ gap: 12px;
2219
+ }
2220
+ .sr-only {
2221
+ position: absolute;
2222
+ width: 1px;
2223
+ height: 1px;
2224
+ padding: 0;
2225
+ margin: -1px;
2226
+ overflow: hidden;
2227
+ clip: rect(0, 0, 0, 0);
2228
+ border: 0;
2229
+ }
2230
+ /** TODO: Move to components */
2231
+ .codemenu-topbar {
2232
+ background: var(--theme-background-2);
2233
+ border-bottom: 1px solid var(--theme-border-color);
2234
+ padding: 0 7px 0 12px;
2235
+ border-radius: var(--theme-radius) var(--theme-radius) 0 0;
2236
+ }
2237
+ .codemenu {
2238
+ display: flex;
2239
+ position: relative;
2240
+ justify-content: space-between;
2241
+ align-items: center;
2242
+ min-height: 35px;
2243
+ }
2244
+ .codemenu-tabs {
2245
+ display: flex;
2246
+ position: relative;
2247
+ column-gap: 6px;
2248
+ }
2249
+ .codemenu-item {
2250
+ position: relative;
2251
+ display: flex;
2252
+ align-items: center;
2253
+ }
2254
+ .codemenu-item-key {
2255
+ font-size: var(--theme-micro);
2256
+ color: var(--theme-color-3);
2257
+ padding: 6px 4px;
2258
+ cursor: pointer;
2259
+ user-select: none;
2260
+ display: flex;
2261
+ align-items: center;
2262
+ justify-content: center;
2263
+ font-weight: var(--theme-semibold);
2264
+ position: relative;
2265
+ margin-left: -4px;
2266
+ margin-right: -4px;
2267
+ border-radius: var(--theme-radius-lg);
2268
+ text-transform: uppercase;
2269
+ }
2270
+ .codemenu-item-key:hover {
2271
+ background: var(--scalar-api-reference-theme-background-3);
2272
+ }
2273
+ .codemenu-item:first-of-type:last-of-type .codemenu-item-key,
2274
+ .codemenu-item__active .codemenu-item-key {
2275
+ color: var(--theme-color-1);
2276
+ }
2277
+ .codemenu-item:first-of-type:last-of-type:after,
2278
+ .codemenu-item__active:after {
2279
+ content: '';
2280
+ width: 100%;
2281
+ height: 1px;
2282
+ position: absolute;
2283
+ bottom: -4px;
2284
+ background: var(--theme-color-1);
2285
+ }
2286
+ .codemenu-item__disabled {
2287
+ pointer-events: none;
2288
+ }
2289
+ .endpoint {
2290
+ display: flex;
2291
+ white-space: nowrap;
2292
+ cursor: pointer;
2293
+ }
2294
+ .endpoint span:first-of-type {
2295
+ text-transform: uppercase;
2296
+ }
2297
+ .codemenu .endpoint {
2298
+ overflow: hidden;
2299
+ }
2300
+ .endpoint .post {
2301
+ color: var(--theme-post-color);
2302
+ }
2303
+ .endpoint .patch {
2304
+ color: var(--theme-patch-color);
2305
+ }
2306
+ .endpoint .get {
2307
+ color: var(--theme-get-color);
2308
+ }
2309
+ .endpoint .delete {
2310
+ color: var(--theme-delete-color);
2311
+ }
2312
+ .endpoint .put {
2313
+ color: var(--theme-put-color);
2314
+ }
2315
+ .endpoint .post,
2316
+ .endpoint .get,
2317
+ .endpoint .delete,
2318
+ .endpoint .put {
2319
+ white-space: nowrap;
2320
+ }
2321
+ .endpoint span {
2322
+ color: var(--theme-color-2);
2323
+ min-width: 62px;
2324
+ display: inline-block;
2325
+ text-align: right;
2326
+ line-height: 1.55;
2327
+ font-family: var(--theme-font-code);
2328
+ font-size: var(--theme-mini);
2329
+ cursor: pointer;
2330
+ }
2331
+ .languages .example-item-endpoints {
2332
+ background: var(--theme-background-2);
2333
+ width: 100%;
2334
+ border-top: 1px solid var(--theme-border-color);
2335
+ }
2336
+ .endpoint-response p {
2337
+ margin-top: 6px;
2338
+ font-size: var(--theme-small);
2339
+ min-height: auto;
2340
+ line-height: 17px;
2341
+ }
2342
+ .codemenu .endpoint span {
2343
+ text-align: left;
2344
+ min-width: auto;
2345
+ }
2346
+ .endpoint-response {
2347
+ border-top: 1px solid var(--theme-border-color);
2348
+ padding: 12px 0;
2349
+ font-size: var(--theme-small);
2350
+ }
2351
+ .tag-description {
2352
+ margin-top: 12px;
2353
+ }
2354
+ .reference .endpoint-title {
2355
+ display: flex;
2356
+ margin-bottom: 12px;
2357
+ margin-top: 24px;
2358
+ }
2359
+ .copy .title {
2360
+ font-size: var(--theme-heading-4);
2361
+ font-weight: var(--theme-semibold);
2362
+ color: var(--theme-color-1);
2363
+ line-height: 1.45;
2364
+ }
2365
+ .endpoint-response__headers {
2366
+ padding-bottom: 0;
2367
+ }
2368
+ .endpoint-response__headers + .endpoint-response {
2369
+ border-top: none;
2370
+ }
2371
+ /* ----------------------------------------------------- */
2372
+ .reference {
2373
+ position: relative;
2374
+ padding: 0 60px;
2375
+ width: 100%;
2376
+ }
2377
+ .reference:not(:last-of-type) {
2378
+ border-bottom: 1px solid var(--theme-border-color);
2379
+ }
2380
+ .reference .reference-container {
2381
+ position: relative;
2382
+ display: flex;
2383
+ gap: 48px;
2384
+
2385
+ max-width: 1120px;
2386
+ margin: auto;
2387
+ padding: 90px 0;
2388
+ }
2389
+ .reference-container + .reference-container {
2390
+ border-top: 1px solid var(--theme-border-color);
2391
+ }
2392
+ .reference-container .copy,
2393
+ .reference-container .example {
2394
+ flex: 1;
2395
+ min-width: 0;
2396
+ }
2397
+ .response .cm-editor {
2398
+ max-height: calc(50vh - 90px);
2399
+ }
2400
+ .example {
2401
+ padding-top: 48px;
2402
+ top: 12px;
2403
+ height: fit-content;
2404
+ position: sticky;
2405
+ }
2406
+ .copy .tag-description a {
2407
+ color: var(--theme-color-1);
2408
+ text-decoration: underline;
2409
+ }
2410
+ /* ----------------------------------------------------- */
2411
+ /* Responsive styles for narrow reference container (900px) */
2412
+ .references-narrow .reference {
2413
+ padding: 0 30px;
2414
+ }
2415
+ @media screen and (max-width: 1000px) {
2416
+ .references-narrow .reference {
2417
+ padding: 0 24px;
2418
+ }
2419
+ }
2420
+ .references-narrow .reference-container {
2421
+ flex-direction: column;
2422
+ gap: 24px;
2423
+ padding: 48px 0;
2424
+ }
2425
+ .references-narrow .example {
2426
+ padding-top: 0;
2427
+ }
2428
+ .editor-heading h1 {
2429
+ font-size: var(--font-size, var(--theme-heading-2));
2430
+ font-weight: var(--font-weight, var(--theme-bold));
2431
+ /* prettier-ignore */
2432
+ color: var(--theme-color-1);
2433
+ line-height: 1.45;
2434
+ }
2435
+ /** Layout */
2436
+ /* ----------------------------------------------------- */
2437
+ /* Document Layouts */
2438
+ .document {
2439
+ flex: 1;
2440
+ overflow-y: auto;
2441
+ overflow-x: hidden;
2442
+
2443
+ /* Fallback to 100vh if the element height is not specified */
2444
+ --full-height: var(--scalar-api-reference-full-height, 100vh);
2445
+ /* --theme-header-height: 50px; */
2446
+ /* --scalar-api-reference-theme-sidebar-width: 200px; */
2447
+ /* --theme-toc-width: 200px; */
2448
+
2449
+ --document-height: calc(
2450
+ var(--scalar-api-reference-full-height) -
2451
+ var(--scalar-api-reference-theme-header-height)
2452
+ );
2453
+
2454
+ --col-width-1: var(--scalar-api-reference-theme-sidebar-width);
2455
+ --col-width-2: auto;
2456
+ --col-width-3: var(--scalar-api-reference-theme-toc-width);
2457
+
2458
+ display: grid;
2459
+
2460
+ grid-template-rows:
2461
+ var(--scalar-api-reference-theme-header-height)
2462
+ auto
2463
+ auto;
2464
+
2465
+ grid-template-columns:
2466
+ var(--col-width-1)
2467
+ var(--col-width-2)
2468
+ var(--col-width-3);
2469
+
2470
+ grid-template-areas:
2471
+ 'header header header'
2472
+ 'sidebar content aside'
2473
+ 'sidebar footer footer';
2474
+ }
2475
+ .document.hide-aside-left {
2476
+ --col-width-1: 0;
2477
+ }
2478
+ .document.hide-aside-right {
2479
+ --col-width-3: 0;
2480
+ }
2481
+ .document.hide-aside-left .layout-aside-left .layout-aside-content,
2482
+ .document.hide-aside-right .layout-aside-right .layout-aside-content {
2483
+ border-right-color: transparent;
2484
+ border-left-color: transparent;
2485
+ display: none;
2486
+ }
2487
+ .document.footer-below-sidebar {
2488
+ grid-template-areas:
2489
+ 'header header header'
2490
+ 'sidebar content aside'
2491
+ 'footer footer footer';
2492
+ }
2493
+ .layout-header {
2494
+ grid-area: header;
2495
+ position: sticky;
2496
+ top: 0;
2497
+ z-index: 10;
2498
+ }
2499
+ .layout-content {
2500
+ grid-area: content;
2501
+ min-width: 0;
2502
+ background: var(--theme-background-1);
2503
+ }
2504
+ /* Measures the visible viewport of the editor */
2505
+ .layout-content-viewport {
2506
+ position: fixed;
2507
+ left: var(--scalar-api-reference-theme-sidebar-width);
2508
+ right: var(--scalar-api-reference-theme-toc-width);
2509
+ top: calc(
2510
+ var(--scalar-api-reference-app-header-height) +
2511
+ var(--scalar-api-reference-theme-header-height)
2512
+ );
2513
+ bottom: 0;
2514
+ pointer-events: none;
2515
+ }
2516
+ .layout-aside-left {
2517
+ position: relative;
2518
+ grid-area: sidebar;
2519
+ border-right: 1px solid var(--theme-border-color);
2520
+ }
2521
+ .layout-aside-right {
2522
+ position: relative;
2523
+ grid-area: aside;
2524
+ background: var(--theme-background-1);
2525
+ }
2526
+ .layout-aside-content {
2527
+ position: sticky;
2528
+ top: var(--scalar-api-reference-theme-header-height);
2529
+ height: var(--scalar-api-reference-document-height);
2530
+ overflow-y: auto;
2531
+ display: flex;
2532
+ flex-direction: column;
2533
+ }
2534
+ .layout-footer {
2535
+ grid-area: footer;
2536
+ }
2537
+ /* ----------------------------------------------------- */
2538
+ /* Document layout modified for references */
2539
+ .document.layout-swagger-editor {
2540
+ /* Fallback to 100vh if the element height is not specified */
2541
+ --full-height: var(--scalar-api-reference-full-height, 100vh);
2542
+ /* --theme-header-height: 50px; */
2543
+ /* --scalar-api-reference-theme-sidebar-width: 200px; */
2544
+ /* --theme-toc-width: 200px; */
2545
+
2546
+ --document-height: calc(
2547
+ var(--scalar-api-reference-full-height) -
2548
+ var(--scalar-api-reference-theme-header-height)
2549
+ );
2550
+
2551
+ --col-width-1: var(--scalar-api-reference-theme-sidebar-width);
2552
+ --col-width-2: calc(
2553
+ 50% - (var(--scalar-api-reference-theme-sidebar-width) / 2)
2554
+ );
2555
+ --col-width-3: calc(
2556
+ 50% - (var(--scalar-api-reference-theme-sidebar-width) / 2)
2557
+ );
2558
+
2559
+ display: grid;
2560
+
2561
+ grid-template-rows:
2562
+ var(--scalar-api-reference-theme-header-height)
2563
+ auto;
2564
+
2565
+ grid-template-columns:
2566
+ var(--col-width-1)
2567
+ var(--col-width-2)
2568
+ var(--col-width-3);
2569
+
2570
+ grid-template-areas:
2571
+ 'header header header'
2572
+ 'sidebar content aside'
2573
+ 'sidebar content footer';
2574
+ }
2575
+ .document.layout-swagger-editor .layout-content {
2576
+ position: sticky;
2577
+ top: var(--scalar-api-reference-theme-header-height);
2578
+ height: var(--scalar-api-reference-document-height);
2579
+ }
2580
+ .document.preview {
2581
+ --col-width-2: calc(100% - (var(--scalar-api-reference-theme-sidebar-width)));
2582
+ --col-width-3: calc(100% - (var(--scalar-api-reference-theme-sidebar-width)));
2583
+ max-height: 100vh;
2584
+ grid-template-areas:
2585
+ 'header header'
2586
+ 'sidebar aside'
2587
+ 'sidebar footer';
2588
+ }
2589
+ .document.layout-swagger-editor.footer-below-sidebar.preview {
2590
+ grid-template-areas:
2591
+ 'header header'
2592
+ 'sidebar aside'
2593
+ 'footer footer';
2594
+ }
2595
+ .document.layout-swagger-editor.hide-aside-left {
2596
+ --col-width-1: 0;
2597
+ --col-width-2: 50%;
2598
+ --col-width-3: 50%;
2599
+ }
1971
2600
  /* ----------------------------------------------------- */
1972
2601
  /* Responsive styles */
1973
2602
  @media (max-width: 1150px) {