reifyui 0.5.0 → 0.5.1
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/index.cjs +64 -53
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.js +64 -53
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/index.d.ts +3 -0
- package/src/sheet/SheetGrid.jsx +5 -1
package/dist/index.cjs
CHANGED
|
@@ -2410,73 +2410,84 @@ function ColumnMenu({ col, columns, anchor, columnTypes, renderColumnConfig, onA
|
|
|
2410
2410
|
deleteColumn: onDelete,
|
|
2411
2411
|
close: onClose
|
|
2412
2412
|
});
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
className: "shg-menu-input",
|
|
2424
|
-
rows: 3,
|
|
2425
|
-
value: optText,
|
|
2426
|
-
onChange: (e) => setOptText(e.target.value),
|
|
2427
|
-
placeholder: "Todo\nDoing\nDone"
|
|
2428
|
-
}
|
|
2429
|
-
)
|
|
2430
|
-
] }),
|
|
2431
|
-
custom !== void 0 ? custom : /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
|
|
2432
|
-
type === "compute" && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
|
|
2413
|
+
const desc = columnTypes.find((t) => t.type === type) || {};
|
|
2414
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
2415
|
+
PopPortal,
|
|
2416
|
+
{
|
|
2417
|
+
anchor,
|
|
2418
|
+
width: desc.configWidth || 250,
|
|
2419
|
+
estHeight: desc.configHeight || 340,
|
|
2420
|
+
className: "shg-menu",
|
|
2421
|
+
onClose,
|
|
2422
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { onClick: (e) => e.stopPropagation(), children: [
|
|
2433
2423
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-lbl", children: [
|
|
2434
|
-
"
|
|
2435
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("select", { className: "shg-menu-input", value:
|
|
2424
|
+
"Type",
|
|
2425
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("select", { className: "shg-menu-input", value: type, onChange: (e) => setType(e.target.value), children: columnTypes.map((t) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("option", { value: t.type, children: t.label }, t.type)) })
|
|
2436
2426
|
] }),
|
|
2437
|
-
(
|
|
2438
|
-
"
|
|
2439
|
-
"{{Name}}",
|
|
2427
|
+
(type === "select" || type === "tags") && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-lbl", children: [
|
|
2428
|
+
"Options (one per line)",
|
|
2440
2429
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
2441
2430
|
"textarea",
|
|
2442
2431
|
{
|
|
2443
2432
|
className: "shg-menu-input",
|
|
2444
2433
|
rows: 3,
|
|
2445
|
-
value:
|
|
2446
|
-
onChange: (e) =>
|
|
2447
|
-
placeholder: "
|
|
2434
|
+
value: optText,
|
|
2435
|
+
onChange: (e) => setOptText(e.target.value),
|
|
2436
|
+
placeholder: "Todo\nDoing\nDone"
|
|
2448
2437
|
}
|
|
2449
2438
|
)
|
|
2450
2439
|
] }),
|
|
2451
|
-
|
|
2452
|
-
"
|
|
2453
|
-
|
|
2454
|
-
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
"
|
|
2458
|
-
|
|
2440
|
+
custom !== void 0 ? custom : /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
|
|
2441
|
+
type === "compute" && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
|
|
2442
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-lbl", children: [
|
|
2443
|
+
"Runs",
|
|
2444
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("select", { className: "shg-menu-input", value: kind, onChange: (e) => setKind(e.target.value), children: COMPUTE_KINDS.map((k) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("option", { value: k.kind, children: k.label }, k.kind)) })
|
|
2445
|
+
] }),
|
|
2446
|
+
(kind === "prompt" || kind === "harness") && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-lbl", children: [
|
|
2447
|
+
"Prompt \u2014 reference columns as ",
|
|
2448
|
+
"{{Name}}",
|
|
2449
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
2450
|
+
"textarea",
|
|
2451
|
+
{
|
|
2452
|
+
className: "shg-menu-input",
|
|
2453
|
+
rows: 3,
|
|
2454
|
+
value: prompt,
|
|
2455
|
+
onChange: (e) => setPrompt(e.target.value),
|
|
2456
|
+
placeholder: "Summarize {{Company}} in one line"
|
|
2457
|
+
}
|
|
2458
|
+
)
|
|
2459
|
+
] }),
|
|
2460
|
+
kind === "harness" && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-lbl", children: [
|
|
2461
|
+
"Agent id",
|
|
2462
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("input", { className: "shg-menu-input", value: harnessId, onChange: (e) => setHarnessId(e.target.value), placeholder: "chrn_\u2026" })
|
|
2463
|
+
] }),
|
|
2464
|
+
kind === "workflow" && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
|
|
2465
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-lbl", children: [
|
|
2466
|
+
"Workflow id",
|
|
2467
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("input", { className: "shg-menu-input", value: wfSlug, onChange: (e) => setWfSlug(e.target.value), placeholder: "my-workflow" })
|
|
2468
|
+
] }),
|
|
2469
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-lbl", children: [
|
|
2470
|
+
"Output key (optional)",
|
|
2471
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("input", { className: "shg-menu-input", value: outKey, onChange: (e) => setOutKey(e.target.value), placeholder: "summary" })
|
|
2472
|
+
] })
|
|
2473
|
+
] }),
|
|
2474
|
+
others.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "shg-menu-lbl", children: [
|
|
2475
|
+
"Reads columns",
|
|
2476
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "shg-menu-deps", children: others.map((c) => /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-dep", children: [
|
|
2477
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("input", { type: "checkbox", checked: deps.has(c.id), onChange: () => toggleDep(c.id) }),
|
|
2478
|
+
" ",
|
|
2479
|
+
c.name
|
|
2480
|
+
] }, c.id)) })
|
|
2481
|
+
] })
|
|
2459
2482
|
] }),
|
|
2460
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("
|
|
2461
|
-
|
|
2462
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("
|
|
2483
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "shg-menu-actions", children: [
|
|
2484
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("button", { className: "shg-menu-del", onClick: onDelete, children: "Delete column" }),
|
|
2485
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("button", { className: "shg-menu-apply", onClick: apply, children: "Apply" })
|
|
2463
2486
|
] })
|
|
2464
|
-
] }),
|
|
2465
|
-
others.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "shg-menu-lbl", children: [
|
|
2466
|
-
"Reads columns",
|
|
2467
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "shg-menu-deps", children: others.map((c) => /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("label", { className: "shg-menu-dep", children: [
|
|
2468
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("input", { type: "checkbox", checked: deps.has(c.id), onChange: () => toggleDep(c.id) }),
|
|
2469
|
-
" ",
|
|
2470
|
-
c.name
|
|
2471
|
-
] }, c.id)) })
|
|
2472
2487
|
] })
|
|
2473
|
-
] }),
|
|
2474
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "shg-menu-actions", children: [
|
|
2475
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("button", { className: "shg-menu-del", onClick: onDelete, children: "Delete column" }),
|
|
2476
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("button", { className: "shg-menu-apply", onClick: apply, children: "Apply" })
|
|
2477
2488
|
] })
|
|
2478
|
-
|
|
2479
|
-
|
|
2489
|
+
}
|
|
2490
|
+
);
|
|
2480
2491
|
}
|
|
2481
2492
|
function defaultCellText(cell) {
|
|
2482
2493
|
const v = cell?.value;
|