@adoptai/genui-components 0.1.55 → 0.1.56
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/dist/builders/BuilderForm.d.ts.map +1 -1
- package/dist/index.cjs +9 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +9 -1
- package/dist/index.js.map +1 -1
- package/dist/tool-definitions.json +2 -2
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BuilderForm.d.ts","sourceRoot":"","sources":["../../src/builders/BuilderForm.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAiC,MAAM,OAAO,CAAC;AAItD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AACjD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAChD,OAAO,KAAK,EAAE,gBAAgB,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAE7E;;;kDAGkD;AAClD,MAAM,WAAW,iBAAiB;IAChC,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,GAAG,SAAS,GAAG,YAAY,CAAC;IAChD,MAAM,EAAE,KAAK,CAAC;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,CAAC,CAAC;IAC9E,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAClC;AAED,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,cAAc,CAAC;IACxB,QAAQ,EAAE,CAAC,UAAU,EAAE,iBAAiB,KAAK,IAAI,CAAC;IAClD,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,O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idationError
|
|
19732
19732
|
}) {
|
|
19733
|
+
var _a2;
|
|
19733
19734
|
const state = useBuilderState(builder.blocks);
|
|
19734
|
-
const
|
|
19735
|
+
const declaredKind = builder.builder_kind || "form";
|
|
19736
|
+
const blockCount = (builder.blocks || []).length;
|
|
19737
|
+
const kind = blockCount > 1 && declaredKind !== "stepper" ? "stepper" : declaredKind;
|
|
19738
|
+
if (kind !== declaredKind && typeof process !== "undefined" && ((_a2 = process.env) == null ? void 0 : _a2.NODE_ENV) !== "production") {
|
|
19739
|
+
console.warn(
|
|
19740
|
+
`[BuilderForm] builder "${builder.builder_id}" declared builder_kind="${declaredKind}" with ${blockCount} blocks; rendering as stepper to avoid dropping blocks.`
|
|
19741
|
+
);
|
|
19742
|
+
}
|
|
19735
19743
|
const buildSubmission = React41.useCallback(() => {
|
|
19736
19744
|
const blocks = (builder.blocks || []).map((b) => ({
|
|
19737
19745
|
id: b.id,
|