@stainless-api/docs-ui 0.1.0-beta.52 → 0.1.0-beta.54

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.
Files changed (137) hide show
  1. package/dist/{breadcrumbs-CI98FNF5.d.ts → breadcrumbs-CysDvz5L.d.ts} +8 -3
  2. package/dist/{breadcrumbs-nSFZO5Gf.js → breadcrumbs-DgN-xdoA.js} +4 -4
  3. package/dist/{breadcrumbs-DEyC9k79.d.ts → breadcrumbs-Dr94uqc3.d.ts} +8 -3
  4. package/dist/{chunk-DRcLgZ1e.js → chunk-CAbhIZi1.js} +2 -2
  5. package/dist/component-CjLDkCLe.js +23 -0
  6. package/dist/{component-generics-aCdP-C69.d.ts → component-generics-DBrwfCEE.d.ts} +2 -2
  7. package/dist/components/MaskedInput.d.ts +3 -3
  8. package/dist/components/MaskedInput.js +1 -1
  9. package/dist/components/breadcrumbs.d.ts +2 -2
  10. package/dist/components/breadcrumbs.js +4 -4
  11. package/dist/components/icons.d.ts +11 -11
  12. package/dist/components/index.d.ts +10 -10
  13. package/dist/components/index.js +12 -12
  14. package/dist/components/method.d.ts +1 -1
  15. package/dist/components/method.js +4 -4
  16. package/dist/components/overview.d.ts +1 -1
  17. package/dist/components/overview.js +5 -5
  18. package/dist/components/primitives.d.ts +1 -1
  19. package/dist/components/primitives.js +2 -2
  20. package/dist/components/properties.d.ts +1 -1
  21. package/dist/components/properties.js +3 -3
  22. package/dist/components/sdk.d.ts +1 -1
  23. package/dist/components/sdk.js +3 -3
  24. package/dist/components/sidebar.d.ts +1 -1
  25. package/dist/components/sidebar.js +5 -5
  26. package/dist/components/snippets.d.ts +2 -2
  27. package/dist/components/snippets.js +3 -3
  28. package/dist/{components-D7M-BwNI.js → components-oq97SH1A.js} +11 -10
  29. package/dist/contexts/component-generics.d.ts +1 -1
  30. package/dist/contexts/component-types.d.ts +10 -10
  31. package/dist/contexts/component.d.ts +13 -13
  32. package/dist/contexts/component.js +20 -20
  33. package/dist/contexts/docs.d.ts +1 -1
  34. package/dist/contexts/index.d.ts +22 -16
  35. package/dist/contexts/index.js +1 -1
  36. package/dist/contexts/markdown.d.ts +1 -1
  37. package/dist/contexts/navigation.d.ts +1 -1
  38. package/dist/contexts/use-components.d.ts +9 -9
  39. package/dist/contexts/use-components.js +1 -1
  40. package/dist/{contexts-p3rRZDlM.js → contexts-CLpvBI91.js} +2 -2
  41. package/dist/{csharp-CDSxfCZE.js → csharp-E3FbT47c.js} +5 -5
  42. package/dist/{docs-SeQmavpx.d.ts → docs-AUJrRqst.d.ts} +2 -2
  43. package/dist/{docs-CmJkvs5K.d.ts → docs-CTY2OmmX.d.ts} +3 -3
  44. package/dist/{go-1c3S5ETL.js → go-DNSFGJle.js} +5 -5
  45. package/dist/{http-2QNWXH9t.js → http-DXRdcllM.js} +6 -6
  46. package/dist/{index-CzDV0BnQ.d.ts → index-B5r4ELg6.d.ts} +53 -53
  47. package/dist/{index-CErkkMkL.d.ts → index-BouuY88M.d.ts} +53 -53
  48. package/dist/{index-BzTFhFWf.d.ts → index-Cr9OL_Cp.d.ts} +9 -9
  49. package/dist/{index-ReQTPmXD.d.ts → index-I43iZfIE.d.ts} +9 -9
  50. package/dist/index.d.ts +18 -18
  51. package/dist/index.js +22 -22
  52. package/dist/{java-BbjF_oUI.js → java-X1yS0K52.js} +5 -5
  53. package/dist/languages/csharp.d.ts +10 -10
  54. package/dist/languages/csharp.js +3 -3
  55. package/dist/languages/go.d.ts +10 -10
  56. package/dist/languages/go.js +3 -3
  57. package/dist/languages/http.d.ts +10 -10
  58. package/dist/languages/http.js +12 -12
  59. package/dist/languages/index.d.ts +10 -10
  60. package/dist/languages/index.js +19 -19
  61. package/dist/languages/java.d.ts +10 -10
  62. package/dist/languages/java.js +3 -3
  63. package/dist/languages/python.d.ts +10 -10
  64. package/dist/languages/python.js +3 -3
  65. package/dist/languages/ruby.d.ts +10 -10
  66. package/dist/languages/ruby.js +3 -3
  67. package/dist/languages/typescript.d.ts +10 -10
  68. package/dist/languages/typescript.js +3 -3
  69. package/dist/languages-Ir9QQoCT.js +26 -0
  70. package/dist/markdown/index.d.ts +3 -3
  71. package/dist/markdown/index.js +23 -23
  72. package/dist/markdown/md.js +39 -1
  73. package/dist/markdown/printer.d.ts +13 -2
  74. package/dist/markdown/printer.js +91 -23
  75. package/dist/markdown/utils.d.ts +20 -2
  76. package/dist/markdown/utils.js +29 -1
  77. package/dist/{markdown-BGCM0OeE.d.ts → markdown-D5IxykeS.d.ts} +2 -2
  78. package/dist/{markdown-CiFjFgOF.d.ts → markdown-V_bNKjle.d.ts} +2 -2
  79. package/dist/{method-B6eAtYl2.d.ts → method-BDSi2Xo0.d.ts} +7 -7
  80. package/dist/{method-CE08mUME.js → method-nEcioXL5.js} +3 -3
  81. package/dist/{method-BLlsdXBF.d.ts → method-yQoZRX6j.d.ts} +7 -7
  82. package/dist/{navigation-BLGsIR9F.d.ts → navigation-Cy3fvjdT.d.ts} +3 -3
  83. package/dist/{navigation-yYOrOKD9.d.ts → navigation-DbIx-eWp.d.ts} +3 -3
  84. package/dist/{overview-S2hUqPXA.js → overview-BQk6WvtS.js} +7 -7
  85. package/dist/{overview-FMVqthvd.d.ts → overview-Bq6DqXr2.d.ts} +6 -6
  86. package/dist/{overview-CTlpyjbv.d.ts → overview-YYFEHa8T.d.ts} +6 -6
  87. package/dist/{primitives-BIWfwN5L.js → primitives-1WQd5NT-.js} +3 -3
  88. package/dist/{primitives-Epom-ge3.d.ts → primitives-BgkRZCRD.d.ts} +9 -9
  89. package/dist/{primitives-Yt5_6f07.d.ts → primitives-CXBFkjk0.d.ts} +9 -9
  90. package/dist/{properties-jlGW3USi.js → properties-BTdEzx5f.js} +2 -2
  91. package/dist/{properties-e7mCw5QL.d.ts → properties-BrJy8EG2.d.ts} +5 -5
  92. package/dist/{python-CHG2jGvC.js → python-DqdvqQ9I.js} +5 -5
  93. package/dist/{routing-Wbb7YECB.js → routing-Dl0FprK1.js} +2 -2
  94. package/dist/routing.d.ts +1 -1
  95. package/dist/routing.js +1 -1
  96. package/dist/{ruby-CSvGbSLe.js → ruby-CHeld1ey.js} +5 -5
  97. package/dist/{sdk-C_2E2iNT.d.ts → sdk-BQEqCwI6.d.ts} +14 -14
  98. package/dist/{sdk-P5DGFIUC.d.ts → sdk-CpRaFmFQ.d.ts} +2 -2
  99. package/dist/{sdk-CSCbbn3O.js → sdk-DEoUlY8I.js} +4 -4
  100. package/dist/{sidebar-CbCLUteD.d.ts → sidebar-CgBa9Ckc.d.ts} +5 -5
  101. package/dist/{sidebar-rOXMRjUW.d.ts → sidebar-DImBt9YH.d.ts} +5 -5
  102. package/dist/{sidebar-CWyvCrJ0.js → sidebar-D_cK7JN_.js} +4 -4
  103. package/dist/{snippets-BQLXEIf6.js → snippets-BiXJx1BL.js} +2 -2
  104. package/dist/{snippets-BK_yl-X-.d.ts → snippets-Cemr-6OZ.d.ts} +8 -8
  105. package/dist/{snippets-C8xhXoaB.d.ts → snippets-DCiTB0N4.d.ts} +8 -8
  106. package/dist/spec.d.ts +1 -1
  107. package/dist/spec.js +2 -2
  108. package/dist/{style-gnVEeXFj.js → style-cJZFOvnF.js} +3 -0
  109. package/dist/style.d.ts +170 -1
  110. package/dist/style.js +1 -1
  111. package/dist/styles/primitives.css +11 -6
  112. package/dist/styles/search.css +51 -32
  113. package/dist/styles.css +124 -38
  114. package/dist/{typescript-DXG9psK3.js → typescript-C--P_L-R.js} +5 -5
  115. package/dist/use-components-DBx5LZk0.js +7 -0
  116. package/dist/{utils-D_1AWSRX.js → utils-C12Fme2N.js} +3 -3
  117. package/dist/utils.d.ts +14 -2
  118. package/dist/utils.js +1 -1
  119. package/package.json +5 -5
  120. package/dist/component-CjONRbeK.js +0 -23
  121. package/dist/index-CebZpsfQ.d.ts +0 -13
  122. package/dist/index-DGag9-aC.d.ts +0 -13
  123. package/dist/languages-BqGqTy14.js +0 -26
  124. package/dist/md-oM2tUaCA.js +0 -41
  125. package/dist/printer-DBw4S_Jn.d.ts +0 -13
  126. package/dist/printer-DVZVkqAr.d.ts +0 -13
  127. package/dist/printer-Y_ONp3hs.js +0 -74
  128. package/dist/routing-Dhmv52Fd.d.ts +0 -54
  129. package/dist/style-D7RO5ymE.d.ts +0 -168
  130. package/dist/use-components-RWQbviGq.js +0 -7
  131. package/dist/utils-CqnL9Fc3.js +0 -31
  132. package/dist/utils-DBenMgxx.d.ts +0 -21
  133. package/dist/utils-DLRASeee.d.ts +0 -21
  134. package/dist/utils-d8paVwKN.d.ts +0 -14
  135. /package/dist/{component-generics-COP53CRn.d.ts → component-generics-XM4u-Dns.d.ts} +0 -0
  136. /package/dist/{properties-DQTdO9Cq.d.ts → properties-sqAOq5FR.d.ts} +0 -0
  137. /package/dist/{routing-CMqh1cTZ.d.ts → routing-CUnVDpU-.d.ts} +0 -0
package/dist/styles.css CHANGED
@@ -1107,6 +1107,68 @@ a.stl-ui-button {
1107
1107
  }
1108
1108
  }
1109
1109
 
1110
+ .stl-ui-steps {
1111
+ padding-left: 0;
1112
+ }
1113
+
1114
+ .stl-ui-steps__step {
1115
+ --step-icon-width: 24px;
1116
+ --step-padding: 12px;
1117
+ list-style: none;
1118
+ position: relative;
1119
+ padding: var(--step-padding);
1120
+ /* Space for the custom marker */
1121
+ padding-left: calc(var(--step-icon-width) + var(--step-padding));
1122
+ margin: 0;
1123
+
1124
+ &::before {
1125
+ content: counter(list-item);
1126
+ position: absolute;
1127
+ left: 0;
1128
+ top: var(--step-padding);
1129
+ width: var(--step-icon-width);
1130
+ height: var(--step-icon-width);
1131
+ border: 1px solid var(--stl-color-border);
1132
+ border-radius: 100%;
1133
+ display: flex;
1134
+ align-items: center;
1135
+ justify-content: center;
1136
+ background: var(--stl-color-bg);
1137
+ z-index: 1;
1138
+ font-size: var(--stl-typography-text-body-xs);
1139
+ font-style: normal;
1140
+ font-weight: 600;
1141
+ line-height: 100%;
1142
+ }
1143
+
1144
+ &::after {
1145
+ content: '';
1146
+ position: absolute;
1147
+ left: calc(var(--step-icon-width) / 2 - 0.5px);
1148
+ top: calc(var(--step-icon-width) + var(--step-padding));
1149
+ bottom: calc(-1 * (var(--step-padding)));
1150
+ width: 1px;
1151
+ background: var(--stl-color-border);
1152
+ }
1153
+
1154
+ &:last-child {
1155
+ padding-bottom: 0;
1156
+
1157
+ /* No line after the last step */
1158
+ &::after {
1159
+ display: none;
1160
+ }
1161
+ }
1162
+ }
1163
+ .stl-ui-steps__step-title {
1164
+ font-weight: 600;
1165
+ }
1166
+
1167
+ .stl-ui-steps__step-content {
1168
+ margin-bottom: 0;
1169
+ margin-top: 4px;
1170
+ }
1171
+
1110
1172
  /* design system variables */
1111
1173
 
1112
1174
  /* components */
@@ -1407,6 +1469,7 @@ a.stl-ui-button {
1407
1469
  p {
1408
1470
  display: block;
1409
1471
  margin: 0 0 1em;
1472
+ line-height: 150%;
1410
1473
 
1411
1474
  &:last-child {
1412
1475
  margin: 0;
@@ -1434,21 +1497,24 @@ a.stl-ui-button {
1434
1497
  .stldocs-root .stldocs-input {
1435
1498
  border: 1px solid var(--stl-color-border);
1436
1499
  background: var(--stl-color-background);
1437
- border-radius: 0.3rem;
1500
+ border-radius: var(--stl-ui-layout-border-radius-sml);
1438
1501
  display: flex;
1439
- gap: 0.5rem;
1440
1502
 
1441
1503
  &:focus-within {
1442
1504
  border-color: var(--stl-color-accent);
1443
1505
  }
1444
1506
 
1507
+ &.stldocs-input-disabled {
1508
+ opacity: 0.5;
1509
+ }
1510
+
1445
1511
  input,
1446
1512
  .stldocs-masked-input-display {
1447
1513
  flex-grow: 1;
1448
1514
  border: none;
1449
1515
  background-color: transparent;
1450
1516
  margin: 0.5rem;
1451
- font-size: 0.85rem;
1517
+ font-size: 1rem;
1452
1518
  letter-spacing: initial;
1453
1519
  white-space: pre;
1454
1520
  contain: content;
@@ -1469,8 +1535,7 @@ a.stl-ui-button {
1469
1535
  }
1470
1536
 
1471
1537
  .stldocs-icon {
1472
- margin-top: auto;
1473
- margin-bottom: auto;
1538
+ margin: auto 0.25rem auto 0.75rem;
1474
1539
  }
1475
1540
  }
1476
1541
 
@@ -1497,7 +1562,9 @@ a.stl-ui-button {
1497
1562
  }
1498
1563
 
1499
1564
  [data-stldocs-listview-selected='true'] > :first-child {
1500
- background-color: var(--stldocs-color-selected);
1565
+ background:
1566
+ linear-gradient(var(--stl-color-ui-background-hover), var(--stl-color-ui-background-hover)),
1567
+ linear-gradient(var(--stl-color-ui-background), var(--stl-color-ui-background));
1501
1568
  border-radius: 0.5rem;
1502
1569
  }
1503
1570
  }
@@ -2666,32 +2733,8 @@ a.stl-ui-button {
2666
2733
  display: flex;
2667
2734
  gap: 1rem;
2668
2735
 
2669
- .stldocs-togglebutton {
2670
- display: flex;
2736
+ .stl-ui-button {
2671
2737
  flex-grow: 1;
2672
- gap: 0.5rem;
2673
- border-radius: 8px;
2674
- padding: 0.4em 0.8em;
2675
- line-height: 1.5;
2676
- justify-content: center;
2677
- font-size: 0.9rem;
2678
- cursor: pointer;
2679
- background-color: transparent;
2680
- border: 1px solid var(--stl-color-border);
2681
-
2682
- &:hover,
2683
- &[data-stldocs-toggle-selected='true'] {
2684
- background-color: var(--stldocs-color-selected);
2685
-
2686
- .stldocs-search-filter-count {
2687
- color: var(--stl-color-inverse-foreground);
2688
- background-color: var(--stl-color-foreground);
2689
- }
2690
- }
2691
-
2692
- .stldocs-icon {
2693
- margin: auto 0;
2694
- }
2695
2738
 
2696
2739
  .stldocs-search-filter-count {
2697
2740
  font-size: 0.75rem;
@@ -2730,6 +2773,9 @@ a.stl-ui-button {
2730
2773
  .stldocs-search-result-resource-path {
2731
2774
  font-family: var(--stl-typography-font-mono);
2732
2775
  color: var(--stl-color-foreground);
2776
+ overflow: hidden;
2777
+ text-overflow: ellipsis;
2778
+ white-space: nowrap;
2733
2779
  }
2734
2780
  }
2735
2781
  }
@@ -2836,6 +2882,9 @@ a.stl-ui-button {
2836
2882
  display: flex;
2837
2883
  gap: 0.5rem;
2838
2884
  font-size: 0.8rem;
2885
+ overflow: hidden;
2886
+ text-overflow: ellipsis;
2887
+ white-space: nowrap;
2839
2888
 
2840
2889
  .stldocs-search-breadcrumb-item {
2841
2890
  color: var(--stl-color-foreground-muted);
@@ -2846,31 +2895,36 @@ a.stl-ui-button {
2846
2895
  margin-bottom: auto;
2847
2896
  }
2848
2897
  }
2898
+
2899
+ .stldocs-search-disabled-state-container {
2900
+ margin: auto;
2901
+ text-align: center;
2902
+ }
2849
2903
  }
2850
2904
 
2851
2905
  .stldocs-root .stldocs-search-modal {
2852
- height: 100%;
2906
+ height: calc(100svh - var(--sl-nav-height));
2853
2907
  width: 100%;
2854
2908
  overflow: hidden;
2855
- margin: 3rem auto;
2856
2909
  display: none;
2857
2910
  padding: 1rem;
2858
2911
  inset: 0;
2859
- max-width: 1024px;
2860
- max-height: 80vh;
2861
2912
  background-color: var(--stl-color-background);
2862
2913
  color: var(--stl-color-foreground);
2863
- border: 1px solid var(--stl-color-border);
2864
- border-radius: 8px;
2914
+ gap: 0.5rem;
2915
+ border: none;
2865
2916
 
2866
2917
  &:popover-open,
2867
2918
  &[data-stldocs-modal-open='true'] {
2868
- display: block;
2919
+ display: flex;
2920
+ flex-direction: column;
2869
2921
  position: fixed;
2922
+ top: var(--sl-nav-height);
2870
2923
  }
2871
2924
 
2872
2925
  .stldocs-search-form {
2873
2926
  height: 100%;
2927
+ width: 100%;
2874
2928
 
2875
2929
  .stldocs-listview {
2876
2930
  margin: 0.8rem 0;
@@ -2878,10 +2932,16 @@ a.stl-ui-button {
2878
2932
  }
2879
2933
  }
2880
2934
 
2935
+ .stldocs-search-modal-close-button {
2936
+ display: flex;
2937
+ justify-content: flex-end;
2938
+ }
2939
+
2881
2940
  &::backdrop {
2882
2941
  background-color: var(--stldocs-color-backdrop-overlay);
2883
2942
  -webkit-backdrop-filter: blur(0.25rem);
2884
2943
  backdrop-filter: blur(0.25rem);
2944
+ top: var(--sl-nav-height);
2885
2945
  }
2886
2946
  }
2887
2947
 
@@ -2891,6 +2951,32 @@ a.stl-ui-button {
2891
2951
  }
2892
2952
  }
2893
2953
 
2954
+ @media (min-width: 50rem) {
2955
+ .stldocs-root {
2956
+ .stldocs-search-modal {
2957
+ height: 100%;
2958
+ max-width: 1024px;
2959
+ max-height: 80vh;
2960
+ margin: 3rem auto;
2961
+ border: 1px solid var(--stl-color-border);
2962
+ border-radius: var(--stl-ui-layout-border-radius-sml);
2963
+
2964
+ .stldocs-search-modal-close-button {
2965
+ display: none;
2966
+ }
2967
+
2968
+ &:popover-open,
2969
+ &[data-stldocs-modal-open='true'] {
2970
+ top: 0;
2971
+ }
2972
+
2973
+ &::backdrop {
2974
+ top: 0;
2975
+ }
2976
+ }
2977
+ }
2978
+ }
2979
+
2894
2980
  @media (max-width: 50rem) {
2895
2981
  .stldocs-root .stldocs-search-modal {
2896
2982
  .stldocs-search-filter-label,
@@ -1,13 +1,13 @@
1
- import { t as __export } from "./chunk-DRcLgZ1e.js";
1
+ import { t as __exportAll } from "./chunk-CAbhIZi1.js";
2
2
  import { a as useLanguage, l as useSpec, r as useDeclaration } from "./docs-CXqi26jB.js";
3
- import { n as useLanguageComponents } from "./contexts-p3rRZDlM.js";
4
- import { t as useComponents } from "./use-components-RWQbviGq.js";
5
- import { t as style_default } from "./style-gnVEeXFj.js";
3
+ import { n as useLanguageComponents } from "./contexts-CLpvBI91.js";
4
+ import { t as useComponents } from "./use-components-DBx5LZk0.js";
5
+ import { t as style_default } from "./style-cJZFOvnF.js";
6
6
  import * as React$1 from "react";
7
7
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
8
8
 
9
9
  //#region src/languages/typescript.tsx
10
- var typescript_exports = /* @__PURE__ */ __export({
10
+ var typescript_exports = /* @__PURE__ */ __exportAll({
11
11
  Declaration: () => Declaration,
12
12
  MethodSignature: () => MethodSignature,
13
13
  Property: () => Property,
@@ -0,0 +1,7 @@
1
+ import { i as useComponents$1 } from "./component-generics-B6Fn47Mz.js";
2
+
3
+ //#region src/contexts/use-components.tsx
4
+ const useComponents = () => useComponents$1();
5
+
6
+ //#endregion
7
+ export { useComponents as t };
@@ -1,8 +1,8 @@
1
- import { t as __export } from "./chunk-DRcLgZ1e.js";
2
- import { f as parseStainlessPath } from "./routing-Wbb7YECB.js";
1
+ import { t as __exportAll } from "./chunk-CAbhIZi1.js";
2
+ import { f as parseStainlessPath } from "./routing-Dl0FprK1.js";
3
3
 
4
4
  //#region src/utils.ts
5
- var utils_exports = /* @__PURE__ */ __export({
5
+ var utils_exports = /* @__PURE__ */ __exportAll({
6
6
  flatResources: () => flatResources,
7
7
  getResourceFromSpec: () => getResourceFromSpec,
8
8
  isResourceEmpty: () => isResourceEmpty
package/dist/utils.d.ts CHANGED
@@ -1,2 +1,14 @@
1
- import { n as getResourceFromSpec, r as isResourceEmpty, t as flatResources } from "./utils-d8paVwKN.js";
2
- export { flatResources, getResourceFromSpec, isResourceEmpty };
1
+ import * as SDKJSON from "@stainless/sdk-json";
2
+
3
+ //#region src/utils.d.ts
4
+ declare namespace utils_d_exports {
5
+ export { flatResources, getResourceFromSpec, isResourceEmpty };
6
+ }
7
+ declare function flatResources(resources: Record<string, SDKJSON.Resource> | undefined, parents: SDKJSON.Resource[]): {
8
+ resource: SDKJSON.Resource;
9
+ parents: SDKJSON.Resource[];
10
+ }[];
11
+ declare function getResourceFromSpec(stainlessPath: string | string[], spec: SDKJSON.Spec): SDKJSON.Resource | null;
12
+ declare function isResourceEmpty(resource: SDKJSON.Resource): boolean;
13
+ //#endregion
14
+ export { flatResources, getResourceFromSpec, isResourceEmpty, utils_d_exports as t };
package/dist/utils.js CHANGED
@@ -1,3 +1,3 @@
1
- import { n as getResourceFromSpec, r as isResourceEmpty, t as flatResources } from "./utils-D_1AWSRX.js";
1
+ import { n as getResourceFromSpec, r as isResourceEmpty, t as flatResources } from "./utils-C12Fme2N.js";
2
2
 
3
3
  export { flatResources, getResourceFromSpec, isResourceEmpty };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@stainless-api/docs-ui",
3
3
  "private": false,
4
- "version": "0.1.0-beta.52",
4
+ "version": "0.1.0-beta.54",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -17,17 +17,17 @@
17
17
  "@markdoc/markdoc": "^0.5.4",
18
18
  "clsx": "^2.1.1",
19
19
  "htmlparser2": "^10.0.0",
20
- "lucide-react": "^0.561.0",
21
- "@stainless-api/ui-primitives": "0.1.0-beta.39"
20
+ "lucide-react": "^0.562.0",
21
+ "@stainless-api/ui-primitives": "0.1.0-beta.40"
22
22
  },
23
23
  "devDependencies": {
24
- "@types/node": "24.10.3",
24
+ "@types/node": "24.10.4",
25
25
  "@types/react": "19.2.7",
26
26
  "@types/react-dom": "^19.2.3",
27
27
  "dotenv": "17.2.3",
28
28
  "react": "^19.2.3",
29
29
  "react-dom": "^19.2.3",
30
- "tsdown": "^0.18.0",
30
+ "tsdown": "^0.19.0-beta.3",
31
31
  "typescript": "5.9.3",
32
32
  "@stainless/eslint-config": "0.1.0-beta.1",
33
33
  "@stainless/sdk-json": "^0.1.0-beta.2"
@@ -1,23 +0,0 @@
1
- import { n as customizeComponents, t as ComponentProvider } from "./component-generics-B6Fn47Mz.js";
2
- import { t as components_exports } from "./components-D7M-BwNI.js";
3
- import { n as languages_exports } from "./languages-BqGqTy14.js";
4
- import React from "react";
5
- import { jsx } from "react/jsx-runtime";
6
-
7
- //#region src/contexts/component.tsx
8
- const defaultContextValue = {
9
- components: components_exports,
10
- language: languages_exports
11
- };
12
- function ComponentProvider$1({ components, language, children }) {
13
- return /* @__PURE__ */ jsx(ComponentProvider, {
14
- value: React.useMemo(() => customizeComponents(defaultContextValue, {
15
- components,
16
- language
17
- }), [components, language]),
18
- children
19
- });
20
- }
21
-
22
- //#endregion
23
- export { defaultContextValue as n, ComponentProvider$1 as t };
@@ -1,13 +0,0 @@
1
- import { a as useComponents, i as useComponentContext, n as ComponentsContextType, r as customizeComponents, t as ComponentProvider } from "./component-generics-COP53CRn.js";
2
- import { t as LanguageComponentDefinition } from "./index-CErkkMkL.js";
3
- import { a as PropertySettingsType, c as useDocs, d as useSettings, f as useSnippet, i as DocsProviderProps, l as useLanguage, n as DocsContextType, o as useContentPanelLayout, p as useSpec, r as DocsProvider, s as useDeclaration, t as ContentPanelLayout, u as useResource } from "./docs-SeQmavpx.js";
4
- import { a as useNavigation, i as NavigationProviderProps, n as NavigationHandler, r as NavigationProvider, t as NavigationContextType } from "./navigation-yYOrOKD9.js";
5
- import { a as useMarkdownContext, i as useHighlight, n as MarkdownProvider, o as useRenderMarkdown, r as MarkdownProviderProps, t as MarkdownContext } from "./markdown-BGCM0OeE.js";
6
-
7
- //#region src/contexts/index.d.ts
8
- declare namespace index_d_exports {
9
- export { ComponentProvider, ComponentsContextType, ContentPanelLayout, DocsContextType, DocsProvider, DocsProviderProps, MarkdownContext, MarkdownProvider, MarkdownProviderProps, NavigationContextType, NavigationHandler, NavigationProvider, NavigationProviderProps, PropertySettingsType, customizeComponents, useComponentContext, useComponents, useContentPanelLayout, useDeclaration, useDocs, useHighlight, useLanguage, useLanguageComponents, useMarkdownContext, useNavigation, useRenderMarkdown, useResource, useSettings, useSnippet, useSpec };
10
- }
11
- declare function useLanguageComponents(): LanguageComponentDefinition;
12
- //#endregion
13
- export { useLanguageComponents as n, index_d_exports as t };
@@ -1,13 +0,0 @@
1
- import { a as useComponents, i as useComponentContext, n as ComponentsContextType, r as customizeComponents, t as ComponentProvider } from "./component-generics-aCdP-C69.js";
2
- import { t as LanguageComponentDefinition } from "./index-CzDV0BnQ.js";
3
- import { a as PropertySettingsType, c as useDocs, d as useSettings, f as useSnippet, i as DocsProviderProps, l as useLanguage, n as DocsContextType, o as useContentPanelLayout, p as useSpec, r as DocsProvider, s as useDeclaration, t as ContentPanelLayout, u as useResource } from "./docs-CmJkvs5K.js";
4
- import { a as useNavigation, i as NavigationProviderProps, n as NavigationHandler, r as NavigationProvider, t as NavigationContextType } from "./navigation-BLGsIR9F.js";
5
- import { a as useMarkdownContext, i as useHighlight, n as MarkdownProvider, o as useRenderMarkdown, r as MarkdownProviderProps, t as MarkdownContext } from "./markdown-CiFjFgOF.js";
6
-
7
- //#region src/contexts/index.d.ts
8
- declare namespace index_d_exports {
9
- export { ComponentProvider, ComponentsContextType, ContentPanelLayout, DocsContextType, DocsProvider, DocsProviderProps, MarkdownContext, MarkdownProvider, MarkdownProviderProps, NavigationContextType, NavigationHandler, NavigationProvider, NavigationProviderProps, PropertySettingsType, customizeComponents, useComponentContext, useComponents, useContentPanelLayout, useDeclaration, useDocs, useHighlight, useLanguage, useLanguageComponents, useMarkdownContext, useNavigation, useRenderMarkdown, useResource, useSettings, useSnippet, useSpec };
10
- }
11
- declare function useLanguageComponents(): LanguageComponentDefinition;
12
- //#endregion
13
- export { useLanguageComponents as n, index_d_exports as t };
@@ -1,26 +0,0 @@
1
- import { t as __export } from "./chunk-DRcLgZ1e.js";
2
- import { o as typescript_exports } from "./typescript-DXG9psK3.js";
3
- import { o as java_exports } from "./java-BbjF_oUI.js";
4
- import { o as go_exports } from "./go-1c3S5ETL.js";
5
- import { o as python_exports } from "./python-CHG2jGvC.js";
6
- import { o as ruby_exports } from "./ruby-CSvGbSLe.js";
7
- import { s as http_exports } from "./http-2QNWXH9t.js";
8
- import { o as csharp_exports } from "./csharp-CDSxfCZE.js";
9
-
10
- //#region src/languages/index.ts
11
- var languages_exports = /* @__PURE__ */ __export({
12
- csharp: () => csharp_exports,
13
- go: () => go_exports,
14
- http: () => http_exports,
15
- java: () => java_exports,
16
- kotlin: () => kotlin,
17
- node: () => node,
18
- python: () => python_exports,
19
- ruby: () => ruby_exports,
20
- typescript: () => typescript_exports
21
- });
22
- const node = typescript_exports;
23
- const kotlin = java_exports;
24
-
25
- //#endregion
26
- export { languages_exports as n, node as r, kotlin as t };
@@ -1,41 +0,0 @@
1
- import Markdoc from "@markdoc/markdoc";
2
-
3
- //#region src/markdown/md.ts
4
- function heading(level, children) {
5
- const content = inline(...typeof children === "string" ? [text(children)] : children);
6
- return new Markdoc.Ast.Node("heading", { level }, [content]);
7
- }
8
- function text(content) {
9
- return new Markdoc.Ast.Node("text", { content });
10
- }
11
- function code(content) {
12
- return new Markdoc.Ast.Node("code", { content });
13
- }
14
- function paragraph(...children) {
15
- const inline$1 = new Markdoc.Ast.Node("inline", {}, children);
16
- return new Markdoc.Ast.Node("paragraph", {}, [inline$1]);
17
- }
18
- function list(...children) {
19
- return new Markdoc.Ast.Node("list", { ordered: false }, children);
20
- }
21
- function item(...children) {
22
- return new Markdoc.Ast.Node("item", {}, children);
23
- }
24
- function strong(...children) {
25
- return new Markdoc.Ast.Node("strong", {}, children);
26
- }
27
- function inline(...children) {
28
- return new Markdoc.Ast.Node("inline", {}, children);
29
- }
30
- function fence(language, content) {
31
- return new Markdoc.Ast.Node("fence", {
32
- language,
33
- content
34
- });
35
- }
36
- function parse(content) {
37
- return Markdoc.parse(content).children;
38
- }
39
-
40
- //#endregion
41
- export { item as a, parse as c, inline as i, strong as l, fence as n, list as o, heading as r, paragraph as s, code as t, text as u };
@@ -1,13 +0,0 @@
1
- import { t as DocsLanguage } from "./routing-CMqh1cTZ.js";
2
- import * as SDKJSON from "@stainless/sdk-json";
3
-
4
- //#region src/markdown/printer.d.ts
5
- declare namespace printer_d_exports {
6
- export { declaration, methodSignature, type, typeName };
7
- }
8
- declare function typeName(language: DocsLanguage, type: SDKJSON.Type): string;
9
- declare function type(language: DocsLanguage, type: SDKJSON.Type): string;
10
- declare function declaration(language: DocsLanguage, decl: SDKJSON.DeclarationNode): string;
11
- declare function methodSignature(language: DocsLanguage, decl: SDKJSON.DeclarationNode): string;
12
- //#endregion
13
- export { typeName as a, type as i, methodSignature as n, printer_d_exports as r, declaration as t };
@@ -1,13 +0,0 @@
1
- import { t as DocsLanguage } from "./routing-Dhmv52Fd.js";
2
- import * as SDKJSON from "@stainless/sdk-json";
3
-
4
- //#region src/markdown/printer.d.ts
5
- declare namespace printer_d_exports {
6
- export { declaration, methodSignature, type, typeName };
7
- }
8
- declare function typeName(language: DocsLanguage, type: SDKJSON.Type): string;
9
- declare function type(language: DocsLanguage, type: SDKJSON.Type): string;
10
- declare function declaration(language: DocsLanguage, decl: SDKJSON.DeclarationNode): string;
11
- declare function methodSignature(language: DocsLanguage, decl: SDKJSON.DeclarationNode): string;
12
- //#endregion
13
- export { typeName as a, type as i, methodSignature as n, printer_d_exports as r, declaration as t };
@@ -1,74 +0,0 @@
1
- import { t as __export } from "./chunk-DRcLgZ1e.js";
2
- import { t as DocsProvider } from "./docs-CXqi26jB.js";
3
- import { n as useLanguageComponents } from "./contexts-p3rRZDlM.js";
4
- import { t as style_default } from "./style-gnVEeXFj.js";
5
- import { t as ComponentProvider } from "./component-CjONRbeK.js";
6
- import "react";
7
- import { jsx } from "react/jsx-runtime";
8
- import { renderToStaticMarkup } from "react-dom/server";
9
-
10
- //#region src/markdown/printer.tsx
11
- var printer_exports = /* @__PURE__ */ __export({
12
- declaration: () => declaration,
13
- methodSignature: () => methodSignature,
14
- type: () => type,
15
- typeName: () => typeName
16
- });
17
- function Providers({ language, children }) {
18
- return /* @__PURE__ */ jsx(DocsProvider, {
19
- spec: null,
20
- language,
21
- children: /* @__PURE__ */ jsx(ComponentProvider, {
22
- components: { SDKReference({ stainlessPath, children: children$1 }) {
23
- if (!stainlessPath) return children$1;
24
- return /* @__PURE__ */ jsx("span", {
25
- className: style_default.TypeReference,
26
- children: children$1
27
- });
28
- } },
29
- children
30
- })
31
- });
32
- }
33
- function RenderType({ type: type$1, full }) {
34
- const { Type, TypeName } = useLanguageComponents();
35
- return full ? /* @__PURE__ */ jsx(Type, { type: type$1 }) : /* @__PURE__ */ jsx(TypeName, { type: type$1 });
36
- }
37
- function typeName(language, type$1) {
38
- return renderToStaticMarkup(/* @__PURE__ */ jsx(Providers, {
39
- language,
40
- children: /* @__PURE__ */ jsx(RenderType, { type: type$1 })
41
- }));
42
- }
43
- function type(language, type$1) {
44
- return renderToStaticMarkup(/* @__PURE__ */ jsx(Providers, {
45
- language,
46
- children: /* @__PURE__ */ jsx(RenderType, {
47
- type: type$1,
48
- full: true
49
- })
50
- }));
51
- }
52
- function RenderDeclaration({ decl }) {
53
- const { Declaration } = useLanguageComponents();
54
- return /* @__PURE__ */ jsx(Declaration, { decl });
55
- }
56
- function declaration(language, decl) {
57
- return renderToStaticMarkup(/* @__PURE__ */ jsx(Providers, {
58
- language,
59
- children: /* @__PURE__ */ jsx(RenderDeclaration, { decl })
60
- }));
61
- }
62
- function RenderMethod({ method }) {
63
- const { MethodSignature } = useLanguageComponents();
64
- return /* @__PURE__ */ jsx(MethodSignature, { decl: method });
65
- }
66
- function methodSignature(language, decl) {
67
- return renderToStaticMarkup(/* @__PURE__ */ jsx(Providers, {
68
- language,
69
- children: /* @__PURE__ */ jsx(RenderMethod, { method: decl })
70
- }));
71
- }
72
-
73
- //#endregion
74
- export { typeName as a, type as i, methodSignature as n, printer_exports as r, declaration as t };
@@ -1,54 +0,0 @@
1
- import * as SDKJSON from "@stainless/sdk-json";
2
-
3
- //#region src/routing.d.ts
4
- declare namespace routing_d_exports {
5
- export { DocsLanguage, LanguageNames, Languages, ParsedStainlessPath, RouteEntry, SpecTreeEntry, SupportedLanguageSyntaxes, expandToElement, findNavigationPath, generateRoute, generateRouteList, getLanguageSnippet, getResource, isSupportedLanguage, parseRoute, parseStainlessPath, scrollToPath, trimStainlessPath, updateHistory, walkTree };
6
- }
7
- declare const Languages: readonly ["http", "node", "python", "go", "typescript", "terraform", "ruby", "java", "kotlin", "csharp", "php"];
8
- declare const SupportedLanguageSyntaxes: string[];
9
- type DocsLanguage = (typeof Languages)[number];
10
- declare const LanguageNames: Record<DocsLanguage, string>;
11
- declare function getLanguageSnippet(language: DocsLanguage): "http.curl" | "node.default" | "go.default" | "python.default" | "terraform.default" | "typescript.default" | "ruby.default" | "java.default" | "kotlin.default" | "csharp.default" | "php.default";
12
- declare function isSupportedLanguage(language: string): language is DocsLanguage;
13
- type ParsedStainlessPath = ReturnType<typeof parseStainlessPath>;
14
- declare function parseStainlessPath(stainlessPath: string): {
15
- resource: string[] | null;
16
- method: string | null;
17
- model: string | null;
18
- routable: string | undefined;
19
- } | null;
20
- declare function trimStainlessPath(stainlessPath: string): string;
21
- declare function getResource(stainlessPath: string): string | undefined;
22
- declare function parseRoute(basePath: string, route: string): {
23
- stainlessPath: string;
24
- language: DocsLanguage;
25
- };
26
- declare function generateRoute(basePath: string, language: string, stainlessPath: string): string | null;
27
- type SpecTreeEntry = {
28
- data: SDKJSON.Method | SDKJSON.Resource | SDKJSON.Model;
29
- path: string[];
30
- };
31
- declare function walkTree(spec: SDKJSON.Spec, includeModels?: boolean): Generator<SpecTreeEntry, void, any>;
32
- type RouteEntry = {
33
- title: string;
34
- kind: SpecTreeEntry['data']['kind'];
35
- language: DocsLanguage;
36
- stainlessPath: string;
37
- slug: string;
38
- };
39
- declare function generateRouteList({
40
- spec,
41
- languages,
42
- excludeLanguages
43
- }: {
44
- spec: SDKJSON.Spec;
45
- languages?: DocsLanguage[];
46
- excludeLanguages?: DocsLanguage[];
47
- }): RouteEntry[];
48
- type ResourceOrMethod = SDKJSON.Resource | SDKJSON.Method;
49
- declare function findNavigationPath(items: ResourceOrMethod[], target: string): string[] | undefined;
50
- declare function expandToElement(el: HTMLElement | null): void;
51
- declare function scrollToPath(stainlessPath: string): void;
52
- declare function updateHistory(basePath: string, language: DocsLanguage, stainlessPath: string): void;
53
- //#endregion
54
- export { routing_d_exports as _, RouteEntry as a, updateHistory as b, expandToElement as c, generateRouteList as d, getLanguageSnippet as f, parseStainlessPath as g, parseRoute as h, ParsedStainlessPath as i, findNavigationPath as l, isSupportedLanguage as m, LanguageNames as n, SpecTreeEntry as o, getResource as p, Languages as r, SupportedLanguageSyntaxes as s, DocsLanguage as t, generateRoute as u, scrollToPath as v, walkTree as x, trimStainlessPath as y };