@cat-factory/app 0.47.1 → 0.47.2

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.
@@ -9,6 +9,8 @@ import type { SubscriptionVendor } from '~/types/domain'
9
9
 
10
10
  const personal = usePersonalSubscriptionsStore()
11
11
  const auth = useAuthStore()
12
+ const workspace = useWorkspaceStore()
13
+ const models = useModelsStore()
12
14
  const toast = useToast()
13
15
  const { t, d } = useI18n()
14
16
 
@@ -117,6 +119,11 @@ async function connect() {
117
119
  password.value = ''
118
120
  label.value = ''
119
121
  expiresOn.value = ''
122
+ // A connected subscription makes its vendor's models usable, so refresh the catalog:
123
+ // this clears the "No AI model configured" banner and, if the default preset still
124
+ // points at models this subscription doesn't cover, reactively surfaces the
125
+ // preset-mismatch prompt (with its "pick a different preset" link).
126
+ if (workspace.workspaceId) await models.refresh(workspace.workspaceId)
120
127
  toast.add({
121
128
  title: t('personalSubscriptions.toast.connected', { vendor: selectedMeta.value.label }),
122
129
  icon: 'i-lucide-check',
@@ -136,6 +143,9 @@ async function connect() {
136
143
  async function disconnect(v: SubscriptionVendor) {
137
144
  try {
138
145
  await personal.remove(v)
146
+ // Removing the subscription may drop the workspace's last usable model — refresh so the
147
+ // AI-readiness banners re-evaluate (mirrors the API-key flow).
148
+ if (workspace.workspaceId) await models.refresh(workspace.workspaceId)
139
149
  toast.add({ title: t('personalSubscriptions.toast.disconnected'), icon: 'i-lucide-check' })
140
150
  } catch (e) {
141
151
  toast.add({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cat-factory/app",
3
- "version": "0.47.1",
3
+ "version": "0.47.2",
4
4
  "description": "Reusable Nuxt layer for the Agent Architecture Board SPA (components, stores, composables, pages). Consume it from a thin deployment app via `extends: ['@cat-factory/app']` and point it at your backend with NUXT_PUBLIC_API_BASE. See deploy/frontend for an example.",
5
5
  "repository": {
6
6
  "type": "git",