- Translate to English every doc the code branches did not touch: AGENT.md, developer guide, vibe, CHANGELOG, docs index, module pages, all skills except ipal-seo-check (14 pages follow after the security/SEO merge). Placeholder marker is now [TO FILL: …]; skill resources renamed to section-code.md / nav-code.md. AGENT.md and the ipal-skills pointer block say the docs are in English. - docs/seeding.md: create-only, natural keys, never delete, no users or secrets, empty-field globals, fallbackLocale: false, dry run, backup and restore, production update guard, seeds vs migrations, Coolify Terminal. Seed templates gain --dry-run, the SEED_UPDATE production guard (IPAL_SEED_ALLOW_PROD_UPDATE), skip of edited records and a summary. "Seeding on production" rule block in AGENT.md. - Coolify is the single deployment path (deployment, env, developer guide, ipal-setup): build vs runtime env, migrations on container start (prodMigrations), health check and rolling updates, rollback, backups and restore, DNS/Let's Encrypt/CAA. R2: custom domain needs a Cloudflare zone; default is media served by the app (R2_PUBLIC_URL empty). - docsConsistency: no Polish prose outside code/quoted data (pending pages listed); IPAL_* names may also be read by shipped skill templates. Co-Authored-By: Claude Opus 5.5 <[email protected]>
3.0 KiB
name, description
| name | description |
|---|---|
| ipal-collection | Decides whether something should be a Payload collection, a global, or a block, and builds a content collection the ipal-kit way (title, buildSlugField, SEO tab, buildNoindexField, trackSlugHistoryHook, revalidate hook, archive page from System Pages, sitemap and routing via content option). Use when the user asks for a blog, news, products, portfolio, testimonials, authors, categories, or any new collection — and whenever you are about to create a file in src/collections. |
ipal-collection
Sources: node_modules/@intecion/ipal-kit/docs/agent/AGENT.md §5,
docs/content.md, docs/hooks.md, docs/seo.md.
1. Test (always, before any code)
Answer these 4 questions for the user — all must be YES:
- Is it a list of many records of the same type?
- Does each record have its own URL?
- Does the client explicitly require it?
- Does Payload not have it built in?
Any NO → it is not a collection:
- one set of data (company, menu, footer, settings) → global,
- part of a page (FAQ, hero, testimonials in a section) → block (ipal-block skill),
users→ the plugin injects it when the project has none; create your own collection with that slug only to add fields (it wins over the injected one; roles and 2FA attach to it).
Exception: a list without its own URLs managed separately (e.g. testimonials used in many
blocks) — a collection without wiring into content. Justify it in the plan.
2. Plan (write it, then go straight to code — AGENT.md §0a)
slug (camelCase, plural), fields, relations, whether it has URLs (archive), JSON-LD.
Record the "collection vs global vs block" decision in AGENTS.md → "Project decisions".
Ask only when the brief leaves a business question open (e.g. "do posts have authors?").
3. Code
src/collections/<Name>.ts:title(localized),buildSlugField({ from: 'title' }), SEO tab (plugin-seo),buildNoindexField(),trackSlugHistoryHook,buildRevalidateHook,setPublishedAtHook(dated entries), uploads viamedia, links viabuildLinkField(). Field names per AGENT.md §6.5. Panel (AGENT.md §6.5a):admin.useAsTitle,defaultColumns(3–4),admin.group: 'Content',labelsin English, arrays withlabels+rowLabel(), settings in the sidebar.- With URLs: add it to
content.config.ts→{ slug, perPage }. No URL prefix in code — the editor assigns the archive page in Site Settings (<slug>Archive). The plugin handles routing, sitemap, generateStaticParams, hreflang. - Entry list = a block (EntriesList) with
getEntries; the entry page usesresolveRoute(typeentry); JSON-LD per seo.md (e.g. Article). pnpm generate:types,pnpm payload generate:importmap.- Postgres with migrations →
pnpm payload migrate:create.
4. Check
The ipal-audit skill. By hand: an entry in the panel → visible at /<locale>/<archive>/<slug>,
in the sitemap; changing the slug → 308 from the old address.