@kortix/ui 0.15.6 → 0.15.8

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 (226) hide show
  1. package/README.md +7 -7
  2. package/dist/_vendor/kortix-shared.js +36 -1
  3. package/dist/_vendor/shared/my-kortix-agent.d.ts +7 -0
  4. package/dist/_vendor/shared/pixel-mark.d.ts +18 -0
  5. package/dist/customize/connectors/catalog/connector-categories.d.ts +2 -2
  6. package/dist/customize/connectors/catalog/connector-categories.js +2 -2
  7. package/dist/customize/connectors/detail/connector-modal.js +1 -1
  8. package/dist/customize/providers/provider-accordion.js +3 -2
  9. package/dist/customize/providers/provider-connect.d.ts +7 -0
  10. package/dist/customize/providers/provider-connect.js +21 -2
  11. package/dist/customize/providers/provider-sheet.js +3 -2
  12. package/dist/customize/sections/gateway-view.d.ts +2 -2
  13. package/dist/customize/sections/gateway-view.js +30 -15
  14. package/dist/customize/sections/llm-provider/chatgpt-subscription-connect.d.ts +3 -1
  15. package/dist/customize/sections/llm-provider/chatgpt-subscription-connect.js +2 -2
  16. package/dist/customize/sections/view/account-secret-resources-panel.js +8 -5
  17. package/dist/customize/sections/view/agent-editor-basics-fields.js +1 -1
  18. package/dist/customize/sections/view/gateway/gateway-logs.d.ts +1 -1
  19. package/dist/customize/sections/view/git-view.js +1 -1
  20. package/dist/customize/sections/view/permission-editor.js +1 -1
  21. package/dist/customize/sections/view/review-center-connected.js +15 -3
  22. package/dist/customize/sections/view/subscription-usage.d.ts +269 -17
  23. package/dist/customize/sections/view/subscription-usage.js +197 -54
  24. package/dist/customize/shared/entity/entity-modal.js +8 -10
  25. package/dist/files/project/components/drive-toolbar.d.ts +1 -1
  26. package/dist/files/project/components/drive-toolbar.js +1 -1
  27. package/dist/files/project/store/version-store.d.ts +1 -1
  28. package/dist/files/renderers/shared/scroll-area-compat.d.ts +6 -6
  29. package/dist/files/renderers/shared/scroll-area-compat.js +7 -9
  30. package/dist/files/renderers/shared/select-compat.js +3 -7
  31. package/dist/files/viewer/file-preview-modal.d.ts +10 -11
  32. package/dist/files/viewer/file-preview-modal.js +17 -18
  33. package/dist/i18n/en.d.ts +40 -47
  34. package/dist/i18n/en.js +47 -54
  35. package/dist/i18n/ui-catalog/app-registry-translation-keys.generated.js +5 -0
  36. package/dist/index.js +1 -1
  37. package/dist/internal/account-hub/account-hub-location.js +2 -2
  38. package/dist/internal/account-hub/use-account-members.d.ts +28 -1
  39. package/dist/internal/account-hub/use-account-members.js +27 -10
  40. package/dist/internal/auth/auth-primitives.d.ts +27 -0
  41. package/dist/internal/auth/auth-primitives.js +21 -0
  42. package/dist/internal/billing/index.d.ts +1 -0
  43. package/dist/internal/billing/index.js +2 -0
  44. package/dist/internal/billing/use-free-grant-unspent.d.ts +10 -0
  45. package/dist/internal/billing/use-free-grant-unspent.js +20 -0
  46. package/dist/internal/components/agent-mark.d.ts +1 -8
  47. package/dist/internal/components/agent-mark.js +2 -19
  48. package/dist/internal/lib/billing/billing-gate-state.d.ts +20 -0
  49. package/dist/internal/lib/billing/billing-gate-state.js +22 -0
  50. package/dist/internal/lib/error-handler.js +0 -2
  51. package/dist/internal/lib/navigation/modified-click.js +2 -2
  52. package/dist/internal/lib/pixel-mark.d.ts +3 -20
  53. package/dist/internal/lib/pixel-mark.js +3 -34
  54. package/dist/internal/notifications/notification-inbox.js +1 -1
  55. package/dist/internal/stores/active-space-store.d.ts +1 -1
  56. package/dist/internal/stores/browser-recents-store.d.ts +1 -1
  57. package/dist/internal/stores/current-account-store.d.ts +1 -1
  58. package/dist/internal/stores/first-chat-store.d.ts +1 -1
  59. package/dist/internal/stores/mobile-app-promo-store.d.ts +1 -1
  60. package/dist/internal/stores/session-browser-store.d.ts +1 -1
  61. package/dist/internal/stores/session-expanded-store.d.ts +1 -1
  62. package/dist/internal/stores/session-filter-store.d.ts +1 -1
  63. package/dist/internal/stores/session-history-view-store.d.ts +1 -1
  64. package/dist/internal/stores/session-hover-store.d.ts +1 -1
  65. package/dist/internal/stores/session-hover-store.js +1 -1
  66. package/dist/internal/stores/session-panel-memory-store.d.ts +1 -1
  67. package/dist/internal/stores/sound-store.d.ts +1 -1
  68. package/dist/internal/stores/tab-store.d.ts +1 -1
  69. package/dist/internal/stores/upgrade-dialog-store.d.ts +0 -2
  70. package/dist/internal/stores/upgrade-dialog-store.js +0 -2
  71. package/dist/internal/stores/user-preferences-store.d.ts +1 -1
  72. package/dist/internal/stores/web-notification-store.d.ts +1 -1
  73. package/dist/lib/base-ui-compat.d.ts +149 -0
  74. package/dist/lib/base-ui-compat.js +339 -0
  75. package/dist/lib/portal-container.d.ts +3 -7
  76. package/dist/lib/portal-container.js +5 -3
  77. package/dist/lib/z-stack.d.ts +4 -4
  78. package/dist/lib/z-stack.js +5 -5
  79. package/dist/markdown/setup-links/approval-decision.d.ts +1 -1
  80. package/dist/markdown/setup-links/approval-decision.js +1 -1
  81. package/dist/primitives/accordion.d.ts +36 -5
  82. package/dist/primitives/accordion.js +41 -8
  83. package/dist/primitives/alert-dialog.d.ts +33 -11
  84. package/dist/primitives/alert-dialog.js +41 -19
  85. package/dist/primitives/avatar.d.ts +5 -2
  86. package/dist/primitives/avatar.js +3 -3
  87. package/dist/primitives/badge.js +1 -1
  88. package/dist/primitives/breadcrumb.js +1 -1
  89. package/dist/primitives/button-group.js +3 -3
  90. package/dist/primitives/button.js +1 -1
  91. package/dist/primitives/checkbox.d.ts +14 -5
  92. package/dist/primitives/checkbox.js +24 -9
  93. package/dist/primitives/collapsible.d.ts +16 -4
  94. package/dist/primitives/collapsible.js +18 -7
  95. package/dist/primitives/command-core.d.ts +121 -0
  96. package/dist/primitives/command-core.js +642 -0
  97. package/dist/primitives/command.d.ts +38 -4
  98. package/dist/primitives/command.js +22 -13
  99. package/dist/primitives/context-menu.d.ts +61 -31
  100. package/dist/primitives/context-menu.js +40 -53
  101. package/dist/primitives/dialog.d.ts +48 -10
  102. package/dist/primitives/dialog.js +48 -19
  103. package/dist/primitives/disclosure.d.ts +1 -1
  104. package/dist/primitives/disclosure.js +2 -2
  105. package/dist/primitives/drawer.d.ts +28 -9
  106. package/dist/primitives/drawer.js +42 -18
  107. package/dist/primitives/dropdown-menu.d.ts +55 -33
  108. package/dist/primitives/dropdown-menu.js +46 -82
  109. package/dist/primitives/faded-scroll-area.js +2 -1
  110. package/dist/primitives/hint.js +3 -3
  111. package/dist/primitives/hover-card.d.ts +17 -5
  112. package/dist/primitives/hover-card.js +45 -8
  113. package/dist/primitives/item.js +2 -2
  114. package/dist/primitives/label.d.ts +5 -2
  115. package/dist/primitives/label.js +10 -3
  116. package/dist/primitives/menu-base.d.ts +150 -0
  117. package/dist/primitives/menu-base.js +171 -0
  118. package/dist/primitives/menu-recipe.d.ts +1 -1
  119. package/dist/primitives/menu-recipe.js +2 -7
  120. package/dist/primitives/modal.d.ts +19 -52
  121. package/dist/primitives/modal.js +24 -28
  122. package/dist/primitives/navigation-menu.d.ts +36 -11
  123. package/dist/primitives/navigation-menu.js +31 -12
  124. package/dist/primitives/popover.d.ts +31 -6
  125. package/dist/primitives/popover.js +79 -12
  126. package/dist/primitives/preview-image.d.ts +18 -7
  127. package/dist/primitives/preview-image.js +14 -11
  128. package/dist/primitives/progress.d.ts +4 -2
  129. package/dist/primitives/progress.js +4 -3
  130. package/dist/primitives/project-icon-picker.js +2 -2
  131. package/dist/primitives/radio-group.d.ts +28 -5
  132. package/dist/primitives/radio-group.js +18 -10
  133. package/dist/primitives/scroll-area.d.ts +2 -2
  134. package/dist/primitives/scroll-area.js +8 -3
  135. package/dist/primitives/select.d.ts +55 -12
  136. package/dist/primitives/select.js +93 -36
  137. package/dist/primitives/separator.d.ts +6 -2
  138. package/dist/primitives/separator.js +10 -2
  139. package/dist/primitives/sheet.d.ts +17 -10
  140. package/dist/primitives/sheet.js +19 -22
  141. package/dist/primitives/sidebar-menu-primitives.js +8 -8
  142. package/dist/primitives/slider-native.d.ts +2 -2
  143. package/dist/primitives/slider-native.js +11 -9
  144. package/dist/primitives/slider.d.ts +24 -6
  145. package/dist/primitives/slider.js +26 -24
  146. package/dist/primitives/slot.d.ts +6 -0
  147. package/dist/primitives/slot.js +7 -0
  148. package/dist/primitives/split-sheet.js +1 -1
  149. package/dist/primitives/stepper.js +1 -1
  150. package/dist/primitives/switch.d.ts +16 -3
  151. package/dist/primitives/switch.js +7 -6
  152. package/dist/primitives/tabs.d.ts +36 -20
  153. package/dist/primitives/tabs.js +131 -102
  154. package/dist/primitives/toggle.d.ts +16 -3
  155. package/dist/primitives/toggle.js +8 -3
  156. package/dist/primitives/tooltip.d.ts +24 -5
  157. package/dist/primitives/tooltip.js +32 -10
  158. package/dist/primitives/type-to-confirm-dialog.d.ts +1 -1
  159. package/dist/primitives/type-to-confirm-dialog.js +1 -1
  160. package/dist/session/composer/animated-placeholder.js +1 -1
  161. package/dist/session/composer/chat-input/chat-input-control.js +3 -3
  162. package/dist/session/composer/editor/composer-editor.js +1 -1
  163. package/dist/session/composer/menus/menu-shell.d.ts +1 -1
  164. package/dist/session/composer/menus/menu-shell.js +1 -1
  165. package/dist/session/composer/menus/mount.js +1 -1
  166. package/dist/session/composer/reasoning-effort-selector.js +1 -1
  167. package/dist/session/header/session-site-header.js +2 -2
  168. package/dist/session/header/subagent-hover-card.js +2 -2
  169. package/dist/session/media/image-preview.js +1 -1
  170. package/dist/session/models/model-selector.d.ts +1 -1
  171. package/dist/session/models/model-selector.js +18 -12
  172. package/dist/session/models/subscription-switcher.d.ts +37 -0
  173. package/dist/session/models/subscription-switcher.js +97 -0
  174. package/dist/session/models/subscription-windows.d.ts +40 -0
  175. package/dist/session/models/subscription-windows.js +86 -0
  176. package/dist/session/overrides/session-overrides-control.js +3 -3
  177. package/dist/session/panel/diff-dialog.js +1 -1
  178. package/dist/session/panel/easy/detail-view.js +3 -3
  179. package/dist/session/panel/mobile-tool-drawer.js +2 -2
  180. package/dist/session/panel/panel-fallback.js +1 -1
  181. package/dist/session/panel/session-files-explorer.d.ts +1 -1
  182. package/dist/session/panel/session-files-explorer.js +1 -1
  183. package/dist/session/prompts/ask-deck.d.ts +14 -2
  184. package/dist/session/prompts/ask-deck.js +6 -2
  185. package/dist/session/thread/session-chat.js +2 -2
  186. package/dist/session/thread/session-context-message-explorer.js +1 -1
  187. package/dist/session/thread/turn-share.js +3 -4
  188. package/dist/session/tool/shared/show-helpers.js +1 -1
  189. package/dist/session/turn/message-time-label.js +1 -1
  190. package/dist/styles.css +1 -1
  191. package/dist/test-utils/intl.d.ts +40 -47
  192. package/dist/workspace/admin/settings-search.js +4 -12
  193. package/dist/workspace/inbox/workspace-inbox.js +11 -2
  194. package/dist/workspace/layout/new-session-create.d.ts +4 -2
  195. package/dist/workspace/layout/new-session-create.js +11 -0
  196. package/dist/workspace/projects/modal/project-icon-field.js +9 -23
  197. package/dist/workspace/review/approval-modal.d.ts +6 -6
  198. package/dist/workspace/review/approval-modal.js +10 -14
  199. package/dist/workspace/review/review-center.d.ts +9 -2
  200. package/dist/workspace/review/review-center.js +258 -126
  201. package/dist/workspace/review/review-detail.d.ts +20 -10
  202. package/dist/workspace/review/review-detail.js +39 -44
  203. package/dist/workspace/review/review-meta.d.ts +27 -6
  204. package/dist/workspace/review/review-meta.js +46 -34
  205. package/dist/workspace/sessions/session-row.js +1 -1
  206. package/dist/workspace/sidebar/footer/project-download-app-nav.d.ts +10 -0
  207. package/dist/workspace/sidebar/footer/project-download-app-nav.js +53 -0
  208. package/dist/workspace/sidebar/footer/promo-nav-row.d.ts +2 -1
  209. package/dist/workspace/sidebar/footer/promo-nav-row.js +1 -1
  210. package/dist/workspace/sidebar/project-session-list.js +2 -2
  211. package/dist/workspace/sidebar/project-sidebar.d.ts +6 -1
  212. package/dist/workspace/sidebar/project-sidebar.js +3 -2
  213. package/dist/workspace/sidebar/session-brief-hover-card.d.ts +1 -1
  214. package/dist/workspace/sidebar/session-brief-hover-card.js +3 -3
  215. package/dist/workspace/sidebar/session-title.d.ts +2 -2
  216. package/dist/workspace/sidebar/session-title.js +2 -2
  217. package/dist/workspace/sidebar/workspace-menu-model.d.ts +19 -13
  218. package/dist/workspace/sidebar/workspace-menu-model.js +7 -8
  219. package/dist/workspace/sidebar/workspace-menu-section.js +1 -1
  220. package/dist/workspace/spaces/space-links.js +1 -1
  221. package/dist/workspace/spaces/space-threads-tab.js +1 -1
  222. package/package.json +16 -35
  223. package/skills/kortix-ui/SKILL.md +1 -1
  224. package/skills/kortix-ui/references/custom-dashboard.md +1 -1
  225. package/dist/customize/sections/view/subscription-usage-tab.d.ts +0 -25
  226. package/dist/customize/sections/view/subscription-usage-tab.js +0 -121
@@ -107,16 +107,6 @@ export declare const testUiTranslator: import("use-intl")._Translator<{
107
107
  access: string;
108
108
  actions: string;
109
109
  coolingDown: string;
110
- usageFiveHour: string;
111
- usageWeekly: string;
112
- usageWeeklyModel: string;
113
- usagePercent: string;
114
- usagePercentResets: string;
115
- usageLimitReached: string;
116
- usageLimitResets: string;
117
- usageNotSeen: string;
118
- usageObserved: string;
119
- usageAriaLabel: string;
120
110
  member: string;
121
111
  members: string;
122
112
  actionsFor: string;
@@ -158,6 +148,9 @@ export declare const testUiTranslator: import("use-intl")._Translator<{
158
148
  providerKeys: string;
159
149
  chooseSharedKeys: string;
160
150
  sessionKeyPool: string;
151
+ subscriptionSwitcher: string;
152
+ subscriptionSwitcherDefault: string;
153
+ subscriptionSwitcherUse: string;
161
154
  sharedSessionKeys: string;
162
155
  promptedSessionKeys: string;
163
156
  noPersonSessionKeys: string;
@@ -1788,6 +1781,8 @@ export declare const testUiTranslator: import("use-intl")._Translator<{
1788
1781
  title: string;
1789
1782
  description: string;
1790
1783
  confirmDescription: string;
1784
+ unknownDescription: string;
1785
+ closedDescription: string;
1791
1786
  notReceived: string;
1792
1787
  confirmNotReceived: string;
1793
1788
  resendIn: string;
@@ -6206,6 +6201,11 @@ export declare const testUiTranslator: import("use-intl")._Translator<{
6206
6201
  textadca5dfd1e42: string;
6207
6202
  text16ba47efb9f2: string;
6208
6203
  textfd8b8dae4421: string;
6204
+ text674900a77b79: string;
6205
+ text765a8cb04cf5: string;
6206
+ texta68ee4167406: string;
6207
+ texta69c4dece144: string;
6208
+ textab3aff8f7642: string;
6209
6209
  };
6210
6210
  publicShareConfirm: {
6211
6211
  title: string;
@@ -6386,6 +6386,10 @@ export declare const testUiTranslator: import("use-intl")._Translator<{
6386
6386
  deniedDescription: string;
6387
6387
  failed: string;
6388
6388
  };
6389
+ reviewPane: {
6390
+ emptyTitle: string;
6391
+ emptyDescription: string;
6392
+ };
6389
6393
  };
6390
6394
  commandPalette: {
6391
6395
  title: string;
@@ -9795,45 +9799,34 @@ export declare const testUiTranslator: import("use-intl")._Translator<{
9795
9799
  fiveHour: string;
9796
9800
  weekly: string;
9797
9801
  weeklyModel: string;
9798
- reconnect: string;
9799
- disabledTitle: string;
9800
- disabledDescription: string;
9801
- text0: string;
9802
- text1: string;
9803
- text2: string;
9804
- text3: string;
9805
- text4: string;
9806
- text5: string;
9807
- text6: string;
9808
- text7: string;
9809
- text8: string;
9810
- text9: string;
9811
- text10: string;
9812
- text11: string;
9813
- text12: string;
9814
- text13: string;
9815
- text14: string;
9816
- text15: string;
9817
- text16: string;
9818
- text17: string;
9819
- text18: string;
9820
- text19: string;
9821
- text20: string;
9822
- text21: string;
9823
- text22: string;
9824
- text23: string;
9825
- text24: string;
9826
- text25: string;
9827
- text26: string;
9828
- resets: string;
9802
+ inactive: string;
9803
+ limitReached: string;
9804
+ checking: string;
9805
+ title: string;
9829
9806
  observed: string;
9830
9807
  meterLabel: string;
9831
- refreshLabel: string;
9832
- fiveHourNotReported: string;
9833
- fableIncluded: string;
9834
- chatgptUsage: string;
9835
- claudeUsage: string;
9836
- allSubscriptions: string;
9808
+ extraUsage: string;
9809
+ apps: string;
9810
+ codeReview: string;
9811
+ percent: string;
9812
+ percentResets: string;
9813
+ percentBack: string;
9814
+ resetPassed: string;
9815
+ notStarted: string;
9816
+ reconnectToSee: string;
9817
+ availableNow: string;
9818
+ availableCount: string;
9819
+ nextBack: string;
9820
+ rowPeak: string;
9821
+ rowSomeLimited: string;
9822
+ rowAllLimited: string;
9823
+ rowAllLimitedBack: string;
9824
+ noUsageYet: string;
9825
+ refreshFailed: string;
9826
+ loadFailed: string;
9827
+ rowSomeLimitedBack: string;
9828
+ weeklyAll: string;
9829
+ notReported: string;
9837
9830
  };
9838
9831
  gatewayRouting: {
9839
9832
  exceptions: string;
@@ -139,28 +139,20 @@ export const SETTINGS_SEARCH_ENTRIES = [
139
139
  query: { tab: 'logs' },
140
140
  find: null,
141
141
  },
142
- {
143
- id: 'models-usage',
144
- section: 'models',
145
- label: 'Usage',
146
- keywords: 'tokens usage subscription limits',
147
- query: { tab: 'usage' },
148
- find: null,
149
- },
150
142
  {
151
143
  id: 'models-chatgpt-usage',
152
144
  section: 'models',
153
145
  label: 'ChatGPT subscription usage',
154
- keywords: 'chatgpt openai codex subscription weekly allowance quota',
155
- query: { tab: 'usage' },
146
+ keywords: 'chatgpt openai codex subscription usage limits weekly allowance quota code review',
147
+ query: { tab: 'providers', provider: 'openai' },
156
148
  find: null,
157
149
  },
158
150
  {
159
151
  id: 'models-claude-usage',
160
152
  section: 'models',
161
153
  label: 'Claude subscription usage',
162
- keywords: 'claude anthropic subscription weekly allowance quota',
163
- query: { tab: 'usage' },
154
+ keywords: 'claude anthropic subscription usage limits weekly allowance quota opus sonnet extra',
155
+ query: { tab: 'providers', provider: 'anthropic' },
164
156
  find: null,
165
157
  },
166
158
  // Connectors: `?scope=` and `?rules=1` (`connector-routes.ts`).
@@ -1,5 +1,5 @@
1
1
  'use client';
2
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import { useNotificationInbox } from '@kortix/sdk/react';
4
4
  import { ReviewView } from '../../customize/sections/view/review-view.js';
5
5
  import { useTranslations } from '../../i18n/index.js';
@@ -9,6 +9,8 @@ import { NotificationInbox } from '../../internal/notifications/notification-inb
9
9
  import { CountBadge } from '../../primitives/count-badge.js';
10
10
  import { Tabs, TabsList, TabsTrigger } from '../../primitives/tabs.js';
11
11
  import { useUiPathname, useUiRouter, useUiSearchParams, useUiViewerId } from '../../providers/ui-provider.js';
12
+ /** One underline tab: hugs its label and count, full title-bar height. */
13
+ const INBOX_TAB_CLASS = 'h-full w-fit flex-none gap-1.5 px-1';
12
14
  /**
13
15
  * The tab a visit opens: the one `?view=` names; else Review when it holds an
14
16
  * item (`?id=`) or something waits there; else Notifications.
@@ -48,5 +50,12 @@ export function WorkspaceInbox({ projectId }) {
48
50
  };
49
51
  return (
50
52
  // `h-svh`: nothing above this box has a definite height (as the Apps page).
51
- _jsxs("div", { className: "flex h-svh min-h-0 flex-col overflow-hidden", children: [_jsx(ProjectPageHeader, { title: t('inbox.title'), titleAccessory: _jsx(Tabs, { value: view, onValueChange: select, className: "ml-2", children: _jsxs(TabsList, { size: "xs", "aria-label": t('inbox.viewLabel'), children: [_jsxs(TabsTrigger, { value: "review", className: "gap-1.5", "data-testid": "inbox-view-review", children: [t('inbox.viewReview'), reviewNeedsYou > 0 ? _jsx(CountBadge, { count: reviewNeedsYou, tone: "waiting" }) : null] }), _jsxs(TabsTrigger, { value: "notifications", className: "gap-1.5", "data-testid": "inbox-view-notifications", children: [t('inbox.viewNotifications'), unread > 0 ? _jsx(CountBadge, { count: unread }) : null] })] }) }) }), view === 'review' ? (_jsx("div", { className: "mx-auto flex min-h-0 w-full max-w-4xl flex-1 flex-col", children: _jsx(ReviewView, { projectId: projectId }) })) : (_jsx(NotificationInbox, { bare: true }))] }));
53
+ _jsxs("div", { className: "flex h-svh min-h-0 flex-col overflow-hidden", children: [_jsx(ProjectPageHeader, { title: t('inbox.title'), titleAccessory:
54
+ // "Inbox", a rule, then the underline tabs: the same title-bar
55
+ // grammar as the capability tab bar (customize-tab-bar.tsx). Never
56
+ // the segmented control here.
57
+ _jsxs(_Fragment, { children: [_jsx("span", { "aria-hidden": true, className: "bg-border mx-1.5 h-4 w-px shrink-0" }), _jsx(Tabs, { value: view, onValueChange: select, className: "h-full gap-0", children: _jsxs(TabsList, { type: "underline", underlineSize: "md", className: "h-10 justify-start gap-4 border-b-0", "aria-label": t('inbox.viewLabel'), children: [_jsxs(TabsTrigger, { value: "review", className: INBOX_TAB_CLASS, "data-testid": "inbox-view-review", children: [t('inbox.viewReview'), reviewNeedsYou > 0 ? _jsx(CountBadge, { count: reviewNeedsYou, tone: "waiting" }) : null] }), _jsxs(TabsTrigger, { value: "notifications", className: INBOX_TAB_CLASS, "data-testid": "inbox-view-notifications", children: [t('inbox.viewNotifications'), unread > 0 ? _jsx(CountBadge, { count: unread }) : null] })] }) })] }) }), view === 'review' ? (
58
+ // Full width: the list and the open item sit side by side, so no
59
+ // reading-width cap here.
60
+ _jsx("div", { className: "flex min-h-0 w-full flex-1 flex-col", children: _jsx(ReviewView, { projectId: projectId }) })) : (_jsx(NotificationInbox, { bare: true }))] }));
52
61
  }
@@ -1,8 +1,10 @@
1
1
  import type { ComposerOptions } from '../../session/composer/composer-chat-input.js';
2
- import type { SessionConnectorBindingsInput } from '@kortix/sdk';
2
+ import { type SessionConnectorBindingsInput } from '@kortix/sdk';
3
3
  export interface NewSessionCreateInput {
4
4
  sandbox_slug?: string;
5
5
  agent_name?: string;
6
+ /** The composer's launch model, gateway wire form — the create-time pin. */
7
+ model?: string;
6
8
  connector_bindings?: SessionConnectorBindingsInput;
7
9
  inherit_unbound?: boolean;
8
10
  provider_secret_pools?: Record<string, string[]>;
@@ -21,6 +23,6 @@ export interface NewSessionCreateInput {
21
23
  * Returns `undefined` when there is nothing to bind (sandbox stays default and
22
24
  * no agent was picked), so callers can omit the create overrides entirely.
23
25
  */
24
- export declare function buildNewSessionCreateInput(options?: Pick<ComposerOptions, 'agent' | 'scope' | 'providerSecretPools'> & {
26
+ export declare function buildNewSessionCreateInput(options?: Pick<ComposerOptions, 'agent' | 'model' | 'scope' | 'providerSecretPools'> & {
25
27
  sandbox_slug?: string;
26
28
  }): NewSessionCreateInput | undefined;
@@ -1,3 +1,4 @@
1
+ import { modelKeyToWire } from '@kortix/sdk';
1
2
  import { isMyKortixAgentName, MY_KORTIX_SANDBOX_SLUG } from '../../_vendor/kortix-shared.js';
2
3
  /**
3
4
  * Build the session-create payload from the composer's send options.
@@ -23,6 +24,16 @@ export function buildNewSessionCreateInput(options = {}) {
23
24
  }
24
25
  if (options.agent)
25
26
  input.agent_name = options.agent;
27
+ // The launch model as the create-time pin. Only riding `pending_prompt.model`
28
+ // it never reaches the row: the server stamps the default chain, and the
29
+ // session's selector then shows the project default while the session starts
30
+ // even though the first turn runs on this pick. The same top-level `model`
31
+ // the CLI and mobile send — the API validates servability and pins
32
+ // `metadata.model` with `model_source: 'explicit'`, so the row carries the
33
+ // launch model from the first read, before the runtime is up.
34
+ if (options.model && options.model.modelID !== 'auto' && options.model.modelID !== 'kortix/auto') {
35
+ input.model = modelKeyToWire(options.model);
36
+ }
26
37
  if (options.providerSecretPools && Object.keys(options.providerSecretPools).length > 0) {
27
38
  input.provider_secret_pools = options.providerSecretPools;
28
39
  }
@@ -63,10 +63,9 @@ export function ProjectIconField({ value, onChange, onGlyphChange, onClear, disa
63
63
  const [open, setOpen] = useState(false);
64
64
  const reduceMotion = useReducedMotion();
65
65
  // Adjusting state during render: React's documented alternative to an effect
66
- // for "reset state when a prop changes". Radix drives `open` through
67
- // useControllableState, where a CONTROLLED prop that changes value on
68
- // re-render is simply recomputed and fires nothing — onOpenChange only runs
69
- // from setValue. So the `open && !disabled` guard below would close the
66
+ // for "reset state when a prop changes". The popover root fires
67
+ // `onOpenChange` only for changes it makes itself; a CONTROLLED `open` that
68
+ // changes on re-render fires nothing. So the `open && !disabled` guard below would close the
70
69
  // popover when `disabled` goes true without ever telling us, leaving local
71
70
  // `open` stuck at true; the next time `disabled` went false the guard would
72
71
  // re-evaluate to true and the picker would reopen with no user action. Task 7
@@ -88,26 +87,13 @@ export function ProjectIconField({ value, onChange, onGlyphChange, onClear, disa
88
87
  // Button already stops a click reaching us (a disabled button fires none,
89
88
  // and button.tsx adds disabled:pointer-events-none).
90
89
  //
91
- // `modal` is what makes the picker scrollable with a wheel or trackpad.
92
90
  // In workspace Settings this field renders inside `CustomizeSectionWrapper`
93
- // -> `customize-panel.tsx`'s `Modal`, a Radix Dialog, and Radix wraps the
94
- // dialog's OVERLAY in react-remove-scroll with
95
- // `shards: [contentRef]` (react-dialog dist/index.mjs:110). That side-car
96
- // installs a non-passive `wheel` listener on `document` and calls
97
- // preventDefault() on every wheel whose target is neither inside the
98
- // overlay's React subtree nor inside the content shard. A popover portals
99
- // to document.body, so it is in neither: the picker's own overflow-y-auto
100
- // viewport never received the scroll. Dragging its scrollbar still worked,
101
- // which is what made the bug read as "only the scrollbar responds" — a
102
- // scrollbar drag is a pointer gesture, not a wheel event.
103
- //
104
- // `modal` makes Radix wrap THIS popover's content in its own RemoveScroll
105
- // (react-popover dist/index.mjs:134). react-remove-scroll keeps one
106
- // module-level `lockStack`, and its `shouldPrevent` returns early for any
107
- // lock that is not the last one pushed — so while the picker is open the
108
- // dialog's lock stands down and the picker's own lock takes over, with the
109
- // popover content as its container. Its boundary logic then walks into the
110
- // emoji viewport, finds scroll left to give, and lets the wheel through.
91
+ // -> `customize-panel.tsx`'s `Modal`. The picker must scroll with a wheel
92
+ // or trackpad there. The modal locks page scroll with `overflow: hidden`
93
+ // on the document and cancels no wheel event, so the picker's own
94
+ // overflow-y-auto viewport receives the wheel. `modal` on the popover
95
+ // traps focus in the picker and blocks pointer input outside it while it
96
+ // is open.
111
97
  //
112
98
  // Rejected alternative: portalling the popover into the dialog's content
113
99
  // element (PopoverContent already accepts `container`). ModalContent is
@@ -23,19 +23,19 @@ export declare function reviewApprovalAsker(item: ReviewItem, sessionLabels?: Re
23
23
  sessionTitle: string | null;
24
24
  };
25
25
  /**
26
- * The standalone approve page (`/approve/[token]`), in a modal over the inbox.
27
- * One approval UI everywhere: the same panel, the same rows, the same decision.
28
- * No `onDecision` = the viewer may read the call but not decide it.
26
+ * The standalone approve page (`/approve/[token]`), inline in the inbox's
27
+ * detail pane. One approval UI everywhere: the same panel in the same bordered
28
+ * card, the same rows, the same decision. No `onDecision` = the viewer may read
29
+ * the call but not decide it.
29
30
  */
30
- export declare function ApprovalDecisionModal({ details, previewAuthorized, busyDecision, onDecision, onOpenSession, onClose, resolvers, agentName, sessionTitle, }: {
31
- details: ApprovalLinkDetails | null;
31
+ export declare function ApprovalDecisionPane({ details, previewAuthorized, busyDecision, onDecision, onOpenSession, resolvers, agentName, sessionTitle, }: {
32
+ details: ApprovalLinkDetails;
32
33
  previewAuthorized?: boolean;
33
34
  /** Who decides the call, for a viewer who may not (KRTX-1724). */
34
35
  resolvers?: ApprovalResolvers | null;
35
36
  busyDecision: ApprovalDecisionValue | null;
36
37
  onDecision?: (decision: ApprovalDecisionValue, note?: string) => void;
37
38
  onOpenSession?: () => void;
38
- onClose: () => void;
39
39
  /** The agent that asked. Null: "An agent". */
40
40
  agentName?: string | null;
41
41
  /** The session that asked, by its title. Null: not named. */
@@ -2,8 +2,8 @@
2
2
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  import { approvalReviewable, useApprovalWaitingText, } from '../../session/prompts/approval-request.js';
4
4
  import { ApprovalDecisionPanel } from '../../markdown/setup-links/approval-decision.js';
5
- import { Modal, ModalContent, ModalDescription, ModalTitle } from '../../primitives/modal.js';
6
5
  import { useTranslations } from '../../i18n/index.js';
6
+ import { useId } from 'react';
7
7
  import { connectorCallId } from './review-actions.js';
8
8
  /**
9
9
  * A Connector approval as the standalone approve page reads it, built from the
@@ -71,21 +71,17 @@ export function reviewApprovalAsker(item, sessionLabels = {}) {
71
71
  };
72
72
  }
73
73
  /**
74
- * The standalone approve page (`/approve/[token]`), in a modal over the inbox.
75
- * One approval UI everywhere: the same panel, the same rows, the same decision.
76
- * No `onDecision` = the viewer may read the call but not decide it.
74
+ * The standalone approve page (`/approve/[token]`), inline in the inbox's
75
+ * detail pane. One approval UI everywhere: the same panel in the same bordered
76
+ * card, the same rows, the same decision. No `onDecision` = the viewer may read
77
+ * the call but not decide it.
77
78
  */
78
- export function ApprovalDecisionModal({ details, previewAuthorized, busyDecision, onDecision, onOpenSession, onClose, resolvers = null, agentName = null, sessionTitle = null, }) {
79
+ export function ApprovalDecisionPane({ details, previewAuthorized, busyDecision, onDecision, onOpenSession, resolvers = null, agentName = null, sessionTitle = null, }) {
79
80
  const tI18nComplete = useTranslations('hardcodedUi.i18nComplete');
80
81
  const waitingText = useApprovalWaitingText(resolvers);
81
82
  // The panel's own rule: a pending call with no decision on offer waits on
82
- // someone else, so the dialog is not announced as a request to this viewer.
83
- const waiting = details?.pending === true && !onDecision;
84
- return (_jsx(Modal, { open: details !== null, onOpenChange: (open) => !open && onClose(), children: _jsxs(ModalContent, { showCloseButton: false,
85
- // Focus the dialog itself, not its first control: that is the
86
- // description's info trigger, and focus would open its hover card.
87
- onOpenAutoFocus: (event) => {
88
- event.preventDefault();
89
- event.currentTarget?.focus();
90
- }, className: "space-y-0 lg:h-auto lg:max-h-[85svh] lg:max-w-md", children: [_jsx(ModalTitle, { className: "sr-only", children: waiting ? tI18nComplete.raw('textdb0e960b68b5') : tI18nComplete.raw('text1862f81ed9d6') }), _jsx(ModalDescription, { className: "sr-only", children: waiting ? waitingText : tI18nComplete.raw('text32c6817c8380') }), details ? (_jsx(ApprovalDecisionPanel, { details: details, outcome: null, busyDecision: busyDecision, error: null, onDecision: onDecision, onOpenSession: onOpenSession, previewAuthorized: previewAuthorized, resolvers: resolvers, agentName: agentName, sessionTitle: sessionTitle })) : null] }) }));
83
+ // someone else, so the region is not announced as a request to this viewer.
84
+ const waiting = details.pending === true && !onDecision;
85
+ const titleId = useId();
86
+ return (_jsxs("section", { "aria-labelledby": titleId, className: "mx-auto w-full max-w-xl", children: [_jsx("h2", { id: titleId, className: "sr-only", children: waiting ? tI18nComplete.raw('textdb0e960b68b5') : tI18nComplete.raw('text1862f81ed9d6') }), _jsx("p", { className: "sr-only", children: waiting ? waitingText : tI18nComplete.raw('text32c6817c8380') }), _jsx("div", { className: "border-border overflow-hidden rounded-xl border", children: _jsx(ApprovalDecisionPanel, { details: details, outcome: null, busyDecision: busyDecision, error: null, onDecision: onDecision, onOpenSession: onOpenSession, previewAuthorized: previewAuthorized, resolvers: resolvers, agentName: agentName, sessionTitle: sessionTitle }) })] }));
91
87
  }
@@ -3,8 +3,15 @@ import { type ReactNode } from 'react';
3
3
  import { type BulkResult } from './review-actions.js';
4
4
  import { type ReviewItem, type ReviewSegment } from './types.js';
5
5
  export declare function ReviewCenter({ initialItems, segment: segmentProp, onSegmentChange, loadMore, onAct, onBulkAct, onOpenSession, onRecoverChange, recoveringCrId, onRefresh, isLoading, isFetching, isFetched, isError, sessionLabels, verdictAllowed, needsYouDeck, }?: {
6
- /** Shown at the top of Needs you: the asks deck (questions and approvals agents wait on). */
7
- needsYouDeck?: ReactNode;
6
+ /**
7
+ * The asks deck (questions and approvals agents wait on): in the empty
8
+ * detail pane, or above the list on a narrow inbox. It stays mounted while
9
+ * an item is open, `paused`, so a staged answer keeps its Undo window and
10
+ * the deck's keys answer nothing out of sight.
11
+ */
12
+ needsYouDeck?: (opts: {
13
+ paused: boolean;
14
+ }) => ReactNode;
8
15
  /** When provided, the inbox renders real data instead of the mock fixtures. */
9
16
  initialItems?: ReviewItem[];
10
17
  /** Connected mode: the segment is the server's filter, so the parent owns it. */