@scalar/api-reference 0.1.28 → 0.1.29

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