@ahmedrowaihi/8n 6.0.45 → 6.0.47
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/index.mjs +4 -4
- package/package.json +1 -1
- package/starter/content/api/ar/index.mdx +4 -0
- package/starter/content/changelog/ar/index.mdx +3 -0
- package/starter/content/changelog/en/index.mdx +3 -0
- package/starter/content/docs/ar/index.mdx +1 -0
- package/starter/content/docs/en/index.mdx +1 -0
- package/starter/content/mcp/ar/index.mdx +4 -0
- package/starter/content/mcp/en/index.mdx +4 -0
- package/starter/content/ui/ar/index.mdx +4 -0
- package/starter/package.json +1 -1
- package/starter/src/features/docs/section-page.jsx +2 -1
- package/starter/src/lib/content-source.js +1 -1
- package/starter/src/lib/docs-page.js +1 -0
- package/starter/content/api/ar/meta.json +0 -1
- package/starter/content/api/en/meta.json +0 -5
- package/starter/content/changelog/ar/meta.json +0 -3
- package/starter/content/changelog/en/meta.json +0 -3
- package/starter/content/docs/ar/components/meta.json +0 -27
- package/starter/content/docs/ar/meta.json +0 -4
- package/starter/content/docs/en/components/meta.json +0 -27
- package/starter/content/docs/en/meta.json +0 -4
- package/starter/content/mcp/ar/meta.json +0 -1
- package/starter/content/mcp/en/meta.json +0 -5
- package/starter/content/ui/ar/meta.json +0 -1
- package/starter/content/ui/en/meta.json +0 -5
- /package/starter/content/api/en/{listPets.mdx → 01-listPets.mdx} +0 -0
- /package/starter/content/api/en/{showPetById.mdx → 02-showPetById.mdx} +0 -0
- /package/starter/content/api/en/{createPet.mdx → 03-createPet.mdx} +0 -0
- /package/starter/content/api/en/{deletePet.mdx → 04-deletePet.mdx} +0 -0
- /package/starter/content/docs/ar/{getting-started.mdx → 01-getting-started.mdx} +0 -0
- /package/starter/content/docs/en/{getting-started.mdx → 01-getting-started.mdx} +0 -0
- /package/starter/content/mcp/en/{config.mdx → 01-config.mdx} +0 -0
- /package/starter/content/mcp/en/{structure.mdx → 02-structure.mdx} +0 -0
- /package/starter/content/mcp/en/{frontmatter.mdx → 03-frontmatter.mdx} +0 -0
- /package/starter/content/mcp/en/{components.mdx → 04-components.mdx} +0 -0
package/dist/index.mjs
CHANGED
|
@@ -3736,7 +3736,7 @@ async function checkSelfUpdate() {
|
|
|
3736
3736
|
});
|
|
3737
3737
|
if (!res.ok) return;
|
|
3738
3738
|
const { version: latest } = await res.json();
|
|
3739
|
-
const current = "6.0.
|
|
3739
|
+
const current = "6.0.47";
|
|
3740
3740
|
if (latest !== current) console.log(pc.yellow("⚠") + pc.dim(` new version available: `) + pc.cyan(latest) + pc.dim(` (current: ${current}) — run `) + pc.cyan("npm i -g @ahmedrowaihi/8n") + pc.dim(" to update"));
|
|
3741
3741
|
} catch {}
|
|
3742
3742
|
}
|
|
@@ -3849,7 +3849,7 @@ async function dev() {
|
|
|
3849
3849
|
async function build({ server = false } = {}) {
|
|
3850
3850
|
const { config, contentDir } = await resolveProject();
|
|
3851
3851
|
const projectDir = process.cwd();
|
|
3852
|
-
console.log(pc.cyan("8n") + pc.dim(` v6.0.
|
|
3852
|
+
console.log(pc.cyan("8n") + pc.dim(` v6.0.47 build → ${contentDir}`));
|
|
3853
3853
|
if (server) await runNextFlat(projectDir, "build", buildEnv({
|
|
3854
3854
|
config,
|
|
3855
3855
|
contentDir,
|
|
@@ -4167,7 +4167,7 @@ async function mcp() {
|
|
|
4167
4167
|
const mcpDir = join(getStarterDir(), "content", "mcp", "en");
|
|
4168
4168
|
const server = new McpServer({
|
|
4169
4169
|
name: "8n",
|
|
4170
|
-
version: "6.0.
|
|
4170
|
+
version: "6.0.47"
|
|
4171
4171
|
});
|
|
4172
4172
|
server.registerTool("read_me", {
|
|
4173
4173
|
description: "Returns how to use the 8n MCP tools. Call this BEFORE documenting anything with 8n.",
|
|
@@ -4308,7 +4308,7 @@ Example: get_component({ name: "components" }) returns all available MDX compone
|
|
|
4308
4308
|
|
|
4309
4309
|
//#endregion
|
|
4310
4310
|
//#region src/index.ts
|
|
4311
|
-
const program = new Command().name("8n").description("Run your 8n docs site").version("6.0.
|
|
4311
|
+
const program = new Command().name("8n").description("Run your 8n docs site").version("6.0.47").addOption(new Option("--debug").hideHelp()).hook("preAction", (cmd) => {
|
|
4312
4312
|
if (cmd.opts().debug) process.env.DEBUG_8N = "1";
|
|
4313
4313
|
});
|
|
4314
4314
|
program.command("init").description("Scaffold a new docs project in the current directory").action(init);
|
package/package.json
CHANGED
package/starter/package.json
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use server";
|
|
2
|
+
import{jsx as t}from"react/jsx-runtime";import{notFound as e,redirect as r}from"next/navigation";import{relative as i}from"node:path";import{DocsPageContent as o}from".";import{getMDXComponentsForLang as a}from"../../components/fumadocs/mdx-server.js";import{getSections as n}from"../../lib/source";import{getDocsPageMeta as m,resolveDocsPage as c}from"../../lib/docs-page";import{localeConfig as l}from"../../locale.config";import{env as s}from"../../config";export async function generateStaticParams(){return Object.entries(await n()).flatMap(([t,e])=>e.generateParams().map(e=>({section:t,...e})))}export async function generateMetadata({params:t}){let{lang:e,section:r,slug:i=[]}=await t,o=await m(r,i,e);if(!o||"redirect"===o.type)return{};let a=l[e]?.siteName??l.en.siteName;return{title:`${o.title} — ${a}`,description:o.description}}export default async function p({params:n}){let{lang:m,section:l,slug:f=[]}=await n,d=await c(l,f,m);return d||e(),"redirect"===d.type&&r(d.url),t(o,{toc:d.toc,frontmatter:{title:d.title,description:d.description},github:s.NEXT_PUBLIC_GITHUB_REPO?{repo:s.NEXT_PUBLIC_GITHUB_REPO,fileUrl:`${s.NEXT_PUBLIC_GITHUB_REPO}/blob/HEAD/${i(process.cwd(),d.filePath)}`}:void 0,markdownUrl:d.markdownUrl,path:d.path,lang:m,lastModified:d.lastModified,neighbours:d.neighbours,full:d.full,children:t(d.MDX,{components:a(m,d.title,s.NEXT_PUBLIC_GITHUB_REPO)})})}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{readdir as t,readFile as e,stat as a}from"node:fs/promises";let
|
|
1
|
+
import{readdir as t,readFile as e,stat as a}from"node:fs/promises";import{join as i,relative as n}from"node:path";import r from"gray-matter";let l=new Set(["home"]);export async function discoverSections(e){let a;try{a=await t(e,{withFileTypes:!0})}catch{return[]}return a.filter(t=>t.isDirectory()&&!l.has(t.name)).map(t=>t.name)}let m=/^(\d+)-(.+)$/;function o(t){let e=t.match(m);return e?[parseInt(e[1],10),e[2]]:[1/0,t]}function c(t){return[...t].sort((t,e)=>{let[a,i]=o(t.name),[n,r]=o(e.name);return a!==n?a-n:i.localeCompare(r)})}async function d(l,o,f){let s;try{s=await t(l,{withFileTypes:!0})}catch{return}let p=s.filter(t=>t.isFile()&&(t.name.endsWith(".mdx")||t.name.endsWith(".md"))),h=s.filter(t=>t.isDirectory()),u=p.find(t=>"index.mdx"===t.name||"index.md"===t.name),y=c(p.filter(t=>"index.mdx"!==t.name&&"index.md"!==t.name)),w=c(h);if(u){let t=i(l,u.name),m=n(o,l);try{let l=await e(t,"utf8"),c=await a(t),{data:d,content:s}=r(l),p=d.label??d.title??void 0,h={};p&&(h.title=p),d.icon&&(h.icon=d.icon);let u=m?i(m,"meta.json"):"meta.json";if(f.push({type:"meta",path:u,data:h}),s.trim().length>0){let e=n(o,t);f.push({type:"page",path:e,data:{...d,title:d.title??"Untitled",filePath:t,lastModified:c.mtime}})}}catch{}}for(let t of y){let c=i(l,t.name),d=n(o,i(l,t.name.replace(m,"$2")));try{let t=await e(c,"utf8"),i=await a(c),{data:n}=r(t);f.push({type:"page",path:d,data:{...n,title:n.title??"Untitled",filePath:c,lastModified:i.mtime}})}catch{}}for(let t of w)await d(i(l,t.name),o,f)}export async function createFsSource(t){let e=[];return await d(t,t,e),{files:e}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{findNeighbour as e}from"fumadocs-core/page-tree";import{readFile as t}from"node:fs/promises";import{getSections as r}from"./source";import{compiler as a}from"./mdx-compiler";export async function getDocsPageMeta(e,t,a){let i=(await r())[e];if(!i)return null;let l=i.getPage(t,a);if(!l){if(0===t.length){let e=i.getPages(a)[0];if(e)return{type:"redirect",url:e.url}}return null}return l.data.redirect?{type:"redirect",url:l.data.redirect}:{type:"meta",title:l.data.title,description:l.data.description}}export async function resolveDocsPage(i,l,d){let o=(await r())[i];if(!o)return null;let n=o.getPage(l,d);if(!n){if(0===l.length){let e=o.getPages(d)[0];if(e)return{type:"redirect",url:e.url}}return null}if(n.data.redirect)return{type:"redirect",url:n.data.redirect};let u=await t(n.data.filePath,"utf-8"),c=await a.compile({source:u});return{type:"page",title:n.data.title,description:n.data.description,filePath:n.data.filePath,lastModified:n.data.lastModified??null,full:n.data.full??!1,path:n.path,toc:c.toc,MDX:c.body,neighbours:e(o.getPageTree(d),n.url),markdownUrl:`/llms.mdx/${i}/${[...n.slugs,"index.mdx"].join("/")}`}}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{ "title": "مرجع API", "icon": "PlugZap" }
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "المكونات",
|
|
3
|
-
"icon": "Layers",
|
|
4
|
-
"pages": [
|
|
5
|
-
"index",
|
|
6
|
-
"callout",
|
|
7
|
-
"cards",
|
|
8
|
-
"tabs",
|
|
9
|
-
"steps",
|
|
10
|
-
"accordion",
|
|
11
|
-
"code-blocks",
|
|
12
|
-
"inline-toc",
|
|
13
|
-
"dynamic-code-block",
|
|
14
|
-
"mermaid",
|
|
15
|
-
"files",
|
|
16
|
-
"type-table",
|
|
17
|
-
"twoslash",
|
|
18
|
-
"math",
|
|
19
|
-
"video",
|
|
20
|
-
"audio",
|
|
21
|
-
"excalidraw",
|
|
22
|
-
"tweet",
|
|
23
|
-
"drawio",
|
|
24
|
-
"figma",
|
|
25
|
-
"circuit-board"
|
|
26
|
-
]
|
|
27
|
-
}
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "Components",
|
|
3
|
-
"icon": "Layers",
|
|
4
|
-
"pages": [
|
|
5
|
-
"index",
|
|
6
|
-
"callout",
|
|
7
|
-
"cards",
|
|
8
|
-
"tabs",
|
|
9
|
-
"steps",
|
|
10
|
-
"accordion",
|
|
11
|
-
"code-blocks",
|
|
12
|
-
"inline-toc",
|
|
13
|
-
"dynamic-code-block",
|
|
14
|
-
"mermaid",
|
|
15
|
-
"files",
|
|
16
|
-
"type-table",
|
|
17
|
-
"twoslash",
|
|
18
|
-
"math",
|
|
19
|
-
"video",
|
|
20
|
-
"audio",
|
|
21
|
-
"excalidraw",
|
|
22
|
-
"tweet",
|
|
23
|
-
"drawio",
|
|
24
|
-
"figma",
|
|
25
|
-
"circuit-board"
|
|
26
|
-
]
|
|
27
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{ "title": "معرفة MCP", "icon": "Bot" }
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{ "title": "مكونات UI", "icon": "Palette" }
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|