create-pmos 0.361.0 → 0.363.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.
Files changed (43) hide show
  1. package/package.json +40 -25
  2. package/payload/KIT-VERSION +1 -1
  3. package/payload/planning/evals/eval-calibration.md +1 -1
  4. package/payload/planning/okrs/health-budgets.md +1 -1
  5. package/payload/state/discoveries.md +1 -1
  6. package/workspace/briefing-premium-board-test.js +4 -4
  7. package/workspace/briefing-premium-calendar-2-test.js +3 -3
  8. package/workspace/briefing-premium-calendar-3-test.js +6 -5
  9. package/workspace/briefing-premium-calendar-test.js +3 -2
  10. package/workspace/briefing-premium-initiative-test.js +3 -3
  11. package/workspace/briefing-premium-insights-test.js +1 -1
  12. package/workspace/briefing-premium-test.js +26 -11
  13. package/workspace/briefing-premium-work-test.js +1 -1
  14. package/workspace/changelog.json +39 -0
  15. package/workspace/guide/briefing-premium.md +26 -21
  16. package/workspace/lib/board-premium.js +8 -3
  17. package/workspace/lib/engine/boards.js +5 -3
  18. package/workspace/lib/proactive.js +21 -3
  19. package/workspace/lib/routes-board-premium.js +1 -1
  20. package/workspace/lib/routes-boards.js +15 -1
  21. package/workspace/package-lock.json +2 -2
  22. package/workspace/package.json +1 -1
  23. package/workspace/premium-studio-test.js +6 -6
  24. package/workspace/premium-vw-item-test.js +2 -2
  25. package/workspace/premium-vw-jira-test.js +22 -6
  26. package/workspace/premium-vw-meet-test.js +32 -21
  27. package/workspace/premium-vw-notes-test.js +5 -5
  28. package/workspace/premium-vw-rec-test.js +1 -1
  29. package/workspace/public/pm/premium-board.js +3 -3
  30. package/workspace/public/pm/premium-meeting.js +28 -29
  31. package/workspace/public/pm/premium-shell.js +44 -21
  32. package/workspace/public/pm/premium-vw-jira-model.js +8 -5
  33. package/workspace/public/pm/premium-vw-jira.css +9 -0
  34. package/workspace/public/pm/premium-vw-jira.js +21 -9
  35. package/workspace/public/pm/premium-vw-meet.css +27 -7
  36. package/workspace/public/pm/premium-vw-meet.js +31 -16
  37. package/workspace/public/pm/premium.css +28 -4
  38. package/workspace/public/premium-board.html +1 -0
  39. package/workspace/public/premium-initiative.html +1 -0
  40. package/workspace/public/premium-insights.html +1 -0
  41. package/workspace/public/premium-work.html +2 -1
  42. package/workspace/public/premium.html +2 -1
  43. package/workspace/server.js +13 -2
@@ -25,6 +25,7 @@
25
25
  <i class="ind"></i>
26
26
  <button class="pl" data-go="brief" aria-current="page"><svg class="i" viewBox="0 0 24 24"><circle cx="12" cy="12" r="4"/><path d="M12 2v2M12 20v2M2 12h2M20 12h2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4"/></svg>Briefing</button>
27
27
  <button class="pl" data-go="work"><svg class="i" viewBox="0 0 24 24"><rect x="4" y="4" width="16" height="16" rx="3"/><path d="m8.5 12 2.5 2.5 4.5-5"/></svg>My work</button>
28
+ <button class="pl pchat" data-go="chat" aria-haspopup="dialog" aria-label="Chat" title="Chat"><span class="orb"><svg class="i" viewBox="0 0 24 24"><path d="M4 5h16v11h-9l-5 4v-4H4z"/><path d="M12 7.6l.8 1.9 1.9.8-1.9.8-.8 1.9-.8-1.9-1.9-.8 1.9-.8z"/></svg><i class="cdot" hidden></i></span>Chat</button>
28
29
  <button class="pl" data-go="init"><svg class="i" viewBox="0 0 24 24"><path d="M12 3 3 8l9 5 9-5z"/><path d="m3 13 9 5 9-5"/></svg>Board</button>
29
30
  <button class="pl" data-go="rep"><svg class="i" viewBox="0 0 24 24"><path d="M4 20V10M10 20V4M16 20v-8M22 20H2"/></svg>Insights</button>
30
31
  </nav>
@@ -42,7 +43,7 @@
42
43
  <div class="toast glass" id="toast" role="status"></div>
43
44
  <main class="stage" id="stage">
44
45
  <header class="top rise" style="--d:0">
45
- <h1 class="vh">Briefing</h1><div class="where"><span class="glass name" aria-hidden="true">Briefing</span><button class="round tbchat" id="pgChat" aria-haspopup="dialog" aria-label="Ask about this page" title="Ask about this page"></button></div>
46
+ <h1 class="vh">Briefing</h1><div class="where"><span class="glass name" aria-hidden="true">Briefing</span></div>
46
47
  <div class="tools tools-top"><span class="vh" id="snap">Reading the repository</span>
47
48
  <span id="pkPark" hidden><span class="pkw" id="pkw" hidden><button class="fchip" id="pick" aria-haspopup="menu" aria-expanded="false" aria-controls="pickMenu">Products<em id="pickN"></em></button><div class="crmenu pkmenu" id="pickMenu" role="menu" hidden></div></span></span></div>
48
49
  </header>
@@ -4914,6 +4914,17 @@ function proSettings() {
4914
4914
  try { const n = proactiveLib.normalizeSettings(JSON.parse(fs.readFileSync(PRO_SETTINGS(), 'utf8'))); if (n.ok) return n.settings; } catch { /* defaults */ }
4915
4915
  return proactiveLib.normalizeSettings({}).settings;
4916
4916
  }
4917
+ /* The connectors a new Claude session starts with: those of the default profile, else those of Claude Code's own config
4918
+ * (~/.claude.json, or the one in CLAUDE_CONFIG_DIR). Names only (profile-discovery.connectorsIn), each with the brief source
4919
+ * it already backs, so premium Settings can list every connector and say which ones nothing reads yet. */
4920
+ function sessionConnectors() {
4921
+ const disc = require('./lib/profile-discovery');
4922
+ const id = defaultProfileFor('claude');
4923
+ const prof = id ? profileById(id).profile : null;
4924
+ const dir = prof ? (prof.env && prof.env.CLAUDE_CONFIG_DIR) || null : process.env.CLAUDE_CONFIG_DIR || os.homedir();
4925
+ const names = [...new Set([...(prof && Array.isArray(prof.mcp) ? prof.mcp : []), ...(dir ? disc.connectorsIn(dir) : [])])];
4926
+ return { profile: prof ? prof.id : null, list: names.slice(0, proactiveLib.MAX_CONNECTORS).map((name) => ({ name, label: proactiveLib.connectorLabel(name) || name, source: proactiveLib.connectorSource(name) })) };
4927
+ }
4917
4928
  function proactiveCtx(now, settings) {
4918
4929
  const repos = [];
4919
4930
  const allSchedules = readSchedules();
@@ -9245,7 +9256,7 @@ async function handleRequest(req, res) {
9245
9256
  }
9246
9257
  }
9247
9258
  if (p === '/api/proactive/settings') {
9248
- if (req.method === 'GET') return json(res, { ok: true, settings: proSettings() });
9259
+ if (req.method === 'GET') return json(res, { ok: true, settings: proSettings(), connectors: sessionConnectors() });
9249
9260
  if (req.method === 'POST') {
9250
9261
  let body = {}; try { body = JSON.parse((await readBody(req)) || '{}'); } catch { return json(res, { ok: false, error: 'invalid JSON body' }, 400); }
9251
9262
  const g = pmGuard.requirePagePress(req, body); // a settings write is a page press, so an agent session gets 403
@@ -9257,7 +9268,7 @@ async function handleRequest(req, res) {
9257
9268
  const dayCheck = body.dayCheck && typeof body.dayCheck === 'object' && !Array.isArray(body.dayCheck) ? { ...cur.dayCheck, ...body.dayCheck } : (body.dayCheck === undefined ? cur.dayCheck : body.dayCheck);
9258
9269
  const bpr = body.placeRepos && typeof body.placeRepos === 'object' && !Array.isArray(body.placeRepos) ? body.placeRepos : null;
9259
9270
  const placeRepos = bpr ? { ...cur.placeRepos, ...Object.fromEntries(Object.entries(bpr).map(([k, v]) => [k, v && typeof v === 'object' && !Array.isArray(v) ? { ...((cur.placeRepos || {})[k] || {}), ...v } : v])) } : cur.placeRepos;
9260
- const n = proactiveLib.normalizeSettings({ ...cur, ...body, placeRepos, triggers: { ...cur.triggers, ...(body.triggers || {}) }, briefSources: { ...cur.briefSources, ...(body.briefSources || {}) }, about: { ...(cur.about || {}), ...(body.about && typeof body.about === 'object' && !Array.isArray(body.about) ? body.about : {}) }, scopes, dayCheck });
9271
+ const n = proactiveLib.normalizeSettings({ ...cur, ...body, placeRepos, triggers: { ...cur.triggers, ...(body.triggers || {}) }, briefSources: { ...cur.briefSources, ...(body.briefSources || {}) }, connectors: body.connectors && typeof body.connectors === 'object' && !Array.isArray(body.connectors) ? { ...(cur.connectors || {}), ...body.connectors } : (body.connectors === undefined ? cur.connectors : body.connectors), about: { ...(cur.about || {}), ...(body.about && typeof body.about === 'object' && !Array.isArray(body.about) ? body.about : {}) }, scopes, dayCheck });
9261
9272
  if (!n.ok) return json(res, { ok: false, error: n.error }, 400);
9262
9273
  try { fs.mkdirSync(STATE, { recursive: true }); fs.writeFileSync(PRO_SETTINGS(), JSON.stringify(n.settings) + '\n'); }
9263
9274
  catch (e) { warnWriteFail('proactive-settings.json', e); return json(res, { ok: false, error: 'could not save — nothing changed' }, 500); }