@floless/app 0.126.4 → 0.127.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.
@@ -572,6 +572,9 @@
572
572
  const ws = mode === 'workspaces';
573
573
  $app.classList.toggle('mode-workspaces', ws);
574
574
  document.body.classList.toggle('mode-workspaces', ws);
575
+ // The provenance strip is workflow-level data. Workspaces replaces that surface (including its
576
+ // landing), so cancel any late workflow-pin paint before the project UI starts loading.
577
+ if (ws && bridge.clearKbInformed) bridge.clearKbInformed();
575
578
  $switch.querySelectorAll('button').forEach((b) => {
576
579
  const on = b.dataset.mode === mode;
577
580
  b.classList.toggle('active', on);
@@ -8173,6 +8176,26 @@
8173
8176
  if ($projPopover && !$projPopover.hidden && $projCombo && !$projCombo.contains(e.target)) closeProjCombo(false);
8174
8177
  });
8175
8178
 
8176
- window.flolessWorkspaces = { setMode, refresh: loadProjects, findActive: wsFindActive, find: wsFind, clearFind: wsClearFind, openHistory: wsOpenHistory };
8179
+ /**
8180
+ * Open one Knowledge Base page, from outside this module — the "Informed by" row in Workflows mode
8181
+ * is the only caller today. The page viewer is driven by module-private `current` + `viewer` state,
8182
+ * so there is no way in without a seam.
8183
+ *
8184
+ * EVERY await here is load-bearing. `openProject` is async and its `setStep('knowledge')` runs
8185
+ * `kbResetViewer()` → `setViewer({mode:'graph'})`; setting the page viewer before that resolves
8186
+ * would be silently overwritten and drop the user on the graph, looking like the link went to the
8187
+ * wrong place. The `current` re-check afterwards is the ordinary stale-navigation guard — the user
8188
+ * can pick a different project while the open is in flight.
8189
+ */
8190
+ async function openKnowledgePage(projectId, slug) {
8191
+ if (!projectId || !slug) return;
8192
+ await setMode('workspaces');
8193
+ await openProject(projectId, 'knowledge');
8194
+ if (!current || current.id !== projectId) return; // navigated away mid-open
8195
+ setViewer({ mode: 'page', slug, sourceId: null });
8196
+ renderKnowledge();
8197
+ }
8198
+
8199
+ window.flolessWorkspaces = { setMode, refresh: loadProjects, findActive: wsFindActive, find: wsFind, clearFind: wsClearFind, openHistory: wsOpenHistory, openKnowledgePage };
8177
8200
  applyMode(); // restore persisted mode immediately (matches panels.js applyView timing)
8178
8201
  })();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@floless/app",
3
- "version": "0.126.4",
3
+ "version": "0.127.0",
4
4
  "type": "module",
5
5
  "description": "Thin localhost host for floless.app — serves web/ and shells the aware CLI. No engine, no LLM.",
6
6
  "bin": {