@llmnative/runner 1.0.3 → 1.1.1

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.
package/dist/ui.mjs CHANGED
@@ -2,7 +2,8 @@ import { RunnerError as e } from "./client.mjs";
2
2
  import { RUNNER_REQUIREMENTS as t, checkRunner as n, installCommand as r, isDomain as i, lookupDomain as a, verifiedInstallCommands as o } from "./steps.mjs";
3
3
  import { useCallback as s, useEffect as c, useMemo as l, useState as u } from "react";
4
4
  import { ActionButton as d, Alert as f, Badge as p, Card as m, Code as h, DescriptionList as g, Form as _, LoadingButton as v, Modal as y, ModalYesNo as b, Password as x, Select as S, String as C, Switch as w, TextArea as T } from "@llmnative/react";
5
- import { Fragment as E, jsx as D, jsxs as O } from "react/jsx-runtime";
5
+ import { jsx as E, jsxs as D } from "react/jsx-runtime";
6
+ import { createPortal as O } from "react-dom";
6
7
  // src/ui/texts.ts
7
8
  var k = {
8
9
  accountsTitleUser: "My subscriptions",
@@ -73,7 +74,7 @@ var k = {
73
74
  addGuided: "Guide me",
74
75
  addGuidedHint: "Step by step instructions to install it by hand.",
75
76
  addExisting: "It is already installed",
76
- addExistingHint: "Its address and a pairing code.",
77
+ addExistingHint: "Its address: you approve on the runner.",
77
78
  addName: "Name",
78
79
  addNamePlaceholder: "Runner Europe 1",
79
80
  addUrl: "Address",
@@ -116,6 +117,26 @@ var k = {
116
117
  consoleRemoveTenant: "Remove tenant",
117
118
  consoleRemoveTenantConfirm: "Remove {name}, its keys and chats?",
118
119
  consoleAccounts: "Accounts",
120
+ pairNext: "Continue",
121
+ pairWaitingTitle: "Approve on the runner",
122
+ pairWaitingHint: "Open the runner and approve the request: check that it shows this same code.",
123
+ pairOpen: "Open the runner to approve",
124
+ pairWaiting: "Waiting for the approval… (until {at})",
125
+ pairDenied: "The request was refused on the runner.",
126
+ pairExpired: "The request expired: ask again.",
127
+ pairAgain: "Ask again",
128
+ pairWithCode: "I have a pairing code",
129
+ pairWithApproval: "Approve on the runner instead",
130
+ consoleRequests: "Requests to connect",
131
+ consoleRequestsHint: "A platform asked to connect to this runner. Approve only if you asked from there and the code is the one it shows.",
132
+ consoleRequestsEmpty: "No requests waiting.",
133
+ consoleRequestFrom: "{name}, from {from}, asked at {at}",
134
+ consoleRequestMatch: "The request you opened",
135
+ consoleApprove: "Approve",
136
+ consoleDeny: "Refuse",
137
+ consoleApproved: "Approved: {name} is connected.",
138
+ consoleDenied: "Refused.",
139
+ consoleRemember: "Remember on this browser",
119
140
  close: "Close",
120
141
  cancel: "Cancel"
121
142
  }, A = {
@@ -187,7 +208,7 @@ var k = {
187
208
  addGuided: "Guidami",
188
209
  addGuidedHint: "Istruzioni passo passo per installarlo a mano.",
189
210
  addExisting: "È già installato",
190
- addExistingHint: "Il suo indirizzo e un codice di abbinamento.",
211
+ addExistingHint: "Il suo indirizzo: approvi sul runner.",
191
212
  addName: "Nome",
192
213
  addNamePlaceholder: "Runner Europa 1",
193
214
  addUrl: "Indirizzo",
@@ -230,6 +251,26 @@ var k = {
230
251
  consoleRemoveTenant: "Rimuovi tenant",
231
252
  consoleRemoveTenantConfirm: "Rimuovere {name}, le sue chiavi e le sue chat?",
232
253
  consoleAccounts: "Account",
254
+ pairNext: "Continua",
255
+ pairWaitingTitle: "Approva sul runner",
256
+ pairWaitingHint: "Apri il runner e approva la richiesta: controlla che mostri questo stesso codice.",
257
+ pairOpen: "Apri il runner per approvare",
258
+ pairWaiting: "In attesa dell'approvazione… (fino alle {at})",
259
+ pairDenied: "La richiesta è stata rifiutata sul runner.",
260
+ pairExpired: "La richiesta è scaduta: chiedi di nuovo.",
261
+ pairAgain: "Chiedi di nuovo",
262
+ pairWithCode: "Ho un codice di abbinamento",
263
+ pairWithApproval: "Approva sul runner invece",
264
+ consoleRequests: "Richieste di collegamento",
265
+ consoleRequestsHint: "Una piattaforma ha chiesto di collegarsi a questo runner. Approva solo se l'hai chiesto tu da lì e il codice è quello che mostra.",
266
+ consoleRequestsEmpty: "Nessuna richiesta in attesa.",
267
+ consoleRequestFrom: "{name}, da {from}, alle {at}",
268
+ consoleRequestMatch: "La richiesta che hai aperto",
269
+ consoleApprove: "Approva",
270
+ consoleDeny: "Rifiuta",
271
+ consoleApproved: "Approvata: {name} è collegato.",
272
+ consoleDenied: "Rifiutata.",
273
+ consoleRemember: "Ricorda su questo browser",
233
274
  close: "Chiudi",
234
275
  cancel: "Annulla"
235
276
  }, j = {
@@ -268,88 +309,88 @@ function I({ client: t, scope: n, locale: r, texts: i, onChange: a }) {
268
309
  let e = await C();
269
310
  a?.(e);
270
311
  };
271
- return /* @__PURE__ */ O(m, {
312
+ return /* @__PURE__ */ D(m, {
272
313
  title: n === "user" ? o.accountsTitleUser : o.accountsTitleTenant,
273
314
  loading: l === null,
274
315
  loaderMinHeight: 120,
275
- children: [/* @__PURE__ */ O("div", {
316
+ children: [/* @__PURE__ */ D("div", {
276
317
  className: "flex flex-col gap-3",
277
318
  children: [
278
- /* @__PURE__ */ D("p", {
319
+ /* @__PURE__ */ E("p", {
279
320
  className: "text-sm text-muted-foreground",
280
321
  children: n === "user" ? o.accountsIntroUser : o.accountsIntroTenant
281
322
  }),
282
- g && /* @__PURE__ */ D(f, {
323
+ g && /* @__PURE__ */ E(f, {
283
324
  variant: "danger",
284
325
  children: N(o.error, { error: g })
285
326
  }),
286
- l?.length === 0 && !g && /* @__PURE__ */ D("p", {
327
+ l?.length === 0 && !g && /* @__PURE__ */ E("p", {
287
328
  className: "text-sm text-muted-foreground",
288
329
  children: o.accountsEmpty
289
330
  }),
290
- l?.map((e) => /* @__PURE__ */ O("div", {
331
+ l?.map((e) => /* @__PURE__ */ D("div", {
291
332
  className: "flex flex-wrap items-center gap-2 rounded-md border border-border p-3",
292
- children: [/* @__PURE__ */ O("div", {
333
+ children: [/* @__PURE__ */ D("div", {
293
334
  className: "min-w-0 flex-1",
294
- children: [/* @__PURE__ */ O("div", {
335
+ children: [/* @__PURE__ */ D("div", {
295
336
  className: "flex flex-wrap items-center gap-2",
296
337
  children: [
297
- /* @__PURE__ */ D("span", {
338
+ /* @__PURE__ */ E("span", {
298
339
  className: "font-medium",
299
340
  children: e.label ?? P[e.provider] ?? e.provider
300
341
  }),
301
- /* @__PURE__ */ D(p, {
342
+ /* @__PURE__ */ E(p, {
302
343
  variant: "secondary",
303
344
  children: P[e.provider] ?? e.provider
304
345
  }),
305
- e.noCreditUntil && /* @__PURE__ */ D(p, {
346
+ e.noCreditUntil && /* @__PURE__ */ E(p, {
306
347
  variant: "warning",
307
348
  children: N(o.accountsNoCredit, { at: F(e.noCreditUntil) })
308
349
  })
309
350
  ]
310
- }), /* @__PURE__ */ D("p", {
351
+ }), /* @__PURE__ */ E("p", {
311
352
  className: "text-xs text-muted-foreground",
312
353
  children: N(o.accountsConnected, { at: F(e.at) })
313
354
  })]
314
- }), /* @__PURE__ */ D(d, {
355
+ }), /* @__PURE__ */ E(d, {
315
356
  icon: "unlink",
316
357
  label: o.accountsRemove,
317
358
  variant: "outline-danger",
318
359
  onClick: () => S(e)
319
360
  })]
320
361
  }, `${e.provider}/${e.id}`)),
321
- v === "claude" && /* @__PURE__ */ D(L, {
362
+ v === "claude" && /* @__PURE__ */ E(L, {
322
363
  client: t,
323
364
  t: o,
324
365
  onDone: w,
325
366
  onCancel: () => y(null)
326
367
  }),
327
- v === "opencode" && /* @__PURE__ */ D(R, {
368
+ v === "opencode" && /* @__PURE__ */ E(R, {
328
369
  client: t,
329
370
  t: o,
330
371
  onDone: w,
331
372
  onCancel: () => y(null)
332
373
  }),
333
- !v && /* @__PURE__ */ O("div", {
374
+ !v && /* @__PURE__ */ D("div", {
334
375
  className: "flex flex-wrap gap-2",
335
- children: [/* @__PURE__ */ D(d, {
376
+ children: [/* @__PURE__ */ E(d, {
336
377
  icon: "plus",
337
378
  label: o.claudeConnect,
338
379
  variant: "primary",
339
380
  onClick: () => y("claude")
340
- }), /* @__PURE__ */ D(d, {
381
+ }), /* @__PURE__ */ E(d, {
341
382
  icon: "plus",
342
383
  label: o.opencodeConnect,
343
384
  variant: "outline-secondary",
344
385
  onClick: () => y("opencode")
345
386
  })]
346
387
  }),
347
- /* @__PURE__ */ D("p", {
388
+ /* @__PURE__ */ E("p", {
348
389
  className: "text-xs text-muted-foreground",
349
390
  children: o.termsNote
350
391
  })
351
392
  ]
352
- }), x && /* @__PURE__ */ D(b, {
393
+ }), x && /* @__PURE__ */ E(b, {
353
394
  title: o.accountsRemove,
354
395
  danger: !0,
355
396
  onClose: () => S(null),
@@ -365,47 +406,47 @@ function L({ client: t, t: n, onDone: r, onCancel: i }) {
365
406
  return t.accounts.startClaudeLogin().then(({ url: t }) => !e && o(t)).catch(() => !e && g(n.claudeNoLink)), () => {
366
407
  e = !0;
367
408
  };
368
- }, [t, n]), /* @__PURE__ */ O("div", {
409
+ }, [t, n]), /* @__PURE__ */ D("div", {
369
410
  className: "flex flex-col gap-3 rounded-md border border-border p-3",
370
411
  children: [
371
- h && /* @__PURE__ */ D(f, {
412
+ h && /* @__PURE__ */ E(f, {
372
413
  variant: "danger",
373
414
  children: h
374
415
  }),
375
- /* @__PURE__ */ D("p", {
416
+ /* @__PURE__ */ E("p", {
376
417
  className: "text-sm",
377
418
  children: n.claudeStep1
378
419
  }),
379
- /* @__PURE__ */ D("div", { children: /* @__PURE__ */ D(d, {
420
+ /* @__PURE__ */ E("div", { children: /* @__PURE__ */ E(d, {
380
421
  icon: "external-link",
381
422
  label: n.claudeOpen,
382
423
  variant: "primary",
383
424
  disabled: !a,
384
425
  onClick: () => a && window.open(a, "_blank", "noopener,noreferrer")
385
426
  }) }),
386
- /* @__PURE__ */ D("p", {
427
+ /* @__PURE__ */ E("p", {
387
428
  className: "text-sm",
388
429
  children: n.claudeStep2
389
430
  }),
390
- /* @__PURE__ */ O(_, {
431
+ /* @__PURE__ */ D(_, {
391
432
  appearance: "empty",
392
433
  showNotice: !1,
393
434
  onSubmit: () => !1,
394
- children: [/* @__PURE__ */ D(C, {
435
+ children: [/* @__PURE__ */ E(C, {
395
436
  name: "code",
396
437
  label: n.claudeCode,
397
438
  autoComplete: "off",
398
439
  onChange: ({ value: e }) => l(String(e ?? ""))
399
- }), /* @__PURE__ */ D(C, {
440
+ }), /* @__PURE__ */ E(C, {
400
441
  name: "label",
401
442
  label: n.claudeLabel,
402
443
  placeholder: n.claudeLabelPlaceholder,
403
444
  onChange: ({ value: e }) => m(String(e ?? ""))
404
445
  })]
405
446
  }),
406
- /* @__PURE__ */ O("div", {
447
+ /* @__PURE__ */ D("div", {
407
448
  className: "flex gap-2",
408
- children: [/* @__PURE__ */ D(v, {
449
+ children: [/* @__PURE__ */ E(v, {
409
450
  label: n.claudeFinish,
410
451
  variant: "primary",
411
452
  disabled: !a || !s.trim(),
@@ -416,7 +457,7 @@ function L({ client: t, t: n, onDone: r, onCancel: i }) {
416
457
  g(t instanceof e && t.code === "refused" ? n.claudeRefused : N(n.error, { error: t instanceof e ? t.code : String(t) }));
417
458
  }
418
459
  }
419
- }), /* @__PURE__ */ D(d, {
460
+ }), /* @__PURE__ */ E(d, {
420
461
  label: n.cancel,
421
462
  variant: "outline-secondary",
422
463
  onClick: i
@@ -427,31 +468,31 @@ function L({ client: t, t: n, onDone: r, onCancel: i }) {
427
468
  }
428
469
  function R({ client: t, t: n, onDone: r, onCancel: i }) {
429
470
  let [a, o] = u(""), [s, c] = u(""), [l, p] = u(null);
430
- return /* @__PURE__ */ O("div", {
471
+ return /* @__PURE__ */ D("div", {
431
472
  className: "flex flex-col gap-3 rounded-md border border-border p-3",
432
473
  children: [
433
- l && /* @__PURE__ */ D(f, {
474
+ l && /* @__PURE__ */ E(f, {
434
475
  variant: "danger",
435
476
  children: l
436
477
  }),
437
- /* @__PURE__ */ O(_, {
478
+ /* @__PURE__ */ D(_, {
438
479
  appearance: "empty",
439
480
  showNotice: !1,
440
481
  onSubmit: () => !1,
441
- children: [/* @__PURE__ */ D(x, {
482
+ children: [/* @__PURE__ */ E(x, {
442
483
  name: "key",
443
484
  label: n.opencodeKey,
444
485
  autoComplete: "off",
445
486
  onChange: ({ value: e }) => o(String(e ?? ""))
446
- }), /* @__PURE__ */ D(C, {
487
+ }), /* @__PURE__ */ E(C, {
447
488
  name: "label",
448
489
  label: n.claudeLabel,
449
490
  onChange: ({ value: e }) => c(String(e ?? ""))
450
491
  })]
451
492
  }),
452
- /* @__PURE__ */ O("div", {
493
+ /* @__PURE__ */ D("div", {
453
494
  className: "flex gap-2",
454
- children: [/* @__PURE__ */ D(v, {
495
+ children: [/* @__PURE__ */ E(v, {
455
496
  label: n.opencodeAdd,
456
497
  variant: "primary",
457
498
  disabled: !a.trim(),
@@ -462,7 +503,7 @@ function R({ client: t, t: n, onDone: r, onCancel: i }) {
462
503
  p(N(n.error, { error: t instanceof e ? t.code : String(t) }));
463
504
  }
464
505
  }
465
- }), /* @__PURE__ */ D(d, {
506
+ }), /* @__PURE__ */ E(d, {
466
507
  label: n.cancel,
467
508
  variant: "outline-secondary",
468
509
  onClick: i
@@ -473,11 +514,11 @@ function R({ client: t, t: n, onDone: r, onCancel: i }) {
473
514
  }
474
515
  // src/ui/InstallGuide.tsx
475
516
  function z({ title: e, children: t, done: n }) {
476
- return /* @__PURE__ */ O("section", {
517
+ return /* @__PURE__ */ D("section", {
477
518
  className: "flex flex-col gap-2 border-l-2 border-border pl-4",
478
- children: [/* @__PURE__ */ O("h4", {
519
+ children: [/* @__PURE__ */ D("h4", {
479
520
  className: "flex items-center gap-2 text-sm font-semibold",
480
- children: [e, n && /* @__PURE__ */ D(p, {
521
+ children: [e, n && /* @__PURE__ */ E(p, {
481
522
  variant: "success",
482
523
  children: "✓"
483
524
  })]
@@ -485,13 +526,13 @@ function z({ title: e, children: t, done: n }) {
485
526
  });
486
527
  }
487
528
  function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p = n, version: m }) {
488
- let g = M(e, s), [y, b] = u(""), [x, S] = u(null), [w, T] = u(null), [E, k] = u(""), [A, j] = u(!1), [P, F] = u(null), I = i(y), L = `https://${y.trim().toLowerCase()}`, R = t;
489
- return /* @__PURE__ */ O("div", {
529
+ let g = M(e, s), [y, b] = u(""), [x, S] = u(null), [w, T] = u(null), [O, k] = u(""), [A, j] = u(!1), [P, F] = u(null), I = i(y), L = `https://${y.trim().toLowerCase()}`, R = t;
530
+ return /* @__PURE__ */ D("div", {
490
531
  className: "flex flex-col gap-5",
491
532
  children: [
492
- /* @__PURE__ */ D(z, {
533
+ /* @__PURE__ */ E(z, {
493
534
  title: g.guideServerTitle,
494
- children: /* @__PURE__ */ D("p", {
535
+ children: /* @__PURE__ */ E("p", {
495
536
  className: "text-sm",
496
537
  children: N(g.guideServer, {
497
538
  systems: R.systems.join(", "),
@@ -502,19 +543,19 @@ function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p =
502
543
  })
503
544
  })
504
545
  }),
505
- /* @__PURE__ */ O(z, {
546
+ /* @__PURE__ */ D(z, {
506
547
  title: g.guideDnsTitle,
507
548
  done: !!x?.ips.length,
508
549
  children: [
509
- /* @__PURE__ */ D("p", {
550
+ /* @__PURE__ */ E("p", {
510
551
  className: "text-sm",
511
552
  children: g.guideDns
512
553
  }),
513
- /* @__PURE__ */ D(_, {
554
+ /* @__PURE__ */ E(_, {
514
555
  appearance: "empty",
515
556
  showNotice: !1,
516
557
  onSubmit: () => !1,
517
- children: /* @__PURE__ */ D(C, {
558
+ children: /* @__PURE__ */ E(C, {
518
559
  name: "domain",
519
560
  label: g.guideDomain,
520
561
  placeholder: "runner.example.com",
@@ -524,18 +565,18 @@ function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p =
524
565
  }
525
566
  })
526
567
  }),
527
- /* @__PURE__ */ O("div", {
568
+ /* @__PURE__ */ D("div", {
528
569
  className: "flex flex-wrap items-center gap-2",
529
- children: [/* @__PURE__ */ D(v, {
570
+ children: [/* @__PURE__ */ E(v, {
530
571
  label: g.guideCheckDns,
531
572
  variant: "outline-secondary",
532
573
  disabled: !I,
533
574
  onClick: async () => S({ ips: await l(y.trim().toLowerCase()).catch(() => []) })
534
- }), x && (x.ips.length ? /* @__PURE__ */ D(f, {
575
+ }), x && (x.ips.length ? /* @__PURE__ */ E(f, {
535
576
  variant: "success",
536
577
  appearance: "text",
537
578
  children: N(g.guideDnsOk, { ips: x.ips.join(", ") })
538
- }) : /* @__PURE__ */ D(f, {
579
+ }) : /* @__PURE__ */ E(f, {
539
580
  variant: "warning",
540
581
  appearance: "text",
541
582
  children: g.guideDnsMissing
@@ -543,21 +584,21 @@ function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p =
543
584
  })
544
585
  ]
545
586
  }),
546
- /* @__PURE__ */ D(z, {
587
+ /* @__PURE__ */ E(z, {
547
588
  title: g.guideAccessTitle,
548
- children: /* @__PURE__ */ D("p", {
589
+ children: /* @__PURE__ */ E("p", {
549
590
  className: "text-sm",
550
591
  children: g.guideAccess
551
592
  })
552
593
  }),
553
- /* @__PURE__ */ O(z, {
594
+ /* @__PURE__ */ D(z, {
554
595
  title: g.guideInstallTitle,
555
596
  children: [
556
- /* @__PURE__ */ D("p", {
597
+ /* @__PURE__ */ E("p", {
557
598
  className: "text-sm",
558
599
  children: g.guideInstall
559
600
  }),
560
- /* @__PURE__ */ D(h, {
601
+ /* @__PURE__ */ E(h, {
561
602
  language: "bash",
562
603
  showCopy: !0,
563
604
  children: r({
@@ -565,12 +606,12 @@ function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p =
565
606
  ...m ? { version: m } : {}
566
607
  })
567
608
  }),
568
- /* @__PURE__ */ D("div", { children: /* @__PURE__ */ D(d, {
609
+ /* @__PURE__ */ E("div", { children: /* @__PURE__ */ E(d, {
569
610
  label: g.guideVerified,
570
611
  variant: "link",
571
612
  onClick: () => j((e) => !e)
572
613
  }) }),
573
- A && /* @__PURE__ */ D(h, {
614
+ A && /* @__PURE__ */ E(h, {
574
615
  language: "bash",
575
616
  showCopy: !0,
576
617
  children: o({
@@ -580,19 +621,19 @@ function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p =
580
621
  })
581
622
  ]
582
623
  }),
583
- /* @__PURE__ */ O(z, {
624
+ /* @__PURE__ */ D(z, {
584
625
  title: g.guidePairTitle,
585
626
  done: w?.ok,
586
627
  children: [
587
- /* @__PURE__ */ D("p", {
628
+ /* @__PURE__ */ E("p", {
588
629
  className: "text-sm",
589
630
  children: g.guidePair
590
631
  }),
591
- /* @__PURE__ */ D(_, {
632
+ /* @__PURE__ */ E(_, {
592
633
  appearance: "empty",
593
634
  showNotice: !1,
594
635
  onSubmit: () => !1,
595
- children: /* @__PURE__ */ D(C, {
636
+ children: /* @__PURE__ */ E(C, {
596
637
  name: "code",
597
638
  label: g.addCode,
598
639
  placeholder: "ABCD-EFGH",
@@ -600,18 +641,18 @@ function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p =
600
641
  onChange: ({ value: e }) => k(String(e ?? ""))
601
642
  })
602
643
  }),
603
- w && /* @__PURE__ */ D(f, {
644
+ w && /* @__PURE__ */ E(f, {
604
645
  variant: w.ok ? "success" : "warning",
605
646
  appearance: "text",
606
647
  children: w.text
607
648
  }),
608
- P && /* @__PURE__ */ D(f, {
649
+ P && /* @__PURE__ */ E(f, {
609
650
  variant: "danger",
610
651
  children: P
611
652
  }),
612
- /* @__PURE__ */ O("div", {
653
+ /* @__PURE__ */ D("div", {
613
654
  className: "flex flex-wrap gap-2",
614
- children: [/* @__PURE__ */ D(v, {
655
+ children: [/* @__PURE__ */ E(v, {
615
656
  label: g.guideCheckHealth,
616
657
  variant: "outline-secondary",
617
658
  disabled: !I,
@@ -628,15 +669,15 @@ function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p =
628
669
  text: N(g.guideHealthKo, { url: L })
629
670
  });
630
671
  }
631
- }), /* @__PURE__ */ D(v, {
672
+ }), /* @__PURE__ */ E(v, {
632
673
  label: g.addConnect,
633
674
  variant: "primary",
634
- disabled: !I || E.trim().length < 8,
675
+ disabled: !I || O.trim().length < 8,
635
676
  onClick: async () => {
636
677
  try {
637
678
  F(null), await c({
638
679
  url: L,
639
- code: E.trim()
680
+ code: O.trim()
640
681
  });
641
682
  } catch (e) {
642
683
  F(N(g.error, { error: e.message }));
@@ -646,9 +687,9 @@ function B({ locale: e, texts: s, onPair: c, lookup: l = (e) => a(e), check: p =
646
687
  })
647
688
  ]
648
689
  }),
649
- /* @__PURE__ */ D(z, {
690
+ /* @__PURE__ */ E(z, {
650
691
  title: g.guideTroubleTitle,
651
- children: /* @__PURE__ */ D("p", {
692
+ children: /* @__PURE__ */ E("p", {
652
693
  className: "text-sm text-muted-foreground",
653
694
  children: g.guideTrouble
654
695
  })
@@ -674,19 +715,19 @@ function V({ fleet: e, locale: t, texts: n }) {
674
715
  c(() => {
675
716
  T();
676
717
  }, [T]);
677
- let E = async (t, n) => {
718
+ let O = async (t, n) => {
678
719
  await e.update(t, n), await T();
679
720
  };
680
- return /* @__PURE__ */ O("div", {
721
+ return /* @__PURE__ */ D("div", {
681
722
  className: "flex flex-col gap-4",
682
723
  children: [
683
- /* @__PURE__ */ D(m, {
684
- header: /* @__PURE__ */ O("div", {
724
+ /* @__PURE__ */ E(m, {
725
+ header: /* @__PURE__ */ D("div", {
685
726
  className: "flex flex-wrap items-center gap-2",
686
- children: [/* @__PURE__ */ D("h3", {
727
+ children: [/* @__PURE__ */ E("h3", {
687
728
  className: "flex-1 text-base font-semibold",
688
729
  children: r.runnersTitle
689
- }), /* @__PURE__ */ D(d, {
730
+ }), /* @__PURE__ */ E(d, {
690
731
  icon: "plus",
691
732
  label: r.runnersAdd,
692
733
  variant: "primary",
@@ -695,56 +736,56 @@ function V({ fleet: e, locale: t, texts: n }) {
695
736
  }),
696
737
  loading: i === null,
697
738
  loaderMinHeight: 120,
698
- children: /* @__PURE__ */ O("div", {
739
+ children: /* @__PURE__ */ D("div", {
699
740
  className: "flex flex-col gap-3",
700
741
  children: [
701
- /* @__PURE__ */ D("p", {
742
+ /* @__PURE__ */ E("p", {
702
743
  className: "text-sm text-muted-foreground",
703
744
  children: r.runnersIntro
704
745
  }),
705
- x && /* @__PURE__ */ D(f, {
746
+ x && /* @__PURE__ */ E(f, {
706
747
  variant: "danger",
707
748
  children: x
708
749
  }),
709
- i?.length === 0 && /* @__PURE__ */ D("p", {
750
+ i?.length === 0 && /* @__PURE__ */ E("p", {
710
751
  className: "text-sm text-muted-foreground",
711
752
  children: r.runnersEmpty
712
753
  }),
713
- i?.map((e) => /* @__PURE__ */ O("div", {
754
+ i?.map((e) => /* @__PURE__ */ D("div", {
714
755
  className: "flex flex-col gap-2 rounded-md border border-border p-3",
715
- children: [/* @__PURE__ */ O("div", {
756
+ children: [/* @__PURE__ */ D("div", {
716
757
  className: "flex flex-wrap items-center gap-2",
717
758
  children: [
718
- /* @__PURE__ */ D("span", {
759
+ /* @__PURE__ */ E("span", {
719
760
  className: "font-medium",
720
761
  children: e.name
721
762
  }),
722
- /* @__PURE__ */ D("span", {
763
+ /* @__PURE__ */ E("span", {
723
764
  className: "text-xs text-muted-foreground",
724
765
  children: e.url
725
766
  }),
726
- e.status === null && /* @__PURE__ */ D(p, {
767
+ e.status === null && /* @__PURE__ */ E(p, {
727
768
  variant: "danger",
728
769
  children: r.runnersUnreachable
729
770
  }),
730
- e.status && /* @__PURE__ */ D(p, {
771
+ e.status && /* @__PURE__ */ E(p, {
731
772
  variant: "secondary",
732
773
  children: N(r.runnersVersion, { version: e.status.version })
733
774
  }),
734
- e.status && /* @__PURE__ */ D(p, {
775
+ e.status && /* @__PURE__ */ E(p, {
735
776
  variant: "info",
736
777
  children: N(r.runnersLoad, {
737
778
  chats: e.status.load.chats,
738
779
  max: e.status.load.maxChats
739
780
  })
740
781
  }),
741
- e.status && /* @__PURE__ */ D(p, {
782
+ e.status && /* @__PURE__ */ E(p, {
742
783
  variant: "light",
743
784
  children: N(r.runnersTenants, { count: e.status.tenants.length })
744
785
  }),
745
- /* @__PURE__ */ D("div", {
786
+ /* @__PURE__ */ E("div", {
746
787
  className: "ml-auto",
747
- children: /* @__PURE__ */ D(d, {
788
+ children: /* @__PURE__ */ E(d, {
748
789
  icon: "trash",
749
790
  label: r.runnersRemove,
750
791
  variant: "outline-danger",
@@ -752,7 +793,7 @@ function V({ fleet: e, locale: t, texts: n }) {
752
793
  })
753
794
  })
754
795
  ]
755
- }), /* @__PURE__ */ D(_, {
796
+ }), /* @__PURE__ */ E(_, {
756
797
  appearance: "empty",
757
798
  showNotice: !1,
758
799
  onSubmit: () => !1,
@@ -760,18 +801,18 @@ function V({ fleet: e, locale: t, texts: n }) {
760
801
  isDefault: e.isDefault ? "true" : "",
761
802
  draining: e.draining ? "true" : ""
762
803
  },
763
- children: /* @__PURE__ */ O("div", {
804
+ children: /* @__PURE__ */ D("div", {
764
805
  className: "flex flex-wrap gap-4",
765
- children: [/* @__PURE__ */ D(w, {
806
+ children: [/* @__PURE__ */ E(w, {
766
807
  name: "isDefault",
767
808
  label: r.runnersDefault,
768
809
  valueChecked: "true",
769
- onChange: ({ value: t }) => void E(e.id, { isDefault: !!t })
770
- }), /* @__PURE__ */ D(w, {
810
+ onChange: ({ value: t }) => void O(e.id, { isDefault: !!t })
811
+ }), /* @__PURE__ */ E(w, {
771
812
  name: "draining",
772
813
  label: r.runnersDraining,
773
814
  valueChecked: "true",
774
- onChange: ({ value: t }) => void E(e.id, { draining: !!t })
815
+ onChange: ({ value: t }) => void O(e.id, { draining: !!t })
775
816
  })]
776
817
  })
777
818
  })]
@@ -779,26 +820,26 @@ function V({ fleet: e, locale: t, texts: n }) {
779
820
  ]
780
821
  })
781
822
  }),
782
- e.tenants && i && i.length > 0 && /* @__PURE__ */ D(m, {
823
+ e.tenants && i && i.length > 0 && /* @__PURE__ */ E(m, {
783
824
  title: r.distributionTitle,
784
825
  loading: o === null,
785
826
  loaderMinHeight: 80,
786
- children: /* @__PURE__ */ O("div", {
827
+ children: /* @__PURE__ */ D("div", {
787
828
  className: "flex flex-col gap-2",
788
- children: [/* @__PURE__ */ D("p", {
829
+ children: [/* @__PURE__ */ E("p", {
789
830
  className: "text-sm text-muted-foreground",
790
831
  children: r.distributionIntro
791
- }), /* @__PURE__ */ D(_, {
832
+ }), /* @__PURE__ */ E(_, {
792
833
  appearance: "empty",
793
834
  showNotice: !1,
794
835
  onSubmit: () => !1,
795
836
  defaultValues: Object.fromEntries((o ?? []).map((e) => [`runner_${e.id}`, e.runnerId ?? ""])),
796
- children: (o ?? []).map((t) => /* @__PURE__ */ O("div", {
837
+ children: (o ?? []).map((t) => /* @__PURE__ */ D("div", {
797
838
  className: "flex flex-wrap items-center gap-2",
798
- children: [/* @__PURE__ */ D("span", {
839
+ children: [/* @__PURE__ */ E("span", {
799
840
  className: "min-w-40 flex-1 text-sm",
800
841
  children: t.name
801
- }), /* @__PURE__ */ D(S, {
842
+ }), /* @__PURE__ */ E(S, {
802
843
  name: `runner_${t.id}`,
803
844
  title: r.distributionRunner,
804
845
  placeholderOption: {
@@ -817,7 +858,7 @@ function V({ fleet: e, locale: t, texts: n }) {
817
858
  })]
818
859
  })
819
860
  }),
820
- h && /* @__PURE__ */ D(H, {
861
+ h && /* @__PURE__ */ E(W, {
821
862
  fleet: e,
822
863
  t: r,
823
864
  locale: t,
@@ -826,7 +867,7 @@ function V({ fleet: e, locale: t, texts: n }) {
826
867
  g(!1), await T();
827
868
  }
828
869
  }),
829
- v && /* @__PURE__ */ D(b, {
870
+ v && /* @__PURE__ */ E(b, {
830
871
  title: r.runnersRemove,
831
872
  danger: !0,
832
873
  onClose: () => y(null),
@@ -836,93 +877,103 @@ function V({ fleet: e, locale: t, texts: n }) {
836
877
  ]
837
878
  });
838
879
  }
839
- function H({ fleet: e, t, locale: n, onClose: r, onAdded: i }) {
840
- let [a, o] = u("choose"), [s, c] = u(""), [l, p] = u(null), m = (e) => p(N(t.error, { error: e.message })), h = /* @__PURE__ */ D(_, {
841
- appearance: "empty",
842
- showNotice: !1,
843
- onSubmit: () => !1,
844
- children: /* @__PURE__ */ D(C, {
845
- name: "name",
846
- label: t.addName,
847
- placeholder: t.addNamePlaceholder,
848
- onChange: ({ value: e }) => c(String(e ?? ""))
849
- })
850
- });
851
- return /* @__PURE__ */ D(y, {
880
+ function H({ target: e, children: t }) {
881
+ return e ? O(t, e) : null;
882
+ }
883
+ var U = (e) => {
884
+ try {
885
+ return new URL(e).hostname;
886
+ } catch {
887
+ return e;
888
+ }
889
+ };
890
+ function W({ fleet: e, t, locale: n, onClose: r, onAdded: i }) {
891
+ let [a, o] = u("choose"), [c, l] = u(null), [p, m] = u(null), h = s((e) => l(N(t.error, { error: e.message })), [t]);
892
+ return /* @__PURE__ */ E(y, {
852
893
  title: t.addTitle,
853
894
  size: "lg",
854
895
  onClose: r,
855
- footer: !1,
856
- children: /* @__PURE__ */ O("div", {
896
+ footer: a === "choose" || a === "guided" ? !1 : /* @__PURE__ */ E("div", {
897
+ ref: m,
898
+ className: "flex w-full flex-wrap items-center justify-end gap-3"
899
+ }),
900
+ children: /* @__PURE__ */ D("div", {
857
901
  className: "flex flex-col gap-4",
858
902
  children: [
859
- l && /* @__PURE__ */ D(f, {
903
+ c && /* @__PURE__ */ E(f, {
860
904
  variant: "danger",
861
- children: l
905
+ children: c
862
906
  }),
863
- a === "choose" && /* @__PURE__ */ O("div", {
907
+ a === "choose" && /* @__PURE__ */ D("div", {
864
908
  className: "grid gap-3 sm:grid-cols-3",
865
909
  children: [
866
- e.install && /* @__PURE__ */ D(U, {
910
+ e.install && /* @__PURE__ */ E(G, {
867
911
  title: t.addAutomatic,
868
912
  hint: t.addAutomaticHint,
869
913
  onClick: () => o("automatic")
870
914
  }),
871
- /* @__PURE__ */ D(U, {
915
+ /* @__PURE__ */ E(G, {
872
916
  title: t.addGuided,
873
917
  hint: t.addGuidedHint,
874
918
  onClick: () => o("guided")
875
919
  }),
876
- /* @__PURE__ */ D(U, {
920
+ /* @__PURE__ */ E(G, {
877
921
  title: t.addExisting,
878
922
  hint: t.addExistingHint,
879
923
  onClick: () => o("existing")
880
924
  })
881
925
  ]
882
926
  }),
883
- a !== "choose" && /* @__PURE__ */ D("div", { children: /* @__PURE__ */ D(d, {
927
+ a !== "choose" && /* @__PURE__ */ E("div", { children: /* @__PURE__ */ E(d, {
884
928
  icon: "arrow-left",
885
929
  label: t.addBack,
886
930
  variant: "link",
887
931
  onClick: () => {
888
- o("choose"), p(null);
932
+ o("choose"), l(null);
889
933
  }
890
934
  }) }),
891
- a === "automatic" && e.install && /* @__PURE__ */ O(E, { children: [h, /* @__PURE__ */ D(K, {
935
+ a === "automatic" && e.install && /* @__PURE__ */ E(ee, {
892
936
  t,
937
+ footer: p,
893
938
  localKeys: !!e.localKeys,
894
939
  install: (t, n, r) => e.install({
895
- name: s.trim() || t,
940
+ name: t,
896
941
  domain: t,
897
942
  access: n
898
943
  }, r),
899
944
  onDone: i,
900
- onError: m
901
- })] }),
902
- a === "guided" && /* @__PURE__ */ O(E, { children: [h, /* @__PURE__ */ D(B, {
945
+ onError: h
946
+ }),
947
+ a === "guided" && /* @__PURE__ */ E(B, {
903
948
  locale: n,
904
949
  texts: t,
905
950
  onPair: async ({ url: t, code: n }) => {
906
951
  await i(await e.add({
907
- name: s.trim() || new URL(t).hostname,
952
+ name: U(t),
908
953
  url: t,
909
954
  code: n
910
955
  }));
911
956
  }
912
- })] }),
913
- a === "existing" && /* @__PURE__ */ D(W, {
957
+ }),
958
+ a === "existing" && /* @__PURE__ */ E(Y, {
914
959
  t,
915
- name: s,
916
- nameField: h,
960
+ footer: p,
961
+ pairing: e.startPairing && e.pairingStatus ? {
962
+ start: e.startPairing.bind(e),
963
+ status: e.pairingStatus.bind(e)
964
+ } : void 0,
965
+ onAdded: i,
966
+ onError: h,
967
+ onClearError: () => l(null),
917
968
  onConnect: async (t, n) => {
918
969
  try {
919
970
  await i(await e.add({
920
- name: s.trim() || new URL(t).hostname,
971
+ name: U(t),
921
972
  url: t,
922
973
  code: n
923
974
  }));
924
975
  } catch (e) {
925
- m(e);
976
+ h(e);
926
977
  }
927
978
  }
928
979
  })
@@ -930,53 +981,143 @@ function H({ fleet: e, t, locale: n, onClose: r, onAdded: i }) {
930
981
  })
931
982
  });
932
983
  }
933
- function U({ title: e, hint: t, onClick: n }) {
934
- return /* @__PURE__ */ O("button", {
984
+ function G({ title: e, hint: t, onClick: n }) {
985
+ return /* @__PURE__ */ D("button", {
935
986
  type: "button",
936
987
  onClick: n,
937
988
  className: "rounded-lg border border-border p-4 text-left transition-colors hover:border-primary hover:bg-muted focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
938
- children: [/* @__PURE__ */ D("span", {
989
+ children: [/* @__PURE__ */ E("span", {
939
990
  className: "block font-medium",
940
991
  children: e
941
- }), /* @__PURE__ */ D("span", {
992
+ }), /* @__PURE__ */ E("span", {
942
993
  className: "mt-1 block text-sm text-muted-foreground",
943
994
  children: t
944
995
  })]
945
996
  });
946
997
  }
947
- function W({ t: e, nameField: t, onConnect: n }) {
948
- let [r, i] = u(""), [a, o] = u(""), s = /^https?:\/\//.test(r.trim()) ? r.trim() : `https://${r.trim()}`;
949
- return /* @__PURE__ */ O("div", {
998
+ var K = (e) => (/^https?:\/\//.test(e.trim()) ? e.trim() : `https://${e.trim()}`).replace(/\/+$/, ""), q = (e) => new Date(e).toLocaleTimeString(void 0, {
999
+ hour: "2-digit",
1000
+ minute: "2-digit"
1001
+ }), J = 5;
1002
+ function Y({ t: e, footer: t, pairing: n, onAdded: r, onError: i, onClearError: a, onConnect: o }) {
1003
+ let [s, l] = u(""), [p, m] = u(""), [h, g] = u(!n), [y, b] = u(null), [x, S] = u(null);
1004
+ return c(() => {
1005
+ if (!y || !n) return;
1006
+ let e = !1, t = 0, a, o = async () => {
1007
+ try {
1008
+ let i = await n.status(y.id);
1009
+ if (t = 0, e) return;
1010
+ if (i.status === "approved") {
1011
+ await r(i.runner);
1012
+ return;
1013
+ }
1014
+ if (i.status !== "pending") {
1015
+ S(i.status), b(null);
1016
+ return;
1017
+ }
1018
+ } catch (n) {
1019
+ t += 1, !e && t >= J && i(n);
1020
+ }
1021
+ e || (a = setTimeout(() => void o(), 2e3));
1022
+ };
1023
+ return a = setTimeout(() => void o(), 2e3), () => {
1024
+ e = !0, clearTimeout(a);
1025
+ };
1026
+ }, [
1027
+ y,
1028
+ n,
1029
+ r,
1030
+ i
1031
+ ]), y ? /* @__PURE__ */ D("div", {
1032
+ className: "flex flex-col gap-3",
1033
+ children: [
1034
+ /* @__PURE__ */ E("h4", {
1035
+ className: "font-semibold",
1036
+ children: e.pairWaitingTitle
1037
+ }),
1038
+ /* @__PURE__ */ E("p", {
1039
+ className: "text-sm text-muted-foreground",
1040
+ children: e.pairWaitingHint
1041
+ }),
1042
+ /* @__PURE__ */ E("div", {
1043
+ className: "rounded-lg border border-border p-4 text-center font-mono text-3xl font-semibold tracking-widest",
1044
+ children: y.code
1045
+ }),
1046
+ /* @__PURE__ */ E("p", {
1047
+ className: "text-sm text-muted-foreground",
1048
+ children: N(e.pairWaiting, { at: q(y.expiresAt) })
1049
+ }),
1050
+ /* @__PURE__ */ E(H, {
1051
+ target: t,
1052
+ children: /* @__PURE__ */ E(d, {
1053
+ icon: "external-link",
1054
+ label: e.pairOpen,
1055
+ variant: "primary",
1056
+ onClick: () => window.open(y.approveUrl, "_blank", "noopener")
1057
+ })
1058
+ })
1059
+ ]
1060
+ }) : /* @__PURE__ */ D("div", {
950
1061
  className: "flex flex-col gap-3",
951
1062
  children: [
952
- t,
953
- /* @__PURE__ */ O(_, {
1063
+ x && /* @__PURE__ */ E(f, {
1064
+ variant: x === "denied" ? "danger" : "warning",
1065
+ children: x === "denied" ? e.pairDenied : e.pairExpired
1066
+ }),
1067
+ /* @__PURE__ */ D(_, {
954
1068
  appearance: "empty",
955
1069
  showNotice: !1,
956
1070
  onSubmit: () => !1,
957
- children: [/* @__PURE__ */ D(C, {
1071
+ defaultValues: {
1072
+ url: s,
1073
+ code: p
1074
+ },
1075
+ children: [/* @__PURE__ */ E(C, {
958
1076
  name: "url",
959
1077
  label: e.addUrl,
960
1078
  placeholder: "https://runner.example.com",
961
- onChange: ({ value: e }) => i(String(e ?? ""))
962
- }), /* @__PURE__ */ D(C, {
1079
+ onChange: ({ value: e }) => l(String(e ?? ""))
1080
+ }), h && /* @__PURE__ */ E(C, {
963
1081
  name: "code",
964
1082
  label: e.addCode,
965
1083
  placeholder: "ABCD-EFGH",
966
1084
  autoComplete: "off",
967
- onChange: ({ value: e }) => o(String(e ?? ""))
1085
+ onChange: ({ value: e }) => m(String(e ?? ""))
968
1086
  })]
969
1087
  }),
970
- /* @__PURE__ */ D("div", { children: /* @__PURE__ */ D(v, {
971
- label: e.addConnect,
972
- variant: "primary",
973
- disabled: !r.trim() || a.trim().length < 8,
974
- onClick: () => n(s, a.trim())
975
- }) })
1088
+ /* @__PURE__ */ D(H, {
1089
+ target: t,
1090
+ children: [n && /* @__PURE__ */ E(d, {
1091
+ label: h ? e.pairWithApproval : e.pairWithCode,
1092
+ variant: "link",
1093
+ onClick: () => g((e) => !e)
1094
+ }), h ? /* @__PURE__ */ E(v, {
1095
+ label: e.addConnect,
1096
+ variant: "primary",
1097
+ disabled: !s.trim() || p.trim().length < 8,
1098
+ onClick: () => o(K(s), p.trim())
1099
+ }) : /* @__PURE__ */ E(v, {
1100
+ label: x ? e.pairAgain : e.pairNext,
1101
+ variant: "primary",
1102
+ disabled: !s.trim(),
1103
+ onClick: async () => {
1104
+ S(null), a();
1105
+ try {
1106
+ let e = K(s);
1107
+ b(await n.start({
1108
+ name: U(e),
1109
+ url: e
1110
+ }));
1111
+ } catch (e) {
1112
+ i(e);
1113
+ }
1114
+ }
1115
+ })]
1116
+ })
976
1117
  ]
977
1118
  });
978
1119
  }
979
- var G = [
1120
+ var X = [
980
1121
  "check",
981
1122
  "docker",
982
1123
  "files",
@@ -987,60 +1128,60 @@ var G = [
987
1128
  "tls",
988
1129
  "done"
989
1130
  ];
990
- function K({ t: e, localKeys: t, install: n, onDone: r, onError: i }) {
991
- let [a, o] = u({
1131
+ function ee({ t: e, footer: t, localKeys: n, install: r, onDone: i, onError: a }) {
1132
+ let [o, s] = u({
992
1133
  host: "",
993
1134
  port: "22",
994
- username: t ? "" : "root",
995
- auth: t ? "local" : "key",
1135
+ username: n ? "" : "root",
1136
+ auth: n ? "local" : "key",
996
1137
  privateKey: "",
997
1138
  password: "",
998
1139
  domain: ""
999
- }), [s, c] = u([]), [l, d] = u(null), [f, m] = u(!1), h = (e) => ({ value: t }) => o((n) => ({
1140
+ }), [c, l] = u([]), [d, f] = u(null), [m, h] = u(!1), g = (e) => ({ value: t }) => s((n) => ({
1000
1141
  ...n,
1001
1142
  [e]: String(t ?? "")
1002
- })), g = a.host.trim() && a.domain.trim() && (a.auth === "local" || a.username.trim()) && (a.auth === "local" || (a.auth === "key" ? a.privateKey.trim() : a.password));
1003
- return /* @__PURE__ */ O("div", {
1143
+ })), y = o.host.trim() && o.domain.trim() && (o.auth === "local" || o.username.trim()) && (o.auth === "local" || (o.auth === "key" ? o.privateKey.trim() : o.password));
1144
+ return /* @__PURE__ */ D("div", {
1004
1145
  className: "flex flex-col gap-3",
1005
1146
  children: [
1006
- !f && /* @__PURE__ */ O(_, {
1147
+ !m && /* @__PURE__ */ D(_, {
1007
1148
  appearance: "empty",
1008
1149
  showNotice: !1,
1009
1150
  onSubmit: () => !1,
1010
- defaultValues: a,
1151
+ defaultValues: o,
1011
1152
  children: [
1012
- /* @__PURE__ */ D(C, {
1153
+ /* @__PURE__ */ E(C, {
1013
1154
  name: "domain",
1014
1155
  label: e.guideDomain,
1015
1156
  placeholder: "runner.example.com",
1016
- onChange: h("domain")
1157
+ onChange: g("domain")
1017
1158
  }),
1018
- /* @__PURE__ */ O("div", {
1159
+ /* @__PURE__ */ D("div", {
1019
1160
  className: "grid gap-3 sm:grid-cols-3",
1020
1161
  children: [
1021
- /* @__PURE__ */ D(C, {
1162
+ /* @__PURE__ */ E(C, {
1022
1163
  name: "host",
1023
1164
  label: e.addHost,
1024
1165
  placeholder: "203.0.113.10",
1025
- onChange: h("host")
1166
+ onChange: g("host")
1026
1167
  }),
1027
- /* @__PURE__ */ D(C, {
1168
+ /* @__PURE__ */ E(C, {
1028
1169
  name: "port",
1029
1170
  label: e.addPort,
1030
- onChange: h("port")
1171
+ onChange: g("port")
1031
1172
  }),
1032
- /* @__PURE__ */ D(C, {
1173
+ /* @__PURE__ */ E(C, {
1033
1174
  name: "username",
1034
1175
  label: e.addUser,
1035
- onChange: h("username")
1176
+ onChange: g("username")
1036
1177
  })
1037
1178
  ]
1038
1179
  }),
1039
- /* @__PURE__ */ D(S, {
1180
+ /* @__PURE__ */ E(S, {
1040
1181
  name: "auth",
1041
1182
  label: e.addAuth,
1042
1183
  options: [
1043
- ...t ? [{
1184
+ ...n ? [{
1044
1185
  label: e.addLocalKey,
1045
1186
  value: "local"
1046
1187
  }] : [],
@@ -1053,217 +1194,226 @@ function K({ t: e, localKeys: t, install: n, onDone: r, onError: i }) {
1053
1194
  value: "password"
1054
1195
  }
1055
1196
  ],
1056
- onChange: h("auth")
1197
+ onChange: g("auth")
1057
1198
  }),
1058
- a.auth === "local" && /* @__PURE__ */ D("p", {
1199
+ o.auth === "local" && /* @__PURE__ */ E("p", {
1059
1200
  className: "text-xs text-muted-foreground",
1060
1201
  children: e.addLocalKeyHint
1061
1202
  }),
1062
- a.auth === "local" ? null : a.auth === "key" ? /* @__PURE__ */ D(T, {
1203
+ o.auth === "local" ? null : o.auth === "key" ? /* @__PURE__ */ E(T, {
1063
1204
  name: "privateKey",
1064
1205
  label: e.addKey,
1065
1206
  placeholder: "-----BEGIN OPENSSH PRIVATE KEY-----",
1066
- onChange: h("privateKey")
1067
- }) : /* @__PURE__ */ D(x, {
1207
+ onChange: g("privateKey")
1208
+ }) : /* @__PURE__ */ E(x, {
1068
1209
  name: "password",
1069
1210
  label: e.addPassword,
1070
1211
  autoComplete: "off",
1071
- onChange: h("password")
1212
+ onChange: g("password")
1072
1213
  })
1073
1214
  ]
1074
1215
  }),
1075
- /* @__PURE__ */ D("p", {
1216
+ /* @__PURE__ */ E("p", {
1076
1217
  className: "text-xs text-muted-foreground",
1077
1218
  children: e.addCredentialsNote
1078
1219
  }),
1079
- f && /* @__PURE__ */ D("div", {
1220
+ m && /* @__PURE__ */ E("div", {
1080
1221
  className: "flex flex-wrap gap-1",
1081
- children: G.map((e) => /* @__PURE__ */ D(p, {
1082
- variant: l === e ? "primary" : G.indexOf(e) < G.indexOf(l ?? "check") ? "success" : "light",
1222
+ children: X.map((e) => /* @__PURE__ */ E(p, {
1223
+ variant: d === e ? "primary" : X.indexOf(e) < X.indexOf(d ?? "check") ? "success" : "light",
1083
1224
  children: e
1084
1225
  }, e))
1085
1226
  }),
1086
- s.length > 0 && /* @__PURE__ */ D("pre", {
1227
+ c.length > 0 && /* @__PURE__ */ E("pre", {
1087
1228
  className: "max-h-64 overflow-auto rounded-md bg-muted p-2 text-xs",
1088
- children: s.slice(-200).join("\n")
1229
+ children: c.slice(-200).join("\n")
1089
1230
  }),
1090
- /* @__PURE__ */ D("div", { children: /* @__PURE__ */ D(v, {
1091
- label: f ? e.addInstalling : e.addInstall,
1092
- variant: "primary",
1093
- disabled: !g || f,
1094
- onClick: async () => {
1095
- m(!0), c([]);
1096
- try {
1097
- await r(await n(a.domain.trim().toLowerCase(), {
1098
- host: a.host.trim(),
1099
- port: Number(a.port) || 22,
1100
- username: a.username.trim(),
1101
- ...a.auth === "key" ? { privateKey: a.privateKey } : a.auth === "password" ? { password: a.password } : {}
1102
- }, ({ line: e, phase: t }) => {
1103
- t && d(t), /^[A-Z_]+=/.test(e) || c((t) => [...t, e]);
1104
- }));
1105
- } catch (e) {
1106
- i(e);
1107
- } finally {
1108
- m(!1);
1231
+ /* @__PURE__ */ E(H, {
1232
+ target: t,
1233
+ children: /* @__PURE__ */ E(v, {
1234
+ label: m ? e.addInstalling : e.addInstall,
1235
+ variant: "primary",
1236
+ disabled: !y || m,
1237
+ onClick: async () => {
1238
+ h(!0), l([]);
1239
+ try {
1240
+ await i(await r(o.domain.trim().toLowerCase(), {
1241
+ host: o.host.trim(),
1242
+ port: Number(o.port) || 22,
1243
+ username: o.username.trim(),
1244
+ ...o.auth === "key" ? { privateKey: o.privateKey } : o.auth === "password" ? { password: o.password } : {}
1245
+ }, ({ line: e, phase: t }) => {
1246
+ t && f(t), /^[A-Z_]+=/.test(e) || l((t) => [...t, e]);
1247
+ }));
1248
+ } catch (e) {
1249
+ a(e);
1250
+ } finally {
1251
+ h(!1);
1252
+ }
1109
1253
  }
1110
- }
1111
- }) })
1254
+ })
1255
+ })
1112
1256
  ]
1113
1257
  });
1114
1258
  }
1115
1259
  // src/ui/RunnerConsole.tsx
1116
- var q = (e) => (e / 1024 ** 3).toFixed(1), J = (e) => new Date(e).toLocaleString(void 0, {
1260
+ var Z = (e) => (e / 1024 ** 3).toFixed(1), Q = (e) => new Date(e).toLocaleString(void 0, {
1117
1261
  dateStyle: "short",
1118
1262
  timeStyle: "short"
1119
1263
  });
1120
- function Y({ client: t, locale: n, texts: r, onSignOut: i }) {
1121
- let a = M(n, r), [o, l] = u(null), [p, y] = u(null), [b, x] = u(null), [S, w] = u({
1264
+ function te({ client: t, locale: n, texts: r, onSignOut: i, approve: a }) {
1265
+ let o = M(n, r), [l, p] = u(null), [y, b] = u(null), [x, S] = u(null), [w, T] = u({
1122
1266
  id: "",
1123
1267
  name: ""
1124
- }), [T, E] = u(null), k = s(async () => {
1268
+ }), [O, k] = u(null), A = s(async () => {
1125
1269
  try {
1126
- l(await t.platform.status()), y(null);
1270
+ p(await t.platform.status()), b(null);
1127
1271
  } catch (t) {
1128
- y(N(a.error, { error: t instanceof e ? t.code : String(t) }));
1272
+ b(N(o.error, { error: t instanceof e ? t.code : String(t) }));
1129
1273
  }
1130
- }, [t, a]);
1274
+ }, [t, o]);
1131
1275
  return c(() => {
1132
- k();
1133
- }, [k]), /* @__PURE__ */ O("div", {
1276
+ A();
1277
+ }, [A]), /* @__PURE__ */ D("div", {
1134
1278
  className: "mx-auto flex max-w-4xl flex-col gap-4 p-4",
1135
1279
  children: [
1136
- /* @__PURE__ */ O("div", {
1280
+ /* @__PURE__ */ D("div", {
1137
1281
  className: "flex items-center gap-2",
1138
- children: [/* @__PURE__ */ D("h1", {
1282
+ children: [/* @__PURE__ */ E("h1", {
1139
1283
  className: "flex-1 text-xl font-semibold",
1140
- children: a.consoleTitle
1141
- }), i && /* @__PURE__ */ D(d, {
1284
+ children: o.consoleTitle
1285
+ }), i && /* @__PURE__ */ E(d, {
1142
1286
  icon: "log-out",
1143
- label: a.consoleSignOut,
1287
+ label: o.consoleSignOut,
1144
1288
  variant: "outline-secondary",
1145
1289
  onClick: i
1146
1290
  })]
1147
1291
  }),
1148
- p && /* @__PURE__ */ D(f, {
1292
+ y && /* @__PURE__ */ E(f, {
1149
1293
  variant: "danger",
1150
- children: p
1294
+ children: y
1295
+ }),
1296
+ /* @__PURE__ */ E(re, {
1297
+ client: t,
1298
+ t: o,
1299
+ approve: a,
1300
+ onAnswered: A
1151
1301
  }),
1152
- /* @__PURE__ */ D(m, {
1153
- title: a.consoleStatus,
1154
- loading: !o && !p,
1302
+ /* @__PURE__ */ E(m, {
1303
+ title: o.consoleStatus,
1304
+ loading: !l && !y,
1155
1305
  loaderMinHeight: 100,
1156
- children: o && /* @__PURE__ */ D(g, { items: [
1306
+ children: l && /* @__PURE__ */ E(g, { items: [
1157
1307
  {
1158
1308
  label: "Version",
1159
- value: o.version
1309
+ value: l.version
1160
1310
  },
1161
1311
  {
1162
1312
  label: "URL",
1163
- value: o.url
1313
+ value: l.url
1164
1314
  },
1165
1315
  {
1166
1316
  label: "Chats",
1167
- value: `${o.load.chats} / ${o.load.maxChats}`
1317
+ value: `${l.load.chats} / ${l.load.maxChats}`
1168
1318
  },
1169
1319
  {
1170
1320
  label: "Machine",
1171
- value: N(a.consoleMachine, {
1172
- memory: q(o.machine.availableBytes),
1173
- total: q(o.machine.totalBytes),
1174
- cpus: o.machine.cpus
1321
+ value: N(o.consoleMachine, {
1322
+ memory: Z(l.machine.availableBytes),
1323
+ total: Z(l.machine.totalBytes),
1324
+ cpus: l.machine.cpus
1175
1325
  })
1176
1326
  },
1177
1327
  {
1178
1328
  label: "Agent",
1179
- value: o.agentImage
1329
+ value: l.agentImage
1180
1330
  }
1181
1331
  ] })
1182
1332
  }),
1183
- /* @__PURE__ */ D(m, {
1184
- title: a.consolePairing,
1185
- children: /* @__PURE__ */ O("div", {
1333
+ /* @__PURE__ */ E(m, {
1334
+ title: o.consolePairing,
1335
+ children: /* @__PURE__ */ D("div", {
1186
1336
  className: "flex flex-col gap-2",
1187
1337
  children: [
1188
- /* @__PURE__ */ D("p", {
1338
+ /* @__PURE__ */ E("p", {
1189
1339
  className: "text-sm text-muted-foreground",
1190
- children: a.consolePairingHint
1340
+ children: o.consolePairingHint
1191
1341
  }),
1192
- b && /* @__PURE__ */ D(h, {
1342
+ x && /* @__PURE__ */ E(h, {
1193
1343
  showCopy: !0,
1194
- children: b.code
1344
+ children: x.code
1195
1345
  }),
1196
- b && /* @__PURE__ */ D("p", {
1346
+ x && /* @__PURE__ */ E("p", {
1197
1347
  className: "text-xs text-muted-foreground",
1198
- children: N(a.consoleCode, {
1199
- code: b.code,
1200
- at: J(b.expiresAt)
1348
+ children: N(o.consoleCode, {
1349
+ code: x.code,
1350
+ at: Q(x.expiresAt)
1201
1351
  })
1202
1352
  }),
1203
- /* @__PURE__ */ D("div", { children: /* @__PURE__ */ D(v, {
1204
- label: a.consoleNewCode,
1353
+ /* @__PURE__ */ E("div", { children: /* @__PURE__ */ E(v, {
1354
+ label: o.consoleNewCode,
1205
1355
  variant: "outline-primary",
1206
- onClick: async () => x(await t.createPairing())
1356
+ onClick: async () => S(await t.createPairing())
1207
1357
  }) })
1208
1358
  ]
1209
1359
  })
1210
1360
  }),
1211
- /* @__PURE__ */ D(m, {
1212
- title: a.consoleTenants,
1213
- children: /* @__PURE__ */ O("div", {
1361
+ /* @__PURE__ */ E(m, {
1362
+ title: o.consoleTenants,
1363
+ children: /* @__PURE__ */ D("div", {
1214
1364
  className: "flex flex-col gap-3",
1215
1365
  children: [
1216
- T && /* @__PURE__ */ D(f, {
1366
+ O && /* @__PURE__ */ E(f, {
1217
1367
  variant: "warning",
1218
- onClose: () => E(null),
1219
- children: /* @__PURE__ */ D("span", {
1368
+ onClose: () => k(null),
1369
+ children: /* @__PURE__ */ E("span", {
1220
1370
  className: "break-all",
1221
- children: N(a.consoleKeyShown, { key: T })
1371
+ children: N(o.consoleKeyShown, { key: O })
1222
1372
  })
1223
1373
  }),
1224
- o?.tenants.map((e) => /* @__PURE__ */ D(X, {
1374
+ l?.tenants.map((e) => /* @__PURE__ */ E(ne, {
1225
1375
  client: t,
1226
1376
  tenant: e,
1227
- t: a,
1377
+ t: o,
1228
1378
  locale: n,
1229
- onKey: E,
1230
- onChange: k
1379
+ onKey: k,
1380
+ onChange: A
1231
1381
  }, e.id)),
1232
- /* @__PURE__ */ D(_, {
1382
+ /* @__PURE__ */ E(_, {
1233
1383
  appearance: "empty",
1234
1384
  showNotice: !1,
1235
1385
  onSubmit: () => !1,
1236
- children: /* @__PURE__ */ O("div", {
1386
+ children: /* @__PURE__ */ D("div", {
1237
1387
  className: "grid gap-2 sm:grid-cols-[1fr_1fr_auto] sm:items-end",
1238
1388
  children: [
1239
- /* @__PURE__ */ D(C, {
1389
+ /* @__PURE__ */ E(C, {
1240
1390
  name: "tenantId",
1241
- label: a.consoleTenantId,
1391
+ label: o.consoleTenantId,
1242
1392
  placeholder: "acme",
1243
- onChange: ({ value: e }) => w((t) => ({
1393
+ onChange: ({ value: e }) => T((t) => ({
1244
1394
  ...t,
1245
1395
  id: String(e ?? "")
1246
1396
  }))
1247
1397
  }),
1248
- /* @__PURE__ */ D(C, {
1398
+ /* @__PURE__ */ E(C, {
1249
1399
  name: "tenantName",
1250
- label: a.consoleTenantName,
1400
+ label: o.consoleTenantName,
1251
1401
  placeholder: "Acme",
1252
- onChange: ({ value: e }) => w((t) => ({
1402
+ onChange: ({ value: e }) => T((t) => ({
1253
1403
  ...t,
1254
1404
  name: String(e ?? "")
1255
1405
  }))
1256
1406
  }),
1257
- /* @__PURE__ */ D(v, {
1258
- label: a.consoleCreate,
1407
+ /* @__PURE__ */ E(v, {
1408
+ label: o.consoleCreate,
1259
1409
  variant: "primary",
1260
- disabled: !/^[a-z0-9][a-z0-9-]{0,62}$/.test(S.id),
1410
+ disabled: !/^[a-z0-9][a-z0-9-]{0,62}$/.test(w.id),
1261
1411
  onClick: async () => {
1262
1412
  try {
1263
- let e = await t.platform.createTenant(S.id, { name: S.name || void 0 });
1264
- e.key && E(e.key), await k();
1413
+ let e = await t.platform.createTenant(w.id, { name: w.name || void 0 });
1414
+ e.key && k(e.key), await A();
1265
1415
  } catch (t) {
1266
- y(N(a.error, { error: t instanceof e ? t.code : String(t) }));
1416
+ b(N(o.error, { error: t instanceof e ? t.code : String(t) }));
1267
1417
  }
1268
1418
  }
1269
1419
  })
@@ -1276,24 +1426,24 @@ function Y({ client: t, locale: n, texts: r, onSignOut: i }) {
1276
1426
  ]
1277
1427
  });
1278
1428
  }
1279
- function X({ client: e, tenant: t, t: n, locale: r, onKey: i, onChange: a }) {
1429
+ function ne({ client: e, tenant: t, t: n, locale: r, onKey: i, onChange: a }) {
1280
1430
  let [o, f] = u(!1), [m, h] = u(null), [g, _] = u(!1), y = l(() => e.as({ tenant: t.id }), [e, t.id]), x = s(async () => h(await e.platform.keys(t.id)), [e, t.id]);
1281
1431
  return c(() => {
1282
1432
  o && x();
1283
- }, [o, x]), /* @__PURE__ */ O("div", {
1433
+ }, [o, x]), /* @__PURE__ */ D("div", {
1284
1434
  className: "rounded-md border border-border p-3",
1285
1435
  children: [
1286
- /* @__PURE__ */ O("div", {
1436
+ /* @__PURE__ */ D("div", {
1287
1437
  className: "flex flex-wrap items-center gap-2",
1288
1438
  children: [
1289
- /* @__PURE__ */ O("button", {
1439
+ /* @__PURE__ */ D("button", {
1290
1440
  type: "button",
1291
1441
  className: "flex-1 text-left font-medium",
1292
1442
  onClick: () => f((e) => !e),
1293
1443
  children: [
1294
1444
  t.name,
1295
1445
  " ",
1296
- /* @__PURE__ */ O("span", {
1446
+ /* @__PURE__ */ D("span", {
1297
1447
  className: "text-xs text-muted-foreground",
1298
1448
  children: [
1299
1449
  "(",
@@ -1303,11 +1453,11 @@ function X({ client: e, tenant: t, t: n, locale: r, onKey: i, onChange: a }) {
1303
1453
  })
1304
1454
  ]
1305
1455
  }),
1306
- t.usersWithAccounts !== void 0 && /* @__PURE__ */ O(p, {
1456
+ t.usersWithAccounts !== void 0 && /* @__PURE__ */ D(p, {
1307
1457
  variant: "light",
1308
1458
  children: [t.usersWithAccounts, " 👤"]
1309
1459
  }),
1310
- /* @__PURE__ */ D(d, {
1460
+ /* @__PURE__ */ E(d, {
1311
1461
  icon: "trash",
1312
1462
  label: n.consoleRemoveTenant,
1313
1463
  variant: "outline-danger",
@@ -1315,25 +1465,25 @@ function X({ client: e, tenant: t, t: n, locale: r, onKey: i, onChange: a }) {
1315
1465
  })
1316
1466
  ]
1317
1467
  }),
1318
- o && /* @__PURE__ */ O("div", {
1468
+ o && /* @__PURE__ */ D("div", {
1319
1469
  className: "mt-3 flex flex-col gap-3",
1320
1470
  children: [
1321
- /* @__PURE__ */ D("h4", {
1471
+ /* @__PURE__ */ E("h4", {
1322
1472
  className: "text-sm font-semibold",
1323
1473
  children: n.consoleKeys
1324
1474
  }),
1325
- m?.map((r) => /* @__PURE__ */ O("div", {
1475
+ m?.map((r) => /* @__PURE__ */ D("div", {
1326
1476
  className: "flex flex-wrap items-center gap-2 text-sm",
1327
1477
  children: [
1328
- /* @__PURE__ */ D("span", {
1478
+ /* @__PURE__ */ E("span", {
1329
1479
  className: "flex-1",
1330
1480
  children: r.name
1331
1481
  }),
1332
- r.permissions.map((e) => /* @__PURE__ */ D(p, {
1482
+ r.permissions.map((e) => /* @__PURE__ */ E(p, {
1333
1483
  variant: "info",
1334
1484
  children: e
1335
1485
  }, e)),
1336
- /* @__PURE__ */ D(d, {
1486
+ /* @__PURE__ */ E(d, {
1337
1487
  label: n.consoleRevoke,
1338
1488
  variant: "outline-danger",
1339
1489
  onClick: async () => {
@@ -1342,7 +1492,7 @@ function X({ client: e, tenant: t, t: n, locale: r, onKey: i, onChange: a }) {
1342
1492
  })
1343
1493
  ]
1344
1494
  }, r.id)),
1345
- /* @__PURE__ */ D("div", { children: /* @__PURE__ */ D(v, {
1495
+ /* @__PURE__ */ E("div", { children: /* @__PURE__ */ E(v, {
1346
1496
  label: n.consoleNewKey,
1347
1497
  variant: "outline-secondary",
1348
1498
  onClick: async () => {
@@ -1358,11 +1508,11 @@ function X({ client: e, tenant: t, t: n, locale: r, onKey: i, onChange: a }) {
1358
1508
  })).key), await x();
1359
1509
  }
1360
1510
  }) }),
1361
- /* @__PURE__ */ D("h4", {
1511
+ /* @__PURE__ */ E("h4", {
1362
1512
  className: "text-sm font-semibold",
1363
1513
  children: n.consoleAccounts
1364
1514
  }),
1365
- /* @__PURE__ */ D(I, {
1515
+ /* @__PURE__ */ E(I, {
1366
1516
  client: y,
1367
1517
  scope: "tenant",
1368
1518
  locale: r,
@@ -1370,7 +1520,7 @@ function X({ client: e, tenant: t, t: n, locale: r, onKey: i, onChange: a }) {
1370
1520
  })
1371
1521
  ]
1372
1522
  }),
1373
- g && /* @__PURE__ */ D(b, {
1523
+ g && /* @__PURE__ */ E(b, {
1374
1524
  title: n.consoleRemoveTenant,
1375
1525
  danger: !0,
1376
1526
  onClose: () => _(!1),
@@ -1380,6 +1530,88 @@ function X({ client: e, tenant: t, t: n, locale: r, onKey: i, onChange: a }) {
1380
1530
  ]
1381
1531
  });
1382
1532
  }
1383
- export { H as AddRunner, B as InstallGuide, I as RunnerAccounts, Y as RunnerConsole, V as RunnersSettings, N as fill, j as runnerTexts, M as textsFor };
1533
+ var $ = (e) => e.toUpperCase().replace(/[^A-Z0-9]/g, "");
1534
+ function re({ client: e, t, approve: n, onAnswered: r }) {
1535
+ let [i, a] = u(null), [o, l] = u(null), d = s(async () => {
1536
+ try {
1537
+ let t = await e.pairingRequests(), r = n ? $(n) : "";
1538
+ a([...t].sort((e, t) => Number($(t.code) === r) - Number($(e.code) === r)));
1539
+ } catch {
1540
+ a([]);
1541
+ }
1542
+ }, [e, n]);
1543
+ return c(() => {
1544
+ d();
1545
+ let e = setInterval(() => void d(), 5e3);
1546
+ return () => clearInterval(e);
1547
+ }, [d]), !n && !i?.length && !o ? null : /* @__PURE__ */ E(m, {
1548
+ title: t.consoleRequests,
1549
+ loading: i === null,
1550
+ loaderMinHeight: 80,
1551
+ children: /* @__PURE__ */ D("div", {
1552
+ className: "flex flex-col gap-3",
1553
+ children: [
1554
+ /* @__PURE__ */ E("p", {
1555
+ className: "text-sm text-muted-foreground",
1556
+ children: t.consoleRequestsHint
1557
+ }),
1558
+ o && /* @__PURE__ */ E(f, {
1559
+ variant: o.variant,
1560
+ children: o.text
1561
+ }),
1562
+ i?.length === 0 && !o && /* @__PURE__ */ E("p", {
1563
+ className: "text-sm text-muted-foreground",
1564
+ children: t.consoleRequestsEmpty
1565
+ }),
1566
+ i?.map((i) => {
1567
+ let a = !!n && $(i.code) === $(n), o = async (n) => {
1568
+ let a = await e.answerPairing(i.code, n);
1569
+ l(n ? {
1570
+ variant: "success",
1571
+ text: N(t.consoleApproved, { name: a.name })
1572
+ } : {
1573
+ variant: "info",
1574
+ text: t.consoleDenied
1575
+ }), await d(), await r();
1576
+ };
1577
+ return /* @__PURE__ */ D("div", {
1578
+ className: `flex flex-col gap-2 rounded-md border p-3 ${a ? "border-primary" : "border-border"}`,
1579
+ children: [
1580
+ a && /* @__PURE__ */ E(p, {
1581
+ variant: "primary",
1582
+ children: t.consoleRequestMatch
1583
+ }),
1584
+ /* @__PURE__ */ E("div", {
1585
+ className: "font-mono text-2xl font-semibold tracking-widest",
1586
+ children: i.code
1587
+ }),
1588
+ /* @__PURE__ */ E("p", {
1589
+ className: "text-sm",
1590
+ children: N(t.consoleRequestFrom, {
1591
+ name: i.name,
1592
+ from: i.from ?? "?",
1593
+ at: Q(i.createdAt)
1594
+ })
1595
+ }),
1596
+ /* @__PURE__ */ D("div", {
1597
+ className: "flex flex-wrap gap-2",
1598
+ children: [/* @__PURE__ */ E(v, {
1599
+ label: t.consoleApprove,
1600
+ variant: "primary",
1601
+ onClick: () => o(!0)
1602
+ }), /* @__PURE__ */ E(v, {
1603
+ label: t.consoleDeny,
1604
+ variant: "outline-danger",
1605
+ onClick: () => o(!1)
1606
+ })]
1607
+ })
1608
+ ]
1609
+ }, i.code);
1610
+ })
1611
+ ]
1612
+ })
1613
+ });
1614
+ }
1615
+ export { W as AddRunner, B as InstallGuide, I as RunnerAccounts, te as RunnerConsole, V as RunnersSettings, N as fill, j as runnerTexts, M as textsFor };
1384
1616
 
1385
1617
  //# sourceMappingURL=ui.mjs.map