@xenosystem/blocks 0.16.0 → 0.16.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.
@@ -1199,9 +1199,10 @@ declare function fieldMatches(field: XenoInspectorField, term: string): boolean;
1199
1199
  /**
1200
1200
  * Project a schema into renderable sections.
1201
1201
  *
1202
- * Visibility-by-data: a section is dropped entirely when it has no matching fields AND no
1203
- * `emptyHint` — the panel never renders an empty box the user cannot act on. While a filter is
1204
- * active, `emptyHint`-only sections are also dropped (they are not search results).
1202
+ * Visibility-by-data: a section is dropped entirely when it has no matching fields AND nothing to
1203
+ * act on — no `emptyHint`, no `actions`, no `addMenu` — the panel never renders an empty box the
1204
+ * user cannot act on. (An action-only section — Canvas's align strip — IS something to act on.)
1205
+ * While a filter is active, fieldless sections are dropped regardless (they are not search results).
1205
1206
  */
1206
1207
  declare function projectSections(schema: XenoInspectorSchema, options?: ProjectOptions$1): ProjectedSection[];
1207
1208
  /** Whether a section is collapsed, honoring `defaultCollapsed` for sections the user never touched. */
@@ -1970,7 +1970,8 @@ function projectSections(schema, options = {}) {
1970
1970
  for (const section of schema.sections) {
1971
1971
  const fields = filtering ? section.fields.filter((f) => fieldMatches(f, term)) : section.fields;
1972
1972
  const empty = fields.length === 0;
1973
- if (empty && (filtering || !section.emptyHint)) continue;
1973
+ const actionable = !!section.emptyHint || (section.actions?.length ?? 0) > 0 || (section.addMenu?.length ?? 0) > 0;
1974
+ if (empty && (filtering || !actionable)) continue;
1974
1975
  const collapsed = !filtering && !!section.collapsible && isCollapsed(section, collapsedSet);
1975
1976
  out.push({
1976
1977
  section,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xenosystem/blocks",
3
- "version": "0.16.0",
3
+ "version": "0.16.1",
4
4
  "description": "XENO Blocks — rung 3 of the front ladder: components composed into a contract-bearing unit (manifest: ports, intents, commands, agent surface), rendered by @xenosystem/workbench. ONE package, one subpath per family (/auth, /edit, /data, /time, /ops, /trust, /agent), one named export per block — XENO PACKAGE NAMING - STANDARD.md.",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",