From 42551733d8a07aa79cb7cfdc1f824f517d15631c Mon Sep 17 00:00:00 2001 From: Agent Date: Sun, 11 Oct 2026 08:31:35 +0000 Subject: [PATCH] v1.2.1: fix unstyled advisor button (stylesheet install was dropped in the per-session refactor) --- client.js | 2 ++ package.json | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/client.js b/client.js index 7e52a7b..baab59d 100644 --- a/client.js +++ b/client.js @@ -150,6 +150,7 @@ window.__ModuleLoader__.load({ } function AdvisorPickerFor({ sessionId, directory, load, t }) { + React.useEffect(installCss, []); // idempotent; also installed in apply() const store = storeFor(sessionId); const st = useSettings(store); const dir = React.useSyncExternalStore((f) => directory.subscribe(f), () => directory.getSnapshot()); @@ -296,6 +297,7 @@ window.__ModuleLoader__.load({ inject: ['slots', 'locale', 'sessions', 'modelDirectories'], apply(ctx) { ctx.effect(() => ctx.locale.register(NS, { en, zh }), 'omp-advisor: dictionaries'); + installCss(); // styles must exist before the first render of the composer control ctx.slots.inject('conversation.input.right', () => ctx.slots.register({ name: 'conversation.input.right', id: 'omp-advisor', diff --git a/package.json b/package.json index d039bf3..8832127 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@local/omp-advisor", - "version": "1.2.0", + "version": "1.2.1", "description": "oh-my-pi style advisor for DSH: a second model reviews every agent step and injects notes, concerns or blockers.", "private": true, "type": "module",