@farming-labs/nuxt-theme 0.0.2-beta.22 → 0.0.2-beta.23
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@farming-labs/nuxt-theme",
|
|
3
|
-
"version": "0.0.2-beta.
|
|
3
|
+
"version": "0.0.2-beta.23",
|
|
4
4
|
"description": "Nuxt/Vue UI components for @farming-labs/docs — layout, sidebar, TOC, search, and theme toggle",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"docs",
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
},
|
|
54
54
|
"dependencies": {
|
|
55
55
|
"sugar-high": "^0.9.5",
|
|
56
|
-
"@farming-labs/docs": "0.0.2-beta.
|
|
56
|
+
"@farming-labs/docs": "0.0.2-beta.23"
|
|
57
57
|
},
|
|
58
58
|
"peerDependencies": {
|
|
59
59
|
"nuxt": ">=3.0.0",
|
|
@@ -36,6 +36,13 @@ const breadcrumbEnabled = computed(() => {
|
|
|
36
36
|
const showEditOnGithub = computed(() => !!props.config?.github && !!props.data.editOnGithub);
|
|
37
37
|
const showLastModified = computed(() => !!props.data.lastModified);
|
|
38
38
|
|
|
39
|
+
const llmsTxtEnabled = computed(() => {
|
|
40
|
+
const cfg = props.config?.llmsTxt;
|
|
41
|
+
if (cfg === true) return true;
|
|
42
|
+
if (typeof cfg === "object" && cfg !== null) return (cfg as { enabled?: boolean }).enabled !== false;
|
|
43
|
+
return false;
|
|
44
|
+
});
|
|
45
|
+
|
|
39
46
|
const entry = computed(() => (props.config?.entry as string) ?? "docs");
|
|
40
47
|
|
|
41
48
|
const metaDescription = computed(
|
|
@@ -59,6 +66,7 @@ useHead({
|
|
|
59
66
|
:next-page="data.nextPage ?? null"
|
|
60
67
|
:edit-on-github="showEditOnGithub ? data.editOnGithub : null"
|
|
61
68
|
:last-modified="showLastModified ? data.lastModified : null"
|
|
69
|
+
:llms-txt-enabled="llmsTxtEnabled"
|
|
62
70
|
>
|
|
63
71
|
<p v-if="data.description" class="fd-page-description">{{ data.description }}</p>
|
|
64
72
|
<div class="fd-docs-content" v-html="data.html" />
|
|
@@ -13,6 +13,7 @@ const props = withDefaults(
|
|
|
13
13
|
nextPage?: { name: string; url: string } | null;
|
|
14
14
|
editOnGithub?: string | null;
|
|
15
15
|
lastModified?: string | null;
|
|
16
|
+
llmsTxtEnabled?: boolean;
|
|
16
17
|
}>(),
|
|
17
18
|
{
|
|
18
19
|
tocEnabled: true,
|
|
@@ -23,6 +24,7 @@ const props = withDefaults(
|
|
|
23
24
|
nextPage: null,
|
|
24
25
|
editOnGithub: null,
|
|
25
26
|
lastModified: null,
|
|
27
|
+
llmsTxtEnabled: false,
|
|
26
28
|
},
|
|
27
29
|
);
|
|
28
30
|
|
|
@@ -106,7 +108,7 @@ watch(
|
|
|
106
108
|
</div>
|
|
107
109
|
|
|
108
110
|
<footer class="fd-page-footer">
|
|
109
|
-
<div v-if="editOnGithub || lastModified" class="fd-edit-on-github">
|
|
111
|
+
<div v-if="editOnGithub || lastModified || llmsTxtEnabled" class="fd-edit-on-github">
|
|
110
112
|
<a v-if="editOnGithub" :href="editOnGithub" target="_blank" rel="noopener noreferrer">
|
|
111
113
|
<svg
|
|
112
114
|
width="14"
|
|
@@ -123,6 +125,10 @@ watch(
|
|
|
123
125
|
</svg>
|
|
124
126
|
Edit on GitHub
|
|
125
127
|
</a>
|
|
128
|
+
<span v-if="llmsTxtEnabled" class="fd-llms-txt-links">
|
|
129
|
+
<a href="/api/docs?format=llms" target="_blank" rel="noopener noreferrer" class="fd-llms-txt-link">llms.txt</a>
|
|
130
|
+
<a href="/api/docs?format=llms-full" target="_blank" rel="noopener noreferrer" class="fd-llms-txt-link">llms-full.txt</a>
|
|
131
|
+
</span>
|
|
126
132
|
<span v-if="lastModified" class="fd-last-modified">Last updated: {{ lastModified }}</span>
|
|
127
133
|
</div>
|
|
128
134
|
|
package/styles/docs.css
CHANGED
|
@@ -1237,6 +1237,29 @@ html.dark pre.shiki {
|
|
|
1237
1237
|
font-size: 12px;
|
|
1238
1238
|
}
|
|
1239
1239
|
|
|
1240
|
+
.fd-llms-txt-links {
|
|
1241
|
+
display: inline-flex;
|
|
1242
|
+
align-items: center;
|
|
1243
|
+
gap: 0.5rem;
|
|
1244
|
+
}
|
|
1245
|
+
|
|
1246
|
+
.fd-llms-txt-link {
|
|
1247
|
+
color: var(--color-fd-muted-foreground);
|
|
1248
|
+
font-size: 0.75rem;
|
|
1249
|
+
font-family: var(--fd-font-mono, ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace);
|
|
1250
|
+
text-decoration: none;
|
|
1251
|
+
padding: 0.125rem 0.375rem;
|
|
1252
|
+
border-radius: 0.25rem;
|
|
1253
|
+
border: 1px solid var(--color-fd-border, hsl(0 0% 80% / 50%));
|
|
1254
|
+
transition: color 150ms, border-color 150ms;
|
|
1255
|
+
}
|
|
1256
|
+
|
|
1257
|
+
.fd-llms-txt-link:hover {
|
|
1258
|
+
color: var(--color-fd-foreground);
|
|
1259
|
+
border-color: var(--color-fd-foreground);
|
|
1260
|
+
text-decoration: none;
|
|
1261
|
+
}
|
|
1262
|
+
|
|
1240
1263
|
/* ─── Previous / Next Navigation ────────────────────────────────────── */
|
|
1241
1264
|
|
|
1242
1265
|
.fd-page-nav {
|