fimo 2.6.0-staging.2 → 2.6.0-staging.4

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.
@@ -98,7 +98,24 @@ export declare class FimoMedia {
98
98
  get __fimo(): FimoSource;
99
99
  }
100
100
  /**
101
- * FimoBoolean - Boolean with source tracking (for display purposes)
101
+ * FimoBoolean - a boolean with source tracking.
102
+ *
103
+ * Read `.value` before any condition, comparison, attribute, or third-party
104
+ * call, and pass the wrapper itself to `<Boolean>` so Studio keeps the edit
105
+ * target.
106
+ *
107
+ * `if (entry.featured)` is ALWAYS true, including for `false`, because the
108
+ * wrapper is an object. That is a language rule, not a gap to close here:
109
+ * `ToBoolean` on an object never consults `valueOf`, `Symbol.toPrimitive`, a
110
+ * `Boolean` subclass, or a `Proxy`, and TypeScript reports nothing (it
111
+ * special-cases only Promises and functions). Removing the wrapper is the only
112
+ * real fix; do not add a coercion hook that appears to solve it.
113
+ *
114
+ * `toString` and `toJSON` cover the two boundaries that DO give us a hook, so
115
+ * the wrapper stops leaking there: `${flag}` reads `"true"`/`"false"` instead
116
+ * of `"[object Object]"`, and `JSON.stringify` emits `false` instead of
117
+ * `{"value":false}` — a payload that rehydrates as a permanently truthy object.
118
+ * Framework boundaries still use `serializeContent`, which also drops metadata.
102
119
  */
103
120
  export declare class FimoBoolean {
104
121
  readonly value: boolean;
@@ -107,6 +124,8 @@ export declare class FimoBoolean {
107
124
  constructor(value: boolean, source: string, context?: FimoSourceContext);
108
125
  get __fimo(): FimoSource;
109
126
  valueOf(): boolean;
127
+ toString(): string;
128
+ toJSON(): boolean;
110
129
  }
111
130
  /**
112
131
  * Tiptap JSONContent structure for rich text
@@ -180,7 +180,24 @@ export class FimoMedia {
180
180
  }
181
181
  _f = FIMO_SOURCE, _g = FIMO_SOURCE_CONTEXT;
182
182
  /**
183
- * FimoBoolean - Boolean with source tracking (for display purposes)
183
+ * FimoBoolean - a boolean with source tracking.
184
+ *
185
+ * Read `.value` before any condition, comparison, attribute, or third-party
186
+ * call, and pass the wrapper itself to `<Boolean>` so Studio keeps the edit
187
+ * target.
188
+ *
189
+ * `if (entry.featured)` is ALWAYS true, including for `false`, because the
190
+ * wrapper is an object. That is a language rule, not a gap to close here:
191
+ * `ToBoolean` on an object never consults `valueOf`, `Symbol.toPrimitive`, a
192
+ * `Boolean` subclass, or a `Proxy`, and TypeScript reports nothing (it
193
+ * special-cases only Promises and functions). Removing the wrapper is the only
194
+ * real fix; do not add a coercion hook that appears to solve it.
195
+ *
196
+ * `toString` and `toJSON` cover the two boundaries that DO give us a hook, so
197
+ * the wrapper stops leaking there: `${flag}` reads `"true"`/`"false"` instead
198
+ * of `"[object Object]"`, and `JSON.stringify` emits `false` instead of
199
+ * `{"value":false}` — a payload that rehydrates as a permanently truthy object.
200
+ * Framework boundaries still use `serializeContent`, which also drops metadata.
184
201
  */
185
202
  export class FimoBoolean {
186
203
  constructor(value, source, context) {
@@ -212,6 +229,12 @@ export class FimoBoolean {
212
229
  valueOf() {
213
230
  return this.value;
214
231
  }
232
+ toString() {
233
+ return String(this.value);
234
+ }
235
+ toJSON() {
236
+ return this.value;
237
+ }
215
238
  }
216
239
  _h = FIMO_SOURCE, _j = FIMO_SOURCE_CONTEXT;
217
240
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fimo",
3
- "version": "2.6.0-staging.2",
3
+ "version": "2.6.0-staging.4",
4
4
  "description": "Fimo CLI - create, deploy, and manage Fimo projects",
5
5
  "keywords": [
6
6
  "astro-component"
@@ -194,13 +194,13 @@
194
194
  "devDependencies": {
195
195
  "@clack/core": "^1.2.0",
196
196
  "@clack/prompts": "^1.2.0",
197
- "@fimo/agents-bundle": "2.6.0-staging.2",
198
- "@fimo/api-contracts": "2.6.0-staging.2",
199
- "@fimo/cli-kit": "2.6.0-staging.2",
200
- "@fimo/framework-detect": "2.6.0-staging.2",
201
- "@fimo/routes": "2.6.0-staging.2",
202
- "@fimo/sdk": "2.6.0-staging.2",
203
- "@fimo/tsconfig": "2.6.0-staging.2",
197
+ "@fimo/agents-bundle": "2.6.0-staging.4",
198
+ "@fimo/api-contracts": "2.6.0-staging.4",
199
+ "@fimo/cli-kit": "2.6.0-staging.4",
200
+ "@fimo/framework-detect": "2.6.0-staging.4",
201
+ "@fimo/routes": "2.6.0-staging.4",
202
+ "@fimo/sdk": "2.6.0-staging.4",
203
+ "@fimo/tsconfig": "2.6.0-staging.4",
204
204
  "@types/node": "22.18.6",
205
205
  "agent-install": "^0.0.5",
206
206
  "astro": "^7.1.6",
@@ -9,8 +9,8 @@
9
9
  "check": "astro sync && astro check"
10
10
  },
11
11
  "dependencies": {
12
- "fimo": "2.6.0-staging.2",
13
- "fimo-astro": "2.6.0-staging.2"
12
+ "fimo": "2.6.0-staging.4",
13
+ "fimo-astro": "2.6.0-staging.4"
14
14
  },
15
15
  "devDependencies": {
16
16
  "@astrojs/check": "^0.9.10",
@@ -12,9 +12,9 @@
12
12
  },
13
13
  "dependencies": {
14
14
  "@tanstack/react-query": "^5.80.6",
15
- "fimo": "2.6.0-staging.2",
16
- "fimo-next": "2.6.0-staging.2",
17
- "fimo-react": "2.6.0-staging.2",
15
+ "fimo": "2.6.0-staging.4",
16
+ "fimo-next": "2.6.0-staging.4",
17
+ "fimo-react": "2.6.0-staging.4",
18
18
  "next": "^16.3.3",
19
19
  "react": "^19.2.7",
20
20
  "react-dom": "^19.2.7"
@@ -21,10 +21,10 @@
21
21
  "cn": "0.2.4",
22
22
  "date-fns": "^4.1.0",
23
23
  "embla-carousel-react": "^8.6.0",
24
- "fimo": "2.6.0-staging.2",
25
- "fimo-react": "2.6.0-staging.2",
26
- "fimo-react-router": "2.6.0-staging.2",
27
- "fimo-vite": "2.6.0-staging.2",
24
+ "fimo": "2.6.0-staging.4",
25
+ "fimo-react": "2.6.0-staging.4",
26
+ "fimo-react-router": "2.6.0-staging.4",
27
+ "fimo-vite": "2.6.0-staging.4",
28
28
  "input-otp": "^1.4.2",
29
29
  "isbot": "^5",
30
30
  "lucide-react": "^0.577.0",
@@ -11,8 +11,8 @@
11
11
  "prepare": "svelte-kit sync"
12
12
  },
13
13
  "dependencies": {
14
- "fimo": "2.6.0-staging.2",
15
- "fimo-sveltekit": "2.6.0-staging.2"
14
+ "fimo": "2.6.0-staging.4",
15
+ "fimo-sveltekit": "2.6.0-staging.4"
16
16
  },
17
17
  "devDependencies": {
18
18
  "@sveltejs/kit": "^2.70.2",
@@ -11,10 +11,10 @@
11
11
  },
12
12
  "dependencies": {
13
13
  "@tanstack/react-query": "^5.80.6",
14
- "fimo": "2.6.0-staging.2",
15
- "fimo-react": "2.6.0-staging.2",
16
- "fimo-react-router": "2.6.0-staging.2",
17
- "fimo-vite": "2.6.0-staging.2",
14
+ "fimo": "2.6.0-staging.4",
15
+ "fimo-react": "2.6.0-staging.4",
16
+ "fimo-react-router": "2.6.0-staging.4",
17
+ "fimo-vite": "2.6.0-staging.4",
18
18
  "react": "^19.2.7",
19
19
  "react-dom": "^19.2.7",
20
20
  "react-router": "^8.3.0"