@stacksjs/bunpress 0.1.21 → 0.2.1

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 (57) hide show
  1. package/dist/bin/cli.d.ts +3 -0
  2. package/dist/bin/cli.js +1 -1
  3. package/dist/bin/commands/doctor.d.ts +1 -0
  4. package/dist/bin/commands/seo.d.ts +19 -0
  5. package/dist/{chunk-qrp18ybj.js → chunk-desvs9bx.js} +1 -1
  6. package/dist/chunk-em1tv2bw.js +38 -0
  7. package/dist/{chunk-kxr6zf7e.js → chunk-kfbpnqaw.js} +1308 -696
  8. package/dist/chunk-qqn901qf.js +393 -0
  9. package/dist/{chunk-qdmkac4z.js → chunk-qzhr4d2q.js} +10 -11
  10. package/dist/chunk-y3z183hg.js +10 -0
  11. package/dist/chunk-yfwm5337.js +2 -0
  12. package/dist/{chunk-m0g9vk1e.js → chunk-zkdm5pr7.js} +401 -194
  13. package/dist/src/build-manifest.d.ts +22 -0
  14. package/dist/src/config.d.ts +12 -0
  15. package/dist/src/data-loader.d.ts +6 -3
  16. package/dist/src/highlighter.d.ts +2 -1
  17. package/dist/src/i18n.d.ts +67 -0
  18. package/dist/src/index.d.ts +2 -0
  19. package/dist/src/index.js +1 -1
  20. package/dist/src/markdown-fences.d.ts +37 -0
  21. package/dist/src/page-meta.d.ts +19 -0
  22. package/dist/src/search-index.d.ts +61 -0
  23. package/dist/src/serve.d.ts +20 -5
  24. package/dist/src/toc.d.ts +20 -2
  25. package/dist/src/types.d.ts +80 -8
  26. package/dist/templates/blocks/alerts/caution.stx +2 -2
  27. package/dist/templates/blocks/alerts/important.stx +2 -2
  28. package/dist/templates/blocks/alerts/note.stx +2 -2
  29. package/dist/templates/blocks/alerts/tip.stx +2 -2
  30. package/dist/templates/blocks/alerts/warning.stx +2 -2
  31. package/dist/templates/blocks/containers/danger.stx +2 -2
  32. package/dist/templates/blocks/containers/details.stx +2 -2
  33. package/dist/templates/blocks/containers/info.stx +2 -2
  34. package/dist/templates/blocks/containers/raw.stx +1 -1
  35. package/dist/templates/blocks/containers/tip.stx +2 -2
  36. package/dist/templates/blocks/containers/warning.stx +2 -2
  37. package/dist/templates/copy-page.stx +81 -0
  38. package/dist/templates/doc-footer.stx +51 -0
  39. package/dist/templates/footer.stx +45 -0
  40. package/dist/templates/hero.stx +9 -2
  41. package/dist/templates/layout-doc.stx +8 -125
  42. package/dist/templates/layout-home.stx +7 -14
  43. package/dist/templates/layout-page.stx +7 -14
  44. package/dist/templates/locale-switcher.stx +115 -0
  45. package/dist/templates/navbar.stx +49 -0
  46. package/dist/templates/page-outline.stx +149 -0
  47. package/dist/templates/page-toc.stx +1 -1
  48. package/dist/templates/search-algolia.stx +85 -0
  49. package/dist/templates/search.stx +661 -0
  50. package/dist/templates/sidebar-section.stx +44 -11
  51. package/dist/templates/sidebar.stx +11 -2
  52. package/dist/themes/vitepress/index.ts +558 -165
  53. package/package.json +16 -7
  54. package/dist/chunk-9cm3e4r4.js +0 -688
  55. package/dist/chunk-mjhqecp5.js +0 -467
  56. package/dist/chunk-wmvgjzgh.js +0 -3
  57. package/dist/chunk-zmxtnx2v.js +0 -8
@@ -14,7 +14,14 @@
14
14
 
15
15
  <style>
16
16
  .sidebar-section {
17
- margin-bottom: 16px;
17
+ margin-bottom: 4px;
18
+ padding-bottom: 4px;
19
+ }
20
+
21
+ .sidebar-section + .sidebar-section {
22
+ border-top: 1px solid var(--bp-c-divider);
23
+ padding-top: 10px;
24
+ margin-top: 10px;
18
25
  }
19
26
 
20
27
  .sidebar-section-toggle {
@@ -22,9 +29,11 @@
22
29
  display: flex;
23
30
  align-items: center;
24
31
  justify-content: space-between;
25
- padding: 8px 24px;
26
- font-size: 14px;
27
- font-weight: 600;
32
+ gap: 8px;
33
+ padding: 6px 20px 6px 22px;
34
+ font-size: 13px;
35
+ font-weight: 700;
36
+ letter-spacing: 0.01em;
28
37
  color: var(--bp-c-text-1);
29
38
  background: transparent;
30
39
  border: none;
@@ -34,20 +43,28 @@
34
43
  text-align: left;
35
44
  }
36
45
 
46
+ .sidebar-section-toggle > span {
47
+ min-width: 0;
48
+ overflow: hidden;
49
+ text-overflow: ellipsis;
50
+ white-space: nowrap;
51
+ }
52
+
37
53
  .sidebar-section-toggle:hover {
38
54
  color: var(--bp-c-brand-1);
39
55
  }
40
56
 
41
57
  .sidebar-section-toggle .chevron {
42
- width: 16px;
43
- height: 16px;
58
+ width: 14px;
59
+ height: 14px;
60
+ color: var(--bp-c-text-3);
44
61
  transition: transform 0.2s ease-in-out;
45
62
  flex-shrink: 0;
46
63
  }
47
64
 
48
65
  .sidebar-items {
49
66
  list-style: none;
50
- margin: 4px 0 0 0;
67
+ margin: 2px 0 0 0;
51
68
  padding: 0;
52
69
  }
53
70
 
@@ -69,25 +86,41 @@
69
86
 
70
87
  .BPSidebarItem-link {
71
88
  display: block;
72
- padding: 6px 24px;
89
+ /* Indented one step past the section title so the hierarchy reads at a
90
+ * glance; the 2px rail is transparent until active, so the label never
91
+ * shifts sideways when you navigate to it. */
92
+ padding: 6px 20px 6px 32px;
73
93
  color: var(--bp-c-text-2);
74
94
  text-decoration: none;
75
95
  font-size: 14px;
76
96
  line-height: 1.5;
77
- transition: color 0.25s;
97
+ transition: color 0.25s, background-color 0.25s;
78
98
  border-left: 2px solid transparent;
79
- margin-left: 0;
99
+ overflow-wrap: anywhere;
80
100
  }
81
101
 
82
102
  .BPSidebarItem-link:hover {
83
103
  color: var(--bp-c-brand-1);
104
+ background-color: var(--bp-c-default-soft, var(--bp-c-gray-soft));
84
105
  }
85
106
 
86
107
  .BPSidebarItem-link.is-active {
87
108
  color: var(--bp-c-brand-1);
88
109
  font-weight: 600;
89
110
  border-left-color: var(--bp-c-brand-1);
90
- padding-left: 22px;
111
+ }
112
+
113
+ /* Larger rows on touch layouts, where the drawer is the primary navigation. */
114
+ @media (max-width: 959px) {
115
+ .BPSidebarItem-link {
116
+ padding-top: 9px;
117
+ padding-bottom: 9px;
118
+ }
119
+
120
+ .sidebar-section-toggle {
121
+ padding-top: 10px;
122
+ padding-bottom: 10px;
123
+ }
91
124
  }
92
125
  </style>
93
126
 
@@ -42,8 +42,17 @@ if (!window.__bpSidebarBound) {
42
42
  }
43
43
 
44
44
  .sidebar-content {
45
- width: var(--bp-sidebar-width, 272px);
46
- margin-left: auto;
45
+ width: 100%;
46
+ }
47
+
48
+ /* Below 960px the sidebar is a drawer: cap it against the viewport so it never
49
+ * covers the whole screen on a small phone, and leave a visible strip of page
50
+ * behind it as an affordance for tapping out. */
51
+ @media (max-width: 959px) {
52
+ .BPSidebar {
53
+ width: min(var(--bp-sidebar-width, 272px), 84vw);
54
+ padding: 16px 0 32px;
55
+ }
47
56
  }
48
57
 
49
58
  /* At 960px+ (tablet), position sidebar normally */