@bluepic/embed 0.4.0-next.138 → 0.4.0-next.142

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.
@@ -0,0 +1,20 @@
1
+ import type { BluepicField } from '@bluepic/types';
2
+ /**
3
+ * Pure field-tree walks, deliberately kept OUT of `./fields.ts`.
4
+ *
5
+ * `fields.ts` imports the per-type icon components, so importing anything from
6
+ * it drags a dozen Vue SFCs along — fine in the browser bundle, fatal for any
7
+ * consumer that runs outside Vite (Node tests, headless tooling). These
8
+ * functions are plain logic over the field tree and have no such need.
9
+ *
10
+ * `fields.ts` re-exports `flattenFieldTable` so existing imports keep working.
11
+ */
12
+ /**
13
+ * Every LEAF field, in document order. `Group` is pure presentation — it holds
14
+ * no binding of its own — so it is flattened away rather than returned.
15
+ *
16
+ * `Collection` is NOT descended into: its nested `props.fields` are the
17
+ * per-item template, not fields with live bindings, while the Collection field
18
+ * itself does carry a `modelValue`. So it is returned as the leaf it behaves as.
19
+ */
20
+ export declare function flattenFieldTable(fields: BluepicField[]): BluepicField[];
@@ -10,7 +10,7 @@ export declare function modelField(model: BluepicField['model'], data: Ref<{
10
10
  [x: string]: unknown;
11
11
  };
12
12
  export declare function flattenFields(fields: BluepicField[]): MobileFieldsSlide[];
13
- export declare function flattenFieldTable(fields: BluepicField[]): BluepicField[];
13
+ export { flattenFieldTable } from './fieldTree';
14
14
  export declare function useMobileFields(fields: Ref<BluepicField[]>): {
15
15
  mobileFields: import("vue").ComputedRef<{
16
16
  originalField: BluepicFieldGroup | undefined;
@@ -54,6 +54,7 @@ export declare function stringifyField(field: BluepicField): {
54
54
  maxWidth: string;
55
55
  };
56
56
  hitbox?: import("@bluepic/types").Hitbox;
57
+ hintType?: import("@bluepic/types").FieldHintType;
57
58
  frameIndex?: number;
58
59
  } | {
59
60
  props: {
@@ -70,6 +71,7 @@ export declare function stringifyField(field: BluepicField): {
70
71
  maxWidth: string;
71
72
  };
72
73
  hitbox?: import("@bluepic/types").Hitbox;
74
+ hintType?: import("@bluepic/types").FieldHintType;
73
75
  frameIndex?: number;
74
76
  } | {
75
77
  props: {
@@ -87,6 +89,7 @@ export declare function stringifyField(field: BluepicField): {
87
89
  maxWidth: string;
88
90
  };
89
91
  hitbox?: import("@bluepic/types").Hitbox;
92
+ hintType?: import("@bluepic/types").FieldHintType;
90
93
  frameIndex?: number;
91
94
  } | {
92
95
  props: {
@@ -101,6 +104,7 @@ export declare function stringifyField(field: BluepicField): {
101
104
  maxWidth: string;
102
105
  };
103
106
  hitbox?: import("@bluepic/types").Hitbox;
107
+ hintType?: import("@bluepic/types").FieldHintType;
104
108
  frameIndex?: number;
105
109
  } | {
106
110
  props: {
@@ -117,6 +121,7 @@ export declare function stringifyField(field: BluepicField): {
117
121
  maxWidth: string;
118
122
  };
119
123
  hitbox?: import("@bluepic/types").Hitbox;
124
+ hintType?: import("@bluepic/types").FieldHintType;
120
125
  frameIndex?: number;
121
126
  } | {
122
127
  props: {
@@ -133,6 +138,7 @@ export declare function stringifyField(field: BluepicField): {
133
138
  maxWidth: string;
134
139
  };
135
140
  hitbox?: import("@bluepic/types").Hitbox;
141
+ hintType?: import("@bluepic/types").FieldHintType;
136
142
  frameIndex?: number;
137
143
  } | {
138
144
  props: {
@@ -149,6 +155,7 @@ export declare function stringifyField(field: BluepicField): {
149
155
  maxWidth: string;
150
156
  };
151
157
  hitbox?: import("@bluepic/types").Hitbox;
158
+ hintType?: import("@bluepic/types").FieldHintType;
152
159
  frameIndex?: number;
153
160
  } | {
154
161
  props: {
@@ -165,6 +172,7 @@ export declare function stringifyField(field: BluepicField): {
165
172
  maxWidth: string;
166
173
  };
167
174
  hitbox?: import("@bluepic/types").Hitbox;
175
+ hintType?: import("@bluepic/types").FieldHintType;
168
176
  frameIndex?: number;
169
177
  } | {
170
178
  props: {
@@ -181,6 +189,7 @@ export declare function stringifyField(field: BluepicField): {
181
189
  maxWidth: string;
182
190
  };
183
191
  hitbox?: import("@bluepic/types").Hitbox;
192
+ hintType?: import("@bluepic/types").FieldHintType;
184
193
  frameIndex?: number;
185
194
  } | {
186
195
  props: {
@@ -197,6 +206,7 @@ export declare function stringifyField(field: BluepicField): {
197
206
  maxWidth: string;
198
207
  };
199
208
  hitbox?: import("@bluepic/types").Hitbox;
209
+ hintType?: import("@bluepic/types").FieldHintType;
200
210
  frameIndex?: number;
201
211
  } | {
202
212
  props: {
@@ -213,6 +223,7 @@ export declare function stringifyField(field: BluepicField): {
213
223
  maxWidth: string;
214
224
  };
215
225
  hitbox?: import("@bluepic/types").Hitbox;
226
+ hintType?: import("@bluepic/types").FieldHintType;
216
227
  frameIndex?: number;
217
228
  } | {
218
229
  props: {
@@ -229,6 +240,7 @@ export declare function stringifyField(field: BluepicField): {
229
240
  maxWidth: string;
230
241
  };
231
242
  hitbox?: import("@bluepic/types").Hitbox;
243
+ hintType?: import("@bluepic/types").FieldHintType;
232
244
  frameIndex?: number;
233
245
  } | {
234
246
  props: {
@@ -245,6 +257,7 @@ export declare function stringifyField(field: BluepicField): {
245
257
  maxWidth: string;
246
258
  };
247
259
  hitbox?: import("@bluepic/types").Hitbox;
260
+ hintType?: import("@bluepic/types").FieldHintType;
248
261
  frameIndex?: number;
249
262
  } | {
250
263
  props: {
@@ -261,6 +274,7 @@ export declare function stringifyField(field: BluepicField): {
261
274
  maxWidth: string;
262
275
  };
263
276
  hitbox?: import("@bluepic/types").Hitbox;
277
+ hintType?: import("@bluepic/types").FieldHintType;
264
278
  frameIndex?: number;
265
279
  } | {
266
280
  props: {
@@ -275,6 +289,7 @@ export declare function stringifyField(field: BluepicField): {
275
289
  maxWidth: string;
276
290
  };
277
291
  hitbox?: import("@bluepic/types").Hitbox;
292
+ hintType?: import("@bluepic/types").FieldHintType;
278
293
  frameIndex?: number;
279
294
  } | {
280
295
  props: {
@@ -291,6 +306,7 @@ export declare function stringifyField(field: BluepicField): {
291
306
  maxWidth: string;
292
307
  };
293
308
  hitbox?: import("@bluepic/types").Hitbox;
309
+ hintType?: import("@bluepic/types").FieldHintType;
294
310
  frameIndex?: number;
295
311
  };
296
312
  export declare function renderFieldIcon(fieldType: BluepicField['type']): import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bluepic/embed",
3
- "version": "0.4.0-next.138",
3
+ "version": "0.4.0-next.142",
4
4
  "description": "Bluepic embed sdk",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -37,14 +37,15 @@
37
37
  "dev:types": "vue-tsc -p tsconfig.build.json --declaration --emitDeclarationOnly --outDir dist --watch",
38
38
  "playground:dev": "vite --config vite.playground.config.ts",
39
39
  "test:autocrop": "tsx src/util/autoCrop/solveAutoCrop.test.ts",
40
- "test:gallery": "tsx src/util/gallery.test.ts"
40
+ "test:gallery": "tsx src/util/gallery.test.ts",
41
+ "test:fieldhints": "tsx src/util/fieldHints/fieldHints.test.ts"
41
42
  },
42
43
  "peerDependencies": {
43
44
  "vue": "^3.5.23"
44
45
  },
45
46
  "devDependencies": {
46
47
  "@auth0/auth0-vue": "^2.4.0",
47
- "@bluepic/types": "^0.6.486",
48
+ "@bluepic/types": "^0.6.494",
48
49
  "@hono/zod-openapi": "^1.1.4",
49
50
  "@types/css": "^0.0.38",
50
51
  "@types/downloadjs": "^1.4.6",