boltdocs 1.4.1 → 1.6.0

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 (43) hide show
  1. package/dist/{PackageManagerTabs-XW3AVXVX.mjs → PackageManagerTabs-NVT7G625.mjs} +1 -1
  2. package/dist/{SearchDialog-O3V36MXA.css → SearchDialog-3QICRMWF.css} +145 -5
  3. package/dist/{SearchDialog-FBNGKRPK.mjs → SearchDialog-J3KNRGNO.mjs} +1 -1
  4. package/dist/{chunk-S5G55FBI.mjs → chunk-7SFUJWTB.mjs} +4 -4
  5. package/dist/{chunk-D7YBQG6H.mjs → chunk-HSPDIRTW.mjs} +312 -134
  6. package/dist/client/index.css +145 -5
  7. package/dist/client/index.d.mts +22 -5
  8. package/dist/client/index.d.ts +22 -5
  9. package/dist/client/index.js +725 -459
  10. package/dist/client/index.mjs +182 -61
  11. package/dist/client/ssr.css +145 -5
  12. package/dist/client/ssr.d.mts +1 -1
  13. package/dist/client/ssr.d.ts +1 -1
  14. package/dist/client/ssr.js +544 -395
  15. package/dist/client/ssr.mjs +1 -1
  16. package/dist/{config-BD5ZHz15.d.mts → config-DkZg5aCf.d.mts} +2 -0
  17. package/dist/{config-BD5ZHz15.d.ts → config-DkZg5aCf.d.ts} +2 -0
  18. package/dist/node/index.d.mts +2 -2
  19. package/dist/node/index.d.ts +2 -2
  20. package/dist/node/index.js +5 -1
  21. package/dist/node/index.mjs +5 -1
  22. package/dist/{types-CvrzTbEX.d.mts → types-DGIo1VKD.d.mts} +2 -0
  23. package/dist/{types-CvrzTbEX.d.ts → types-DGIo1VKD.d.ts} +2 -0
  24. package/package.json +1 -1
  25. package/src/client/app/index.tsx +2 -12
  26. package/src/client/app/preload.tsx +3 -1
  27. package/src/client/index.ts +2 -0
  28. package/src/client/theme/components/CodeBlock/CodeBlock.tsx +0 -11
  29. package/src/client/theme/components/mdx/FileTree.tsx +229 -0
  30. package/src/client/theme/components/mdx/Tabs.tsx +1 -4
  31. package/src/client/theme/components/mdx/index.ts +3 -0
  32. package/src/client/theme/components/mdx/mdx-components.css +109 -0
  33. package/src/client/theme/icons/pnpm.tsx +5 -5
  34. package/src/client/theme/styles/markdown.css +1 -5
  35. package/src/client/theme/ui/Link/Link.tsx +156 -18
  36. package/src/client/theme/ui/Link/LinkPreview.tsx +64 -0
  37. package/src/client/theme/ui/Link/link-preview.css +64 -0
  38. package/src/client/types.ts +2 -0
  39. package/src/node/config.ts +2 -0
  40. package/src/node/routes/parser.ts +14 -1
  41. package/dist/CodeBlock-QYIKJMEB.mjs +0 -7
  42. package/dist/chunk-KS5B3O6W.mjs +0 -43
  43. package/src/client/theme/icons/yarn.tsx +0 -16
@@ -3,7 +3,7 @@ import {
3
3
  Deno,
4
4
  NPM,
5
5
  Pnpm
6
- } from "./chunk-S5G55FBI.mjs";
6
+ } from "./chunk-7SFUJWTB.mjs";
7
7
  import {
8
8
  copyToClipboard
9
9
  } from "./chunk-FMTOYQLO.mjs";
@@ -1072,7 +1072,7 @@ a {
1072
1072
  right: 0.75rem;
1073
1073
  z-index: 50;
1074
1074
  padding: 0.4rem;
1075
- background-color: rgba(20, 20, 30, 0.8);
1075
+ background-color: var(--ld-surface);
1076
1076
  backdrop-filter: blur(8px);
1077
1077
  -webkit-backdrop-filter: blur(8px);
1078
1078
  border: 1px solid var(--ld-border-subtle);
@@ -1081,13 +1081,9 @@ a {
1081
1081
  cursor: pointer;
1082
1082
  transition: all 0.2s ease;
1083
1083
  opacity: 0;
1084
- visibility: hidden;
1085
- pointer-events: none;
1086
1084
  }
1087
1085
  .code-block-wrapper:hover .code-block-copy {
1088
1086
  opacity: 1;
1089
- visibility: visible;
1090
- pointer-events: auto;
1091
1087
  }
1092
1088
  .code-block-copy:hover {
1093
1089
  color: var(--ld-text-main);
@@ -1575,6 +1571,97 @@ a {
1575
1571
  .ld-list--arrow .ld-list__icon {
1576
1572
  color: var(--ld-color-primary);
1577
1573
  }
1574
+ .ld-file-tree {
1575
+ margin: 1.5rem 0;
1576
+ padding: 1rem;
1577
+ border-radius: var(--ld-radius-lg);
1578
+ border: 1px solid var(--ld-border-subtle);
1579
+ background: var(--ld-bg-soft);
1580
+ font-family: var(--ld-font-mono);
1581
+ font-size: 0.875rem;
1582
+ overflow-x: auto;
1583
+ }
1584
+ .ld-file-tree__list {
1585
+ list-style: none !important;
1586
+ margin: 0 !important;
1587
+ padding: 0;
1588
+ position: relative;
1589
+ }
1590
+ .ld-file-tree__list:not(.ld-file-tree__list--root) {
1591
+ padding-left: 1.25rem;
1592
+ margin-top: 0.25rem !important;
1593
+ position: relative;
1594
+ }
1595
+ .ld-file-tree__list:not(.ld-file-tree__list--root)::before {
1596
+ content: "";
1597
+ position: absolute;
1598
+ top: 0;
1599
+ bottom: 0;
1600
+ left: 0.45rem;
1601
+ width: 1px;
1602
+ background-color: var(--ld-border-subtle);
1603
+ z-index: 0;
1604
+ }
1605
+ .ld-file-tree__item {
1606
+ position: relative;
1607
+ margin: 0.2rem 0 !important;
1608
+ padding: 0 !important;
1609
+ display: block !important;
1610
+ }
1611
+ .ld-file-tree__label {
1612
+ display: inline-flex;
1613
+ align-items: center;
1614
+ gap: 0.5rem;
1615
+ color: var(--ld-text-muted);
1616
+ user-select: none;
1617
+ border-radius: var(--ld-radius-sm);
1618
+ padding: 0.25rem 0.6rem 0.25rem 0.4rem;
1619
+ transition: all 0.2s ease;
1620
+ position: relative;
1621
+ z-index: 1;
1622
+ }
1623
+ .ld-file-tree__label:hover {
1624
+ background: var(--ld-bg-mute);
1625
+ color: var(--ld-text-main);
1626
+ }
1627
+ .ld-file-tree__label--folder {
1628
+ color: var(--ld-text-main);
1629
+ font-weight: 500;
1630
+ }
1631
+ .ld-file-tree__icon {
1632
+ display: inline-flex;
1633
+ align-items: center;
1634
+ justify-content: center;
1635
+ opacity: 0.8;
1636
+ flex-shrink: 0;
1637
+ }
1638
+ .ld-file-tree__icon-folder {
1639
+ color: var(--ld-color-primary);
1640
+ }
1641
+ .ld-file-tree__name {
1642
+ white-space: nowrap;
1643
+ }
1644
+ .ld-file-tree__icon--chevron {
1645
+ width: 14px;
1646
+ height: 14px;
1647
+ opacity: 0.5;
1648
+ transition: opacity 0.2s ease;
1649
+ display: flex !important;
1650
+ align-items: center;
1651
+ justify-content: center;
1652
+ }
1653
+ .ld-file-tree__label:hover .ld-file-tree__icon--chevron {
1654
+ opacity: 1;
1655
+ }
1656
+ .ld-file-tree__chevron {
1657
+ transition: transform 0.2s ease;
1658
+ }
1659
+ .ld-file-tree__chevron--open {
1660
+ transform: rotate(90deg);
1661
+ }
1662
+ .ld-file-tree__icon--spacer {
1663
+ width: 14px;
1664
+ }
1578
1665
 
1579
1666
  /* src/client/theme/components/PackageManagerTabs/pkg-tabs.css */
1580
1667
  .pkg-tabs-wrapper {
@@ -2078,3 +2165,56 @@ a.not-found-link:hover {
2078
2165
  }
2079
2166
 
2080
2167
  /* src/client/theme/styles.css */
2168
+
2169
+ /* src/client/theme/ui/Link/link-preview.css */
2170
+ .boltdocs-link-preview {
2171
+ position: fixed;
2172
+ z-index: 1000;
2173
+ width: 320px;
2174
+ padding: 1rem;
2175
+ background-color: var(--ld-navbar-bg);
2176
+ backdrop-filter: blur(var(--ld-navbar-blur));
2177
+ -webkit-backdrop-filter: blur(var(--ld-navbar-blur));
2178
+ border: 1px solid var(--ld-border-subtle);
2179
+ border-radius: var(--ld-radius-md);
2180
+ box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
2181
+ pointer-events: none;
2182
+ opacity: 0;
2183
+ transform: translateY(10px) scale(0.95);
2184
+ transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1), transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
2185
+ font-family: var(--ld-font-sans);
2186
+ }
2187
+ .boltdocs-link-preview.is-visible {
2188
+ opacity: 1;
2189
+ transform: translateY(0) scale(1);
2190
+ }
2191
+ .boltdocs-link-preview-title {
2192
+ display: block;
2193
+ font-weight: 600;
2194
+ font-size: 0.95rem;
2195
+ color: var(--ld-text-main);
2196
+ margin-bottom: 0.5rem;
2197
+ line-height: 1.4;
2198
+ }
2199
+ .boltdocs-link-preview-summary {
2200
+ display: block;
2201
+ font-size: 0.85rem;
2202
+ color: var(--ld-text-muted);
2203
+ line-height: 1.5;
2204
+ display: -webkit-box;
2205
+ -webkit-line-clamp: 4;
2206
+ line-clamp: 4;
2207
+ -webkit-box-orient: vertical;
2208
+ overflow: hidden;
2209
+ }
2210
+ [data-theme=dark] .boltdocs-link-preview {
2211
+ background-color: var(--ld-navbar-bg);
2212
+ border-color: var(--ld-border-subtle);
2213
+ box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
2214
+ }
2215
+ [data-theme=dark] .boltdocs-link-preview-title {
2216
+ color: #f8fafc;
2217
+ }
2218
+ [data-theme=dark] .boltdocs-link-preview-summary {
2219
+ color: #94a3b8;
2220
+ }
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Link
3
- } from "./chunk-D7YBQG6H.mjs";
3
+ } from "./chunk-HSPDIRTW.mjs";
4
4
  import "./chunk-FMTOYQLO.mjs";
5
5
 
6
6
  // src/client/theme/ui/SearchDialog/SearchDialog.tsx
@@ -83,10 +83,10 @@ var Pnpm = (props) => /* @__PURE__ */ jsxs2(
83
83
  /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__a40WtxIl8d", fill: "#f9ad00" }) }),
84
84
  /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__h2CN9AEEpe", fill: "#f9ad00" }) }),
85
85
  /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__dqv5133G8", fill: "#f9ad00" }) }),
86
- /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__b1Lv79ypvm", fill: "currentColor" }) }),
87
- /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__hy1IZWwLX", fill: "currentColor" }) }),
88
- /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__akQfjxQes", fill: "currentColor" }) }),
89
- /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__bdSrwE5pk", fill: "currentColor" }) })
86
+ /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__b1Lv79ypvm", fill: "#ffffff" }) }),
87
+ /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__hy1IZWwLX", fill: "#ffffff" }) }),
88
+ /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__akQfjxQes", fill: "#ffffff" }) }),
89
+ /* @__PURE__ */ jsx2("g", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: "#pnpm_dark__bdSrwE5pk", fill: "#ffffff" }) })
90
90
  ] })
91
91
  ]
92
92
  }