@adecore/agents-react 0.55.3 → 0.56.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.
@@ -7,8 +7,10 @@ import { Trans, useTranslation } from 'react-i18next';
7
7
  import { AccountDot } from '../agents/AccountDot.js';
8
8
  import { accountName, FOLDER_VARIABLES } from '../agents/accounts.js';
9
9
  import { useChatHost } from '../host.js';
10
+ import { useHostCanShareAccountConfig } from '../host-hooks.js';
10
11
  import { useChatScope } from '../scope.js';
11
- import { removeAccount, saveAccount } from './account-actions.js';
12
+ import { useProviderAccounts } from '../state/provider-accounts.js';
13
+ import { removeAccount, saveAccount, shareAccountConfig } from './account-actions.js';
12
14
  import { AccountColors } from './AccountColors.js';
13
15
  import { AccountVariables } from './AccountVariables.js';
14
16
  import { CliMark } from './parts.js';
@@ -76,7 +78,7 @@ function _temp(event_0) {
76
78
  }
77
79
  }
78
80
  export function AccountDetail(t0) {
79
- const $ = _c(161);
81
+ const $ = _c(177);
80
82
  const {
81
83
  provider,
82
84
  entry,
@@ -111,9 +113,24 @@ export function AccountDetail(t0) {
111
113
  const folder = status?.home ?? "";
112
114
  const variable = FOLDER_VARIABLES[provider.kind];
113
115
  const signedIn = status?.state === "ready";
116
+ const sharedConfigKinds = useProviderAccounts(_temp2);
117
+ const canShareConfig = useHostCanShareAccountConfig(scope.id);
118
+ const sharesConfig = account.shareConfig === true;
114
119
  let t2;
115
- if ($[3] !== folder || $[4] !== host || $[5] !== t) {
116
- t2 = () => {
120
+ if ($[3] !== canShareConfig || $[4] !== isDefault || $[5] !== provider.kind || $[6] !== sharedConfigKinds) {
121
+ t2 = canShareConfig && !isDefault && sharedConfigKinds?.includes(provider.kind) === true;
122
+ $[3] = canShareConfig;
123
+ $[4] = isDefault;
124
+ $[5] = provider.kind;
125
+ $[6] = sharedConfigKinds;
126
+ $[7] = t2;
127
+ } else {
128
+ t2 = $[7];
129
+ }
130
+ const showShareConfig = t2;
131
+ let t3;
132
+ if ($[8] !== folder || $[9] !== host || $[10] !== t) {
133
+ t3 = () => {
117
134
  copyText(folder);
118
135
  host.notify({
119
136
  kind: "success",
@@ -121,18 +138,18 @@ export function AccountDetail(t0) {
121
138
  description: folder
122
139
  });
123
140
  };
124
- $[3] = folder;
125
- $[4] = host;
126
- $[5] = t;
127
- $[6] = t2;
141
+ $[8] = folder;
142
+ $[9] = host;
143
+ $[10] = t;
144
+ $[11] = t3;
128
145
  } else {
129
- t2 = $[6];
146
+ t3 = $[11];
130
147
  }
131
- const showFolder = t2;
148
+ const showFolder = t3;
132
149
  const trouble = status !== null && TROUBLE.has(status.state) && status.message ? status.message : null;
133
- let t3;
134
- if ($[7] !== signedIn || $[8] !== status || $[9] !== t || $[10] !== trouble) {
135
- t3 = () => {
150
+ let t4;
151
+ if ($[12] !== signedIn || $[13] !== status || $[14] !== t || $[15] !== trouble) {
152
+ t4 = () => {
136
153
  if (trouble !== null) {
137
154
  return trouble;
138
155
  }
@@ -143,169 +160,169 @@ export function AccountDetail(t0) {
143
160
  plan: status.plan
144
161
  }) : t("account.login.detail");
145
162
  };
146
- $[7] = signedIn;
147
- $[8] = status;
148
- $[9] = t;
149
- $[10] = trouble;
150
- $[11] = t3;
163
+ $[12] = signedIn;
164
+ $[13] = status;
165
+ $[14] = t;
166
+ $[15] = trouble;
167
+ $[16] = t4;
151
168
  } else {
152
- t3 = $[11];
169
+ t4 = $[16];
153
170
  }
154
- const loginDetail = t3;
155
- const t4 = loginBlocked !== null;
156
- let t5;
157
- if ($[12] !== host || $[13] !== id || $[14] !== name || $[15] !== provider.kind || $[16] !== scope) {
158
- t5 = () => void host.openLogin?.(scope.id, provider.kind, id, name);
159
- $[12] = host;
160
- $[13] = id;
161
- $[14] = name;
162
- $[15] = provider.kind;
163
- $[16] = scope;
164
- $[17] = t5;
171
+ const loginDetail = t4;
172
+ const t5 = loginBlocked !== null;
173
+ let t6;
174
+ if ($[17] !== host || $[18] !== id || $[19] !== name || $[20] !== provider.kind || $[21] !== scope.id) {
175
+ t6 = () => void host.openLogin?.(scope.id, provider.kind, id, name);
176
+ $[17] = host;
177
+ $[18] = id;
178
+ $[19] = name;
179
+ $[20] = provider.kind;
180
+ $[21] = scope.id;
181
+ $[22] = t6;
165
182
  } else {
166
- t5 = $[17];
183
+ t6 = $[22];
167
184
  }
168
- let t6;
169
- if ($[18] === Symbol.for("react.memo_cache_sentinel")) {
170
- t6 = /*#__PURE__*/_jsx(Icon, {
185
+ let t7;
186
+ if ($[23] === Symbol.for("react.memo_cache_sentinel")) {
187
+ t7 = /*#__PURE__*/_jsx(Icon, {
171
188
  icon: LogIn,
172
189
  size: 14
173
190
  });
174
- $[18] = t6;
191
+ $[23] = t7;
175
192
  } else {
176
- t6 = $[18];
193
+ t7 = $[23];
177
194
  }
178
- let t7;
179
- if ($[19] !== signedIn || $[20] !== t) {
180
- t7 = signedIn ? t("account.login.logInAgain") : t("account.login.logIn");
181
- $[19] = signedIn;
182
- $[20] = t;
183
- $[21] = t7;
195
+ let t8;
196
+ if ($[24] !== signedIn || $[25] !== t) {
197
+ t8 = signedIn ? t("account.login.logInAgain") : t("account.login.logIn");
198
+ $[24] = signedIn;
199
+ $[25] = t;
200
+ $[26] = t8;
184
201
  } else {
185
- t7 = $[21];
202
+ t8 = $[26];
186
203
  }
187
- let t8;
188
- if ($[22] !== t4 || $[23] !== t5 || $[24] !== t7) {
189
- t8 = /*#__PURE__*/_jsxs(Button, {
204
+ let t9;
205
+ if ($[27] !== t5 || $[28] !== t6 || $[29] !== t8) {
206
+ t9 = /*#__PURE__*/_jsxs(Button, {
190
207
  variant: "secondary",
191
- disabled: t4,
192
- onClick: t5,
193
- children: [t6, t7]
208
+ disabled: t5,
209
+ onClick: t6,
210
+ children: [t7, t8]
194
211
  });
195
- $[22] = t4;
196
- $[23] = t5;
197
- $[24] = t7;
198
- $[25] = t8;
212
+ $[27] = t5;
213
+ $[28] = t6;
214
+ $[29] = t8;
215
+ $[30] = t9;
199
216
  } else {
200
- t8 = $[25];
217
+ t9 = $[30];
201
218
  }
202
- const loginButton = t8;
203
- let t9;
204
- if ($[26] !== account.color) {
205
- t9 = /*#__PURE__*/_jsx("span", {
219
+ const loginButton = t9;
220
+ let t10;
221
+ if ($[31] !== account.color) {
222
+ t10 = /*#__PURE__*/_jsx("span", {
206
223
  className: "grid h-6 shrink-0 place-items-center",
207
224
  children: /*#__PURE__*/_jsx(AccountDot, {
208
225
  color: account.color,
209
226
  className: "size-3"
210
227
  })
211
228
  });
212
- $[26] = account.color;
213
- $[27] = t9;
229
+ $[31] = account.color;
230
+ $[32] = t10;
214
231
  } else {
215
- t9 = $[27];
232
+ t10 = $[32];
216
233
  }
217
- let t10;
218
- if ($[28] !== provider.kind) {
219
- t10 = /*#__PURE__*/_jsx(CliMark, {
234
+ let t11;
235
+ if ($[33] !== provider.kind) {
236
+ t11 = /*#__PURE__*/_jsx(CliMark, {
220
237
  kind: provider.kind,
221
238
  size: 12,
222
239
  className: "text-text-muted"
223
240
  });
224
- $[28] = provider.kind;
225
- $[29] = t10;
241
+ $[33] = provider.kind;
242
+ $[34] = t11;
226
243
  } else {
227
- t10 = $[29];
244
+ t11 = $[34];
228
245
  }
229
- let t11;
230
- if ($[30] !== provider.name || $[31] !== t) {
231
- t11 = t("account.kind", {
246
+ let t12;
247
+ if ($[35] !== provider.name || $[36] !== t) {
248
+ t12 = t("account.kind", {
232
249
  provider: provider.name
233
250
  });
234
- $[30] = provider.name;
235
- $[31] = t;
236
- $[32] = t11;
251
+ $[35] = provider.name;
252
+ $[36] = t;
253
+ $[37] = t12;
237
254
  } else {
238
- t11 = $[32];
255
+ t12 = $[37];
239
256
  }
240
- let t12;
241
- if ($[33] !== t10 || $[34] !== t11) {
242
- t12 = /*#__PURE__*/_jsxs(_Fragment, {
243
- children: [t10, t11]
257
+ let t13;
258
+ if ($[38] !== t11 || $[39] !== t12) {
259
+ t13 = /*#__PURE__*/_jsxs(_Fragment, {
260
+ children: [t11, t12]
244
261
  });
245
- $[33] = t10;
246
- $[34] = t11;
247
- $[35] = t12;
262
+ $[38] = t11;
263
+ $[39] = t12;
264
+ $[40] = t13;
248
265
  } else {
249
- t12 = $[35];
266
+ t13 = $[40];
250
267
  }
251
- let t13;
252
- if ($[36] !== folder || $[37] !== showFolder || $[38] !== t) {
253
- t13 = folder !== "" && /*#__PURE__*/_jsx(Button, {
268
+ let t14;
269
+ if ($[41] !== folder || $[42] !== showFolder || $[43] !== t) {
270
+ t14 = folder !== "" && /*#__PURE__*/_jsx(Button, {
254
271
  variant: "secondary",
255
272
  onClick: showFolder,
256
273
  children: t("account.showFolder")
257
274
  });
258
- $[36] = folder;
259
- $[37] = showFolder;
260
- $[38] = t;
261
- $[39] = t13;
262
- } else {
263
- t13 = $[39];
264
- }
265
- let t14;
266
- if ($[40] !== name || $[41] !== t12 || $[42] !== t13 || $[43] !== t9) {
267
- t14 = /*#__PURE__*/_jsx(DetailHeader, {
268
- mark: t9,
269
- title: name,
270
- subtitle: t12,
271
- actions: t13
272
- });
273
- $[40] = name;
274
- $[41] = t12;
275
- $[42] = t13;
276
- $[43] = t9;
275
+ $[41] = folder;
276
+ $[42] = showFolder;
277
+ $[43] = t;
277
278
  $[44] = t14;
278
279
  } else {
279
280
  t14 = $[44];
280
281
  }
281
282
  let t15;
282
- if ($[45] !== t) {
283
- t15 = t("account.enabled.label");
284
- $[45] = t;
285
- $[46] = t15;
283
+ if ($[45] !== name || $[46] !== t10 || $[47] !== t13 || $[48] !== t14) {
284
+ t15 = /*#__PURE__*/_jsx(DetailHeader, {
285
+ mark: t10,
286
+ title: name,
287
+ subtitle: t13,
288
+ actions: t14
289
+ });
290
+ $[45] = name;
291
+ $[46] = t10;
292
+ $[47] = t13;
293
+ $[48] = t14;
294
+ $[49] = t15;
286
295
  } else {
287
- t15 = $[46];
296
+ t15 = $[49];
288
297
  }
289
298
  let t16;
290
- if ($[47] !== t) {
291
- t16 = t("account.enabled.description");
292
- $[47] = t;
293
- $[48] = t16;
299
+ if ($[50] !== t) {
300
+ t16 = t("account.enabled.label");
301
+ $[50] = t;
302
+ $[51] = t16;
294
303
  } else {
295
- t16 = $[48];
304
+ t16 = $[51];
296
305
  }
297
- const t17 = account.enabled !== false;
298
- let t18;
299
- if ($[49] !== t) {
300
- t18 = t("account.enabled.label");
301
- $[49] = t;
302
- $[50] = t18;
306
+ let t17;
307
+ if ($[52] !== t) {
308
+ t17 = t("account.enabled.description");
309
+ $[52] = t;
310
+ $[53] = t17;
303
311
  } else {
304
- t18 = $[50];
312
+ t17 = $[53];
305
313
  }
314
+ const t18 = account.enabled !== false;
306
315
  let t19;
307
- if ($[51] !== account || $[52] !== host || $[53] !== id || $[54] !== scope) {
308
- t19 = checked => {
316
+ if ($[54] !== t) {
317
+ t19 = t("account.enabled.label");
318
+ $[54] = t;
319
+ $[55] = t19;
320
+ } else {
321
+ t19 = $[55];
322
+ }
323
+ let t20;
324
+ if ($[56] !== account || $[57] !== host || $[58] !== id || $[59] !== scope) {
325
+ t20 = checked => {
309
326
  const {
310
327
  enabled: _enabled,
311
328
  ...rest
@@ -315,170 +332,200 @@ export function AccountDetail(t0) {
315
332
  enabled: false
316
333
  });
317
334
  };
318
- $[51] = account;
319
- $[52] = host;
320
- $[53] = id;
321
- $[54] = scope;
322
- $[55] = t19;
323
- } else {
324
- t19 = $[55];
325
- }
326
- let t20;
327
- if ($[56] !== t17 || $[57] !== t18 || $[58] !== t19) {
328
- t20 = /*#__PURE__*/_jsx(Switch, {
329
- checked: t17,
330
- label: t18,
331
- onCheckedChange: t19
332
- });
333
- $[56] = t17;
334
- $[57] = t18;
335
- $[58] = t19;
336
- $[59] = t20;
335
+ $[56] = account;
336
+ $[57] = host;
337
+ $[58] = id;
338
+ $[59] = scope;
339
+ $[60] = t20;
337
340
  } else {
338
- t20 = $[59];
341
+ t20 = $[60];
339
342
  }
340
343
  let t21;
341
- if ($[60] !== t15 || $[61] !== t16 || $[62] !== t20) {
342
- t21 = /*#__PURE__*/_jsx(SettingsRow, {
343
- label: t15,
344
- description: t16,
345
- control: t20
344
+ if ($[61] !== t18 || $[62] !== t19 || $[63] !== t20) {
345
+ t21 = /*#__PURE__*/_jsx(Switch, {
346
+ checked: t18,
347
+ label: t19,
348
+ onCheckedChange: t20
346
349
  });
347
- $[60] = t15;
348
- $[61] = t16;
349
- $[62] = t20;
350
- $[63] = t21;
350
+ $[61] = t18;
351
+ $[62] = t19;
352
+ $[63] = t20;
353
+ $[64] = t21;
351
354
  } else {
352
- t21 = $[63];
355
+ t21 = $[64];
353
356
  }
354
357
  let t22;
355
- if ($[64] !== t) {
356
- t22 = t("account.name");
357
- $[64] = t;
358
- $[65] = t22;
358
+ if ($[65] !== t16 || $[66] !== t17 || $[67] !== t21) {
359
+ t22 = /*#__PURE__*/_jsx(SettingsRow, {
360
+ label: t16,
361
+ description: t17,
362
+ control: t21
363
+ });
364
+ $[65] = t16;
365
+ $[66] = t17;
366
+ $[67] = t21;
367
+ $[68] = t22;
359
368
  } else {
360
- t22 = $[65];
369
+ t22 = $[68];
361
370
  }
362
371
  let t23;
363
- if ($[66] !== t) {
372
+ if ($[69] !== t) {
364
373
  t23 = t("account.name");
365
- $[66] = t;
366
- $[67] = t23;
374
+ $[69] = t;
375
+ $[70] = t23;
367
376
  } else {
368
- t23 = $[67];
377
+ t23 = $[70];
369
378
  }
370
379
  let t24;
371
- if ($[68] !== account || $[69] !== host || $[70] !== id || $[71] !== scope) {
372
- t24 = label => void saveAccount(scope, host, id, {
373
- ...account,
374
- label
375
- });
376
- $[68] = account;
377
- $[69] = host;
378
- $[70] = id;
379
- $[71] = scope;
380
+ if ($[71] !== t) {
381
+ t24 = t("account.name");
382
+ $[71] = t;
380
383
  $[72] = t24;
381
384
  } else {
382
385
  t24 = $[72];
383
386
  }
384
387
  let t25;
385
- if ($[73] !== name || $[74] !== t23 || $[75] !== t24) {
386
- t25 = /*#__PURE__*/_jsx(NameField, {
387
- value: name,
388
- label: t23,
389
- onSave: t24
390
- }, name);
391
- $[73] = name;
392
- $[74] = t23;
393
- $[75] = t24;
394
- $[76] = t25;
388
+ if ($[73] !== account || $[74] !== host || $[75] !== id || $[76] !== scope) {
389
+ t25 = label => void saveAccount(scope, host, id, {
390
+ ...account,
391
+ label
392
+ });
393
+ $[73] = account;
394
+ $[74] = host;
395
+ $[75] = id;
396
+ $[76] = scope;
397
+ $[77] = t25;
395
398
  } else {
396
- t25 = $[76];
399
+ t25 = $[77];
397
400
  }
398
401
  let t26;
399
- if ($[77] !== t22 || $[78] !== t25) {
400
- t26 = /*#__PURE__*/_jsx(SettingsRow, {
401
- label: t22,
402
- control: t25
403
- });
404
- $[77] = t22;
405
- $[78] = t25;
406
- $[79] = t26;
402
+ if ($[78] !== name || $[79] !== t24 || $[80] !== t25) {
403
+ t26 = /*#__PURE__*/_jsx(NameField, {
404
+ value: name,
405
+ label: t24,
406
+ onSave: t25
407
+ }, name);
408
+ $[78] = name;
409
+ $[79] = t24;
410
+ $[80] = t25;
411
+ $[81] = t26;
407
412
  } else {
408
- t26 = $[79];
413
+ t26 = $[81];
409
414
  }
410
415
  let t27;
411
- if ($[80] !== t) {
412
- t27 = t("account.color");
413
- $[80] = t;
414
- $[81] = t27;
416
+ if ($[82] !== t23 || $[83] !== t26) {
417
+ t27 = /*#__PURE__*/_jsx(SettingsRow, {
418
+ label: t23,
419
+ control: t26
420
+ });
421
+ $[82] = t23;
422
+ $[83] = t26;
423
+ $[84] = t27;
415
424
  } else {
416
- t27 = $[81];
425
+ t27 = $[84];
417
426
  }
418
- const t28 = account.color;
419
- let t29;
420
- if ($[82] !== t) {
421
- t29 = t("account.color");
422
- $[82] = t;
423
- $[83] = t29;
427
+ let t28;
428
+ if ($[85] !== t) {
429
+ t28 = t("account.color");
430
+ $[85] = t;
431
+ $[86] = t28;
424
432
  } else {
425
- t29 = $[83];
433
+ t28 = $[86];
426
434
  }
435
+ const t29 = account.color;
427
436
  let t30;
428
- if ($[84] !== account || $[85] !== host || $[86] !== id || $[87] !== scope) {
429
- t30 = color => void saveAccount(scope, host, id, {
430
- ...account,
431
- color
432
- });
433
- $[84] = account;
434
- $[85] = host;
435
- $[86] = id;
436
- $[87] = scope;
437
+ if ($[87] !== t) {
438
+ t30 = t("account.color");
439
+ $[87] = t;
437
440
  $[88] = t30;
438
441
  } else {
439
442
  t30 = $[88];
440
443
  }
441
444
  let t31;
442
- if ($[89] !== account.color || $[90] !== t29 || $[91] !== t30) {
443
- t31 = /*#__PURE__*/_jsx(AccountColors, {
444
- value: t28,
445
- label: t29,
446
- onChange: t30
445
+ if ($[89] !== account || $[90] !== host || $[91] !== id || $[92] !== scope) {
446
+ t31 = color => void saveAccount(scope, host, id, {
447
+ ...account,
448
+ color
447
449
  });
448
- $[89] = account.color;
449
- $[90] = t29;
450
- $[91] = t30;
451
- $[92] = t31;
450
+ $[89] = account;
451
+ $[90] = host;
452
+ $[91] = id;
453
+ $[92] = scope;
454
+ $[93] = t31;
452
455
  } else {
453
- t31 = $[92];
456
+ t31 = $[93];
454
457
  }
455
458
  let t32;
456
- if ($[93] !== t27 || $[94] !== t31) {
457
- t32 = /*#__PURE__*/_jsx(SettingsRow, {
458
- label: t27,
459
- control: t31
459
+ if ($[94] !== account.color || $[95] !== t30 || $[96] !== t31) {
460
+ t32 = /*#__PURE__*/_jsx(AccountColors, {
461
+ value: t29,
462
+ label: t30,
463
+ onChange: t31
460
464
  });
461
- $[93] = t27;
462
- $[94] = t31;
463
- $[95] = t32;
465
+ $[94] = account.color;
466
+ $[95] = t30;
467
+ $[96] = t31;
468
+ $[97] = t32;
464
469
  } else {
465
- t32 = $[95];
470
+ t32 = $[97];
466
471
  }
467
472
  let t33;
468
- if ($[96] !== t21 || $[97] !== t26 || $[98] !== t32) {
469
- t33 = /*#__PURE__*/_jsxs(SettingsSection, {
470
- children: [t21, t26, t32]
473
+ if ($[98] !== t28 || $[99] !== t32) {
474
+ t33 = /*#__PURE__*/_jsx(SettingsRow, {
475
+ label: t28,
476
+ control: t32
471
477
  });
472
- $[96] = t21;
473
- $[97] = t26;
474
- $[98] = t32;
475
- $[99] = t33;
478
+ $[98] = t28;
479
+ $[99] = t32;
480
+ $[100] = t33;
476
481
  } else {
477
- t33 = $[99];
482
+ t33 = $[100];
478
483
  }
479
484
  let t34;
480
- if ($[100] !== canOpenLogin || $[101] !== folder || $[102] !== login || $[103] !== loginBlocked || $[104] !== loginButton || $[105] !== loginDetail || $[106] !== signedIn || $[107] !== status || $[108] !== t || $[109] !== trouble || $[110] !== variable) {
481
- t34 = (login === "chat" || login === "terminal" && canOpenLogin) && /*#__PURE__*/_jsxs(SettingsSection, {
485
+ if ($[101] !== t22 || $[102] !== t27 || $[103] !== t33) {
486
+ t34 = /*#__PURE__*/_jsxs(SettingsSection, {
487
+ children: [t22, t27, t33]
488
+ });
489
+ $[101] = t22;
490
+ $[102] = t27;
491
+ $[103] = t33;
492
+ $[104] = t34;
493
+ } else {
494
+ t34 = $[104];
495
+ }
496
+ let t35;
497
+ if ($[105] !== host || $[106] !== id || $[107] !== provider.name || $[108] !== scope || $[109] !== sharesConfig || $[110] !== showShareConfig || $[111] !== status || $[112] !== t || $[113] !== trouble) {
498
+ t35 = showShareConfig && /*#__PURE__*/_jsx(SettingsSection, {
499
+ children: /*#__PURE__*/_jsx(SettingsRow, {
500
+ label: t("account.shareConfig.label"),
501
+ description: sharesConfig && !trouble && status?.message ? `${t("account.shareConfig.description", {
502
+ provider: provider.name
503
+ })} ${status.message}` : t("account.shareConfig.description", {
504
+ provider: provider.name
505
+ }),
506
+ control: /*#__PURE__*/_jsx(Switch, {
507
+ checked: sharesConfig,
508
+ label: t("account.shareConfig.label"),
509
+ onCheckedChange: checked_0 => void shareAccountConfig(scope, host, id, checked_0)
510
+ })
511
+ })
512
+ });
513
+ $[105] = host;
514
+ $[106] = id;
515
+ $[107] = provider.name;
516
+ $[108] = scope;
517
+ $[109] = sharesConfig;
518
+ $[110] = showShareConfig;
519
+ $[111] = status;
520
+ $[112] = t;
521
+ $[113] = trouble;
522
+ $[114] = t35;
523
+ } else {
524
+ t35 = $[114];
525
+ }
526
+ let t36;
527
+ if ($[115] !== canOpenLogin || $[116] !== folder || $[117] !== login || $[118] !== loginBlocked || $[119] !== loginButton || $[120] !== loginDetail || $[121] !== signedIn || $[122] !== status || $[123] !== t || $[124] !== trouble || $[125] !== variable) {
528
+ t36 = (login === "chat" || login === "terminal" && canOpenLogin) && /*#__PURE__*/_jsxs(SettingsSection, {
482
529
  title: t("account.login.title"),
483
530
  children: [login === "chat" ? /*#__PURE__*/_jsx(SettingsRow, {
484
531
  label: t("account.login.inChat"),
@@ -520,185 +567,189 @@ export function AccountDetail(t0) {
520
567
  })]
521
568
  })]
522
569
  });
523
- $[100] = canOpenLogin;
524
- $[101] = folder;
525
- $[102] = login;
526
- $[103] = loginBlocked;
527
- $[104] = loginButton;
528
- $[105] = loginDetail;
529
- $[106] = signedIn;
530
- $[107] = status;
531
- $[108] = t;
532
- $[109] = trouble;
533
- $[110] = variable;
534
- $[111] = t34;
535
- } else {
536
- t34 = $[111];
570
+ $[115] = canOpenLogin;
571
+ $[116] = folder;
572
+ $[117] = login;
573
+ $[118] = loginBlocked;
574
+ $[119] = loginButton;
575
+ $[120] = loginDetail;
576
+ $[121] = signedIn;
577
+ $[122] = status;
578
+ $[123] = t;
579
+ $[124] = trouble;
580
+ $[125] = variable;
581
+ $[126] = t36;
582
+ } else {
583
+ t36 = $[126];
537
584
  }
538
- let t35;
539
- if ($[112] !== account.env) {
540
- t35 = JSON.stringify(account.env ?? []);
541
- $[112] = account.env;
542
- $[113] = t35;
585
+ let t37;
586
+ if ($[127] !== account.env) {
587
+ t37 = JSON.stringify(account.env ?? []);
588
+ $[127] = account.env;
589
+ $[128] = t37;
543
590
  } else {
544
- t35 = $[113];
591
+ t37 = $[128];
545
592
  }
546
- const t36 = `${id}:${t35}`;
547
- let t37;
548
- if ($[114] !== account || $[115] !== id || $[116] !== secretsAvailable || $[117] !== t36) {
549
- t37 = /*#__PURE__*/_jsx(AccountVariables, {
593
+ const t38 = `${id}:${t37}`;
594
+ let t39;
595
+ if ($[129] !== account || $[130] !== id || $[131] !== secretsAvailable || $[132] !== t38) {
596
+ t39 = /*#__PURE__*/_jsx(AccountVariables, {
550
597
  id: id,
551
598
  account: account,
552
599
  secretsAvailable: secretsAvailable
553
- }, t36);
554
- $[114] = account;
555
- $[115] = id;
556
- $[116] = secretsAvailable;
557
- $[117] = t36;
558
- $[118] = t37;
600
+ }, t38);
601
+ $[129] = account;
602
+ $[130] = id;
603
+ $[131] = secretsAvailable;
604
+ $[132] = t38;
605
+ $[133] = t39;
559
606
  } else {
560
- t37 = $[118];
607
+ t39 = $[133];
561
608
  }
562
- let t38;
563
- if ($[119] !== t) {
564
- t38 = t("account.remove.label");
565
- $[119] = t;
566
- $[120] = t38;
609
+ let t40;
610
+ if ($[134] !== t) {
611
+ t40 = t("account.remove.label");
612
+ $[134] = t;
613
+ $[135] = t40;
567
614
  } else {
568
- t38 = $[120];
615
+ t40 = $[135];
569
616
  }
570
- let t39;
571
- if ($[121] !== isDefault || $[122] !== t) {
572
- t39 = isDefault ? t("account.remove.defaultNote") : t("account.remove.description");
573
- $[121] = isDefault;
574
- $[122] = t;
575
- $[123] = t39;
617
+ let t41;
618
+ if ($[136] !== isDefault || $[137] !== t) {
619
+ t41 = isDefault ? t("account.remove.defaultNote") : t("account.remove.description");
620
+ $[136] = isDefault;
621
+ $[137] = t;
622
+ $[138] = t41;
576
623
  } else {
577
- t39 = $[123];
624
+ t41 = $[138];
578
625
  }
579
- let t40;
580
- if ($[124] === Symbol.for("react.memo_cache_sentinel")) {
581
- t40 = () => setConfirming(true);
582
- $[124] = t40;
626
+ let t42;
627
+ if ($[139] === Symbol.for("react.memo_cache_sentinel")) {
628
+ t42 = () => setConfirming(true);
629
+ $[139] = t42;
583
630
  } else {
584
- t40 = $[124];
631
+ t42 = $[139];
585
632
  }
586
- let t41;
587
- if ($[125] !== t) {
588
- t41 = t("account.remove.button");
589
- $[125] = t;
590
- $[126] = t41;
633
+ let t43;
634
+ if ($[140] !== t) {
635
+ t43 = t("account.remove.button");
636
+ $[140] = t;
637
+ $[141] = t43;
591
638
  } else {
592
- t41 = $[126];
639
+ t43 = $[141];
593
640
  }
594
- let t42;
595
- if ($[127] !== isDefault || $[128] !== t41) {
596
- t42 = /*#__PURE__*/_jsx(Button, {
641
+ let t44;
642
+ if ($[142] !== isDefault || $[143] !== t43) {
643
+ t44 = /*#__PURE__*/_jsx(Button, {
597
644
  variant: "danger-outline",
598
645
  disabled: isDefault,
599
- onClick: t40,
600
- children: t41
646
+ onClick: t42,
647
+ children: t43
601
648
  });
602
- $[127] = isDefault;
603
- $[128] = t41;
604
- $[129] = t42;
649
+ $[142] = isDefault;
650
+ $[143] = t43;
651
+ $[144] = t44;
605
652
  } else {
606
- t42 = $[129];
653
+ t44 = $[144];
607
654
  }
608
- let t43;
609
- if ($[130] !== t38 || $[131] !== t39 || $[132] !== t42) {
610
- t43 = /*#__PURE__*/_jsx(SettingsSection, {
655
+ let t45;
656
+ if ($[145] !== t40 || $[146] !== t41 || $[147] !== t44) {
657
+ t45 = /*#__PURE__*/_jsx(SettingsSection, {
611
658
  children: /*#__PURE__*/_jsx(SettingsRow, {
612
- label: t38,
613
- description: t39,
614
- control: t42
659
+ label: t40,
660
+ description: t41,
661
+ control: t44
615
662
  })
616
663
  });
617
- $[130] = t38;
618
- $[131] = t39;
619
- $[132] = t42;
620
- $[133] = t43;
664
+ $[145] = t40;
665
+ $[146] = t41;
666
+ $[147] = t44;
667
+ $[148] = t45;
621
668
  } else {
622
- t43 = $[133];
669
+ t45 = $[148];
623
670
  }
624
- let t44;
625
- if ($[134] !== name || $[135] !== t) {
626
- t44 = t("account.remove.confirmTitle", {
671
+ let t46;
672
+ if ($[149] !== name || $[150] !== t) {
673
+ t46 = t("account.remove.confirmTitle", {
627
674
  account: name
628
675
  });
629
- $[134] = name;
630
- $[135] = t;
631
- $[136] = t44;
676
+ $[149] = name;
677
+ $[150] = t;
678
+ $[151] = t46;
632
679
  } else {
633
- t44 = $[136];
680
+ t46 = $[151];
634
681
  }
635
- let t45;
636
- if ($[137] !== folder || $[138] !== t) {
637
- t45 = t("account.remove.confirmDescription", {
682
+ let t47;
683
+ if ($[152] !== folder || $[153] !== t) {
684
+ t47 = t("account.remove.confirmDescription", {
638
685
  folder
639
686
  });
640
- $[137] = folder;
641
- $[138] = t;
642
- $[139] = t45;
687
+ $[152] = folder;
688
+ $[153] = t;
689
+ $[154] = t47;
643
690
  } else {
644
- t45 = $[139];
691
+ t47 = $[154];
645
692
  }
646
- let t46;
647
- if ($[140] !== t) {
648
- t46 = t("account.remove.confirm");
649
- $[140] = t;
650
- $[141] = t46;
693
+ let t48;
694
+ if ($[155] !== t) {
695
+ t48 = t("account.remove.confirm");
696
+ $[155] = t;
697
+ $[156] = t48;
651
698
  } else {
652
- t46 = $[141];
699
+ t48 = $[156];
653
700
  }
654
- let t47;
655
- if ($[142] !== host || $[143] !== id || $[144] !== onRemoved || $[145] !== provider.kind || $[146] !== scope) {
656
- t47 = async () => {
701
+ let t49;
702
+ if ($[157] !== host || $[158] !== id || $[159] !== onRemoved || $[160] !== provider.kind || $[161] !== scope) {
703
+ t49 = async () => {
657
704
  await removeAccount(scope, host, id, provider.kind);
658
705
  onRemoved();
659
706
  };
660
- $[142] = host;
661
- $[143] = id;
662
- $[144] = onRemoved;
663
- $[145] = provider.kind;
664
- $[146] = scope;
665
- $[147] = t47;
666
- } else {
667
- t47 = $[147];
668
- }
669
- let t48;
670
- if ($[148] !== confirming || $[149] !== t44 || $[150] !== t45 || $[151] !== t46 || $[152] !== t47) {
671
- t48 = /*#__PURE__*/_jsx(ConfirmDialog, {
707
+ $[157] = host;
708
+ $[158] = id;
709
+ $[159] = onRemoved;
710
+ $[160] = provider.kind;
711
+ $[161] = scope;
712
+ $[162] = t49;
713
+ } else {
714
+ t49 = $[162];
715
+ }
716
+ let t50;
717
+ if ($[163] !== confirming || $[164] !== t46 || $[165] !== t47 || $[166] !== t48 || $[167] !== t49) {
718
+ t50 = /*#__PURE__*/_jsx(ConfirmDialog, {
672
719
  open: confirming,
673
720
  onOpenChange: setConfirming,
674
- title: t44,
675
- description: t45,
676
- confirmLabel: t46,
677
- onConfirm: t47
721
+ title: t46,
722
+ description: t47,
723
+ confirmLabel: t48,
724
+ onConfirm: t49
678
725
  });
679
- $[148] = confirming;
680
- $[149] = t44;
681
- $[150] = t45;
682
- $[151] = t46;
683
- $[152] = t47;
684
- $[153] = t48;
685
- } else {
686
- t48 = $[153];
687
- }
688
- let t49;
689
- if ($[154] !== t14 || $[155] !== t33 || $[156] !== t34 || $[157] !== t37 || $[158] !== t43 || $[159] !== t48) {
690
- t49 = /*#__PURE__*/_jsxs(_Fragment, {
691
- children: [t14, t33, t34, t37, t43, t48]
726
+ $[163] = confirming;
727
+ $[164] = t46;
728
+ $[165] = t47;
729
+ $[166] = t48;
730
+ $[167] = t49;
731
+ $[168] = t50;
732
+ } else {
733
+ t50 = $[168];
734
+ }
735
+ let t51;
736
+ if ($[169] !== t15 || $[170] !== t34 || $[171] !== t35 || $[172] !== t36 || $[173] !== t39 || $[174] !== t45 || $[175] !== t50) {
737
+ t51 = /*#__PURE__*/_jsxs(_Fragment, {
738
+ children: [t15, t34, t35, t36, t39, t45, t50]
692
739
  });
693
- $[154] = t14;
694
- $[155] = t33;
695
- $[156] = t34;
696
- $[157] = t37;
697
- $[158] = t43;
698
- $[159] = t48;
699
- $[160] = t49;
700
- } else {
701
- t49 = $[160];
702
- }
703
- return t49;
740
+ $[169] = t15;
741
+ $[170] = t34;
742
+ $[171] = t35;
743
+ $[172] = t36;
744
+ $[173] = t39;
745
+ $[174] = t45;
746
+ $[175] = t50;
747
+ $[176] = t51;
748
+ } else {
749
+ t51 = $[176];
750
+ }
751
+ return t51;
752
+ }
753
+ function _temp2(row) {
754
+ return row.accounts?.sharedConfigKinds;
704
755
  }