@cardenelabs/cdl 0.108.0 → 0.109.0

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.js CHANGED
@@ -23474,12 +23474,13 @@ function CdlHeader({
23474
23474
  stateValues,
23475
23475
  states,
23476
23476
  onJumpPhase,
23477
- headingLevel = 3
23477
+ headingLevel = 3,
23478
+ showTopic = true
23478
23479
  }) {
23479
23480
  const HeadingTag = `h${headingLevel}`;
23480
23481
  return /* @__PURE__ */ jsxs("div", { className: "border-b border-[var(--cdl-divider,#d4d4d8)]/35 px-7 py-6", children: [
23481
23482
  /* @__PURE__ */ jsxs("div", { className: "mb-5 flex items-center gap-3", children: [
23482
- /* @__PURE__ */ jsx("div", { className: "text-[10px] font-bold uppercase tracking-[0.2em]", style: { color: "var(--cdl-text-accent, #2d6a8f)" }, children: topic }),
23483
+ showTopic && /* @__PURE__ */ jsx("div", { className: "text-[10px] font-bold uppercase tracking-[0.2em]", style: { color: "var(--cdl-text-accent, #2d6a8f)" }, children: topic }),
23483
23484
  /* @__PURE__ */ jsxs("div", { className: "ml-auto flex items-center gap-1.5", children: [
23484
23485
  phases.map((p, idx) => {
23485
23486
  const active = idx === phaseIdx;
@@ -33585,6 +33586,11 @@ function CdlDiagramView({ diagram: diagram2, laid: laidProp, hideHeader = false,
33585
33586
  return mergeStateValues(baseStateValues, interactive.stateOverrides);
33586
33587
  }, [isInteractive, baseStateValues, interactive.stateOverrides]);
33587
33588
  const \u5024\u306E\u540D\u524D = useMemo(() => \u5024\u306E\u540D\u524D\u306E\u8868\u3092\u4F5C\u308B(diagram2.inputs), [diagram2.inputs]);
33589
+ const \u56F3\u304C\u8A71\u984C\u3092\u63CF\u304F = useMemo(() => {
33590
+ const \u8A71\u984C = laid.topic.trim();
33591
+ if (\u8A71\u984C === "") return false;
33592
+ return laid.nodes.some((n) => drawsFigureTitle(n.kind) && (n.title ?? "").trim() === \u8A71\u984C);
33593
+ }, [laid.nodes, laid.topic]);
33588
33594
  return /* @__PURE__ */ jsxs(
33589
33595
  "div",
33590
33596
  {
@@ -33609,7 +33615,8 @@ function CdlDiagramView({ diagram: diagram2, laid: laidProp, hideHeader = false,
33609
33615
  timeline.goto(idx);
33610
33616
  timeline.play();
33611
33617
  },
33612
- headingLevel
33618
+ headingLevel,
33619
+ showTopic: !\u56F3\u304C\u8A71\u984C\u3092\u63CF\u304F
33613
33620
  }
33614
33621
  ),
33615
33622
  isInteractive && interactive.panel,