docus 2.1.0 → 3.0.0-beta.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 (274) hide show
  1. package/README.md +6 -4
  2. package/app/router.options.ts +18 -0
  3. package/assets/css/fonts.css +84 -0
  4. package/assets/css/main.css +11 -0
  5. package/assets/css/tailwind.css +282 -0
  6. package/components/app/Container.vue +23 -0
  7. package/components/app/Footer.vue +38 -0
  8. package/components/app/Navbar.vue +26 -0
  9. package/components/app/NavbarLogo.vue +31 -0
  10. package/components/app/Page.vue +7 -0
  11. package/components/app/PoweredByDocus.vue +11 -0
  12. package/components/content/Alert.vue +124 -0
  13. package/components/content/BlockHero.vue +54 -0
  14. package/components/content/ButtonLink.vue +44 -0
  15. package/components/content/Card.vue +46 -0
  16. package/components/content/CardGrid.vue +23 -0
  17. package/components/content/CodeBlock.vue +47 -0
  18. package/components/content/CodeGroup.vue +134 -0
  19. package/components/content/CopyButton.vue +48 -0
  20. package/{dist/runtime/app/components/prose/ProseOl.vue → components/content/List.vue} +2 -2
  21. package/components/content/NeedContribution.vue +23 -0
  22. package/components/content/ReadMore.vue +24 -0
  23. package/components/content/Sandbox.vue +100 -0
  24. package/components/content/TabsHeader.vue +44 -0
  25. package/components/content/Terminal.vue +70 -0
  26. package/components/content/VideoPlayer.vue +113 -0
  27. package/components/docs/DocsAside.vue +19 -0
  28. package/components/docs/DocsAsideTree.vue +101 -0
  29. package/components/docs/DocsHero.vue +39 -0
  30. package/components/docs/DocsPage.vue +22 -0
  31. package/components/docs/DocsPageContent.vue +29 -0
  32. package/components/docs/DocsToc.vue +72 -0
  33. package/components/globals/Icon.vue +24 -0
  34. package/{dist/runtime/app/components/prose/ProseHr.vue → components/globals/Logo.vue} +1 -1
  35. package/components/globals/NuxtImg.vue +43 -0
  36. package/components/globals/SocialIcons.vue +43 -0
  37. package/components/globals/ThemeSelect.vue +35 -0
  38. package/components/icons/IconAlgolia.vue +8 -0
  39. package/components/icons/IconArrowLeft.vue +10 -0
  40. package/components/icons/IconArrowRight.vue +10 -0
  41. package/components/icons/IconBadgeCheck.vue +14 -0
  42. package/components/icons/IconCheck.vue +10 -0
  43. package/components/icons/IconCheckCircle.vue +10 -0
  44. package/components/icons/IconChevronRight.vue +12 -0
  45. package/components/icons/IconClipboardCheck.vue +14 -0
  46. package/components/icons/IconClipboardCopy.vue +14 -0
  47. package/components/icons/IconCodeSandbox.vue +8 -0
  48. package/components/icons/IconCopy.vue +17 -0
  49. package/components/icons/IconDots.vue +10 -0
  50. package/components/icons/IconEdit.vue +18 -0
  51. package/components/icons/IconExclamationCircle.vue +12 -0
  52. package/components/icons/IconExclamationTriangle.vue +10 -0
  53. package/components/icons/IconExternalLink.vue +12 -0
  54. package/components/icons/IconGit.vue +7 -0
  55. package/components/icons/IconGitHub.vue +10 -0
  56. package/components/icons/IconHeart.vue +9 -0
  57. package/components/icons/IconInformationCircle.vue +10 -0
  58. package/components/icons/IconLighthouse.vue +83 -0
  59. package/components/icons/IconLine.vue +10 -0
  60. package/components/icons/IconMarkdown.vue +13 -0
  61. package/components/icons/IconMenu.vue +12 -0
  62. package/components/icons/IconMenuAlt.vue +10 -0
  63. package/components/icons/IconMinus.vue +10 -0
  64. package/components/icons/IconMoon.vue +10 -0
  65. package/components/icons/IconNuxt.vue +14 -0
  66. package/components/icons/IconNuxtContent.vue +20 -0
  67. package/components/icons/IconNuxtLabs.vue +21 -0
  68. package/components/icons/IconPlus.vue +10 -0
  69. package/components/icons/IconPuzzle.vue +8 -0
  70. package/components/icons/IconSSG.vue +7 -0
  71. package/components/icons/IconSearch.vue +12 -0
  72. package/components/icons/IconSun.vue +10 -0
  73. package/components/icons/IconTocBack.vue +21 -0
  74. package/components/icons/IconTocCurrent.vue +21 -0
  75. package/components/icons/IconTocNext.vue +8 -0
  76. package/components/icons/IconTranslate.vue +14 -0
  77. package/components/icons/IconTwitter.vue +8 -0
  78. package/components/icons/IconVite.vue +30 -0
  79. package/components/icons/IconVue.vue +6 -0
  80. package/components/icons/IconVueTelescope.vue +11 -0
  81. package/components/icons/IconWindi.vue +17 -0
  82. package/components/icons/IconX.vue +12 -0
  83. package/components/icons/IconXCircle.vue +10 -0
  84. package/components/icons/IconZap.vue +8 -0
  85. package/components/prose/ProseA.vue +66 -0
  86. package/components/prose/ProseBlockquote.vue +21 -0
  87. package/components/prose/ProseCode.vue +68 -0
  88. package/components/prose/ProseCodeInline.vue +38 -0
  89. package/components/prose/ProseEm.vue +11 -0
  90. package/components/prose/ProseH1.vue +22 -0
  91. package/components/prose/ProseH2.vue +22 -0
  92. package/components/prose/ProseH3.vue +24 -0
  93. package/components/prose/ProseH4.vue +24 -0
  94. package/components/prose/ProseHr.vue +13 -0
  95. package/components/prose/ProseImg.vue +32 -0
  96. package/components/prose/ProseLi.vue +31 -0
  97. package/components/prose/ProseOl.vue +16 -0
  98. package/components/prose/ProseP.vue +14 -0
  99. package/components/prose/ProseStrong.vue +14 -0
  100. package/components/prose/ProseTable.vue +13 -0
  101. package/{dist/runtime/app/components → components}/prose/ProseTbody.vue +0 -0
  102. package/components/prose/ProseTd.vue +11 -0
  103. package/components/prose/ProseTh.vue +11 -0
  104. package/components/prose/ProseThead.vue +11 -0
  105. package/components/prose/ProseTr.vue +11 -0
  106. package/components/prose/ProseUl.vue +15 -0
  107. package/composables/useContent.ts +155 -0
  108. package/composables/useMenu.ts +20 -0
  109. package/composables/useScrollToHeading.ts +35 -0
  110. package/composables/useScrollspy.ts +45 -0
  111. package/composables/useTheme.ts +10 -0
  112. package/layouts/default.vue +27 -0
  113. package/layouts/page.vue +11 -0
  114. package/nuxt.config.ts +151 -0
  115. package/package.json +46 -83
  116. package/pages/[...slug].vue +24 -0
  117. package/public/android-chrome-192x192.png +0 -0
  118. package/public/android-chrome-512x512.png +0 -0
  119. package/public/apple-touch-icon.png +0 -0
  120. package/public/favicon-16x16.png +0 -0
  121. package/public/favicon-32x32.png +0 -0
  122. package/public/favicon.ico +0 -0
  123. package/public/site.webmanifest +1 -0
  124. package/LICENSE +0 -21
  125. package/dist/index.cjs +0 -549
  126. package/dist/index.d.ts +0 -25
  127. package/dist/index.mjs +0 -523
  128. package/dist/runtime/app/components/DocusContent.vue +0 -215
  129. package/dist/runtime/app/components/DocusContent.vue.d.ts +0 -25
  130. package/dist/runtime/app/components/Error.vue +0 -19
  131. package/dist/runtime/app/components/Error.vue.d.ts +0 -9
  132. package/dist/runtime/app/components/Markdown.vue +0 -56
  133. package/dist/runtime/app/components/Markdown.vue.d.ts +0 -25
  134. package/dist/runtime/app/components/Page.vue +0 -29
  135. package/dist/runtime/app/components/Page.vue.d.ts +0 -2
  136. package/dist/runtime/app/components/Props.vue +0 -130
  137. package/dist/runtime/app/components/Props.vue.d.ts +0 -80
  138. package/dist/runtime/app/components/prose/ProseA.vue +0 -41
  139. package/dist/runtime/app/components/prose/ProseA.vue.d.ts +0 -23
  140. package/dist/runtime/app/components/prose/ProseBlockquote.vue +0 -5
  141. package/dist/runtime/app/components/prose/ProseCode.vue +0 -5
  142. package/dist/runtime/app/components/prose/ProseCodeInline.vue +0 -5
  143. package/dist/runtime/app/components/prose/ProseEm.vue +0 -5
  144. package/dist/runtime/app/components/prose/ProseH1.vue +0 -3
  145. package/dist/runtime/app/components/prose/ProseH2.vue +0 -3
  146. package/dist/runtime/app/components/prose/ProseH3.vue +0 -3
  147. package/dist/runtime/app/components/prose/ProseH4.vue +0 -3
  148. package/dist/runtime/app/components/prose/ProseH5.vue +0 -3
  149. package/dist/runtime/app/components/prose/ProseH6.vue +0 -3
  150. package/dist/runtime/app/components/prose/ProseImg.vue +0 -32
  151. package/dist/runtime/app/components/prose/ProseImg.vue.d.ts +0 -21
  152. package/dist/runtime/app/components/prose/ProseLi.vue +0 -3
  153. package/dist/runtime/app/components/prose/ProseParagraph.vue +0 -3
  154. package/dist/runtime/app/components/prose/ProseStrong.vue +0 -5
  155. package/dist/runtime/app/components/prose/ProseTable.vue +0 -5
  156. package/dist/runtime/app/components/prose/ProseTd.vue +0 -5
  157. package/dist/runtime/app/components/prose/ProseTh.vue +0 -5
  158. package/dist/runtime/app/components/prose/ProseThead.vue +0 -5
  159. package/dist/runtime/app/components/prose/ProseTr.vue +0 -5
  160. package/dist/runtime/app/components/prose/ProseUl.vue +0 -5
  161. package/dist/runtime/app/composables/helpers.d.ts +0 -4
  162. package/dist/runtime/app/composables/helpers.js +0 -66
  163. package/dist/runtime/app/composables/helpers.mjs +0 -40
  164. package/dist/runtime/app/composables/index.d.ts +0 -90
  165. package/dist/runtime/app/composables/index.js +0 -108
  166. package/dist/runtime/app/composables/index.mjs +0 -63
  167. package/dist/runtime/app/composables/navigation.d.ts +0 -37
  168. package/dist/runtime/app/composables/navigation.js +0 -227
  169. package/dist/runtime/app/composables/navigation.mjs +0 -148
  170. package/dist/runtime/app/composables/store.d.ts +0 -7
  171. package/dist/runtime/app/composables/store.js +0 -52
  172. package/dist/runtime/app/composables/store.mjs +0 -35
  173. package/dist/runtime/app/composables/style.d.ts +0 -11
  174. package/dist/runtime/app/composables/style.js +0 -117
  175. package/dist/runtime/app/composables/style.mjs +0 -71
  176. package/dist/runtime/app/composables/theme-colors.d.ts +0 -30
  177. package/dist/runtime/app/composables/theme-colors.js +0 -80
  178. package/dist/runtime/app/composables/theme-colors.mjs +0 -48
  179. package/dist/runtime/app/composables/websocket.d.ts +0 -3
  180. package/dist/runtime/app/composables/websocket.js +0 -79
  181. package/dist/runtime/app/composables/websocket.mjs +0 -63
  182. package/dist/runtime/app/layouts/default.vue +0 -5
  183. package/dist/runtime/app/layouts/error.vue +0 -33
  184. package/dist/runtime/app/layouts/error.vue.d.ts +0 -21
  185. package/dist/runtime/app/pages/_.vue +0 -222
  186. package/dist/runtime/app/pages/_.vue.d.ts +0 -2
  187. package/dist/runtime/context.d.ts +0 -1
  188. package/dist/runtime/context.js +0 -17
  189. package/dist/runtime/context.mjs +0 -5
  190. package/dist/runtime/database/Query.d.ts +0 -18
  191. package/dist/runtime/database/Query.js +0 -68
  192. package/dist/runtime/database/Query.mjs +0 -49
  193. package/dist/runtime/database/index.d.ts +0 -4
  194. package/dist/runtime/database/index.js +0 -45
  195. package/dist/runtime/database/index.mjs +0 -25
  196. package/dist/runtime/database/providers/local/Query.d.ts +0 -14
  197. package/dist/runtime/database/providers/local/Query.js +0 -85
  198. package/dist/runtime/database/providers/local/Query.mjs +0 -60
  199. package/dist/runtime/database/providers/local/index.d.ts +0 -3
  200. package/dist/runtime/database/providers/local/index.js +0 -63
  201. package/dist/runtime/database/providers/local/index.mjs +0 -39
  202. package/dist/runtime/database/providers/local/operations.d.ts +0 -2
  203. package/dist/runtime/database/providers/local/operations.js +0 -83
  204. package/dist/runtime/database/providers/local/operations.mjs +0 -53
  205. package/dist/runtime/database/providers/local/utils.d.ts +0 -8
  206. package/dist/runtime/database/providers/local/utils.js +0 -28
  207. package/dist/runtime/database/providers/local/utils.mjs +0 -17
  208. package/dist/runtime/index.d.ts +0 -3
  209. package/dist/runtime/index.js +0 -44
  210. package/dist/runtime/index.mjs +0 -3
  211. package/dist/runtime/navigation.d.ts +0 -4
  212. package/dist/runtime/navigation.js +0 -176
  213. package/dist/runtime/navigation.mjs +0 -137
  214. package/dist/runtime/server/api/get.d.ts +0 -10
  215. package/dist/runtime/server/api/get.js +0 -24
  216. package/dist/runtime/server/api/get.mjs +0 -13
  217. package/dist/runtime/server/api/list.d.ts +0 -9
  218. package/dist/runtime/server/api/list.js +0 -34
  219. package/dist/runtime/server/api/list.mjs +0 -18
  220. package/dist/runtime/server/api/navigation.d.ts +0 -7
  221. package/dist/runtime/server/api/navigation.js +0 -20
  222. package/dist/runtime/server/api/navigation.mjs +0 -10
  223. package/dist/runtime/server/api/preview.d.ts +0 -3
  224. package/dist/runtime/server/api/preview.js +0 -54
  225. package/dist/runtime/server/api/preview.mjs +0 -31
  226. package/dist/runtime/server/api/reload.d.ts +0 -6
  227. package/dist/runtime/server/api/reload.js +0 -27
  228. package/dist/runtime/server/api/reload.mjs +0 -11
  229. package/dist/runtime/server/api/search.d.ts +0 -6
  230. package/dist/runtime/server/api/search.js +0 -27
  231. package/dist/runtime/server/api/search.mjs +0 -13
  232. package/dist/runtime/server/content.d.ts +0 -46
  233. package/dist/runtime/server/content.js +0 -175
  234. package/dist/runtime/server/content.mjs +0 -114
  235. package/dist/runtime/server/socket.d.ts +0 -9
  236. package/dist/runtime/server/socket.js +0 -33
  237. package/dist/runtime/server/socket.mjs +0 -20
  238. package/dist/runtime/server/utils/cache.d.ts +0 -19
  239. package/dist/runtime/server/utils/cache.js +0 -110
  240. package/dist/runtime/server/utils/cache.mjs +0 -75
  241. package/dist/runtime/server/utils/index.d.ts +0 -4
  242. package/dist/runtime/server/utils/index.js +0 -18
  243. package/dist/runtime/server/utils/index.mjs +0 -8
  244. package/dist/runtime/transformers/index.d.ts +0 -1
  245. package/dist/runtime/transformers/index.js +0 -26
  246. package/dist/runtime/transformers/index.mjs +0 -11
  247. package/dist/runtime/transformers/json.d.ts +0 -3
  248. package/dist/runtime/transformers/json.js +0 -15
  249. package/dist/runtime/transformers/json.mjs +0 -5
  250. package/dist/runtime/transformers/markdown/index.d.ts +0 -8
  251. package/dist/runtime/transformers/markdown/index.js +0 -25
  252. package/dist/runtime/transformers/markdown/index.mjs +0 -16
  253. package/dist/runtime/transformers/utils/index.d.ts +0 -1
  254. package/dist/runtime/transformers/utils/index.js +0 -18
  255. package/dist/runtime/transformers/utils/index.mjs +0 -1
  256. package/dist/runtime/transformers/utils/path.d.ts +0 -26
  257. package/dist/runtime/transformers/utils/path.js +0 -88
  258. package/dist/runtime/transformers/utils/path.mjs +0 -56
  259. package/dist/runtime/utils/index.d.ts +0 -1
  260. package/dist/runtime/utils/index.js +0 -18
  261. package/dist/runtime/utils/index.mjs +0 -1
  262. package/dist/runtime/utils/log.d.ts +0 -1
  263. package/dist/runtime/utils/log.js +0 -14
  264. package/dist/runtime/utils/log.mjs +0 -2
  265. package/dist/runtime/utils/object.d.ts +0 -9
  266. package/dist/runtime/utils/object.js +0 -22
  267. package/dist/runtime/utils/object.mjs +0 -4
  268. package/dist/templates/content.mjs +0 -50
  269. package/dist/templates/docus.mjs +0 -13
  270. package/dist/templates/hot.mjs +0 -16
  271. package/dist/templates/i18n.mjs +0 -23
  272. package/dist/templates/options.mjs +0 -46
  273. package/shims.d.ts +0 -24
  274. package/types.d.ts +0 -397
package/README.md CHANGED
@@ -1,9 +1,11 @@
1
1
  <h1>
2
- <img src="./.github/banner.png" >
3
- </h1>
2
+ <img src="https://user-images.githubusercontent.com/904724/105075054-872fac80-5a89-11eb-8aab-46dd254ad986.png">
3
+ </h1>
4
4
 
5
- <p>
5
+ <p>
6
6
  <a href="https://www.npmjs.com/package/docus"><img src="https://badgen.net/npm/dm/docus" alt="Downloads"></a>
7
7
  <a href="https://www.npmjs.com/package/docus"><img src="https://badgen.net/npm/v/docus" alt="Version"></a>
8
8
  <a href="https://www.npmjs.com/package/docus"><img src="https://badgen.net/npm/license/docus" alt="License"></a>
9
- </p>
9
+ </p>
10
+
11
+ Docus is the fastest way to create documentations websites with [**Nuxt3**](https://v3.nuxtjs.org).
@@ -0,0 +1,18 @@
1
+ import type { RouterConfig } from '@nuxt/schema'
2
+
3
+ // https://router.vuejs.org/api/#routeroptions
4
+ export default <RouterConfig>{
5
+ scrollBehavior: (to) => {
6
+ if (to.params?.smooth) {
7
+ return {
8
+ el: to.params?.smooth,
9
+ behavior: 'smooth',
10
+ }
11
+ }
12
+
13
+ // Scroll to top of window
14
+ window.scrollTo({
15
+ top: 0,
16
+ })
17
+ },
18
+ }
@@ -0,0 +1,84 @@
1
+ /* `font-light` */
2
+ @font-face {
3
+ font-family: "RoobertPRO";
4
+ src: url("/fonts/RoobertPRO-Light.woff2") format("woff2"),
5
+ url("/fonts/RoobertPRO-Light.woff") format("woff");
6
+ font-weight: 300;
7
+ }
8
+ @font-face {
9
+ font-family: "RoobertPRO";
10
+ src: url("/fonts/RoobertPRO-LightItalic.woff2") format("woff2"),
11
+ url("/fonts/RoobertPRO-LightItalic.woff") format("woff");
12
+ font-weight: 300;
13
+ font-style: italic;
14
+ }
15
+ /* `font-normal` */
16
+ @font-face {
17
+ font-family: "RoobertPRO";
18
+ src: url("/fonts/RoobertPRO-Regular.woff2") format("woff2"),
19
+ url("/fonts/RoobertPRO-Regular.woff") format("woff");
20
+ font-weight: 400;
21
+ }
22
+ @font-face {
23
+ font-family: "RoobertPRO";
24
+ src: url("/fonts/RoobertPRO-RegularItalic.woff2") format("woff2"),
25
+ url("/fonts/RoobertPRO-RegularItalic.woff") format("woff");
26
+ font-weight: 400;
27
+ font-style: italic;
28
+ }
29
+ /* `font-medium */
30
+ @font-face {
31
+ font-family: "RoobertPRO";
32
+ src: url("/fonts/RoobertPRO-Medium.woff2") format("woff2"),
33
+ url("/fonts/RoobertPRO-Medium.woff") format("woff");
34
+ font-weight: 500;
35
+ }
36
+ @font-face {
37
+ font-family: "RoobertPRO";
38
+ src: url("/fonts/RoobertPRO-MediumItalic.woff2") format("woff2"),
39
+ url("/fonts/RoobertPRO-MediumItalic.woff") format("woff");
40
+ font-weight: 500;
41
+ font-style: italic;
42
+ }
43
+ /* `font-semibold` */
44
+ @font-face {
45
+ font-family: "RoobertPRO";
46
+ src: url("/fonts/RoobertPRO-SemiBold.woff2") format("woff2"),
47
+ url("/fonts/RoobertPRO-SemiBold.woff") format("woff");
48
+ font-weight: 600;
49
+ }
50
+ @font-face {
51
+ font-family: "RoobertPRO";
52
+ src: url("/fonts/RoobertPRO-SemiBoldItalic.woff2") format("woff2"),
53
+ url("/fonts/RoobertPRO-SemiBoldItalic.woff") format("woff");
54
+ font-weight: 600;
55
+ font-style: italic;
56
+ }
57
+ /* `font-bold` */
58
+ @font-face {
59
+ font-family: "RoobertPRO";
60
+ src: url("/fonts/RoobertPRO-Bold.woff2") format("woff2"),
61
+ url("/fonts/RoobertPRO-Bold.woff") format("woff");
62
+ font-weight: 700;
63
+ }
64
+ @font-face {
65
+ font-family: "RoobertPRO";
66
+ src: url("/fonts/RoobertPRO-BoldItalic.woff2") format("woff2"),
67
+ url("/fonts/RoobertPRO-BoldItalic.woff") format("woff");
68
+ font-weight: 700;
69
+ font-style: italic;
70
+ }
71
+ /* `font-extrabold` */
72
+ @font-face {
73
+ font-family: "RoobertPRO";
74
+ src: url("/fonts/RoobertPRO-Heavy.woff2") format("woff2"),
75
+ url("/fonts/RoobertPRO-Heavy.woff") format("woff");
76
+ font-weight: 800;
77
+ }
78
+ @font-face {
79
+ font-family: "RoobertPRO";
80
+ src: url("/fonts/RoobertPRO-HeavyItalic.woff2") format("woff2"),
81
+ url("/fonts/RoobertPRO-HeavyItalic.woff") format("woff");
82
+ font-weight: 800;
83
+ font-style: italic;
84
+ }
@@ -0,0 +1,11 @@
1
+ html {
2
+ @apply text-primary bg-white overflow-y-scroll;
3
+
4
+ &.dark {
5
+ @apply bg-gray-900;
6
+ }
7
+ }
8
+
9
+ body {
10
+ @apply antialiased font-sans text-gray-700 dark:text-gray-200;
11
+ }
@@ -0,0 +1,282 @@
1
+ @tailwind base;
2
+ @tailwind components;
3
+ @tailwind utilities;
4
+
5
+ @layer components {
6
+ /* Base */
7
+ .text-primary {
8
+ @apply text-gray-900 dark:text-gray-50;
9
+ }
10
+
11
+ .text-secondary {
12
+ @apply text-gray-500 dark:text-gray-400;
13
+ }
14
+
15
+ .text-secondary-active {
16
+ @apply text-primary-500 dark:text-primary-400;
17
+ }
18
+
19
+ .text-secondary-hover {
20
+ @apply hover:text-primary-500 hover:dark:text-primary-400;
21
+ }
22
+
23
+ .text-secondary-group-hover {
24
+ @apply group-hover:dark:text-primary-400 group-hover:text-primary-500;
25
+ }
26
+
27
+ .transition-base {
28
+ @apply transition-colors transition-opacity duration-100 ease-in-out;
29
+ }
30
+
31
+ /* Icons */
32
+ .icon-base {
33
+ @apply transition-base text-secondary text-secondary-hover;
34
+ }
35
+
36
+ /* ProseA */
37
+ .d-prose-a-text {
38
+ @apply text-primary-500;
39
+ }
40
+
41
+ .d-prose-a-border {
42
+ @apply border-b border-transparent;
43
+ }
44
+
45
+ .d-prose-a-border-hover {
46
+ @apply border-b border-primary-500;
47
+ }
48
+
49
+ .d-prose-a-headline-border {
50
+ @apply border-b border-dashed border-gray-900 dark:border-gray-100;
51
+ }
52
+
53
+ /* ProseBlockquote */
54
+ .d-prose-blockquote-border {
55
+ @apply border-l-2 border-gray-200 dark:border-gray-700;
56
+ }
57
+
58
+ .d-prose-blockquote-text {
59
+ @apply text-secondary;
60
+ }
61
+
62
+ /** UNCONVERTED **/
63
+ .d-body-bg {
64
+ @apply bg-white dark:bg-gray-900;
65
+ }
66
+
67
+ .d-body-text-color {
68
+ @apply text-gray-900 dark:text-gray-50;
69
+ }
70
+
71
+ .d-secondary-bg {
72
+ @apply bg-gray-500 dark:bg-gray-400;
73
+ }
74
+
75
+ .d-secondary-text {
76
+ @apply text-gray-500 dark:text-gray-400;
77
+ }
78
+
79
+ .d-secondary-text-hover {
80
+ @apply text-primary-500 dark:text-primary-400;
81
+ }
82
+
83
+ .d-tertiary-text {
84
+ @apply text-gray-400 dark:text-gray-500;
85
+ }
86
+
87
+ .d-border-tertiary {
88
+ @apply border-gray-400 dark:border-gray-500;
89
+ }
90
+
91
+ .d-primary-text-hover {
92
+ @apply text-gray-600 dark:text-gray-400;
93
+ }
94
+
95
+ .d-secondary-text-active {
96
+ @apply text-gray-900 dark:text-gray-300;
97
+ }
98
+
99
+ .d-prose-code-inline-bg {
100
+ background-color: #282c34;
101
+ }
102
+
103
+ .d-prose-code-bg {
104
+ background-color: #282c34;
105
+ }
106
+
107
+ .d-prose-thead-border {
108
+ @apply border-b border-gray-200 dark:border-gray-700;
109
+ }
110
+
111
+ .d-prose-tr-border {
112
+ @apply border-b border-gray-100 dark:border-gray-800;
113
+ }
114
+
115
+ .d-prose-blockquote-border {
116
+ @apply border-l-2 border-gray-200 dark:border-gray-700;
117
+ }
118
+
119
+ .d-prose-blockquote-text {
120
+ @apply d-secondary-text;
121
+ }
122
+
123
+ .d-prose-a-text {
124
+ @apply text-primary-500;
125
+ }
126
+
127
+ .d-prose-a-border {
128
+ @apply border-b border-transparent;
129
+ }
130
+
131
+ .d-prose-a-border-hover {
132
+ @apply border-b border-primary-500;
133
+ }
134
+
135
+ .d-prose-a-headline-border {
136
+ @apply border-b border-dashed border-gray-900 dark:border-gray-100;
137
+ }
138
+
139
+ .d-text-primary {
140
+ @apply text-primary-500 dark:text-primary-400;
141
+ }
142
+
143
+ .d-border-primary {
144
+ @apply border-primary-500 dark:border-primary-400;
145
+ }
146
+
147
+ .d-bg-primary {
148
+ @apply bg-primary-500 dark:bg-primary-400;
149
+ }
150
+
151
+ .d-page-mobile-toc-bg {
152
+ @apply bg-white bg-opacity-80 dark:bg-gray-900 dark:bg-opacity-80;
153
+ }
154
+
155
+ .d-aside-header-bg {
156
+ @apply bg-gray-50 dark:bg-gray-800;
157
+ }
158
+
159
+ .d-active-aside-navigation-item-bg {
160
+ @apply bg-primary-50 dark:bg-primary-900;
161
+ }
162
+
163
+ .d-active-aside-navigation-item-text {
164
+ @apply text-primary-500 dark:text-primary-400 ;
165
+ }
166
+
167
+ .d-code-group-header-bg {
168
+ @apply bg-gray-200 dark:bg-gray-700;
169
+ }
170
+
171
+ .d-code-group-tab {
172
+ @apply bg-gray-300 dark:bg-gray-600;
173
+ }
174
+
175
+ .d-prose-code-inline-in-heading-border-hover {
176
+ @apply border-gray-500 dark:border-gray-200;
177
+ }
178
+
179
+ .d-prose-hr-border {
180
+ @apply border-t border-gray-100 dark:border-gray-800;
181
+ }
182
+
183
+ .d-prose-ul-li-bullet {
184
+ @apply d-secondary-bg;
185
+ }
186
+
187
+ .d-text-icon {
188
+ @apply d-secondary-text hover:d-secondary-text-hover;
189
+ }
190
+
191
+ .d-icon {
192
+ @apply d-text-icon focus:outline-none;
193
+ }
194
+
195
+ .light-img {
196
+ @apply dark:hidden;
197
+ }
198
+
199
+ .dark-img {
200
+ @apply light:hidden;
201
+ }
202
+
203
+ .d-max-w-container {
204
+ @apply max-w-7xl;
205
+ }
206
+
207
+ .d-px-container {
208
+ @apply px-4 sm:px-6;
209
+ }
210
+
211
+ .d-container {
212
+ @apply d-max-w-container mx-auto;
213
+ }
214
+
215
+ .d-container-content {
216
+ @apply d-container d-px-container;
217
+ }
218
+
219
+ .d-blur-header {
220
+ @apply blur-12;
221
+ }
222
+
223
+ .d-bg-header {
224
+ @apply bg-white bg-opacity-80 dark:bg-gray-900 dark:bg-opacity-80;
225
+ }
226
+
227
+ .d-border {
228
+ @apply light:border-gray-200 light:border-opacity-50 dark:border-gray-800;
229
+ }
230
+
231
+ .d-border-hover {
232
+ @apply border-primary-200 dark:border-gray-700;
233
+ }
234
+
235
+ .d-border-header {
236
+ @apply border-b border-gray-200 dark:border-gray-800 border-opacity-50;
237
+ }
238
+
239
+ .d-header {
240
+ @apply sticky w-full top-0 z-50 d-bg-header d-border-header d-blur-header h-header;
241
+ }
242
+
243
+ .d-header-title {
244
+ @apply text-2xl font-bold tracking-tighter text-gray-900 dark:text-gray-100;
245
+ }
246
+
247
+ .d-header-title-logo {
248
+ @apply d-header-title ml-4;
249
+ }
250
+
251
+ .d-header-logo {
252
+ @apply flex items-center flex-none lg:w-60;
253
+ }
254
+
255
+ .d-logo-color {
256
+ @apply text-black dark:text-white;
257
+ }
258
+
259
+ .d-logo {
260
+ @apply w-auto h-6 md:h-8 d-logo-color;
261
+ }
262
+
263
+ .d-heading-title {
264
+ @apply !mb-0 !mt-0 flex-1 !text-4xl font-semibold tracking-tight;
265
+ }
266
+
267
+ .d-heading-description {
268
+ @apply !mt-2 !mb-0 text-lg font-medium d-secondary-text;
269
+ }
270
+
271
+ .d-heading-hr {
272
+ @apply !mt-4 !mb-0 d-border;
273
+ }
274
+
275
+ .d-aside-title {
276
+ @apply py-2 text-base font-semibold text-gray-900 cursor-pointer dark:text-gray-100;
277
+ }
278
+
279
+ .d-badge {
280
+ @apply text-gray-600 dark:text-gray-400 bg-gray-900;
281
+ }
282
+ }
@@ -0,0 +1,23 @@
1
+ <script setup lang="ts">
2
+ const props = defineProps({
3
+ padded: {
4
+ type: Boolean,
5
+ default: false,
6
+ },
7
+ constrained: {
8
+ type: Boolean,
9
+ default: true,
10
+ },
11
+ })
12
+
13
+ const containerClass = computed(() => classNames(
14
+ 'mx-auto max-w-7xl px-4 sm:px-6',
15
+ props.padded && 'px-4',
16
+ ))
17
+ </script>
18
+
19
+ <template>
20
+ <div :class="containerClass">
21
+ <slot />
22
+ </div>
23
+ </template>
@@ -0,0 +1,38 @@
1
+ <script setup lang="ts">
2
+ const { footer } = useTheme()
3
+
4
+ const icons = computed(() => footer?.icons || [])
5
+ </script>
6
+
7
+ <template>
8
+ <footer class="py-6 sm:py-0 bg-gray-50 dark:bg-gray-800 dark:bg-opacity-25 h-[8rem] sm:h-[4rem]">
9
+ <Container class="flex h-full flex-col gap-y-4 sm:flex-row justify-between items-center">
10
+ <a
11
+ v-if="footer.credits"
12
+ href="https://nuxtlabs.com"
13
+ rel="noopener"
14
+ target="_blank"
15
+ class="flex items-end text-secondary transition-base dark:hover:text-gray-100 hover:text-gray-600 mb-3 sm:mb-0"
16
+ >
17
+ <IconNuxtLabs class="mr-2" />
18
+ <p class="font-semibold text-sm">Made by Nuxt Labs</p>
19
+ </a>
20
+
21
+ <div class="flex">
22
+ <a
23
+ v-for="icon in icons"
24
+ :key="icon.label"
25
+ rel="noopener"
26
+ :aria-label="icon.label"
27
+ :href="icon.href"
28
+ target="_blank"
29
+ class="text-sm flex items-center font-medium p-1 icon-base"
30
+ >
31
+ <Component :is="icon.component" class="w-8 h-8" />
32
+ </a>
33
+
34
+ <SocialIcons size="w-8 h-8" padding="p-1" />
35
+ </div>
36
+ </Container>
37
+ </footer>
38
+ </template>
@@ -0,0 +1,26 @@
1
+ <template>
2
+ <header class="sticky w-full h-[4rem] top-0 z-50 bg-white bg-opacity-80 dark:bg-gray-900 dark:bg-opacity-80 border-b border-gray-200 dark:border-gray-800 border-opacity-50 sticky w-full top-0 z-50 backdrop-blur supports-backdrop-blur:bg-white/95">
3
+ <Container class="flex flex-none h-full">
4
+ <!-- <NavigationButton v-if="aside" /> -->
5
+
6
+ <div class="justify-center flex items-center flex-1 lg:flex-none">
7
+ <NavbarLogo />
8
+ </div>
9
+
10
+ <div class="items-center hidden lg:flex lg:flex-1">
11
+ <!-- <HeaderNavigation /> -->
12
+ </div>
13
+
14
+ <!-- Desktop: Right section -->
15
+ <div class="flex items-center justify-end lg:flex-none">
16
+ <!-- <ColorSwitcher /> -->
17
+
18
+ <div class="items-center justify-end hidden lg:flex">
19
+ <!-- <LangSwitcher /> -->
20
+ <ThemeSelect />
21
+ <!-- <SocialIcons /> -->
22
+ </div>
23
+ </div>
24
+ </Container>
25
+ </header>
26
+ </template>
@@ -0,0 +1,31 @@
1
+ <script setup lang="ts">
2
+ const theme = useTheme()
3
+ const hasLogo = computed(() => theme.header.logo)
4
+ const hasTitle = computed(() => theme.header.title)
5
+ </script>
6
+
7
+ <template>
8
+ <NuxtLink to="/" :aria-label="theme.header.title">
9
+ <!-- Only title -->
10
+ <span v-if="!hasLogo && hasTitle">
11
+ {{ theme.header.title }}
12
+ </span>
13
+
14
+ <!-- Title and Logo -->
15
+ <template v-else-if="hasLogo && hasTitle">
16
+ <Logo />
17
+
18
+ <span>
19
+ {{ theme.header.title }}
20
+ </span>
21
+ </template>
22
+
23
+ <!-- Only Logo -->
24
+ <Logo v-else-if="hasLogo" class="w-12 h-12" />
25
+
26
+ <!-- Placeholder -->
27
+ <template v-else>
28
+ <IconDots class="w-12 h-12" />
29
+ </template>
30
+ </NuxtLink>
31
+ </template>
@@ -0,0 +1,7 @@
1
+ <template>
2
+ <main class="relative flex-1 pb-4 sm:pb-6 lg:py-8">
3
+ <Container padded>
4
+ <slot />
5
+ </Container>
6
+ </main>
7
+ </template>
@@ -0,0 +1,11 @@
1
+ <template>
2
+ <div class="p-3 text-center border-t border-gray-200 border-dashed dark:border-gray-800 dark:bg-gray-900">
3
+ <a
4
+ href="https://docus.dev"
5
+ target="_blank"
6
+ class="text-xs text-gray-400 hover:text-gray-600 dark:text-gray-600 group dark:hover:text-gray-400"
7
+ >
8
+ Powered by <strong class="font-bold">Docus</strong>
9
+ </a>
10
+ </div>
11
+ </template>
@@ -0,0 +1,124 @@
1
+ <script setup lang="ts">
2
+ defineProps({
3
+ /**
4
+ * @values info, success, warning, danger
5
+ */
6
+ type: {
7
+ type: String,
8
+ default: 'info',
9
+ validator(value: string) {
10
+ return ['info', 'success', 'warning', 'danger'].includes(value)
11
+ },
12
+ },
13
+ })
14
+ </script>
15
+
16
+ <template>
17
+ <div
18
+ class="px-4 py-3 mt-4 mb-4 rounded-xl alert text-sm leading-relaxed"
19
+ :class="[type]"
20
+ >
21
+ <div class="flex items-start">
22
+ <div class="flex-grow alert-content">
23
+ <Markdown unwrap="p" />
24
+ </div>
25
+ </div>
26
+ </div>
27
+ </template>
28
+
29
+ <style lang="postcss" scoped>
30
+ .alert {
31
+ &.success {
32
+ @apply bg-green-50 dark:bg-green-800 dark:bg-opacity-25 text-green-600 dark:text-green-200 border border-green-100 dark:border-green-900;
33
+
34
+ :deep() {
35
+ code {
36
+ @apply bg-green-100 dark:bg-green-900 dark:bg-opacity-50 shadow-none text-current border-green-200 dark:border-green-800;
37
+ }
38
+ a:hover {
39
+ code {
40
+ @apply border-green-400 dark:border-green-700;
41
+ }
42
+ }
43
+ }
44
+ }
45
+
46
+ &.info {
47
+ @apply bg-blue-50 dark:bg-blue-800 dark:bg-opacity-25 text-blue-600 dark:text-blue-200 border border-blue-100 dark:border-blue-900;
48
+
49
+ :deep() {
50
+ code {
51
+ @apply bg-blue-100 dark:bg-blue-900 dark:bg-opacity-50 shadow-none text-current border-blue-200 dark:border-blue-800;
52
+ }
53
+ a:hover {
54
+ code {
55
+ @apply border-blue-400 dark:border-blue-700;
56
+ }
57
+ }
58
+ }
59
+ }
60
+
61
+ &.warning {
62
+ @apply bg-yellow-50 dark:bg-yellow-800 dark:bg-opacity-25 text-yellow-600 dark:text-yellow-100 border border-yellow-100 dark:border-yellow-900;
63
+
64
+ :deep() {
65
+ code {
66
+ @apply bg-yellow-100 dark:bg-yellow-900 dark:bg-opacity-50 shadow-none text-current border-yellow-200 dark:border-yellow-800;
67
+ }
68
+ a:hover {
69
+ code {
70
+ @apply border-yellow-400 dark:border-yellow-700;
71
+ }
72
+ }
73
+ }
74
+ }
75
+
76
+ &.danger {
77
+ @apply bg-red-50 dark:bg-red-800 dark:bg-opacity-25 text-red-600 dark:text-red-100 border border-red-100 dark:border-red-900;
78
+
79
+ :deep() {
80
+ code {
81
+ @apply bg-red-100 dark:bg-red-900 dark:bg-opacity-50 shadow-none text-current border-red-200 dark:border-red-800;
82
+ }
83
+ a:hover {
84
+ code {
85
+ @apply border-red-400 dark:border-red-700;
86
+ }
87
+ }
88
+ }
89
+ }
90
+
91
+ :deep() {
92
+ strong {
93
+ @apply font-semibold text-current;
94
+ }
95
+
96
+ a {
97
+ @apply underline border-none font-semibold text-current;
98
+ code {
99
+ @apply border border-transparent border-dashed;
100
+ }
101
+ }
102
+
103
+ .prose-code {
104
+ @apply my-4;
105
+
106
+ code {
107
+ @apply bg-gray-50 dark:bg-gray-900;
108
+ }
109
+ }
110
+ }
111
+ }
112
+
113
+ .alert :deep(p) {
114
+ @apply m-0 !important;
115
+ }
116
+
117
+ .dark .alert {
118
+ :deep() {
119
+ a {
120
+ @apply text-current;
121
+ }
122
+ }
123
+ }
124
+ </style>