@farming-labs/theme 0.2.113 → 0.2.115
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/dist/docs-api.d.mts
CHANGED
|
@@ -82,6 +82,8 @@ interface DocsAPIOptions {
|
|
|
82
82
|
agent?: DocsConfig["agent"];
|
|
83
83
|
/** @internal Build-time Agent Skills snapshot supplied by framework adapters. */
|
|
84
84
|
_preloadedAgentSkills?: readonly DocsPublishedAgentSkill[];
|
|
85
|
+
/** @internal Build-time root document snapshot (skill.md, AGENTS.md, AGENT.md) supplied by framework adapters. */
|
|
86
|
+
_preloadedRootDocuments?: Readonly<Record<string, string>>;
|
|
85
87
|
}
|
|
86
88
|
interface DocsMCPAPIOptions {
|
|
87
89
|
rootDir?: string;
|
|
@@ -103,6 +105,8 @@ interface DocsMCPAPIOptions {
|
|
|
103
105
|
feedback?: DocsConfig["feedback"];
|
|
104
106
|
/** @internal Build-time Agent Skills snapshot supplied by framework adapters. */
|
|
105
107
|
_preloadedAgentSkills?: readonly DocsPublishedAgentSkill[];
|
|
108
|
+
/** @internal Build-time root document snapshot (skill.md, AGENTS.md, AGENT.md) supplied by framework adapters. */
|
|
109
|
+
_preloadedRootDocuments?: Readonly<Record<string, string>>;
|
|
106
110
|
}
|
|
107
111
|
type LlmsTxtOptions = LlmsTxtConfig;
|
|
108
112
|
/**
|
package/dist/docs-api.mjs
CHANGED
|
@@ -1451,7 +1451,7 @@ function renderAgentsDocument({ origin, entry, apiRoute, apiCatalog, search, con
|
|
|
1451
1451
|
lines.push("", "## Framework Maintenance", "- For @farming-labs/docs projects, keep the framework package current before debugging missing agent surfaces.", "", "```sh", "npx @farming-labs/docs@latest upgrade --latest", "```", "", "- For framework setup, configuration, CLI, Ask AI, page actions, or theme work, install the reusable Skills pack:", "", "```sh", "npx skills add farming-labs/docs", "```");
|
|
1452
1452
|
return lines.join("\n");
|
|
1453
1453
|
}
|
|
1454
|
-
function createRootDocumentReader(rootDir, fileNames) {
|
|
1454
|
+
function createRootDocumentReader(rootDir, fileNames, preloadedDocuments) {
|
|
1455
1455
|
let cached;
|
|
1456
1456
|
return function readRootDocument() {
|
|
1457
1457
|
for (const fileName of fileNames) {
|
|
@@ -1479,6 +1479,10 @@ function createRootDocumentReader(rootDir, fileNames) {
|
|
|
1479
1479
|
}
|
|
1480
1480
|
}
|
|
1481
1481
|
cached = void 0;
|
|
1482
|
+
if (preloadedDocuments) for (const fileName of fileNames) {
|
|
1483
|
+
const content = preloadedDocuments[fileName];
|
|
1484
|
+
if (typeof content === "string") return content;
|
|
1485
|
+
}
|
|
1482
1486
|
return null;
|
|
1483
1487
|
};
|
|
1484
1488
|
}
|
|
@@ -2555,8 +2559,8 @@ function generateLlmsTxt(indexes, options) {
|
|
|
2555
2559
|
*/
|
|
2556
2560
|
function createDocsAPI(options) {
|
|
2557
2561
|
const root = options?.rootDir ?? process.cwd();
|
|
2558
|
-
const readRootSkillDocument = createRootDocumentReader(root, ["skill.md"]);
|
|
2559
|
-
const readRootAgentsDocument = createRootDocumentReader(root, ["AGENTS.md", "AGENT.md"]);
|
|
2562
|
+
const readRootSkillDocument = createRootDocumentReader(root, ["skill.md"], options?._preloadedRootDocuments);
|
|
2563
|
+
const readRootAgentsDocument = createRootDocumentReader(root, ["AGENTS.md", "AGENT.md"], options?._preloadedRootDocuments);
|
|
2560
2564
|
let publishedAgentSkills;
|
|
2561
2565
|
function getPublishedAgentSkills() {
|
|
2562
2566
|
if (!publishedAgentSkills) publishedAgentSkills = Array.isArray(options?._preloadedAgentSkills) ? Promise.resolve([...options._preloadedAgentSkills]) : resolveConfiguredAgentSkills(options?.agent?.skills, { rootDir: root });
|
|
@@ -3436,7 +3440,7 @@ function createDocsAPI(options) {
|
|
|
3436
3440
|
*/
|
|
3437
3441
|
function createDocsMCPAPI(options = {}) {
|
|
3438
3442
|
const rootDir = options.rootDir ?? process.cwd();
|
|
3439
|
-
const readRootSkillDocument = createRootDocumentReader(rootDir, ["skill.md"]);
|
|
3443
|
+
const readRootSkillDocument = createRootDocumentReader(rootDir, ["skill.md"], options._preloadedRootDocuments);
|
|
3440
3444
|
const entry = options.entry ?? readEntry(rootDir);
|
|
3441
3445
|
const appDir = getNextAppDir(rootDir);
|
|
3442
3446
|
const contentDir = options.contentDir ?? path.join(appDir, entry);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@farming-labs/theme",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.115",
|
|
4
4
|
"description": "Theme package for @farming-labs/docs — layout, provider, MDX components, and styles",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"docs",
|
|
@@ -161,7 +161,7 @@
|
|
|
161
161
|
"tsdown": "^0.20.3",
|
|
162
162
|
"typescript": "^5.9.3",
|
|
163
163
|
"vitest": "^4.1.8",
|
|
164
|
-
"@farming-labs/docs": "0.2.
|
|
164
|
+
"@farming-labs/docs": "0.2.115"
|
|
165
165
|
},
|
|
166
166
|
"peerDependencies": {
|
|
167
167
|
"@farming-labs/docs": ">=0.0.1",
|
|
@@ -5088,7 +5088,7 @@ body {
|
|
|
5088
5088
|
.omni-overlay {
|
|
5089
5089
|
position: fixed;
|
|
5090
5090
|
inset: 0;
|
|
5091
|
-
z-index:
|
|
5091
|
+
z-index: 9998;
|
|
5092
5092
|
background: rgba(0, 0, 0, 0.2);
|
|
5093
5093
|
backdrop-filter: blur(2px);
|
|
5094
5094
|
animation: omni-fade-in 150ms ease-out;
|
|
@@ -5097,7 +5097,7 @@ body {
|
|
|
5097
5097
|
.omni-content {
|
|
5098
5098
|
--omni-content-top: clamp(5rem, 16vh, 7rem);
|
|
5099
5099
|
position: fixed;
|
|
5100
|
-
z-index:
|
|
5100
|
+
z-index: 9999;
|
|
5101
5101
|
top: var(--omni-content-top);
|
|
5102
5102
|
left: 50%;
|
|
5103
5103
|
transform: translateX(-50%);
|
|
@@ -5102,7 +5102,7 @@ code.shiki span {
|
|
|
5102
5102
|
.omni-overlay {
|
|
5103
5103
|
position: fixed;
|
|
5104
5104
|
inset: 0;
|
|
5105
|
-
z-index:
|
|
5105
|
+
z-index: 9998;
|
|
5106
5106
|
background: rgba(0, 0, 0, 0.2);
|
|
5107
5107
|
backdrop-filter: blur(2px);
|
|
5108
5108
|
animation: omni-fade-in 150ms ease-out;
|
|
@@ -5111,7 +5111,7 @@ code.shiki span {
|
|
|
5111
5111
|
.omni-content {
|
|
5112
5112
|
--omni-content-top: clamp(5rem, 16vh, 7rem);
|
|
5113
5113
|
position: fixed;
|
|
5114
|
-
z-index:
|
|
5114
|
+
z-index: 9999;
|
|
5115
5115
|
top: var(--omni-content-top);
|
|
5116
5116
|
left: 50%;
|
|
5117
5117
|
transform: translateX(-50%);
|
package/styles/omni.css
CHANGED
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
.omni-overlay {
|
|
57
57
|
position: fixed;
|
|
58
58
|
inset: 0;
|
|
59
|
-
z-index:
|
|
59
|
+
z-index: 9998;
|
|
60
60
|
background: rgba(0, 0, 0, 0.2);
|
|
61
61
|
backdrop-filter: blur(2px);
|
|
62
62
|
animation: omni-fade-in 150ms ease-out;
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
.omni-content {
|
|
66
66
|
--omni-content-top: clamp(5rem, 16vh, 7rem);
|
|
67
67
|
position: fixed;
|
|
68
|
-
z-index:
|
|
68
|
+
z-index: 9999;
|
|
69
69
|
top: var(--omni-content-top);
|
|
70
70
|
left: 50%;
|
|
71
71
|
transform: translateX(-50%);
|