fimo 0.10.0-experimental.1 → 0.10.0-staging.2

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.
@@ -162,14 +162,33 @@ export function validateSchemaFile(absolutePath, file, schemaUids = new Set()) {
162
162
  file,
163
163
  });
164
164
  }
165
- if ('i18n' in definition || 'localized' in definition) {
166
- const key = 'i18n' in definition ? 'i18n' : 'localized';
165
+ if ('localized' in definition) {
167
166
  errors.push({
168
167
  rule: 'schemas/field-i18n',
169
- message: `Field "${fieldName}": field-level locale settings ("${key}") are not supported.`,
168
+ message: `Field "${fieldName}": "localized" is not supported. Use "i18n": false to share one value across locales.`,
170
169
  file,
171
170
  });
172
171
  }
172
+ // `i18n: false` shares one value across every locale of the document.
173
+ // Structured content follows the locale of the entry that carries it, so
174
+ // the flag has no row of its own to apply to there.
175
+ if ('i18n' in definition) {
176
+ const value = definition.i18n;
177
+ if (typeof value !== 'boolean') {
178
+ errors.push({
179
+ rule: 'schemas/field-i18n',
180
+ message: `Field "${fieldName}": "i18n" must be true or false.`,
181
+ file,
182
+ });
183
+ }
184
+ else if (type === 'blocks') {
185
+ errors.push({
186
+ rule: 'schemas/field-i18n',
187
+ message: `Field "${fieldName}": "i18n" is not supported on blocks fields.`,
188
+ file,
189
+ });
190
+ }
191
+ }
173
192
  if (type === 'blocks') {
174
193
  const parsed = ContentFieldDefinitionSchema.safeParse(definition);
175
194
  if (!parsed.success) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fimo",
3
- "version": "0.10.0-experimental.1",
3
+ "version": "0.10.0-staging.2",
4
4
  "description": "Fimo CLI - create, deploy, and manage Fimo projects",
5
5
  "bin": {
6
6
  "fimo": "dist/cli/index.js"
@@ -21,7 +21,7 @@
21
21
  "cmdk": "^1.1.1",
22
22
  "date-fns": "^4.1.0",
23
23
  "embla-carousel-react": "^8.6.0",
24
- "fimo": "0.10.0-experimental.1",
24
+ "fimo": "0.10.0-staging.2",
25
25
  "input-otp": "^1.4.2",
26
26
  "isbot": "^5",
27
27
  "lucide-react": "^0.577.0",