fimo 2.2.0-staging.8 → 2.2.0
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/assets/agent-templates/_default/config.yaml +6 -0
- package/assets/agent-templates/broken-link-sweeper/config.yaml +1 -0
- package/assets/content-templates/shared/types.eta +65 -6
- package/assets/skills/fimo-cli/SKILL.md +5 -3
- package/assets/skills/fimo-cli/references/agents.md +29 -4
- package/assets/skills/fimo-cli/references/assets.md +42 -3
- package/assets/skills/fimo-cli/references/branches.md +9 -8
- package/assets/skills/fimo-cli/references/content.md +4 -4
- package/assets/skills/fimo-cli/references/credits.md +12 -19
- package/assets/skills/fimo-cli/references/deploy.md +8 -8
- package/assets/skills/fimo-cli/references/forms.md +3 -1
- package/assets/skills/fimo-cli/references/history.md +3 -2
- package/assets/skills/fimo-cli/references/inbox.md +86 -0
- package/assets/skills/fimo-cli/references/init.md +7 -6
- package/assets/skills/fimo-cli/references/invite.md +11 -9
- package/assets/skills/fimo-cli/references/labels.md +3 -11
- package/assets/skills/fimo-cli/references/locales.md +5 -3
- package/assets/skills/fimo-cli/references/preview.md +1 -2
- package/assets/skills/fimo-cli/references/projects.md +8 -8
- package/assets/skills/fimo-cli/references/schedules.md +6 -4
- package/assets/skills/fimo-cli/references/webhooks.md +6 -4
- package/assets/skills/fimo-code/references/assets.md +22 -11
- package/assets/skills/fimo-code/references/content/clients.md +15 -1
- package/assets/skills/fimo-code/references/content/schema.md +1 -0
- package/assets/skills/fimo-code/references/frameworks/astro.md +1 -1
- package/assets/skills/fimo-code/references/frameworks/next/app-router.md +12 -1
- package/assets/skills/fimo-code/references/frameworks/next/locales.md +2 -2
- package/assets/skills/fimo-code/references/frameworks/next.md +1 -1
- package/assets/skills/fimo-code/references/locales.md +4 -2
- package/assets/skills/fimo-migration/SKILL.md +54 -16
- package/assets/skills/fimo-migration/references/frameworks/nextjs.md +8 -0
- package/assets/skills/fimo-migration/references/media.md +11 -0
- package/assets/skills/fimo-migration/references/qa.md +30 -4
- package/assets/skills/fimo-migration/references/questions-and-improvements.md +188 -0
- package/assets/skills/fimo-migration/references/workers/content-planner.md +8 -3
- package/assets/skills/fimo-migration/references/workers/validator.md +20 -6
- package/assets/skills/fimo-migration/references/workers.md +17 -6
- package/assets/skills/fimo-migration/references/workflow.md +36 -6
- package/assets/skills/fimo-studio/SKILL.md +3 -1
- package/assets/skills/fimo-studio/references/agents.md +25 -0
- package/assets/skills/fimo-studio/references/ai-chat.md +1 -2
- package/assets/skills/fimo-studio/references/billing-and-credits.md +14 -7
- package/assets/skills/fimo-studio/references/visual-editing.md +9 -1
- package/assets/skills/fimo-studio/references/webhooks.md +1 -1
- package/dist/cli/bundle.json +2 -2
- package/dist/cli/index.js +210 -179
- package/dist/runtime/content/client/collection-core.js +3 -2
- package/dist/runtime/content/client/core-types.d.ts +4 -3
- package/dist/runtime/content/client/internal.d.ts +2 -0
- package/dist/runtime/content/client/internal.js +54 -25
- package/dist/runtime/content/client/singleton-core.js +2 -1
- package/dist/runtime/content/index.d.ts +1 -1
- package/dist/runtime/content/index.js +1 -1
- package/dist/runtime/content/serialization.d.ts +4 -3
- package/dist/runtime/content/serialization.js +4 -3
- package/dist/runtime/primitives/lib/index.d.ts +1 -1
- package/dist/runtime/primitives/lib/index.js +1 -1
- package/dist/runtime/primitives/lib/primitives.d.ts +39 -12
- package/dist/runtime/primitives/lib/primitives.js +83 -17
- package/dist/runtime/primitives/lib/template.js +2 -2
- package/dist/runtime/shared/local-runtime-env.d.ts +2 -2
- package/dist/runtime/shared/local-runtime-env.js +14 -9
- package/dist/runtime/templates.d.ts +9 -2
- package/dist/runtime/templates.js +36 -7
- package/dist/scripts/validate-schemas.js +10 -15
- package/package.json +10 -8
- package/release.json +2 -2
- package/templates/astro/AGENTS.md +1 -1
- package/templates/astro/package.json +2 -2
- package/templates/nextjs/AGENTS.md +2 -2
- package/templates/nextjs/package.json +3 -3
- package/templates/nextjs/src/app/layout.tsx +4 -1
- package/templates/react-router/AGENTS.md +2 -2
- package/templates/react-router/package.json +4 -4
- package/templates/sveltekit/AGENTS.md +1 -1
- package/templates/sveltekit/package.json +2 -2
- package/templates/vite/AGENTS.md +5 -1
- package/templates/vite/package.json +4 -4
- package/templates/welcome/manifest.json +655 -0
- package/templates/welcome/media/analytics-overview.avif +0 -0
- package/templates/welcome/media/autonomous-loop.avif +0 -0
- package/templates/welcome/media/editable-preview.avif +0 -0
- package/templates/welcome/media/media-library.avif +0 -0
- package/templates/welcome/media/slack-teams.avif +0 -0
- package/templates/welcome/template/.fimo/agents/welcome-guide/GOAL.md +12 -0
- package/templates/welcome/template/.fimo/agents/welcome-guide/capabilities.yaml +3 -0
- package/templates/welcome/template/.fimo/agents/welcome-guide/config.yaml +8 -0
- package/templates/welcome/template/.fimo/config.json +53 -0
- package/templates/welcome/template/src/font.css +60 -0
- package/templates/welcome/template/src/pages/ArticleDetail.tsx +104 -0
- package/templates/welcome/template/src/pages/Index.tsx +36 -0
- package/templates/welcome/template/src/pages/SiteContent.tsx +674 -0
- package/templates/welcome/template/src/pages/fallback-content.ts +152 -0
- package/templates/welcome/template/src/routes.ts +9 -0
- package/templates/welcome/template/src/schemas/Article.json +34 -0
- package/templates/welcome/template/src/schemas/Article.ts +54 -0
- package/templates/welcome/template/src/schemas/Article.types.ts +93 -0
- package/templates/welcome/template/src/schemas/Author.json +17 -0
- package/templates/welcome/template/src/schemas/Author.ts +51 -0
- package/templates/welcome/template/src/schemas/Author.types.ts +54 -0
- package/templates/welcome/template/src/schemas/Category.json +17 -0
- package/templates/welcome/template/src/schemas/Category.ts +51 -0
- package/templates/welcome/template/src/schemas/Category.types.ts +54 -0
- package/templates/welcome/template/src/schemas/HomePage.json +110 -0
- package/templates/welcome/template/src/schemas/HomePage.ts +22 -0
- package/templates/welcome/template/src/schemas/HomePage.types.ts +116 -0
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# Welcome guide
|
|
2
|
+
|
|
3
|
+
Improve this website's footer so its owner can review a real agent proposal.
|
|
4
|
+
|
|
5
|
+
1. Read the HomePage single in the CMS.
|
|
6
|
+
2. Set the "Footer Note" field to exactly:
|
|
7
|
+
"This website is maintained by your Fimo agent. Follow Fimo on X @fimoai and LinkedIn (fimoai)."
|
|
8
|
+
3. Change nothing else.
|
|
9
|
+
4. Finish with a two-sentence report: what you changed and why it helps.
|
|
10
|
+
5. Finish the run with the `retain` action: the owner reviews and accepts this change themselves — never merge or discard it.
|
|
11
|
+
|
|
12
|
+
Do not touch code, assets, or any other content, and do not publish.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
version: 1
|
|
2
|
+
description: 'Reviews the site copy and proposes one small improvement for you to approve.'
|
|
3
|
+
|
|
4
|
+
# Manual only. Pool preparation creates the tutorial's deterministic proposal
|
|
5
|
+
# without firing this trigger; keeping the trigger allows later real runs while
|
|
6
|
+
# avoiding a schedule that would keep spawning task environments.
|
|
7
|
+
triggers:
|
|
8
|
+
- type: manual
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"runtime": { "framework": "react-router" },
|
|
3
|
+
"seo": {
|
|
4
|
+
"title": "Welcome to Fimo",
|
|
5
|
+
"description": "Learn how to edit content, manage media, migrate a website, and run autonomous agents with Fimo.",
|
|
6
|
+
"siteName": "Welcome to Fimo",
|
|
7
|
+
"url": "https://fimo.ai/",
|
|
8
|
+
"image": "https://fimo.ai/socials/og_cover.png",
|
|
9
|
+
"favicon": "https://fimo.ai/favicon-orange.svg",
|
|
10
|
+
"locale": "en_US"
|
|
11
|
+
},
|
|
12
|
+
"i18n": {
|
|
13
|
+
"defaultLocale": "en",
|
|
14
|
+
"locales": ["en"],
|
|
15
|
+
"routing": {
|
|
16
|
+
"strategy": "path-prefix",
|
|
17
|
+
"prefixDefaultLocale": false
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"routes": {
|
|
21
|
+
"home": {
|
|
22
|
+
"label": "Welcome",
|
|
23
|
+
"path": "/:locale",
|
|
24
|
+
"params": { "locale": { "type": "locale", "optional": true } },
|
|
25
|
+
"seo": {
|
|
26
|
+
"title": "Welcome to Fimo",
|
|
27
|
+
"description": "Your editable Fimo tutorial project."
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
"article": {
|
|
31
|
+
"label": "Article",
|
|
32
|
+
"path": "/:locale/articles/:slug",
|
|
33
|
+
"params": {
|
|
34
|
+
"locale": { "type": "locale", "optional": true },
|
|
35
|
+
"slug": {
|
|
36
|
+
"schema": "Article",
|
|
37
|
+
"queryField": "slug"
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"seo": {
|
|
41
|
+
"title": "Fimo tutorial article",
|
|
42
|
+
"description": "Learn how to make your website autonomous with Fimo."
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"agents": {
|
|
47
|
+
"notifications": {
|
|
48
|
+
"email_recipients": []
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"version": "4",
|
|
52
|
+
"source": "cli"
|
|
53
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Geist+Mono:wght@400;500&display=swap');
|
|
2
|
+
|
|
3
|
+
.fimo-starter-font {
|
|
4
|
+
font-family:
|
|
5
|
+
'Manrope',
|
|
6
|
+
ui-sans-serif,
|
|
7
|
+
system-ui,
|
|
8
|
+
-apple-system,
|
|
9
|
+
BlinkMacSystemFont,
|
|
10
|
+
'Segoe UI',
|
|
11
|
+
sans-serif;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.fimo-mono {
|
|
15
|
+
font-family: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
|
|
16
|
+
letter-spacing: 0.08em;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
@keyframes fimo-icon-loop {
|
|
20
|
+
0%,
|
|
21
|
+
100% {
|
|
22
|
+
transform: translate(0, 0) rotate(0deg);
|
|
23
|
+
}
|
|
24
|
+
25% {
|
|
25
|
+
transform: translate(2px, -2px) rotate(6deg);
|
|
26
|
+
}
|
|
27
|
+
50% {
|
|
28
|
+
transform: translate(0, 1px) rotate(0deg);
|
|
29
|
+
}
|
|
30
|
+
75% {
|
|
31
|
+
transform: translate(-2px, -1px) rotate(-6deg);
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.step-cell:hover .step-icon {
|
|
36
|
+
animation: fimo-icon-loop 1.1s ease-in-out 2;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
@keyframes fimo-dot-blink {
|
|
40
|
+
0%,
|
|
41
|
+
80%,
|
|
42
|
+
100% {
|
|
43
|
+
opacity: 0.25;
|
|
44
|
+
}
|
|
45
|
+
40% {
|
|
46
|
+
opacity: 1;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.fimo-dots span {
|
|
51
|
+
animation: fimo-dot-blink 1.2s infinite;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.fimo-dots span:nth-child(2) {
|
|
55
|
+
animation-delay: 0.2s;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.fimo-dots span:nth-child(3) {
|
|
59
|
+
animation-delay: 0.4s;
|
|
60
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import { Image, RichText, Text } from 'fimo-react';
|
|
2
|
+
import { ArrowLeft } from 'lucide-react';
|
|
3
|
+
import { useEffect, useRef } from 'react';
|
|
4
|
+
import { Link, useParams } from 'react-router';
|
|
5
|
+
|
|
6
|
+
import ArticleContent from '@/schemas/Article';
|
|
7
|
+
|
|
8
|
+
import '../font.css';
|
|
9
|
+
import { ARTICLE_POPULATE, AuthorLine, useStudioScrollRelay } from './SiteContent';
|
|
10
|
+
|
|
11
|
+
const ArticleDetail = () => {
|
|
12
|
+
const { slug = '' } = useParams();
|
|
13
|
+
const { data: article, isLoading } = ArticleContent.useGetBySlug(slug, { populate: ARTICLE_POPULATE });
|
|
14
|
+
useStudioScrollRelay();
|
|
15
|
+
|
|
16
|
+
const bodyRef = useRef<HTMLDivElement | null>(null);
|
|
17
|
+
|
|
18
|
+
// Prompts in articles double as one-click actions: a button under each
|
|
19
|
+
// code block hands its text to the Studio chat, which submits it for the
|
|
20
|
+
// user. Injected into the DOM because the rich-text renderer owns the
|
|
21
|
+
// markup; the guard keeps re-renders from stacking duplicates.
|
|
22
|
+
useEffect(() => {
|
|
23
|
+
const container = bodyRef.current;
|
|
24
|
+
if (!container) {
|
|
25
|
+
return;
|
|
26
|
+
}
|
|
27
|
+
for (const pre of Array.from(container.querySelectorAll('pre'))) {
|
|
28
|
+
if (pre.nextElementSibling?.classList.contains('fimo-prompt-cta')) {
|
|
29
|
+
continue;
|
|
30
|
+
}
|
|
31
|
+
const button = document.createElement('button');
|
|
32
|
+
button.type = 'button';
|
|
33
|
+
button.textContent = 'Ask Fimo to build this';
|
|
34
|
+
button.className =
|
|
35
|
+
'fimo-prompt-cta mt-3 w-full cursor-pointer rounded-[8px] border border-orange-600 py-2.5 text-[15px] font-semibold text-orange-700 transition-colors hover:bg-orange-600 hover:text-white';
|
|
36
|
+
const text = pre.innerText;
|
|
37
|
+
button.addEventListener('click', () => {
|
|
38
|
+
window.parent.postMessage({ type: 'fimo:welcome:chat-prompt', text }, '*');
|
|
39
|
+
});
|
|
40
|
+
pre.insertAdjacentElement('afterend', button);
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
|
|
44
|
+
if (!article) {
|
|
45
|
+
return (
|
|
46
|
+
<main className="fimo-starter-font min-h-screen bg-zinc-100 px-3 py-3 text-zinc-950 sm:px-6 sm:py-8">
|
|
47
|
+
<div className="mx-auto max-w-4xl px-6 py-24 text-center sm:px-12">
|
|
48
|
+
<p className="text-zinc-600">{isLoading ? 'Loading article…' : 'This article does not exist.'}</p>
|
|
49
|
+
{!isLoading && (
|
|
50
|
+
<Link
|
|
51
|
+
to="/"
|
|
52
|
+
className="mt-6 inline-flex cursor-pointer items-center gap-2 rounded-[8px] font-semibold text-orange-700 hover:text-orange-800"
|
|
53
|
+
>
|
|
54
|
+
<ArrowLeft className="size-4" aria-hidden />
|
|
55
|
+
Back to the tutorial
|
|
56
|
+
</Link>
|
|
57
|
+
)}
|
|
58
|
+
</div>
|
|
59
|
+
</main>
|
|
60
|
+
);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
return (
|
|
64
|
+
<main className="fimo-starter-font min-h-screen bg-zinc-100 px-3 py-3 text-zinc-950 sm:px-6 sm:py-8">
|
|
65
|
+
<article className="mx-auto max-w-4xl">
|
|
66
|
+
<header className="border-b border-zinc-300 px-6 py-6 sm:px-12">
|
|
67
|
+
<Link
|
|
68
|
+
to="/"
|
|
69
|
+
className="inline-flex cursor-pointer items-center gap-2 rounded-[8px] text-sm font-semibold text-orange-700 hover:text-orange-800"
|
|
70
|
+
>
|
|
71
|
+
<ArrowLeft className="size-4" aria-hidden />
|
|
72
|
+
Back to the tutorial
|
|
73
|
+
</Link>
|
|
74
|
+
</header>
|
|
75
|
+
<div className="px-6 py-12 sm:px-12 sm:py-16">
|
|
76
|
+
<p className="text-xs font-semibold tracking-[0.18em] text-orange-700 uppercase">
|
|
77
|
+
{article.category ? <Text value={article.category.name} as="span" /> : 'Fimo tutorial'}
|
|
78
|
+
</p>
|
|
79
|
+
<Text
|
|
80
|
+
value={article.title}
|
|
81
|
+
as="h1"
|
|
82
|
+
className="mt-5 max-w-3xl text-4xl font-bold tracking-[-0.04em] sm:text-6xl"
|
|
83
|
+
/>
|
|
84
|
+
<Text value={article.summary} as="p" className="mt-6 max-w-2xl text-lg leading-8 text-zinc-600" />
|
|
85
|
+
{article.author ? <AuthorLine author={article.author} className="mt-6 !text-[14px]" /> : null}
|
|
86
|
+
<Image
|
|
87
|
+
value={article.cover}
|
|
88
|
+
className="mt-10 aspect-[48/25] w-full rounded-[8px] border border-zinc-950 object-cover"
|
|
89
|
+
loading="eager"
|
|
90
|
+
fetchPriority="high"
|
|
91
|
+
/>
|
|
92
|
+
<div ref={bodyRef}>
|
|
93
|
+
<RichText
|
|
94
|
+
value={article.body}
|
|
95
|
+
className="mx-auto mt-12 max-w-2xl text-lg leading-8 text-zinc-700 [&_a]:cursor-pointer [&_a]:font-semibold [&_a]:text-orange-700 [&_a]:underline [&_a]:underline-offset-4 [&_h2]:mt-12 [&_h2]:text-2xl [&_h2]:font-bold [&_h2]:tracking-[-0.02em] [&_h2]:text-zinc-950 [&_h2+p]:mt-4 [&_h3]:mt-8 [&_h3]:text-xl [&_h3]:font-bold [&_h3]:text-zinc-950 [&_li+li]:mt-2 [&_p+p]:mt-6 [&_pre]:mt-6 [&_pre]:overflow-x-auto [&_pre]:rounded-[8px] [&_pre]:bg-zinc-950 [&_pre]:p-5 [&_pre]:text-[15px] [&_pre]:leading-7 [&_pre]:whitespace-pre-wrap [&_pre]:text-zinc-100 [&_pre+p]:mt-6 [&_ul]:mt-6 [&_ul]:list-disc [&_ul]:pl-6 [&_ul+p]:mt-6"
|
|
96
|
+
/>
|
|
97
|
+
</div>
|
|
98
|
+
</div>
|
|
99
|
+
</article>
|
|
100
|
+
</main>
|
|
101
|
+
);
|
|
102
|
+
};
|
|
103
|
+
|
|
104
|
+
export default ArticleDetail;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import ArticleContent from '@/schemas/Article';
|
|
2
|
+
import HomePageContent from '@/schemas/HomePage';
|
|
3
|
+
|
|
4
|
+
import '../font.css';
|
|
5
|
+
import { FALLBACK_ARTICLES, FALLBACK_PAGE } from './fallback-content';
|
|
6
|
+
import { ARTICLE_POPULATE, ContentFallback, TutorialPage } from './SiteContent';
|
|
7
|
+
|
|
8
|
+
const Index = () => {
|
|
9
|
+
const { data: page, isLoading, isError } = HomePageContent.useGet();
|
|
10
|
+
const {
|
|
11
|
+
data: articles = [],
|
|
12
|
+
isLoading: articlesLoading,
|
|
13
|
+
isError: articlesError,
|
|
14
|
+
} = ArticleContent.useGet({ populate: ARTICLE_POPULATE });
|
|
15
|
+
|
|
16
|
+
// While loading, the page renders the seed copy through the same
|
|
17
|
+
// components, so the live values reconcile in place with no visible
|
|
18
|
+
// change and no layout shift. Keeping one JSX position avoids a remount
|
|
19
|
+
// on the fallback-to-live switch. Errors keep the seed copy up too —
|
|
20
|
+
// the query refetches on focus/reconnect, so an unreachable backend
|
|
21
|
+
// self-heals; the empty message is reserved for genuinely absent content.
|
|
22
|
+
const showTutorial = Boolean(page) || isLoading || articlesLoading || isError || articlesError;
|
|
23
|
+
const resolvedArticles = articles.length > 0 ? articles : articlesLoading ? FALLBACK_ARTICLES : articles;
|
|
24
|
+
|
|
25
|
+
return (
|
|
26
|
+
<div className="fimo-starter-font min-h-screen bg-white text-zinc-950">
|
|
27
|
+
{showTutorial ? (
|
|
28
|
+
<TutorialPage page={page ?? FALLBACK_PAGE} articles={page ? resolvedArticles : FALLBACK_ARTICLES} />
|
|
29
|
+
) : (
|
|
30
|
+
<ContentFallback />
|
|
31
|
+
)}
|
|
32
|
+
</div>
|
|
33
|
+
);
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export default Index;
|