@sudajs/cli 0.16.0 → 0.17.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sudajs/cli",
3
- "version": "0.16.0",
3
+ "version": "0.17.0",
4
4
  "type": "module",
5
5
  "bin": {
6
6
  "suda": "./bin/suda.js"
@@ -34,7 +34,7 @@
34
34
  "react": "^19.2.7",
35
35
  "react-dom": "^19.2.7",
36
36
  "zod": "^3.24.1",
37
- "@sudajs/theme-engine": "6.0.0"
37
+ "@sudajs/theme-engine": "6.1.0"
38
38
  },
39
39
  "devDependencies": {
40
40
  "@tailwindcss/postcss": "^4.3.0",
@@ -2,7 +2,7 @@
2
2
 
3
3
  This directory is a standalone Vite + React + Tailwind Suda theme generated by `suda theme init`.
4
4
 
5
- Your job in a theme project is to create a complete, publishable theme with theme-specific components, realistic starter pages, scoped styling, assets, and AI metadata. Do not build pages by assembling generic engine components; those are reserved for end users who need supplemental editing blocks after the theme is installed.
5
+ Your job in a theme project is to create a complete, publishable theme with theme-specific components, realistic starter pages, scoped styling, assets, and AI metadata. Do not build starter pages by assembling generic engine components. Suda adds those blocks automatically so users and AI can create supplemental content pages after the theme is installed.
6
6
 
7
7
  ## Component naming and editor organization
8
8
 
@@ -650,7 +650,7 @@ export const Hero: SudaComponentConfig<HeroProps> = {
650
650
  ## Component strategy
651
651
 
652
652
  - Create theme-specific components and sections first. Every page component should express this theme's brand, industry, visual rhythm, and content model.
653
- - Do not register `createEngineComponents()`, `createBaseBlocks()`, or `createContainers()` in `pageConfig.components` when creating a theme. Generic engine components are fallback editing tools for users, not the foundation of a theme template.
653
+ - Do not register `createEngineComponents()`, `createBaseBlocks()`, or `createContainers()` in `pageConfig.components` when creating a theme. Suda automatically adds the platform base content blocks (`Text`, `Heading`, `RichText`, `Markdown`, `Image`, `Button`, and `Spacer`) to every page config. Use the single `Markdown` block for standalone long-form pages such as privacy policies, terms, legal notices, documentation, or guides that should not appear in CMS posts. Generic blocks supplement theme-specific sections; they are not the foundation of starter templates.
654
654
  - Prefer purpose-built sections such as hero, services, product highlights, feature comparisons, gallery, process, pricing, testimonial, FAQ, article list, contact, and CTA when the theme needs those patterns.
655
655
  - Keep section APIs semantic. Expose props that describe content and editor decisions, not implementation details.
656
656
  - Keep `fields`, `defaultProps`, and `render` in sync. Every editor field should have a sensible default, and render functions should tolerate omitted optional values.
@@ -1032,7 +1032,7 @@ Good component instructions explain:
1032
1032
  - Frequency: whether it should appear once, multiple times, or only near another section.
1033
1033
  - Composition: required neighboring content or local blocks, when relevant.
1034
1034
 
1035
- - For icons, expose props with `{ type: "icon" }`, type values as `SudaLucideIconName`, render them with `SudaLucideIcon` from `@sudajs/theme-engine/icons`, and store canonical Lucide names such as `"rocket"` or `"mouse-pointer-click"` (not `"lucide-rocket"`). Do not keep theme-local icon maps, emoji/icon switch statements, or custom SVG icon registries unless the theme truly needs a bespoke non-Lucide graphic.
1035
+ - For icons, expose props with `{ type: "icon" }`, type values as `SudaIconName`, and render them with `SudaIcon` from `@sudajs/theme-engine/icons`. Store canonical Lucide names such as `"rocket"` or `"mouse-pointer-click"` (not `"lucide-rocket"`), or namespaced Simple Icons brand names such as `"simple-icons:github"`. Do not keep theme-local icon maps, emoji/icon switch statements, or custom SVG icon registries unless the theme truly needs a bespoke graphic.
1036
1036
  - Add optional field-level `ai.instructions`, `ai.required`, or `ai.exclude` when a prop needs generation guidance beyond its label and type.
1037
1037
  - Use `ai.exclude: true` only for structural or editor-only components, and still provide instructions explaining why AI must not generate them. `PageOutlet` is the standard example.
1038
1038
 
@@ -1,7 +1,7 @@
1
1
  import type { SudaComponentConfig } from "@sudajs/theme-engine";
2
2
  import {
3
- SudaLucideIcon,
4
- type SudaLucideIconName,
3
+ SudaIcon,
4
+ type SudaIconName,
5
5
  } from "@sudajs/theme-engine/icons";
6
6
  import {
7
7
  getPostResource,
@@ -13,7 +13,7 @@ import {
13
13
  import { t } from "./i18n.js";
14
14
  import { themeAsset } from "./theme-asset.js";
15
15
 
16
- type FeatureItem = { icon?: SudaLucideIconName; title?: string; description?: string };
16
+ type FeatureItem = { icon?: SudaIconName; title?: string; description?: string };
17
17
  type PuckExtras = { puck?: { metadata?: ThemeRenderMetadata } };
18
18
  type HeroProps = {
19
19
  showLogo?: boolean;
@@ -155,7 +155,7 @@ export const FeatureGrid: SudaComponentConfig<FeatureGridProps> = {
155
155
  >
156
156
  {features.map((feature: FeatureItem, index: number) => (
157
157
  <article className="__SUDA_THEME_KEY__-card" key={index}>
158
- <SudaLucideIcon className="__SUDA_THEME_KEY__-card-icon" name={feature.icon} />
158
+ <SudaIcon className="__SUDA_THEME_KEY__-card-icon" name={feature.icon} />
159
159
  <h3>{feature.title}</h3>
160
160
  <p>{feature.description}</p>
161
161
  </article>