docker-client-mx 1.41.0 → 1.42.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.
- package/dist/docker-desktop-mx/browser/{chunk-DSQAF8Vk.js → chunk-3VyqMz_T.js} +2 -2
- package/dist/docker-desktop-mx/browser/{chunk-CMjDdCPI.js → chunk-BW20bBdg.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-Ba_z6LGV.js +1 -0
- package/dist/docker-desktop-mx/browser/chunk-BdOOWVGY.js +4 -0
- package/dist/docker-desktop-mx/browser/chunk-BgNCBUvw2.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-BGRmfw3c.js → chunk-BoN9ZlqT.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-BsAqguck2.js +3 -0
- package/dist/docker-desktop-mx/browser/{chunk-BFURpTzq.js → chunk-Bx2_SrZM.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk--cESao082.js → chunk-C-yEXU2P.js} +2 -2
- package/dist/docker-desktop-mx/browser/chunk-C1Wg9uje.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-eMZWdejE.js → chunk-C22Z7vgK.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-C6u6rXYb2.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-BX2-Fi-r.js → chunk-CC84vXik.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk-BjgRfCzM2.js → chunk-CI9I9Npi.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk-ZkkhKXw6.js → chunk-CMrtklQ1.js} +2 -2
- package/dist/docker-desktop-mx/browser/{chunk-DiZLvyn5.js → chunk-CRNeTD5E.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk-BV3brnpk.js → chunk-CSrKHPxR.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk-DIB1txLC2.js → chunk-CT1ZUgmS.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-CWusqRG0.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-B8Y30jEA.js → chunk-Cbit44lz.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-Cc4_zCxe2.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-C3aJtPX1.js → chunk-Ckq_aT3A.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk-Ckdb4U3d.js → chunk-CrBxmi_g.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-D-7d5O7f.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-CRyY-2KM.js → chunk-D0xC_xVf.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-D29s9m84.js +1 -0
- package/dist/docker-desktop-mx/browser/chunk-DKpHNjiv.js +1 -0
- package/dist/docker-desktop-mx/browser/chunk-DLeqF0uQ.js +1 -0
- package/dist/docker-desktop-mx/browser/chunk-DZjRtM2K.js +1 -0
- package/dist/docker-desktop-mx/browser/chunk-DsuW5Ksa2.js +1 -0
- package/dist/docker-desktop-mx/browser/chunk-DvoPI4MU.js +1 -0
- package/dist/docker-desktop-mx/browser/chunk-DzG5R5Kk.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-CKpDvmRb.js → chunk-KUYJNmP22.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-QaMufr3I.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-xhdtv1sC.js → chunk-V7ftX_10.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk-CxAIbp2c.js → chunk-Zcfhi-RM.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk-B_tQwhwm.js → chunk-Zom3ankA.js} +1 -1
- package/dist/docker-desktop-mx/browser/{chunk-3ILJfWKv.js → chunk-cYufOe8J.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-eG8Su12W.js +1 -0
- package/dist/docker-desktop-mx/browser/chunk-ep62jwHG.js +1 -0
- package/dist/docker-desktop-mx/browser/{chunk-DHIpfbHl.js → chunk-iwVkNYYA.js} +1 -1
- package/dist/docker-desktop-mx/browser/chunk-wa_VZZFY.js +1 -0
- package/dist/docker-desktop-mx/browser/index.html +2 -2
- package/dist/docker-desktop-mx/browser/main-DECBD64Q.js +1 -0
- package/dist/docker-desktop-mx/browser/styles-5TXFXUUF.css +1 -0
- package/dist-electron/channels.js +6 -0
- package/dist-electron/channels.js.map +1 -1
- package/dist-electron/container-commit.js +39 -0
- package/dist-electron/container-commit.js.map +1 -0
- package/dist-electron/container-rename.js +63 -0
- package/dist-electron/container-rename.js.map +1 -0
- package/dist-electron/image-reference.js +92 -0
- package/dist-electron/image-reference.js.map +1 -0
- package/dist-electron/image-tags.js +138 -0
- package/dist-electron/image-tags.js.map +1 -0
- package/dist-electron/images.js +2 -17
- package/dist-electron/images.js.map +1 -1
- package/dist-electron/ipc.js +20 -0
- package/dist-electron/ipc.js.map +1 -1
- package/dist-electron/preload.js +11 -0
- package/dist-electron/preload.js.map +1 -1
- package/dist-electron/pull.js +20 -12
- package/dist-electron/pull.js.map +1 -1
- package/dist-electron/renew.js +2 -2
- package/dist-electron/renew.js.map +1 -1
- package/package.json +1 -1
- package/dist/docker-desktop-mx/browser/chunk-6D7_x-nR.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-B4eF6Vif2.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-BSE5rhLU.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-Bz7JmGk-.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-CTthjUi7.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-Cg-fuusV.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-CkcnVcC4.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-DCF2sSJN.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-DCp2SePu.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-DEE8TVR7.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-DFixEhGx.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-DWmHPcio.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-DhuhbUD7.js +0 -3
- package/dist/docker-desktop-mx/browser/chunk-JmNJabM7.js +0 -4
- package/dist/docker-desktop-mx/browser/chunk-PR65vdNg.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-kvK2KAGk.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-v1AXLZwF.js +0 -1
- package/dist/docker-desktop-mx/browser/chunk-x5sA4n99.js +0 -1
- package/dist/docker-desktop-mx/browser/main-2LC7MYJJ.js +0 -1
- package/dist/docker-desktop-mx/browser/styles-FKMNLG2K.css +0 -1
package/dist-electron/pull.js
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.createPullTracker = createPullTracker;
|
|
4
|
+
exports.loginCommand = loginCommand;
|
|
4
5
|
exports.describePullProblem = describePullProblem;
|
|
5
6
|
exports.openPullStream = openPullStream;
|
|
7
|
+
exports.trackStream = trackStream;
|
|
6
8
|
const docker_client_1 = require("./docker-client");
|
|
7
9
|
const ndjson_1 = require("./ndjson");
|
|
8
10
|
const registry_auth_1 = require("./registry-auth");
|
|
@@ -26,9 +28,12 @@ function asNumber(value) {
|
|
|
26
28
|
* Berichten zonder `id` gaan over de pull als geheel ("Pulling from library/nginx",
|
|
27
29
|
* "Status: Downloaded newer image for …") en worden de algemene melding.
|
|
28
30
|
*/
|
|
29
|
-
function createPullTracker(reference
|
|
31
|
+
function createPullTracker(reference,
|
|
32
|
+
/** Een push (fase 69) gebruikt dezelfde regels, met een eigen begin en eigen woorden voor een fout. */
|
|
33
|
+
options = {}) {
|
|
30
34
|
const layers = new Map();
|
|
31
|
-
let message =
|
|
35
|
+
let message = options.message ??
|
|
36
|
+
(0, i18n_1.t)({ en: `Pulling ${reference}…`, nl: `Bezig met ophalen van ${reference}…`, de: `${reference} wird geholt…`, fr: `Téléchargement de ${reference}…`, es: `Descargando ${reference}…` });
|
|
32
37
|
let problem = null;
|
|
33
38
|
let done = false;
|
|
34
39
|
return {
|
|
@@ -39,7 +44,7 @@ function createPullTracker(reference) {
|
|
|
39
44
|
}
|
|
40
45
|
const error = asString(raw.error) ?? asString(raw.errorDetail?.message);
|
|
41
46
|
if (error !== null) {
|
|
42
|
-
problem = error;
|
|
47
|
+
problem = options.describe === undefined ? error : options.describe(error);
|
|
43
48
|
done = true;
|
|
44
49
|
return;
|
|
45
50
|
}
|
|
@@ -165,7 +170,13 @@ async function openPullStream(reference, onProgress, open = openViaDocker, looku
|
|
|
165
170
|
catch (err) {
|
|
166
171
|
return { ok: false, problem: describePullProblem(err, reference, auth !== null) };
|
|
167
172
|
}
|
|
168
|
-
|
|
173
|
+
return { ok: true, stream: trackStream(stream, createPullTracker(reference), onProgress) };
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* Volgt een stream van de daemon met een tracker, en stuurt hooguit eens per BATCH_MS de stand
|
|
177
|
+
* naar `onProgress`. Voor een pull en een push (fase 69): dezelfde berichten, dezelfde regels.
|
|
178
|
+
*/
|
|
179
|
+
function trackStream(stream, tracker, onProgress) {
|
|
169
180
|
let timer = null;
|
|
170
181
|
let dirty = false;
|
|
171
182
|
function flush() {
|
|
@@ -206,14 +217,11 @@ async function openPullStream(reference, onProgress, open = openViaDocker, looku
|
|
|
206
217
|
flush();
|
|
207
218
|
});
|
|
208
219
|
return {
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
}
|
|
215
|
-
stream.destroy();
|
|
216
|
-
},
|
|
220
|
+
destroy: () => {
|
|
221
|
+
if (timer !== null) {
|
|
222
|
+
clearTimeout(timer);
|
|
223
|
+
}
|
|
224
|
+
stream.destroy();
|
|
217
225
|
},
|
|
218
226
|
};
|
|
219
227
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pull.js","sourceRoot":"","sources":["../electron/pull.ts"],"names":[],"mappings":";;AA+CA,
|
|
1
|
+
{"version":3,"file":"pull.js","sourceRoot":"","sources":["../electron/pull.ts"],"names":[],"mappings":";;AA+CA,8CAgEC;AAuBD,oCAKC;AAcD,kDAgEC;AAWD,wCAiBC;AAMD,kCA6DC;AAvTD,mDAAgD;AAChD,qCAAkC;AAClC,mDAA4F;AAE5F,iCAA2B;AAE3B,0GAA0G;AAC1G,MAAM,QAAQ,GAAG,GAAG,CAAC;AAWrB,SAAS,QAAQ,CAAC,KAAc;IAE9B,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC;AAClE,CAAC;AAED,SAAS,QAAQ,CAAC,KAAc;IAE9B,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;AACzE,CAAC;AASD;;;;;;;;;;GAUG;AACH,SAAgB,iBAAiB,CAC/B,SAAiB;AACjB,uGAAuG;AACvG,UAAwF,EAAE;IAG1F,MAAM,MAAM,GAAG,IAAI,GAAG,EAAqB,CAAC;IAC5C,IAAI,OAAO,GACT,OAAO,CAAC,OAAO;QACf,IAAA,QAAC,EAAC,EAAE,EAAE,EAAE,WAAW,SAAS,GAAG,EAAE,EAAE,EAAE,yBAAyB,SAAS,GAAG,EAAE,EAAE,EAAE,GAAG,SAAS,eAAe,EAAE,EAAE,EAAE,qBAAqB,SAAS,GAAG,EAAE,EAAE,EAAE,eAAe,SAAS,GAAG,EAAE,CAAC,CAAC;IACzL,IAAI,OAAO,GAAkB,IAAI,CAAC;IAClC,IAAI,IAAI,GAAG,KAAK,CAAC;IAEjB,OAAO;QACL,KAAK,EAAE,CAAC,KAAc,EAAE,EAAE;YACxB,MAAM,GAAG,GAAG,KAA4B,CAAC;YAEzC,IAAI,GAAG,KAAK,IAAI,EAAE,CAAC;gBACjB,OAAO;YACT,CAAC;YAED,MAAM,KAAK,GAAG,QAAQ,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,GAAG,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC;YAExE,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;gBACnB,OAAO,GAAG,OAAO,CAAC,QAAQ,KAAK,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;gBAC3E,IAAI,GAAG,IAAI,CAAC;gBAEZ,OAAO;YACT,CAAC;YAED,MAAM,MAAM,GAAG,QAAQ,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;YACpC,MAAM,EAAE,GAAG,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YAE5B,IAAI,MAAM,KAAK,IAAI,EAAE,CAAC;gBACpB,OAAO;YACT,CAAC;YAED,IAAI,EAAE,KAAK,IAAI,EAAE,CAAC;gBAChB,OAAO,GAAG,MAAM,CAAC;gBAEjB,yEAAyE;gBACzE,IAAI,MAAM,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE,CAAC;oBACjC,IAAI,GAAG,IAAI,CAAC;gBACd,CAAC;gBAED,OAAO;YACT,CAAC;YAED,MAAM,QAAQ,GAAG,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YAEhC,MAAM,CAAC,GAAG,CAAC,EAAE,EAAE;gBACb,EAAE;gBACF,MAAM;gBACN,OAAO,EAAE,QAAQ,CAAC,GAAG,CAAC,cAAc,EAAE,OAAO,CAAC,IAAI,CAAC,QAAQ,EAAE,OAAO,IAAI,CAAC,CAAC;gBAC1E,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,cAAc,EAAE,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,KAAK,IAAI,CAAC,CAAC;aACrE,CAAC,CAAC;QACL,CAAC;QAED,QAAQ,EAAE,GAAG,EAAE;YACb,IAAI,GAAG,IAAI,CAAC;QACd,CAAC;QAED,QAAQ,EAAE,GAAG,EAAE,CAAC,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;KACtF,CAAC;AACJ,CAAC;AAaD,KAAK,UAAU,aAAa,CAAC,SAAiB,EAAE,IAAyB;IAEvE,MAAM,EAAE,MAAM,EAAE,GAAG,IAAA,6BAAa,GAAE,CAAC;IAEnC,qFAAqF;IACrF,6DAA6D;IAC7D,OAAO,CAAC,MAAM,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,UAAU,EAAE,IAAI,EAAE,CAAC,CAAyB,CAAC;AAC3G,CAAC;AAED,2FAA2F;AAC3F,SAAgB,YAAY,CAAC,SAAiB;IAE5C,MAAM,QAAQ,GAAG,IAAA,0BAAU,EAAC,SAAS,CAAC,CAAC;IAEvC,OAAO,QAAQ,KAAK,0BAAU,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,gBAAgB,QAAQ,EAAE,CAAC;AAC/E,CAAC;AAMD;;;;;;;GAOG;AACH,SAAgB,mBAAmB,CAAC,GAAY,EAAE,SAAiB,EAAE,aAAa,GAAG,KAAK;IAExF,MAAM,GAAG,GAAG,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAC7D,MAAM,IAAI,GAAG,GAAG,CAAC,WAAW,EAAE,CAAC;IAE/B,IAAI,IAAI,CAAC,QAAQ,CAAC,cAAc,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,EAAE,CAAC;QAC7F,OAAO,IAAA,QAAC,EAAC;YACP,EAAE,EAAE,uHAAuH,SAAS,GAAG;YACvI,EAAE,EAAE,4HAA4H,SAAS,GAAG;YAC5I,EAAE,EAAE,oIAAoI,SAAS,GAAG;YACpJ,EAAE,EAAE,yHAAyH,SAAS,GAAG;YACzI,EAAE,EAAE,2HAA2H,SAAS,GAAG;SAC5I,CAAC,CAAC;IACL,CAAC;IAED,IAAI,IAAI,CAAC,QAAQ,CAAC,kBAAkB,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,cAAc,CAAC,EAAE,CAAC;QACrG,OAAO,IAAA,QAAC,EAAC;YACP,EAAE,EAAE,IAAI,SAAS,iEAAiE;YAClF,EAAE,EAAE,IAAI,SAAS,yDAAyD;YAC1E,EAAE,EAAE,IAAI,SAAS,wDAAwD;YACzE,EAAE,EAAE,IAAI,SAAS,uEAAuE;YACxF,EAAE,EAAE,IAAI,SAAS,gEAAgE;SAClF,CAAC,CAAC;IACL,CAAC;IAED,6FAA6F;IAC7F,8DAA8D;IAC9D,IAAI,IAAI,CAAC,QAAQ,CAAC,cAAc,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,yBAAyB,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE,CAAC;QACzG,MAAM,KAAK,GAAG,YAAY,CAAC,SAAS,CAAC,CAAC;QAEtC,OAAO,aAAa;YAClB,CAAC,CAAC,IAAA,QAAC,EAAC;gBACF,EAAE,EAAE,+CAA+C,SAAS,yBAAyB,KAAK,8CAA8C;gBACxI,EAAE,EAAE,+CAA+C,SAAS,0BAA0B,KAAK,0CAA0C;gBACrI,EAAE,EAAE,2CAA2C,SAAS,4CAA4C,KAAK,qDAAqD;gBAC9J,EAAE,EAAE,+CAA+C,SAAS,6BAA6B,KAAK,4CAA4C;gBAC1I,EAAE,EAAE,mDAAmD,SAAS,mCAAmC,KAAK,6CAA6C;aACtJ,CAAC;YACF,CAAC,CAAC,IAAA,QAAC,EAAC;gBACF,EAAE,EAAE,iBAAiB,SAAS,2CAA2C,KAAK,uDAAuD;gBACrI,EAAE,EAAE,qBAAqB,SAAS,0CAA0C,KAAK,sDAAsD;gBACvI,EAAE,EAAE,qBAAqB,SAAS,iDAAiD,KAAK,6DAA6D;gBACrJ,EAAE,EAAE,kBAAkB,SAAS,mDAAmD,KAAK,mEAAmE;gBAC1J,EAAE,EAAE,iBAAiB,SAAS,gDAAgD,KAAK,+DAA+D;aACnJ,CAAC,CAAC;IACP,CAAC;IAED,IAAI,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,EAAE,CAAC;QAC3D,OAAO,IAAA,QAAC,EAAC;YACP,EAAE,EAAE,YAAY,SAAS,kDAAkD;YAC3E,EAAE,EAAE,oBAAoB,SAAS,8CAA8C;YAC/E,EAAE,EAAE,kBAAkB,SAAS,wDAAwD;YACvF,EAAE,EAAE,yBAAyB,SAAS,oDAAoD;YAC1F,EAAE,EAAE,mBAAmB,SAAS,kDAAkD;SACnF,CAAC,CAAC;IACL,CAAC;IAED,OAAO,IAAA,QAAC,EAAC;QACP,EAAE,EAAE,YAAY,SAAS,aAAa,GAAG,EAAE;QAC3C,EAAE,EAAE,gBAAgB,SAAS,eAAe,GAAG,EAAE;QACjD,EAAE,EAAE,kBAAkB,SAAS,yBAAyB,GAAG,EAAE;QAC7D,EAAE,EAAE,yBAAyB,SAAS,gBAAgB,GAAG,EAAE;QAC3D,EAAE,EAAE,mBAAmB,SAAS,iBAAiB,GAAG,EAAE;KACvD,CAAC,CAAC;AACL,CAAC;AAED;;;;;;;;GAQG;AACI,KAAK,UAAU,cAAc,CAClC,SAAiB,EACjB,UAA4C,EAC5C,OAAoB,aAAa,EACjC,SAA4B,8BAAc;IAG1C,MAAM,IAAI,GAAG,MAAM,MAAM,CAAC,SAAS,CAAC,CAAC;IACrC,IAAI,MAAiB,CAAC;IAEtB,IAAI,CAAC;QACH,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC;IACvC,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,OAAO,EAAE,mBAAmB,CAAC,GAAG,EAAE,SAAS,EAAE,IAAI,KAAK,IAAI,CAAC,EAAE,CAAC;IACpF,CAAC;IAED,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,CAAC,MAAM,EAAE,iBAAiB,CAAC,SAAS,CAAC,EAAE,UAAU,CAAC,EAAE,CAAC;AAC7F,CAAC;AAED;;;GAGG;AACH,SAAgB,WAAW,CAAC,MAAiB,EAAE,OAAoB,EAAE,UAA4C;IAE/G,IAAI,KAAK,GAA0B,IAAI,CAAC;IACxC,IAAI,KAAK,GAAG,KAAK,CAAC;IAElB,SAAS,KAAK;QAEZ,KAAK,GAAG,IAAI,CAAC;QAEb,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,OAAO;QACT,CAAC;QAED,KAAK,GAAG,KAAK,CAAC;QACd,UAAU,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC;IACjC,CAAC;IAED,SAAS,QAAQ;QAEf,KAAK,GAAG,IAAI,CAAC;QAEb,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;YACnB,KAAK,GAAG,UAAU,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;YACpC,KAAK,CAAC,KAAK,EAAE,CAAC;QAChB,CAAC;IACH,CAAC;IAED,SAAS,MAAM;QAEb,OAAO,CAAC,QAAQ,EAAE,CAAC;QACnB,KAAK,GAAG,IAAI,CAAC;QACb,KAAK,EAAE,CAAC;IACV,CAAC;IAED,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,IAAA,eAAM,EAAC,CAAC,KAAK,EAAE,EAAE;QACjC,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QACrB,QAAQ,EAAE,CAAC;IACb,CAAC,CAAC,CAAC,CAAC;IACJ,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;IACzB,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC;IAC3B,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,EAAE;QACtB,OAAO,CAAC,KAAK,CAAC,EAAE,KAAK,EAAE,IAAA,QAAC,EAAC;gBACvB,EAAE,EAAE,0CAA0C;gBAC9C,EAAE,EAAE,yCAAyC;gBAC7C,EAAE,EAAE,8CAA8C;gBAClD,EAAE,EAAE,wCAAwC;gBAC5C,EAAE,EAAE,4CAA4C;aACjD,CAAC,EAAE,CAAC,CAAC;QACN,KAAK,GAAG,IAAI,CAAC;QACb,KAAK,EAAE,CAAC;IACV,CAAC,CAAC,CAAC;IAEH,OAAO;QACL,OAAO,EAAE,GAAG,EAAE;YACZ,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;gBACnB,YAAY,CAAC,KAAK,CAAC,CAAC;YACtB,CAAC;YAED,MAAM,CAAC,OAAO,EAAE,CAAC;QACnB,CAAC;KACF,CAAC;AACJ,CAAC"}
|
package/dist-electron/renew.js
CHANGED
|
@@ -8,7 +8,7 @@ exports.listStaleContainers = listStaleContainers;
|
|
|
8
8
|
exports.renewContainers = renewContainers;
|
|
9
9
|
const compose_1 = require("./compose");
|
|
10
10
|
const docker_client_1 = require("./docker-client");
|
|
11
|
-
const
|
|
11
|
+
const image_reference_1 = require("./image-reference");
|
|
12
12
|
/**
|
|
13
13
|
* Na "Bijwerken" de containers ook vernieuwen.
|
|
14
14
|
*
|
|
@@ -34,7 +34,7 @@ function normalizeReference(reference) {
|
|
|
34
34
|
if (reference.includes('@')) {
|
|
35
35
|
return null;
|
|
36
36
|
}
|
|
37
|
-
const { repository, tag } = (0,
|
|
37
|
+
const { repository, tag } = (0, image_reference_1.splitReference)(reference);
|
|
38
38
|
const slash = repository.indexOf('/');
|
|
39
39
|
const first = slash === -1 ? '' : repository.slice(0, slash);
|
|
40
40
|
// Zoals Docker het zelf beslist: het eerste deel is een host als er een punt of poort in
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"renew.js","sourceRoot":"","sources":["../electron/renew.ts"],"names":[],"mappings":";;AA4BA,gDAgBC;AA+BD,kCAoCC;AAGD,8CAeC;AAiDD,8BASC;AAGD,kDAGC;AAQD,0CAiBC;AAzND,uCAA+F;AAC/F,mDAAgD;AAChD,
|
|
1
|
+
{"version":3,"file":"renew.js","sourceRoot":"","sources":["../electron/renew.ts"],"names":[],"mappings":"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"}
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{A as IS,An as lf,B as M,C as Gi,Ct as Tg,F as Jm,Gn as pj,I as Km,It as Ws,K as Ng,L as Kr,Nt as W,Pn as mj,Qn as sg,Tn as jc,Xn as rf,Y as OD,a as Ar,cn as f,cr as ve$1,er as sw,et as Ot,g as Dj,gr as wt,it as Pr,j as Ib,l as C,mt as S,p as Cr,rt as PS,s as Br,t as $I,tn as br,vt as Se$1,wn as jI,yr as yR,yt as T}from"./chunk-JmNJabM7.js";import{n as $n$1,o as Ne}from"./chunk-Bz7JmGk-.js";import{D as tr,E as tn$1,T as sr,_ as er,a as Je$1,b as me$1,h as ar,i as Gn$1,l as Qn$1,m as Zn$1,o as Jn$1,u as Tt,v as et,w as rr,x as nr}from"./chunk-DCF2sSJN.js";import{i as v,n as f$1,r as g,t as L$1}from"./chunk-BFURpTzq.js";function F(e,o){let t=o;for(;t;){if(t===e)return!0;t=St(t)?t.host:t.parentNode}return!1}function En(e){return e.visibility===`hidden`||e.visibility===`collapse`}function wn(e,o){return!e.isConnected||!o||En(o)?!1:typeof e.checkVisibility==`function`?e.checkVisibility():o.display!==`none`&&o.display!==`contents`}function Cn(e){let o=e.assignedSlot;if(o)return o;if(e.parentElement)return e.parentElement;let t=e.getRootNode();return St(t)?t.host:null}function He(e){for(let o of Array.from(e.children))if(L(o)===`summary`)return o;return null}function Tn(e,o){let t=He(o);return!!t&&(e===t||F(t,e))}function Lt(e){let o=e?L(e):``;return e!=null&&e.matches(bn)&&(o!==`summary`||e.parentElement!=null&&L(e.parentElement)===`details`&&He(e.parentElement)===e)&&(o!==`details`||He(e)==null)&&(o!==`input`||e.type!==`hidden`)}function Fn(e,o){let t=xn(e);return o?!!t&&t.display!==`none`:wn(e,t)}function On(e){if(!Lt(e)||!e.isConnected||e.matches(`:disabled`))return!1;for(let o=e;o;o=Cn(o)){let t=o!==e,n=L(o)===`slot`;if(o.hasAttribute(`inert`)||t&&L(o)===`details`&&!o.open&&!Tn(e,o)||o.hasAttribute(`hidden`)||!n&&!Fn(o,t))return!1}return!0}function Rn(e){let o=e.tabIndex;if(o<0){let t=L(e);if(t===`details`||t===`audio`||t===`video`||fe(e)&&e.isContentEditable)return 0}return o}function Se(e){if(L(e)!==`input`)return null;let o=e;return o.type===`radio`&&o.name!==``?o:null}function Mn(e,o){let t=Se(e);if(!t)return!0;let n=o.find(i=>{let s=Se(i);return s?.name===t.name&&s.form===t.form&&s.checked});return n?n===t:o.find(i=>{let s=Se(i);return s?.name===t.name&&s.form===t.form})===t}function Bt(e){if(fe(e)&&L(e)===`slot`){let o=e.assignedElements({flatten:!0});if(o.length>0)return o}return fe(e)&&e.shadowRoot?Array.from(e.shadowRoot.children):Array.from(e.children)}function Ht(e,o){Bt(e).forEach(t=>{Lt(t)&&o.push(t),Ht(t,o)})}function In(e,o){let t=[],n=i=>{Bt(i).forEach(s=>{fe(s)&&s.matches(o)&&t.push(s),n(s)})};return n(e),t}function An(e){let o=[];return Ht(e,o),o.filter(On)}function ge(e){let o=An(e);return o.filter(t=>Rn(t)>=0&&Mn(t,o))}function me(e){return ge(e)}function Nn(e){let o=ge(e);return[o[0],o[o.length-1]]}function jt(e,o){let t=ge(e);if(t.length===0)return;let n=rr(e.ownerDocument),i=n?t.indexOf(n):-1;return t[i===-1?o===1?0:t.length-1:i+o]}function je(e){let o=(e?.ownerDocument??document).body;return jt(o,1)??e}function Ge(e){let o=(e?.ownerDocument??document).body;return jt(o,-1)??e}function Pn(e){return e.composedPath?.()[0]??e.target}function kn(e,{select:o=!1,root:t}={}){let n=t??e[0]?.ownerDocument??document,i=rr(n);for(let s of e)if(x(s,{select:o}),rr(n)!==i)return!0}function Gt(e){return e instanceof(e?.ownerDocument?.defaultView?.HTMLElement??HTMLElement)&&e.matches(Sn)}function Ln(e){return e instanceof HTMLInputElement&&`select`in e}function x(e,{select:o=!1}={}){if(e&&e.focus){let n=rr((`ownerDocument`in e?e.ownerDocument:void 0)??document);e.focus({preventScroll:!0}),e!==n&&Ln(e)&&o&&e.select()}}function Ve(e){let o=e.createElement(`span`);return o.setAttribute(`tabindex`,`0`),o.setAttribute(ve,``),me$1.screenReader.voiceOver&&me$1.engine.webkit?o.setAttribute(`role`,`button`):o.setAttribute(`aria-hidden`,`true`),Object.assign(o.style,Bn),o}function Nt(e){for(let o of ge(e))o.setAttribute(le,o.getAttribute(`tabindex`)??``),o.setAttribute(`tabindex`,`-1`)}function pe(e){In(e,`[${le}]`).forEach(o=>{let t=o.getAttribute(le);o.removeAttribute(le),t?o.setAttribute(`tabindex`,t):o.removeAttribute(`tabindex`)})}function te(e,o){let t=e.relatedTarget;return!t||!F(o,t)}function Vt(e,o={}){let t=o.enabled??(()=>!0),n=!1;rf(i=>{let s=e();if(!s||!t())return;let r=s.ownerDocument,u=d=>{!d.relatedTarget||!te(d,s)||(d.type===`focusin`?n&&(pe(s),n=!1):(Nt(s),n=!0))};te(new FocusEvent(`focusin`,{relatedTarget:r.activeElement}),s)&&(Nt(s),n=!0),s.addEventListener(`focusin`,u,!0),s.addEventListener(`focusout`,u,!0),i(()=>{s.removeEventListener(`focusin`,u,!0),s.removeEventListener(`focusout`,u,!0),n&&(pe(s),n=!1)})})}function _t(e){return{provide:De,useFactory:e}}function Hn(e){let o=Pt.get(e);return o||(o=wt([]),Pt.set(e,o)),o}function jn(e){let o=Hn(e);return{add(t){let n=o(),i=n[0];t!==i&&i?.pause();let s=kt(n,t);s.unshift(t),o.set(s)},remove(t){let i=kt(o(),t);o.set(i),o()[0]?.resume()}}}function kt(e,o){let t=[...e],n=t.indexOf(o);return n!==-1&&t.splice(n,1),t}var bn;var L;var yn;var fe;var St;var xn;var Le;var Be;var At;var Sn;var ve;var le;var Bn;var De;var Pt;var Do;var Gn;var Vn;var V;var be=f(()=>{Kr();Kr();tn$1();bn=`a[href],button,input,select,textarea,summary,details,iframe,object,embed,[tabindex],[contenteditable]:not([contenteditable="false"]),audio[controls],video[controls]`,L=e=>e.nodeName.toLowerCase(),yn=e=>e!=null&&typeof e.nodeType==`number`,fe=e=>{if(!yn(e))return!1;let o=e.ownerDocument?.defaultView;return o?e instanceof o.HTMLElement:e instanceof HTMLElement},St=e=>e!==null&&e.nodeType===11&&`host`in e,xn=e=>{let o=e.ownerDocument.defaultView;return o?o.getComputedStyle(e):null};Le=`focusScope.autoFocusOnMount`,Be=`focusScope.autoFocusOnUnmount`,At={bubbles:!1,cancelable:!0};Sn=`input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])`;ve=`data-rdx-focus-guard`,le=`data-rdx-tabindex`,Bn={position:`fixed`,top:`0`,left:`0`,width:`1px`,height:`1px`,padding:`0`,margin:`-1px`,overflow:`hidden`,clipPath:`inset(50%)`,whiteSpace:`nowrap`,border:`0`};De=new M(`RdxFocusScopeConfig`,{factory:()=>({trapped:wt(!1)})});Pt=new WeakMap;[Do,Gn]=Gn$1(`FocusScope Context`,`utils/focus-scope`),Vn=()=>{let e=C(V);return{loop:e.loop,trapped:e.isTrapped}},V=(()=>{class e{constructor(){this.injector=C(Se$1),this.destroyRef=C(ve$1),this.elementRef=C(Pr),this.config=C(De),this.ownerDocument=this.elementRef.nativeElement.ownerDocument??document,this.loop=jc(!1,{transform:Dj}),this.trapped=jc(void 0,{transform:t=>t===void 0?void 0:Dj(t)}),this.isTrapped=Ot(()=>this.trapped()??this.config.trapped()),this.mountAutoFocus=pj(),this.unmountAutoFocus=pj(),this.lastFocusedElement=wt(null),this.focusScopesStack=jn(this.ownerDocument),this.focusScope={paused:wt(!1),pause:()=>this.focusScope.paused.set(!0),resume:()=>this.focusScope.paused.set(!1)},this.alive=!0,this.destroyRef.onDestroy(()=>{this.alive=!1}),OD(()=>{rf(t=>{let n=this.elementRef.nativeElement;if(this.isTrapped()){let i=d=>{if(this.focusScope.paused()||!n)return;let v=Pn(d);F(n,v)?this.lastFocusedElement.set(v):x(this.lastFocusedElement(),{select:!0})},s=d=>{if(this.focusScope.paused()||!n)return;let v=d.relatedTarget;v!==null&&(F(n,v)||x(this.lastFocusedElement(),{select:!0}))},r=()=>{F(n,this.lastFocusedElement())||x(n)},u=new MutationObserver(r);n&&u.observe(n,{childList:!0,subtree:!0}),this.ownerDocument.addEventListener(`focusin`,i),this.ownerDocument.addEventListener(`focusout`,s),t(()=>{this.ownerDocument.removeEventListener(`focusin`,i),this.ownerDocument.removeEventListener(`focusout`,s),u.disconnect()})}},{injector:this.injector}),rf(async t=>{let n=this.elementRef.nativeElement;if(await Promise.resolve(),!n||!this.alive)return;this.focusScopesStack.add(this.focusScope);let i=rr(this.ownerDocument),s=F(n,i),r=d=>{this.alive&&this.mountAutoFocus.emit(d)};if(!s){let d=new CustomEvent(Le,At);n.addEventListener(Le,r),n.dispatchEvent(d),d.defaultPrevented||(kn(me(n),{select:!0,root:this.ownerDocument}),rr(this.ownerDocument)===i&&x(n))}let u=d=>{this.alive&&this.unmountAutoFocus.emit(d)};n.addEventListener(Be,u),t(()=>{n.removeEventListener(Le,r);let d=new CustomEvent(Be,At);n.dispatchEvent(d),(this.ownerDocument.defaultView??globalThis).requestAnimationFrame(()=>{let O=this.config.returnFocus?.();O!==!1&&!d.defaultPrevented&&(O?x(O,{select:!0}):this.shouldPreserveMovedFocus()||x(i??this.ownerDocument.body,{select:!0})),n.removeEventListener(Be,u),this.focusScopesStack.remove(this.focusScope)})})},{injector:this.injector})})}shouldPreserveMovedFocus(){let t=rr(this.ownerDocument);return!!t&&t!==this.ownerDocument.body&&!F(this.elementRef.nativeElement,t)}handleKeyDown(t){if(!this.loop()&&!this.isTrapped()||this.focusScope.paused())return;let n=t.key===`Tab`&&!t.altKey&&!t.ctrlKey&&!t.metaKey,i=rr(this.ownerDocument);if(n&&i){let s=t.currentTarget,[r,u]=Nn(s);r&&u?!t.shiftKey&&i===u?(t.preventDefault(),this.loop()&&x(r,{select:!0})):t.shiftKey&&i===r&&(t.preventDefault(),this.loop()&&x(u,{select:!0})):i===s&&t.preventDefault()}}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxFocusScope`,``]],hostAttrs:[`tabindex`,`-1`],hostBindings:function(n,i){n&1&&Jm(`keydown`,function(r){return i.handleKeyDown(r)})},inputs:{loop:[1,`loop`],trapped:[1,`trapped`]},outputs:{mountAutoFocus:`mountAutoFocus`,unmountAutoFocus:`unmountAutoFocus`},features:[IS([Gn(Vn)])]})}}return e})()});function Yt(e){return e?e instanceof ShadowRoot?e.host:Yt(e.parentNode):null}function Kt(e,o){return o.map(t=>{if(e.contains(t))return t;let n=Yt(t);return n&&e.contains(n)?n:null}).filter(t=>t!=null)}function Ut(e){let o=new Set;return e.forEach(t=>{let n=t;for(;n&&!o.has(n);)o.add(n),n=n.parentNode}),o}function Xt(e,o,t){let n=[],i=s=>{!s||t.has(s)||Array.from(s.children).forEach(r=>{r.nodeName.toLowerCase()!==`script`&&(o.has(r)?i(r):n.push(r))})};return i(e),n}function qt(e,o={}){let{ariaHidden:t=!1,inert:n=!1,mark:i=!0}=o,s=e[0];if(!s)return()=>{};let r=s.ownerDocument.body,u=Kt(r,e),d=n?`inert`:t?`aria-hidden`:null,v=[],O=[];if(d){let E=ye[d],l=xe[d],D=Kt(r,Array.from(r.querySelectorAll(`[aria-live]`))),k=u.concat(D);Xt(r,Ut(k),new Set(k)).forEach(R=>{let S=R.getAttribute(d),b=S!==null&&S!==`false`,$=(E.get(R)??0)+1;E.set(R,$),v.push(R),$===1&&b&&l.add(R),b||R.setAttribute(d,d===`inert`?``:`true`)})}return i&&Xt(r,Ut(u),new Set(u)).forEach(l=>{let D=(ne.get(l)??0)+1;ne.set(l,D),O.push(l),D===1&&l.setAttribute(we,``)}),_e+=1,()=>{if(d){let E=ye[d],l=xe[d];v.forEach(D=>{let k=(E.get(D)??0)-1;E.set(D,k),k===0&&(l.has(D)||D.removeAttribute(d),l.delete(D))})}O.forEach(E=>{let l=(ne.get(E)??0)-1;ne.set(E,l),l===0&&E.removeAttribute(we)}),_e-=1,_e===0&&(ye.inert=new WeakMap,ye[`aria-hidden`]=new WeakMap,xe.inert=new WeakSet,xe[`aria-hidden`]=new WeakSet,ne=new WeakMap)}}function Ke(e){return e?typeof KeyboardEvent<`u`&&e instanceof KeyboardEvent?`keyboard`:`pointerType`in e&&typeof e.pointerType==`string`?e.pointerType||`mouse`:typeof MouseEvent<`u`&&e instanceof MouseEvent?e.detail===0?`keyboard`:`mouse`:``:null}function Ce(e){return typeof e==`function`?e():e}function Wt(e,o){let t=typeof e==`function`?e(o):e;return t===!1?!1:Ce(t)}function Kn(e,o){let t=typeof e==`function`?e(o):e;return typeof t==`boolean`?t:Ce(t)}function zt(e){return{provide:$t,useFactory:e}}function Ee(e){return e===void 0?void 0:Dj(e)}function Un(){return _t(()=>({trapped:wt(!1)}))}var we;var ye;var xe;var ne;var _e;var $t;var Te;var Fe=f(()=>{Ne();Kr();Kr();tn$1();be();be();we=`data-rdx-floating-inert`,ye={inert:new WeakMap,"aria-hidden":new WeakMap},xe={inert:new WeakSet,"aria-hidden":new WeakSet},ne=new WeakMap,_e=0;$t=new M(`RdxFloatingFocusManagerConfig`);Te=(()=>{class e{constructor(){this.enabled=jc(void 0,{transform:Ee}),this.modal=jc(void 0,{transform:Ee}),this.inert=jc(void 0,{transform:Ee}),this.initialFocus=jc(void 0),this.returnFocus=jc(void 0),this.restoreFocus=jc(void 0),this.previousFocusableElement=jc(void 0),this.nextFocusableElement=jc(void 0),this.beforeContentFocusGuardRef=jc(void 0),this.externalTree=jc(void 0),this.getInsideElements=jc(void 0),this.closeOnFocusOut=jc(void 0,{transform:Ee}),this.focusOut=pj(),this.config=C($t,{optional:!0}),this.effectiveEnabled=Ot(()=>this.enabled()??this.config?.enabled?.()??!0),this.effectiveModal=Ot(()=>this.modal()??this.config?.modal?.()??!1),this.effectiveInert=Ot(()=>this.inert()??this.config?.inert?.()??this.effectiveModal()),this.effectiveCloseOnFocusOut=Ot(()=>this.closeOnFocusOut()??this.config?.closeOnFocusOut?.()??!0),this.effectiveInitialFocus=Ot(()=>this.initialFocus()!==void 0?this.initialFocus():this.config?.initialFocus?.()??null),this.effectiveReturnFocus=Ot(()=>this.returnFocus()!==void 0?this.returnFocus():this.config?.returnFocus?.()??!0),this.effectiveRestoreFocus=Ot(()=>this.restoreFocus()??this.config?.restoreFocus?.()??!1),this.effectivePreviousFocusableElement=Ot(()=>this.previousFocusableElement()!==void 0?this.previousFocusableElement():this.config?.previousFocusableElement?.()),this.effectiveNextFocusableElement=Ot(()=>this.nextFocusableElement()!==void 0?this.nextFocusableElement():this.config?.nextFocusableElement?.()),this.effectiveBeforeContentFocusGuardRef=Ot(()=>this.beforeContentFocusGuardRef()??this.config?.beforeContentFocusGuardRef?.()),this.effectiveExternalTree=Ot(()=>this.externalTree()??this.config?.externalTree?.()??null),this.insideElements=Ot(()=>((this.getInsideElements()??this.config?.getInsideElements)?.()??[]).filter(n=>n!=null)),this.effectiveOpenInteractionType=Ot(()=>this.config?.openInteractionType?.()??this._interactionType()),this.effectiveCloseInteractionType=Ot(()=>this.config?.closeInteractionType?.()??this._interactionType()),this.trapped=Ot(()=>this.effectiveEnabled()&&this.effectiveModal()),this.focusScopeConfig=C(De),this.host=C(Pr).nativeElement,this.isBrowser=$n$1(C(sw)),this.rootContext=C(et,{optional:!0}),this.registration=C(Je$1,{optional:!0}),this._interactionType=wt(``),this.interactionType=this._interactionType.asReadonly(),rf(()=>this.focusScopeConfig.trapped.set(this.trapped())),this.focusScopeConfig.returnFocus=()=>this.resolveReturnFocusTarget(),this.isBrowser&&(rf(t=>{!this.effectiveEnabled()||!this.isFloatingOpen()||t(qt(this.avoidElements(),{ariaHidden:!1,mark:!0}))}),rf(t=>{!this.effectiveEnabled()||!this.isFloatingOpen()||!this.effectiveInert()||t(qt(this.avoidElements(),{inert:!0,mark:!1}))}),rf(()=>{if(!me$1.engine.webkit||this.isFloatingOpen())return;let t=this.rootContext?.floatingElement??this.host;if(!t)return;let n=rr(t.ownerDocument);Gt(n)&&F(t,n)&&n.blur()}),this.trackInteractionType(),Vt(()=>this.rootContext?.floatingElement??this.host,{enabled:()=>!!this.rootContext&&this.effectiveEnabled()&&this.isFloatingOpen()&&!this.effectiveModal()}),this.wireCloseOnFocusOut(),this.wireRestoreFocus(),this.wirePortalFocusBridge(),this.wireFocusOrchestration(),this.wireInitialFocusFallback())}trackInteractionType(){let t=this.host.ownerDocument,n=s=>{this._interactionType.set(s.pointerType||`mouse`)},i=()=>this._interactionType.set(`keyboard`);t.addEventListener(`pointerdown`,n,!0),t.addEventListener(`keydown`,i,!0),C(ve$1).onDestroy(()=>{t.removeEventListener(`pointerdown`,n,!0),t.removeEventListener(`keydown`,i,!0)})}wireFocusOrchestration(){C(V).mountAutoFocus.subscribe(n=>{let i=this.effectiveOpenInteractionType(),s=Wt(this.effectiveInitialFocus(),i)??this.defaultInitialFocus(i);if(s===!1){n.preventDefault();return}s&&(n.preventDefault(),s.focus())})}resolveReturnTarget(){return this.resolveReturnFocusTarget()}resolveReturnFocusTarget(){let t=Kn(this.effectiveReturnFocus(),this.effectiveCloseInteractionType());if(t===!1||t===void 0)return!1;if(!(t===!0||t==null))return t}defaultInitialFocus(t){if(t!==`touch`)return null;let n=this.rootContext?.floatingElement??this.host;return n.hasAttribute(`tabindex`)||n.setAttribute(`tabindex`,`-1`),n}wireInitialFocusFallback(){rf(()=>{!this.effectiveEnabled()||!this.isFloatingOpen()||this.scheduleInitialFocusFallback()})}scheduleInitialFocusFallback(t=0){(this.host.ownerDocument.defaultView??globalThis).requestAnimationFrame(()=>this.applyInitialFocusFallback(t))}applyInitialFocusFallback(t){if(!this.effectiveEnabled()||!this.isFloatingOpen())return;let n=this.rootContext?.floatingElement??this.host,i=this.host.ownerDocument.activeElement;if(i instanceof HTMLElement&&n.contains(i))return;let s=this.effectiveOpenInteractionType(),r=Wt(this.effectiveInitialFocus(),s);if(r===!1)return;let u=r??this.defaultInitialFocus(s);u&&i!==u&&u.focus({preventScroll:!0}),t<2&&this.scheduleInitialFocusFallback(t+1)}wireCloseOnFocusOut(){let t=this.host.ownerDocument,n=!1,i=()=>{n=!0},s=()=>{n=!1},r=u=>{if(!this.effectiveEnabled()||!this.effectiveCloseOnFocusOut()||this.effectiveModal()||n)return;let d=u.relatedTarget;d&&(d instanceof Element&&d.hasAttribute(ve)||this.isRelatedTargetInside(d)||this.focusOut.emit(u))};t.addEventListener(`pointerdown`,i,!0),t.addEventListener(`pointerup`,s,!0),t.addEventListener(`focusout`,r,!0),C(ve$1).onDestroy(()=>{t.removeEventListener(`pointerdown`,i,!0),t.removeEventListener(`pointerup`,s,!0),t.removeEventListener(`focusout`,r,!0)})}wireRestoreFocus(){let t=this.host.ownerDocument,n=i=>{if(!this.effectiveEnabled()||!this.effectiveRestoreFocus()||!this.isFloatingOpen())return;let s=i.target;if(!s||!this.isRelatedTargetInside(s))return;(t.defaultView??globalThis).requestAnimationFrame(()=>{if(!this.effectiveEnabled()||!this.effectiveRestoreFocus()||!this.isFloatingOpen()||t.activeElement!==t.body)return;let u=this.rootContext?.floatingElement??this.host;x(this.effectiveRestoreFocus()===`popup`?u:me(u).at(-1)??u)})};t.addEventListener(`focusout`,n,!0),C(ve$1).onDestroy(()=>t.removeEventListener(`focusout`,n,!0))}wirePortalFocusBridge(){rf(t=>{if(!this.effectiveEnabled()||!this.isFloatingOpen()){this.setBeforeContentFocusGuardRef(null);return}let n=this.host.ownerDocument,i=this.host.parentNode;if(!i)return;let s=Ve(n),r=Ve(n);s.setAttribute(`data-type`,`inside`),r.setAttribute(`data-type`,`inside`),i.insertBefore(s,this.host),i.insertBefore(r,this.host.nextSibling),this.setBeforeContentFocusGuardRef(s);let u=v=>{if(this.effectiveModal()){x(this.getTabbableContent().at(-1)??this.host);return}if(this.isFromOutsideFocusGuard(v)){pe(this.rootContext?.floatingElement??this.host),x(this.getTabbableContent()[0]??this.host);return}if(te(v,this.portalFocusContainer())){x(je(this.rootContext?.referenceElement??this.host));return}x(Ce(this.effectivePreviousFocusableElement())??this.defaultPreviousFocusable())},d=v=>{if(this.effectiveModal()){x(this.getTabbableContent()[0]??this.host);return}if(te(v,this.portalFocusContainer())){x(Ge(this.rootContext?.referenceElement??this.host));return}x(Ce(this.effectiveNextFocusableElement())??this.defaultNextFocusable())};s.addEventListener(`focus`,u),r.addEventListener(`focus`,d),t(()=>{s.removeEventListener(`focus`,u),r.removeEventListener(`focus`,d),s.remove(),r.remove(),this.setBeforeContentFocusGuardRef(null)})})}avoidElements(){return[this.host,...this.insideElements()].filter(t=>t!=null)}isFloatingOpen(){return this.rootContext?.open()??!0}isRelatedTargetInside(t){if(F(this.rootContext?.floatingElement??this.host,t)||this.rootContext&&this.contextContains(this.rootContext,t)||this.insideElements().some(s=>s===t||F(s,t)))return!0;let i=this.currentFloatingNode();if(i){for(let s of i.tree.ancestors(i))if(s.context&&this.contextContains(s.context,t))return!0;for(let s of i.tree.children(i,{onlyOpen:!0}))if(s.context&&this.contextContains(s.context,t))return!0}return!1}contextContains(t,n){return t.floatingElement&&F(t.floatingElement,n)||t.referenceElement&&F(t.referenceElement,n)?!0:t.triggers.contains(n)}currentFloatingNode(){return(this.registration?.node()??null)||(this.effectiveExternalTree()?.all.find(i=>i.context===this.rootContext)??null)}getTabbableContent(){return me(this.rootContext?.floatingElement??this.host)}portalFocusContainer(){let t=this.rootContext?.floatingElement??this.host,n=t.parentElement;return n&&n!==t.ownerDocument.body?n:t}defaultPreviousFocusable(){return Ge(this.rootContext?.referenceElement??this.host)}defaultNextFocusable(){return je(this.rootContext?.referenceElement??this.host)}setBeforeContentFocusGuardRef(t){let n=this.effectiveBeforeContentFocusGuardRef();n&&(typeof n==`function`?n(t):n.set(t))}isFromOutsideFocusGuard(t){let n=t.relatedTarget;return n instanceof Element&&n.hasAttribute(ve)&&n.getAttribute(`data-type`)===`outside`}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxFloatingFocusManager`,``]],inputs:{enabled:[1,`enabled`],modal:[1,`modal`],inert:[1,`inert`],initialFocus:[1,`initialFocus`],returnFocus:[1,`returnFocus`],restoreFocus:[1,`restoreFocus`],previousFocusableElement:[1,`previousFocusableElement`],nextFocusableElement:[1,`nextFocusableElement`],beforeContentFocusGuardRef:[1,`beforeContentFocusGuardRef`],externalTree:[1,`externalTree`],getInsideElements:[1,`getInsideElements`],closeOnFocusOut:[1,`closeOnFocusOut`]},outputs:{focusOut:`focusOut`},exportAs:[`rdxFloatingFocusManager`],features:[IS([Un()]),jI([{directive:V,inputs:[`loop`,`loop`]}])]})}}return e})()});function qn(e){e||(e=C(ve$1));let o=new T(t=>{if(e.destroyed){t.next();return}return e.onDestroy(t.next.bind(t))});return t=>t.pipe(Ib(o))}function Xe(e,o){return new Ue(e)}function qe(e){let o=yR(e);return new T(t=>{let n=o?.onDestroy(()=>t.complete()),i=e.subscribe(s=>t.next(s));return()=>{i.unsubscribe(),n?.()}})}var Ue;var Jt=f(()=>{Ws();lf();Cr();Ng();Ue=class{source;destroyed=!1;destroyRef=C(ve$1);constructor(o){this.source=o,this.destroyRef.onDestroy(()=>{this.destroyed=!0})}subscribe(o){if(this.destroyed)throw new S(953,!1);let t=this.source.pipe(qn(this.destroyRef)).subscribe({next:n=>o(n)});return{unsubscribe:()=>t.unsubscribe()}}}});function Oe(e){return e!==null&&typeof e.nodeType==`number`}function $n(e){if(!Oe(e))return!1;let o=e.ownerDocument?.defaultView;return o?e instanceof o.HTMLElement:e instanceof HTMLElement}function $e(e){if(!Oe(e))return!1;let o=e.ownerDocument?.defaultView;return o?e instanceof o.Element:e instanceof Element}function zn(e){return!(`button`in e)||e.button===0}function Qt(e){let o=e.ownerDocument;return e===o.documentElement||e===o.body}function ze(e){return e!==null&&e.nodeType===11&&`host`in e}function Jn(e){let o=e.parentNode;if(o)return o;let t=e.getRootNode();return ze(t)?t.host:null}function We(e){return e===null||e.nodeType===Node.DOCUMENT_NODE||ze(e)||$e(e)&&Qt(e)}function Qn(e){let o=e;for(;!We(o);){let t=Jn(o);if(We(t)||!$e(t))break;o=t}return o}function Zn(e,o){if(!$e(e)||Qt(e)||e.closest(`[data-rdx-internal-backdrop], [data-rdx-menu-internal-backdrop], [data-rdx-dialog-internal-backdrop]`))return!1;let t=e.getRootNode(),n=ze(t)?t:o.ownerDocument,i=Array.from(n.querySelectorAll(`[${we}]`));if(i.length===0)return!1;let s=o.floatingElement;if(s&&e.contains(s))return!1;let r=Qn(e);return i.every(u=>!r.contains(u))}function eo(e){let o=e.target;if(!$n(o)||`touches`in e||typeof e.offsetX!=`number`)return!1;let t=o.ownerDocument.defaultView;if(!t)return!1;let n=e,i=t.getComputedStyle(o),s=/auto|scroll/,r=We(o),u=r||s.test(i.overflowX),d=r||s.test(i.overflowY),v=u&&o.clientWidth>0&&o.scrollWidth>o.clientWidth,O=d&&o.clientHeight>0&&o.scrollHeight>o.clientHeight,E=i.direction===`rtl`,l=O&&(E?n.offsetX<=o.offsetWidth-o.clientWidth:n.offsetX>o.clientWidth),D=v&&n.offsetY>o.clientHeight;return l||D}function to(e,o){let t=Ye.get(e);return o===`escape-key`?t?t.escapeKey():!1:t?t.outsidePress():!0}var oe;var Wn;var Yn;var Ye;var Re;var Zt=f(()=>{Ne();Kr();tn$1();Fe();oe=()=>!0,Wn=()=>!1,Yn=()=>`sloppy`;Ye=new WeakMap;Re=class{constructor(o,t,n={}){this.context=o,this.node=t,this.branches=new Set;let i=n.enabled??oe,s=n.escapeKey??oe,r=n.escapeKeyBubbles??Wn,u=n.outsidePress??oe,d=n.outsidePressBubbles??oe,v=n.outsidePressEvent??Yn,O=n.focusOutside??oe;this.active=()=>this.context.open()&&i(),Ye.set(this.context,{escapeKey:r,outsidePress:d});let E=C(ve$1);if(E.onDestroy(()=>Ye.delete(this.context)),!$n$1(C(sw)))return;let l=this.context.ownerDocument,D=l.defaultView??globalThis,k=(c,N)=>{n.onDismiss?.(c,N)},se=!1,R=!1,S=``,b=null,$,Me,_=()=>{D.clearTimeout($),D.clearTimeout(Me)},K=()=>{let c=v();return typeof c==`string`?c:c[S===`pen`||S===``?`mouse`:S]??`sloppy`},Qe=c=>{c.key!==`Escape`||!this.active()||!s()||se||!r()&&this.hasBlockingChild(`escape-key`)||(n.onEscapeKeyDown?.(c),c.defaultPrevented||k(`escape-key`,c),r()||c.stopPropagation())},Ze=()=>{se=!0},et=()=>{D.setTimeout(()=>{se=!1},me$1.engine.webkit?5:0)},z=c=>{!this.active()||!zn(c)||this.isInside(c.target)||!u(c)||Zn(c.target,this.context)||eo(c)||!d()&&this.hasBlockingChild(`outside-press`)||(n.onPointerDownOutside?.(c),c.defaultPrevented||k(`outside-press`,c))},tt=c=>{R=this.isInside(c.target),S=c.pointerType||``},nt=()=>{R=!1},ot=c=>{K()===`sloppy`&&c.pointerType!==`touch`&&z(c)},it=c=>{if(K()===`intentional`){if(R){R=!1;return}z(c)}},st=c=>{if(S=`touch`,K()!==`sloppy`||!this.active()||this.isInside(c.target))return;let N=c.touches?.[0];N&&(_(),b={startX:N.clientX,startY:N.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},$=D.setTimeout(()=>{b&&(b.dismissOnTouchEnd=!1,b.dismissOnMouseDown=!1)},1e3))},rt=c=>{if(!b||K()!==`sloppy`||this.isInside(c.target))return;let N=c.touches?.[0];if(!N)return;let ct=N.clientX-b.startX,lt=N.clientY-b.startY,ft=Math.sqrt(ct*ct+lt*lt);ft>5&&(b.dismissOnTouchEnd=!0),ft>10&&(z(c),_(),b=null)},at=c=>{if(!(!b||K()!==`sloppy`||this.isInside(c.target))){if(b.dismissOnTouchEnd){z(c),_(),b=null;return}D.clearTimeout(Me),Me=D.setTimeout(()=>{b=null},400)}},ut=c=>{if(!(!b||K()!==`sloppy`)){if(!b.dismissOnMouseDown){b=null,_();return}z(c),_(),b=null}},dt=c=>{Promise.resolve().then(()=>Promise.resolve()).then(()=>{!this.active()||!O()||this.isInside(c.target)||(n.onFocusOutside?.(c),c.defaultPrevented||k(`focus-outside`,c))})};l.addEventListener(`keydown`,Qe,{capture:!0}),l.addEventListener(`compositionstart`,Ze,{capture:!0}),l.addEventListener(`compositionend`,et,{capture:!0}),l.addEventListener(`focusin`,dt),l.addEventListener(`pointerdown`,tt,{capture:!0}),l.addEventListener(`pointercancel`,nt,{capture:!0});let hn=D.setTimeout(()=>{l.addEventListener(`pointerdown`,ot),l.addEventListener(`click`,it),l.addEventListener(`touchstart`,st,{capture:!0,passive:!0}),l.addEventListener(`touchmove`,rt,{capture:!0,passive:!0}),l.addEventListener(`touchend`,at,{capture:!0,passive:!0}),l.addEventListener(`mousedown`,ut,{capture:!0})},0);E.onDestroy(()=>{D.clearTimeout(hn),l.removeEventListener(`keydown`,Qe,{capture:!0}),l.removeEventListener(`compositionstart`,Ze,{capture:!0}),l.removeEventListener(`compositionend`,et,{capture:!0}),l.removeEventListener(`focusin`,dt),l.removeEventListener(`pointerdown`,tt,{capture:!0}),l.removeEventListener(`pointercancel`,nt,{capture:!0}),l.removeEventListener(`pointerdown`,ot),l.removeEventListener(`click`,it),l.removeEventListener(`touchstart`,st,{capture:!0}),l.removeEventListener(`touchmove`,rt,{capture:!0}),l.removeEventListener(`touchend`,at,{capture:!0}),l.removeEventListener(`mousedown`,ut,{capture:!0}),_()})}isInside(o){if(this.contextContains(this.context,o))return!0;let t=this.node();if(t){for(let n of t.tree.children(t,{onlyOpen:!0}))if(n.context&&this.contextContains(n.context,o))return!0}if(Oe(o)){for(let n of this.branches)if(n.contains(o))return!0}return!1}contextContains(o,t){let n=o.floatingElement;return n&&Oe(t)&&n.contains(t)?!0:o.triggers.contains(t)}hasBlockingChild(o){let t=this.node();return t?t.tree.children(t,{onlyOpen:!0}).some(n=>n.context!==null&&!to(n.context,o)):!1}}});function no(e,o){return e?typeof e==`string`?o?.querySelector(e)??null:e instanceof Pr?e.nativeElement??null:e instanceof HTMLElement?e:null:null}var en;var tn=f(()=>{Ne();Kr();Kr();g();en=(()=>{class e{constructor(){this.viewContainerRef=C(Gi),this.templateRef=C(Ar),this.document=C(br,{optional:!0}),this.isBrowser=$n$1(C(sw)),this.container=jc(),this.keepMounted=jc(!1,{transform:Dj}),this.contextPresent=C(v).present,this.present=Ot(()=>this.contextPresent()||this.keepMounted()),this._computedContainer=PS(this.container),this.elementContainer=Ot(()=>no(this._computedContainer(),this.document)??this.document?.body??null),this.mountedNodes=wt([]),this.viewRef=null;let t=new f$1({present:this.present,isBrowser:this.isBrowser,injector:C(Se$1),mountView:()=>this.mountView(),destroyView:()=>this.destroyView()});rf(()=>{let n=this.elementContainer(),i=this.mountedNodes();if(!(!this.isBrowser||!n))for(let s of i)n.appendChild(s)}),C(ve$1).onDestroy(()=>t.dispose())}setContainer(t){this._computedContainer.set(t)}mountView(){this.viewRef=this.viewContainerRef.createEmbeddedView(this.templateRef);let t=this.viewRef.rootNodes;return this.mountedNodes.set(t),t.filter(n=>n instanceof HTMLElement)}destroyView(){this.viewRef?.destroy(),this.viewRef=null,this.mountedNodes.set([])}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,inputs:{container:[1,`container`],keepMounted:[1,`keepMounted`]}})}}return e})()});function sn(e){return{provide:on,useValue:W(W({},nn),e)}}function rn(e){return{contentId:e.contentId,titleId:e.titleId.asReadonly(),descriptionId:e.descriptionId.asReadonly(),isOpen:e.open,present:e.present,modal:e.effectiveModal,disablePointerDismissal:e.effectiveDisablePointerDismissal,role:e.role,transitionStatus:e.transitionStatus,trigger:e.trigger.asReadonly(),triggers:e.triggers.asReadonly(),payload:e.payload.asReadonly(),openInteractionType:e.openInteractionType.asReadonly(),closeInteractionType:e.closeInteractionType.asReadonly(),nested:e.nested,nestedDialogOpen:e.nestedDialogOpen,nestedOpenCount:e.nestedOpenCount.asReadonly(),setTitleId:o=>e.titleId.set(o),setDescriptionId:o=>e.descriptionId.set(o),registerTransitionElement:o=>e.registerTransitionElement(o),registerTrigger:(o,t,n)=>e.registerTrigger(o,t,n),setTriggerOpenInteractionType:o=>e.setTriggerOpenInteractionType(o),open:(o,t,n,i,s)=>e.show(o,t,n,i,s),close:(o,t)=>e.close(o,t),toggle:(o,t,n,i)=>e.toggle(o,t,n,i)}}var nn;var on;var ao;var uo;var B;var co;var ie;var an;var un;var dn;var lo;var fo;var cn;var ln;var fn;var pn;var Je=f(()=>{Kr();Kr();tn$1();tn$1();Fe();Fe();Jt();Zt();be();tn();g();nn={role:`dialog`,forceModal:!1,forcePointerDismissalDisabled:!1},on=new M(`RdxDialogVariant`,{factory:()=>nn});ao=e=>e===`trap-focus`?e:Dj(e),uo=()=>rn(C(ie)),[B,co]=Gn$1(`RdxDialogRootContext`,`components/dialog`),ie=(()=>{class e{constructor(){this.destroyRef=C(ve$1),this.parentRoot=C(e,{optional:!0,skipSelf:!0}),this.variant=C(on),this.hasAppliedDefaultOpen=!1,this.hasAppliedDefaultTriggerId=!1,this.registeredTriggers=new Map,this.transition=ar(n=>this.emitOpenChangeComplete(n)),this.transitionStatus=this.transition.status,this.registerTransitionElement=this.transition.registerElement,this.open=mj(!1),this.defaultOpen=jc(!1,{transform:Dj}),this.triggerId=mj(null),this.defaultTriggerId=jc(null),this.modal=jc(!0,{transform:ao}),this.disablePointerDismissal=jc(!1,{transform:Dj}),this.handle=jc(),this.onOpenChange=pj(),this.onOpenChangeComplete=pj(),this.contentId=Tt(`rdx-dialog-content-`),this.titleId=wt(void 0),this.descriptionId=wt(void 0),this.trigger=wt(void 0),this.triggers=wt([]),this.payload=wt(void 0),this.nestedOpenCount=wt(0),this.openInteractionType=wt(null),this.closeInteractionType=wt(null),this.preventUnmountOnClose=wt(!1),this.pendingTriggerOpenInteractionType=wt(null),this.present=Ot(()=>this.open()||this.preventUnmountOnClose()),this.nested=!!this.parentRoot,this.nestedDialogOpen=Ot(()=>this.nestedOpenCount()>0),this.role=this.variant.role,this.effectiveModal=Ot(()=>this.variant.forceModal?!0:this.modal()),this.effectiveDisablePointerDismissal=Ot(()=>this.disablePointerDismissal()||this.variant.forcePointerDismissalDisabled),this.floatingContext=tr({ownerDocument:C(Pr).nativeElement.ownerDocument,open:()=>this.open()}),rf(()=>this.floatingContext.setReferenceElement(this.trigger()??null)),rf(()=>{this.open()&&this.preventUnmountOnClose()&&this.preventUnmountOnClose.set(!1)});let t=this.open();rf(()=>{let n=this.defaultOpen();!this.hasAppliedDefaultOpen&&n&&(this.hasAppliedDefaultOpen=!0,this.open.set(n))}),rf(()=>{let n=this.defaultTriggerId();!this.hasAppliedDefaultTriggerId&&n!==null&&(this.hasAppliedDefaultTriggerId=!0,this.triggerId.set(n))}),rf(()=>{let n=this.triggerId();Tg(()=>this.syncTriggerId(n))}),rf(()=>{let n=this.open();n!==t&&(t=n,Tg(()=>this.transition.start(n)))}),rf(n=>{this.open()&&this.parentRoot&&n(Tg(()=>this.parentRoot.openNestedChild()))}),rf(n=>{let i=this.handle();i&&n(Tg(()=>i.registerRoot(rn(this))))})}show(t=this.trigger(),n,i,s=`none`,r){let u=t!==void 0||n!==void 0;if(this.open()){t&&this.trigger.set(t),i!==void 0&&this.triggerId.set(i),u&&this.payload.set(n);return}let d=r??new Event(`dialog.open-change`),v=this.createOpenChangeEvent(!0,s,d,t,i??this.triggerId());this.onOpenChange.emit(v.payload),!v.eventDetails.isCanceled()&&(this.openInteractionType.set(this.consumeOpenInteractionType(r)),t&&this.trigger.set(t),i!==void 0&&this.triggerId.set(i),u&&this.payload.set(n),this.preventUnmountOnClose.set(!1),this.open.set(!0),this.floatingContext.events.emit(`openchange`,{open:!0,reason:s,event:v.eventDetails.event}))}close(t=`none`,n){if(!this.open())return;let i=n??new Event(`dialog.open-change`),s=this.createOpenChangeEvent(!1,t,i,this.trigger(),this.triggerId());this.onOpenChange.emit(s.payload),!s.eventDetails.isCanceled()&&(this.pendingTriggerOpenInteractionType.set(null),this.closeInteractionType.set(Ke(n)),this.preventUnmountOnClose.set(s.shouldPreventUnmountOnClose()),this.open.set(!1),this.floatingContext.events.emit(`openchange`,{open:!1,reason:t,event:s.eventDetails.event}))}toggle(t,n,i,s=new Event(`dialog.open-change`)){if(this.open()&&this.trigger()===n){this.close(`trigger-press`,s);return}this.show(n,i,t,`trigger-press`,s)}setTriggerOpenInteractionType(t){this.pendingTriggerOpenInteractionType.set(t)}registerTrigger(t,n,i){return this.registeredTriggers.set(t,{element:n,payload:i}),this.triggers.update(s=>s.includes(n)?s:[...s,n]),this.floatingContext.triggers.add(n),(this.triggerId()===t||!this.trigger()&&this.triggerId()===null)&&(this.trigger.set(n),this.payload.set(i())),()=>{if(this.registeredTriggers.get(t)?.element===n&&this.registeredTriggers.delete(t),this.triggers.update(s=>s.filter(r=>r!==n)),this.floatingContext.triggers.delete(n),!this.destroyRef.destroyed&&this.trigger()===n){let s=this.registeredTriggers.entries().next().value;this.triggerId()!==null&&this.triggerId.set(s?.[0]??null),this.trigger.set(s?.[1].element),this.payload.set(s?.[1].payload())}}}openNestedChild(){return this.nestedOpenCount.update(t=>t+1),()=>this.nestedOpenCount.update(t=>t-1)}syncTriggerId(t){if(t===null){this.trigger.set(void 0),this.payload.set(void 0);return}let n=this.registeredTriggers.get(t);n&&n.element!==this.trigger()&&(this.trigger.set(n.element),this.payload.set(n.payload()))}createOpenChangeEvent(t,n,i,s,r){let u=Zn$1(n,i,s);return{eventDetails:u.eventDetails,shouldPreventUnmountOnClose:u.shouldPreventUnmountOnClose,payload:{open:t,triggerId:r,trigger:u.eventDetails.trigger,reason:u.eventDetails.reason,event:u.eventDetails.event,eventDetails:u.eventDetails}}}emitOpenChangeComplete(t){this.destroyRef.destroyed||this.onOpenChangeComplete.emit(t)}consumeOpenInteractionType(t){let n=this.pendingTriggerOpenInteractionType();return this.pendingTriggerOpenInteractionType.set(null),n??Ke(t)}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxDialogRoot`,``]],inputs:{open:[1,`open`],defaultOpen:[1,`defaultOpen`],triggerId:[1,`triggerId`],defaultTriggerId:[1,`defaultTriggerId`],modal:[1,`modal`],disablePointerDismissal:[1,`disablePointerDismissal`],handle:[1,`handle`]},outputs:{open:`openChange`,triggerId:`triggerIdChange`,onOpenChange:`onOpenChange`,onOpenChangeComplete:`onOpenChangeComplete`},exportAs:[`rdxDialogRoot`],features:[IS([co(uo),Jn$1(),Qn$1(()=>C(e).floatingContext)])]})}}return e})();an=(()=>{class e{constructor(){this.rootContext=B(),this.forceRender=jc(!1,{transform:Dj});let t=C(et,{optional:!0});if(t){let n=C(Pr).nativeElement;t.addFloatingElement(n),C(ve$1).onDestroy(()=>t.removeFloatingElement(n))}}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxDialogBackdrop`,``]],hostAttrs:[`role`,`presentation`],hostVars:7,hostBindings:function(n,i){n&2&&(Km(`hidden`,i.rootContext.nested&&!i.forceRender()),Br(`data-closed`,i.rootContext.isOpen()?void 0:``)(`data-ending-style`,i.rootContext.transitionStatus()===`ending`?``:void 0)(`data-open`,i.rootContext.isOpen()?``:void 0)(`data-starting-style`,i.rootContext.transitionStatus()===`starting`?``:void 0)(`data-nested`,i.rootContext.nested?``:void 0)(`data-nested-dialog-open`,i.rootContext.nestedDialogOpen()?``:void 0))},inputs:{forceRender:[1,`forceRender`]},exportAs:[`rdxDialogBackdrop`]})}}return e})(),un=(()=>{class e{constructor(){this.rootContext=B()}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[`button`,`rdxDialogClose`,``]],hostAttrs:[`type`,`button`],hostBindings:function(n,i){n&1&&Jm(`click`,function(r){return i.rootContext.close(`close-press`,r)})},exportAs:[`rdxDialogClose`]})}}return e})(),dn=(()=>{class e{constructor(){this.rootContext=B(),this.id=Tt(`rdx-dialog-description-`),this.rootContext.setDescriptionId(this.id),C(ve$1).onDestroy(()=>this.rootContext.setDescriptionId(void 0))}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxDialogDescription`,``]],hostVars:1,hostBindings:function(n,i){n&2&&Km(`id`,i.id)},exportAs:[`rdxDialogDescription`]})}}return e})(),lo=new Set([`ArrowUp`,`ArrowDown`,`ArrowLeft`,`ArrowRight`,`Home`,`End`]),fo=`data-rdx-dialog-internal-backdrop`,cn=(()=>{class e{constructor(){this.rootContext=B(),this.host=C(Pr).nativeElement,this.floatingContext=C(et),this.registration=C(Je$1,{optional:!0}),this.focusManager=C(Te),this.focusScope=C(V),this.escapeKeyDown=pj(),this.pointerDownOutside=pj(),this.focusOutside=pj(),this.interactOutside=pj(),this.openAutoFocus=Xe(qe(this.focusScope.mountAutoFocus)),this.closeAutoFocus=Xe(qe(this.focusScope.unmountAutoFocus)),this.floatingContext.setFloatingElement(this.host),sr(Ot(()=>this.rootContext.modal()===!0&&this.rootContext.isOpen()),{referenceElement:()=>this.host});let t=this.rootContext.registerTransitionElement(this.host);C(ve$1).onDestroy(t);let n=C(Se$1);OD(()=>nr(this.host,n,{marker:fo,isOpen:()=>this.rootContext.isOpen(),shouldRender:()=>this.rootContext.modal()===!0,cutout:()=>this.host.closest(`[rdxDialogViewport]`),passThrough:()=>this.host.closest(`[rdxDialogViewport]`)!==null})),new Re(this.floatingContext,()=>this.registration?.node()??null,{escapeKey:()=>!0,outsidePress:()=>this.isTopmost()&&!this.rootContext.disablePointerDismissal(),outsidePressEvent:()=>this.rootContext.modal()===!0?`intentional`:`sloppy`,focusOutside:()=>!1,onEscapeKeyDown:i=>this.escapeKeyDown.emit(i),onPointerDownOutside:i=>{this.pointerDownOutside.emit(i),this.interactOutside.emit(i)},onDismiss:(i,s)=>{this.rootContext.close(i===`escape-key`?`escape-key`:`outside-press`,s)}}),this.focusManager.focusOut.subscribe(i=>{this.focusOutside.emit(i),this.interactOutside.emit(i),i.defaultPrevented||this.rootContext.close(`focus-out`,i)})}isTopmost(){return this.rootContext.isOpen()&&!this.rootContext.nestedDialogOpen()}onKeyDown(t){lo.has(t.key)&&t.stopPropagation()}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxDialogPopup`,``]],hostVars:13,hostBindings:function(n,i){n&1&&Jm(`keydown`,function(r){return i.onKeyDown(r)}),n&2&&(Km(`id`,i.rootContext.contentId),Br(`role`,i.rootContext.role)(`aria-modal`,i.rootContext.modal()===!0?`true`:void 0)(`aria-describedby`,i.rootContext.descriptionId())(`aria-labelledby`,i.rootContext.titleId())(`data-closed`,i.rootContext.isOpen()?void 0:``)(`data-ending-style`,i.rootContext.transitionStatus()===`ending`?``:void 0)(`data-open`,i.rootContext.isOpen()?``:void 0)(`data-starting-style`,i.rootContext.transitionStatus()===`starting`?``:void 0)(`data-nested`,i.rootContext.nested?``:void 0)(`data-nested-dialog-open`,i.rootContext.nestedDialogOpen()?``:void 0),sg(`--%NS%nested-dialogs`,i.rootContext.nestedOpenCount()))},outputs:{escapeKeyDown:`escapeKeyDown`,pointerDownOutside:`pointerDownOutside`,focusOutside:`focusOutside`,interactOutside:`interactOutside`,openAutoFocus:`openAutoFocus`,closeAutoFocus:`closeAutoFocus`},exportAs:[`rdxDialogPopup`],features:[IS([zt(()=>{let t=B();return{modal:()=>t.modal()===!0||t.modal()===`trap-focus`,inert:()=>t.modal()===!0,enabled:()=>t.present(),restoreFocus:()=>`popup`,openInteractionType:()=>t.openInteractionType(),closeInteractionType:()=>t.closeInteractionType(),closeOnFocusOut:()=>!t.disablePointerDismissal()}})]),jI([er,Te])]})}}return e})(),ln=(()=>{class e{constructor(){this.container=jc()}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[`ng-template`,`rdxDialogPortal`,``]],inputs:{container:[1,`container`]},exportAs:[`rdxDialogPortal`],features:[IS([L$1(()=>({present:B().present}))]),jI([{directive:en,inputs:[`container`,`container`]}])]})}}return e})(),fn=(()=>{class e{constructor(){this.rootContext=B(),this.id=Tt(`rdx-dialog-title-`),this.rootContext.setTitleId(this.id),C(ve$1).onDestroy(()=>this.rootContext.setTitleId(void 0))}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxDialogTitle`,``]],hostVars:1,hostBindings:function(n,i){n&2&&Km(`id`,i.id)},exportAs:[`rdxDialogTitle`]})}}return e})(),pn=(()=>{class e{constructor(){this.rootContext=B()}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxDialogViewport`,``]],hostAttrs:[`role`,`presentation`],hostVars:8,hostBindings:function(n,i){n&2&&(Br(`data-closed`,i.rootContext.isOpen()?void 0:``)(`data-ending-style`,i.rootContext.transitionStatus()===`ending`?``:void 0)(`data-open`,i.rootContext.isOpen()?``:void 0)(`data-starting-style`,i.rootContext.transitionStatus()===`starting`?``:void 0)(`data-nested`,i.rootContext.nested?``:void 0)(`data-nested-dialog-open`,i.rootContext.nestedDialogOpen()?``:void 0),sg(`pointer-events`,i.rootContext.isOpen()?null:`none`))},exportAs:[`rdxDialogViewport`]})}}return e})()});var Oi;var Ri;var Mi;var Ii;var Ai;var Ni;var Pi;var ki;var ho=f(()=>{Kr();Kr();Je();Je();Oi=(()=>{class e{static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxAlertDialogBackdrop`,``]],exportAs:[`rdxAlertDialogBackdrop`],features:[jI([an])]})}}return e})(),Ri=(()=>{class e{static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[`button`,`rdxAlertDialogClose`,``]],exportAs:[`rdxAlertDialogClose`],features:[jI([un])]})}}return e})(),Mi=(()=>{class e{static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxAlertDialogDescription`,``]],exportAs:[`rdxAlertDialogDescription`],features:[jI([dn])]})}}return e})(),Ii=(()=>{class e{static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxAlertDialogPopup`,``]],exportAs:[`rdxAlertDialogPopup`],features:[jI([{directive:cn,outputs:[`escapeKeyDown`,`escapeKeyDown`,`pointerDownOutside`,`pointerDownOutside`,`focusOutside`,`focusOutside`,`interactOutside`,`interactOutside`,`openAutoFocus`,`openAutoFocus`,`closeAutoFocus`,`closeAutoFocus`]}])]})}}return e})(),Ai=(()=>{class e{static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[`ng-template`,`rdxAlertDialogPortal`,``]],exportAs:[`rdxAlertDialogPortal`],features:[jI([{directive:ln,inputs:[`container`,`container`]}])]})}}return e})(),Ni=(()=>{class e{constructor(){this.dialog=C(ie),this.open=this.dialog.open,this.triggerId=this.dialog.triggerId,this.payload=this.dialog.payload}static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxAlertDialogRoot`,``]],exportAs:[`rdxAlertDialogRoot`],features:[IS([sn({role:`alertdialog`,forceModal:!0,forcePointerDismissalDisabled:!0})]),jI([{directive:ie,inputs:[`open`,`open`,`defaultOpen`,`defaultOpen`,`triggerId`,`triggerId`,`defaultTriggerId`,`defaultTriggerId`,`handle`,`handle`],outputs:[`openChange`,`openChange`,`triggerIdChange`,`triggerIdChange`,`onOpenChange`,`onOpenChange`,`onOpenChangeComplete`,`onOpenChangeComplete`]}])]})}}return e})(),Pi=(()=>{class e{static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxAlertDialogTitle`,``]],exportAs:[`rdxAlertDialogTitle`],features:[jI([fn])]})}}return e})(),ki=(()=>{class e{static{this.ɵfac=function(n){return new(n||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxAlertDialogViewport`,``]],exportAs:[`rdxAlertDialogViewport`],features:[jI([pn])]})}}return e})()});export{pn as _,Ni as a,Ri as c,dn as d,fn as f,ln as g,ki as h,Mi as i,an as l,ie as m,Ii as n,Oi as o,ho as p,Je as r,Pi as s,Ai as t,cn as u,un as v};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{$n as sk,Bn as ok,Cn as ik,D as HE,Dn as kc,En as kE,Et as Ty,F as Jm,Fn as nS,G as Nc,Gt as _m,L as Kr,Nt as W,P as JF,Pt as Wm,Q as Oi,St as Tc,U as My,Wn as pg,Wt as _S,Z as Od,cn as f,cr as ve,et as Ot,gr as wt,gt as SS,ht as SE,jn as lk,l as C,ln as fS,lr as vg,lt as RE,mr as wc,o as BE,on as eH,or as vS,qt as ag,r as Ac,rn as dk,s as Br,sn as ec,st as Qm,w as Gm,x as G,xn as hg,z as Ld}from"./chunk-JmNJabM7.js";import"./chunk-BV3brnpk.js";import{n as u,t as f$1}from"./chunk-xhdtv1sC.js";import"./chunk-DHIpfbHl.js";import{n as y,t as w}from"./chunk-BX2-Fi-r.js";import{i as Ie$1,o as Ne$1}from"./chunk-Bz7JmGk-.js";import"./chunk-DCF2sSJN.js";import"./chunk-BFURpTzq.js";import"./chunk-6D7_x-nR.js";import{n as x,t as u$1}from"./chunk-CMjDdCPI.js";import{n as P,t as K}from"./chunk-Cg-fuusV.js";import{n as W$1,t as J}from"./chunk-CTthjUi7.js";var se;var le=f(()=>{se=[`claude-opus-5`,`claude-sonnet-5`,`claude-haiku-4-5`]});function Se(a,n){if(a&1&&(Oi(0,`span`,34),fS(1),Nc()),a&2){let e=HE(2);ec(),pg(e.t().inUse)}}function Ce(a,n){if(a&1&&(Oi(0,`span`,34),fS(1),Nc()),a&2){let e=HE(2);ec(),pg(e.t().cli)}}function ke(a,n){if(a&1&&(Oi(0,`div`,36),fS(1),Nc()),a&2){let e=HE().$implicit;ec(),pg(e.description)}}function we(a,n){if(a&1&&(Oi(0,`div`,37),fS(1),Nc()),a&2){let e=HE().$implicit;ec(),pg(e.reason)}}function Ee(a,n){a&1&&Qm(0)}function Te(a,n){if(a&1){let e=RE();Oi(0,`li`,5)(1,`div`,30)(2,`div`,31)(3,`div`,32)(4,`span`,33),fS(5),Nc(),SE(6,Se,2,1,`span`,34),SE(7,Ce,2,1,`span`,34),Nc(),Oi(8,`div`,35),fS(9),Nc(),SE(10,ke,2,1,`div`,36),SE(11,we,2,1,`div`,37),Nc(),Oi(12,`button`,38),Jm(`click`,function(){let l=Ld(e).$implicit;return Od(HE().test(l.name,{context:l.name}))}),fS(13),Nc(),Oi(14,`button`,39),Jm(`click`,function(){let l=Ld(e).$implicit;return Od(HE().askRemove(l.name))}),Gm(15,`app-icon`,40),Nc()(),_m(16,Ee,1,0,`ng-container`,28),Nc()}if(a&2){let e=n.$implicit,t=HE(),l=BE(48);Br(`data-testid`,`server-`+e.name),ec(5),pg(e.name),ec(),kE(e.active?6:-1),ec(),kE(e.currentInCli?7:-1),ec(2),pg(e.host),ec(),kE(e.description?10:-1),ec(),kE(!e.supported&&e.reason?11:-1),ec(),Wm(`disabled`,!e.supported||t.testing()!==null),ec(),Ac(` `,t.testing()===e.name?t.t().testing:t.t().test,` `),ec(),Wm(`title`,e.active||e.currentInCli?t.t().removeBlocked:t.t().remove)(`disabled`,e.active||e.currentInCli),Br(`aria-label`,t.t().remove),ec(),Wm(`size`,14),ec(),Wm(`ngTemplateOutlet`,l)(`ngTemplateOutletContext`,SS(15,de,e.name))}}function Pe(a,n){if(a&1&&(Oi(0,`li`,6),fS(1),Nc()),a&2){let e=HE();ec(),pg(e.t().empty)}}function Ie(a,n){if(a&1){let e=RE();Oi(0,`label`,15)(1,`span`,10),fS(2),Nc(),Oi(3,`input`,41),Jm(`input`,function(l){Ld(e);return Od(HE().username.set(l.target.value))}),Nc()()}if(a&2){let e=HE();ec(2),pg(e.t().add.username),ec(),nS(e.input),Wm(`placeholder`,e.t().add.usernamePlaceholder)(`value`,e.username())}}function De(a,n){if(a&1&&(Oi(0,`p`,22),fS(1),Nc()),a&2){let e=HE();ec(),pg(e.t().add.tcpWarning)}}function Me(a,n){a&1&&(Oi(0,`p`,23),fS(1),Nc()),a&2&&(ec(),pg(n))}function Ve(a,n){a&1&&Qm(0)}function Ae(a,n){if(a&1&&(Oi(0,`p`,43),fS(1),Nc()),a&2){let e=HE(),t=HE(2);ec(),pg(t.t().connected(e.version,e.os,e.arch))}}function Ne(a,n){if(a&1){let e=RE();Oi(0,`p`,45),fS(1),Nc(),Oi(2,`div`,46)(3,`code`,47),fS(4),Nc(),Oi(5,`button`,48),Jm(`click`,function(){let l=Ld(e),s=HE(3).$implicit;return Od(HE().trust(s,l.name,l.fingerprint))}),fS(6),Nc()()}if(a&2){let e=n,t=HE(4);ec(),pg(t.t().unknownHostKey(e.name,e.type)),ec(3),pg(e.fingerprint),ec(),Wm(`disabled`,t.testing()!==null),ec(),Ac(` `,t.t().trust,` `)}}function Ue(a,n){if(a&1&&(Oi(0,`p`,44),fS(1),Nc(),SE(2,Ne,7,4)),a&2){let e,t=HE();ec(),pg(t.problem),ec(),kE((e=t.unknownHostKey)?2:-1,e)}}function Oe(a,n){a&1&&(Oi(0,`div`,42),SE(1,Ae,2,1,`p`,43)(2,Ue,3,2),Nc()),a&2&&(ec(),kE(n.ok?1:2))}function Fe(a,n){if(a&1&&SE(0,Oe,3,1,`div`,42),a&2){let e,t=n.$implicit;kE((e=HE().results()[t])?0:-1,e)}}var de;var be;var F;var Le;var L;var pe=f(()=>{Ne$1();Kr();w();lk();sk();J();dk();f$1();Kr();de=a=>({$implicit:a}),be=(a,n)=>n.name;F=`:form`,Le=`mx-focus mt-1 w-full rounded-md border border-ink-700 bg-ink-800 px-3 py-1.5 text-[13px] text-ink-100 placeholder:text-ink-500`,L=class a{contexts=C(y);toast=C(u);t=Ot(()=>ok().settings.servers);form=F;input=Le;servers=Ot(()=>this.contexts.contexts().filter(n=>n.name!=="default"));name=wt(``);kind=wt(`ssh`);username=wt(``);host=wt(``);port=wt(``);description=wt(``);formProblem=wt(null);saving=wt(!1);testing=wt(null);results=wt({});confirmOpen=wt(!1);removing=wt(null);filledIn=Ot(()=>this.name().trim()!==``&&this.host().trim()!==``);constructor(){this.contexts.load()}async test(n,e){this.testing.set(n);try{let t=await window.electron.contexts.test(e);this.results.update(l=>G(W({},l),{[n]:t}))}catch(t){this.results.update(l=>G(W({},l),{[n]:{ok:!1,problem:eH(t),unknownHostKey:null}}))}finally{this.testing.set(null)}}async testForm(){let n=this.server();n!==null&&(this.formProblem.set(null),await this.test(F,{server:n}))}async trust(n,e,t){try{let s=await window.electron.contexts.trustHostKey(e,t);if(!s.ok){this.results.update(_=>G(W({},_),{[n]:{ok:!1,problem:s.problem,unknownHostKey:null}}));return}}catch(s){this.results.update(_=>G(W({},_),{[n]:{ok:!1,problem:eH(s),unknownHostKey:null}}));return}let l=n===F?this.server():null;await this.test(n,l===null?{context:n}:{server:l})}async add(n){n.preventDefault();let e=this.server();if(!(e===null||this.saving())){this.saving.set(!0);try{let t=await window.electron.contexts.create(e);if(!t.ok){this.formProblem.set(t.problem);return}this.toast.success(this.t().add.added(e.name)),this.reset(),await this.contexts.load()}catch(t){this.formProblem.set(eH(t))}finally{this.saving.set(!1)}}}askRemove(n){this.removing.set(n),this.confirmOpen.set(!0)}async remove(){let n=this.removing();if(n!==null)try{let e=await window.electron.contexts.remove(n);if(!e.ok){this.toast.error(e.problem);return}this.forgetResult(n),await this.contexts.load()}catch(e){this.toast.error(eH(e))}finally{this.removing.set(null)}}server(){let n=this.port().trim(),e=n===``?null:Number(n);if(e!==null&&(!Number.isInteger(e)||e<1||e>65535))return this.formProblem.set(ok().settings.servers.add.port+`: 1–65535`),null;let t=this.username().trim(),l=this.description().trim();return{name:this.name().trim(),description:l===``?null:l,kind:this.kind(),host:this.host().trim(),port:e,username:this.kind()===`ssh`&&t!==``?t:null}}reset(){this.name.set(``),this.username.set(``),this.host.set(``),this.port.set(``),this.description.set(``),this.formProblem.set(null),this.forgetResult(F)}forgetResult(n){this.results.update(e=>Object.fromEntries(Object.entries(e).filter(([t])=>t!==n)))}static ɵfac=function(e){return new(e||a)};static ɵcmp=wc({type:a,selectors:[[`app-servers-settings`]],decls:50,vars:50,consts:[[`outcome`,``],[`data-testid`,`servers-settings`,1,`rounded-lg`,`border`,`border-ink-700`,`bg-ink-850`,`px-4`,`py-3`],[1,`text-[13px]`,`font-medium`,`text-ink-200`],[1,`mt-1`,`text-[12px]`,`text-ink-500`],[1,`mt-3`,`divide-y`,`divide-ink-700`,`border-y`,`border-ink-700`],[1,`py-2.5`],[1,`py-2.5`,`text-[13px]`,`text-ink-400`],[`data-testid`,`server-form`,1,`mt-4`,3,`submit`],[1,`mt-2`,`grid`,`grid-cols-6`,`gap-3`],[1,`col-span-3`,`block`],[1,`text-[12px]`,`text-ink-400`],[`type`,`text`,`data-testid`,`server-name`,`autocomplete`,`off`,`spellcheck`,`false`,3,`input`,`placeholder`,`value`],[`data-testid`,`server-kind`,3,`change`],[`value`,`ssh`,3,`selected`],[`value`,`tcp`,3,`selected`],[1,`col-span-2`,`block`],[1,`block`],[`type`,`text`,`data-testid`,`server-host`,`autocomplete`,`off`,`spellcheck`,`false`,3,`input`,`placeholder`,`value`],[1,`col-span-1`,`block`],[`type`,`text`,`inputmode`,`numeric`,`data-testid`,`server-port`,`autocomplete`,`off`,3,`input`,`placeholder`,`value`],[1,`col-span-6`,`block`],[`type`,`text`,`data-testid`,`server-description`,`autocomplete`,`off`,3,`input`,`placeholder`,`value`],[1,`mt-2`,`text-[12px]`,`text-warn`],[`data-testid`,`server-form-problem`,1,`mt-2`,`text-[12px]`,`text-danger`],[1,`mt-3`,`flex`,`justify-end`,`gap-2`],[`type`,`button`,`data-testid`,`server-form-test`,1,`mx-btn`,`mx-focus`,3,`click`,`disabled`],[`type`,`submit`,`data-testid`,`server-add`,1,`mx-btn`,`mx-focus`,3,`disabled`],[`name`,`plus`,3,`size`],[4,`ngTemplateOutlet`,`ngTemplateOutletContext`],[3,`openChange`,`confirmed`,`open`,`title`,`description`],[1,`flex`,`items-center`,`gap-3`],[1,`min-w-0`,`flex-1`],[1,`flex`,`items-center`,`gap-2`],[1,`text-[13px]`,`text-ink-100`],[1,`rounded`,`bg-ink-700`,`px-1.5`,`text-[11px]`,`text-ink-200`],[1,`truncate`,`font-mono`,`text-[12px]`,`text-ink-400`],[1,`text-[12px]`,`text-ink-500`],[1,`text-[12px]`,`text-danger`],[`type`,`button`,`data-testid`,`server-test`,1,`mx-btn`,`mx-focus`,3,`click`,`disabled`],[`type`,`button`,`data-testid`,`server-remove`,1,`mx-btn`,`mx-focus`,3,`click`,`title`,`disabled`],[`name`,`trash`,3,`size`],[`type`,`text`,`data-testid`,`server-username`,`autocomplete`,`off`,`spellcheck`,`false`,3,`input`,`placeholder`,`value`],[`data-testid`,`server-test-result`,1,`mt-2`,`text-[12px]`],[1,`text-ok`],[1,`text-danger`],[1,`mt-2`,`text-ink-300`],[1,`mt-1`,`flex`,`items-center`,`gap-3`],[`data-testid`,`server-fingerprint`,1,`min-w-0`,`flex-1`,`truncate`,`font-mono`,`text-ink-100`],[`type`,`button`,`data-testid`,`server-trust`,1,`mx-btn`,`mx-focus`,3,`click`,`disabled`]],template:function(e,t){if(e&1){let l=RE();Oi(0,`div`,1)(1,`h2`,2),fS(2),Nc(),Oi(3,`p`,3),fS(4),Nc(),Oi(5,`ul`,4),kc(6,Te,17,17,`li`,5,be,!1,Pe,2,1,`li`,6),Nc(),Oi(9,`form`,7),Jm(`submit`,function(_){return t.add(_)}),Oi(10,`h3`,2),fS(11),Nc(),Oi(12,`div`,8)(13,`label`,9)(14,`span`,10),fS(15),Nc(),Oi(16,`input`,11),Jm(`input`,function(_){return t.name.set(_.target.value)}),Nc()(),Oi(17,`label`,9)(18,`span`,10),fS(19),Nc(),Oi(20,`select`,12),Jm(`change`,function(_){return t.kind.set(_.target.value)}),Oi(21,`option`,13),fS(22),Nc(),Oi(23,`option`,14),fS(24),Nc()()(),SE(25,Ie,4,5,`label`,15),Oi(26,`label`,16)(27,`span`,10),fS(28),Nc(),Oi(29,`input`,17),Jm(`input`,function(_){return t.host.set(_.target.value)}),Nc()(),Oi(30,`label`,18)(31,`span`,10),fS(32),Nc(),Oi(33,`input`,19),Jm(`input`,function(_){return t.port.set(_.target.value)}),Nc()(),Oi(34,`label`,20)(35,`span`,10),fS(36),Nc(),Oi(37,`input`,21),Jm(`input`,function(_){return t.description.set(_.target.value)}),Nc()()(),SE(38,De,2,1,`p`,22),SE(39,Me,2,1,`p`,23),Oi(40,`div`,24)(41,`button`,25),Jm(`click`,function(){return t.testForm()}),fS(42),Nc(),Oi(43,`button`,26),Gm(44,`app-icon`,27),fS(45),Nc()(),_m(46,Ve,1,0,`ng-container`,28),Nc()(),_m(47,Fe,1,1,`ng-template`,null,0,_S),Oi(49,`app-confirm-dialog`,29),vg(`openChange`,function(_){return Ld(l),vS(t.confirmOpen,_)||(t.confirmOpen=_),Od(_)}),Jm(`confirmed`,function(){return t.remove()}),Nc()}if(e&2){let l,s=BE(48);ec(2),pg(t.t().heading),ec(2),pg(t.t().hint),ec(2),Tc(t.servers()),ec(5),pg(t.t().add.heading),ec(4),pg(t.t().add.name),ec(),nS(t.input),Wm(`placeholder`,t.t().add.namePlaceholder)(`value`,t.name()),ec(3),pg(t.t().add.kind),ec(),nS(t.input),ec(),Wm(`selected`,t.kind()===`ssh`),ec(),pg(t.t().add.ssh),ec(),Wm(`selected`,t.kind()===`tcp`),ec(),pg(t.t().add.tcp),ec(),kE(t.kind()===`ssh`?25:-1),ec(),ag(`col-span-3`,t.kind()===`ssh`)(`col-span-5`,t.kind()===`tcp`),ec(2),pg(t.t().add.host),ec(),nS(t.input),Wm(`placeholder`,t.t().add.hostPlaceholder)(`value`,t.host()),ec(3),pg(t.t().add.port),ec(),nS(t.input),Wm(`placeholder`,t.kind()===`ssh`?`22`:`2375`)(`value`,t.port()),ec(3),pg(t.t().add.description),ec(),nS(t.input),Wm(`placeholder`,t.t().add.descriptionPlaceholder)(`value`,t.description()),ec(),kE(t.kind()===`tcp`?38:-1),ec(),kE((l=t.formProblem())?39:-1,l),ec(2),Wm(`disabled`,!t.filledIn()||t.testing()!==null),ec(),Ac(` `,t.testing()===t.form?t.t().testing:t.t().test,` `),ec(),Wm(`disabled`,!t.filledIn()||t.saving()),ec(),Wm(`size`,14),ec(),Ac(` `,t.t().add.submit,` `),ec(),Wm(`ngTemplateOutlet`,s)(`ngTemplateOutletContext`,SS(48,de,t.form)),ec(3),hg(`open`,t.confirmOpen),Wm(`title`,t.t().removeTitle(t.removing()??``))(`description`,t.t().removeDescription)}},dependencies:[W$1,My,Ie$1],encapsulation:2})}});function Ke(a,n){if(a&1&&(Oi(0,`option`,10),fS(1),Nc()),a&2){let e=n.$implicit,t=HE();Wm(`value`,e.value)(`selected`,e.value===t.language),Br(`lang`,e.value),ec(),pg(e.name)}}function Re(a,n){if(a&1&&(Oi(0,`p`,17),fS(1),Nc()),a&2){let e=HE(2);ec(),pg(e.t().startup.shortcutTaken)}}function $e(a,n){if(a&1&&(Oi(0,`p`,23),fS(1),Nc()),a&2){let e=HE(),t=HE();ec(),pg(t.lastPrune(e.lastAutoPrune))}}function He(a,n){if(a&1&&(Oi(0,`span`,26),fS(1),Nc()),a&2){let e=HE(2);ec(),pg(e.t().update.version(n.current))}}function je(a,n){if(a&1){let e=RE();Oi(0,`button`,35),Jm(`click`,function(){Ld(e);return Od(HE(2).install())}),fS(1),Nc()}if(a&2){let e=HE(2);ec(),Ac(` `,e.t().update.install,` `)}}function ze(a,n){if(a&1){let e=RE();Oi(0,`button`,36),Jm(`click`,function(){Ld(e);return Od(HE(2).check())}),fS(1),Nc()}if(a&2){let e=HE(2);Wm(`disabled`,e.updateState()===`checking`||e.updateState()===`downloading`),ec(),Ac(` `,e.t().update.check,` `)}}function We(a,n){if(a&1){let e=RE();Oi(0,`div`,29)(1,`app-filter-switch`,16),Jm(`onChange`,function(l){Ld(e);return Od(HE(2).update({autoUpdate:l}))}),Nc()()}if(a&2){let e=HE(),t=HE();ec(),Wm(`label`,t.t().update.auto)(`on`,e.autoUpdate)}}function Be(a,n){if(a&1&&(Oi(0,`option`,10),fS(1),Nc()),a&2){let e=n.$implicit,t=HE();Wm(`value`,e.value)(`selected`,e.value===t.assistantModel),ec(),pg(e.name)}}function Ge(a,n){if(a&1){let e=RE();Oi(0,`div`,7)(1,`span`,39),fS(2),Nc(),Oi(3,`button`,40),Jm(`click`,function(){Ld(e);return Od(HE(3).clearKey())}),Gm(4,`app-icon`,41),fS(5),Nc()()}if(a&2){let e=HE(3);ec(2),pg(e.t().assistant.configured),ec(2),Wm(`size`,14),ec(),Ac(` `,e.t().assistant.clearKey,` `)}}function qe(a,n){if(a&1){let e=RE();Oi(0,`form`,42),Jm(`submit`,function(l){Ld(e);return Od(HE(3).saveKey(l))}),Oi(1,`label`,43),fS(2),Nc(),Oi(3,`input`,44),Jm(`input`,function(l){Ld(e);return Od(HE(3).keyDraft.set(l.target.value))}),Nc(),Oi(4,`button`,45),fS(5),Nc()()}if(a&2){let e=HE(),t=HE(2);ec(2),pg(t.t().assistant.keyLabel),ec(),Wm(`value`,t.keyDraft())(`disabled`,!e.storageAvailable),ec(),Wm(`disabled`,!e.storageAvailable||t.keyDraft().trim()===``),ec(),Ac(` `,t.common().save,` `)}}function Je(a,n){a&1&&(Oi(0,`p`,38),fS(1),Nc()),a&2&&(ec(),pg(n))}function Qe(a,n){if(a&1&&(SE(0,Ge,6,3,`div`,7)(1,qe,6,5,`form`,37),SE(2,Je,2,1,`p`,38),Oi(3,`p`,11),fS(4),Nc()),a&2){let e,t=HE(2);kE(n.configured?0:1),ec(2),kE((e=t.keyProblem())?2:-1,e),ec(2),pg(t.t().assistant.hint)}}function Xe(a,n){if(a&1){let e=RE();Oi(0,`div`,3)(1,`div`,4)(2,`div`,5)(3,`h2`,6),fS(4),Nc(),Oi(5,`div`,7)(6,`label`,8),fS(7),Nc(),Oi(8,`select`,9),Jm(`change`,function(l){Ld(e);return Od(HE().chooseLanguage(l.target.value))}),kc(9,Ke,2,4,`option`,10,ce),Nc()(),Oi(11,`p`,11),fS(12),Nc()(),Oi(13,`div`,12)(14,`h2`,6),fS(15),Nc(),Oi(16,`div`,13)(17,`app-filter-switch`,14),Jm(`onChange`,function(l){Ld(e);return Od(HE().update({startAtLogin:l}))}),Nc()(),Oi(18,`p`,11),fS(19),Nc(),Oi(20,`div`,15)(21,`app-filter-switch`,16),Jm(`onChange`,function(l){Ld(e);return Od(HE().update({paletteShortcut:l}))}),Nc()(),SE(22,Re,2,1,`p`,17),Nc(),Oi(23,`div`,12)(24,`h2`,6),fS(25),Nc(),Oi(26,`div`,18)(27,`div`,19)(28,`app-filter-switch`,16),Jm(`onChange`,function(l){Ld(e);return Od(HE().update({notifyCrash:l}))}),Nc()(),Oi(29,`div`,20)(30,`app-filter-switch`,16),Jm(`onChange`,function(l){Ld(e);return Od(HE().update({notifyUnhealthy:l}))}),Nc()(),Oi(31,`div`,21)(32,`app-filter-switch`,16),Jm(`onChange`,function(l){Ld(e);return Od(HE().update({notifyWiring:l}))}),Nc()()(),Oi(33,`p`,11),fS(34),Nc()(),Oi(35,`div`,12)(36,`h2`,6),fS(37),Nc(),Oi(38,`div`,22)(39,`app-filter-switch`,16),Jm(`onChange`,function(l){Ld(e);return Od(HE().update({autoPrune:l}))}),Nc()(),Oi(40,`p`,11),fS(41),Nc(),SE(42,$e,2,1,`p`,23),Nc(),Oi(43,`div`,24)(44,`div`,25)(45,`h2`,6),fS(46),Nc(),SE(47,He,2,1,`span`,26),SE(48,je,2,1,`button`,27)(49,ze,2,2,`button`,28),Nc(),SE(50,We,2,2,`div`,29),Oi(51,`p`,30),fS(52),Nc()(),Oi(53,`div`,31)(54,`h2`,6),fS(55,`Claude`),Nc(),Oi(56,`div`,32)(57,`label`,33),fS(58),Nc(),Oi(59,`select`,34),Jm(`change`,function(l){Ld(e);return Od(HE().update({assistantModel:l.target.value}))}),kc(60,Be,2,3,`option`,10,ce),Nc()(),Oi(62,`p`,11),fS(63),Nc(),SE(64,Qe,5,3),Nc()(),Gm(65,`app-servers-settings`),Nc()}if(a&2){let e,t,l=n,s=HE();ec(4),pg(s.t().language.heading),ec(3),pg(s.t().language.label),ec(2),Tc(s.languages),ec(3),pg(s.t().language.hint),ec(3),pg(s.t().startup.heading),ec(2),Wm(`label`,s.t().startup.startAtLogin)(`on`,l.startAtLogin)(`disabled`,!l.startAtLoginAvailable),ec(2),Ac(` `,l.startAtLoginAvailable?s.t().startup.hintAvailable:s.t().startup.hintUnavailable,` `),ec(2),Wm(`label`,s.t().startup.paletteShortcut)(`on`,l.paletteShortcut),ec(),kE(l.paletteShortcut&&!l.paletteShortcutActive?22:-1),ec(3),pg(s.t().notifications.heading),ec(3),Wm(`label`,s.t().notifications.crash)(`on`,l.notifyCrash),ec(2),Wm(`label`,s.t().notifications.unhealthy)(`on`,l.notifyUnhealthy),ec(2),Wm(`label`,s.t().notifications.wiring)(`on`,l.notifyWiring),ec(2),pg(s.t().notifications.hint),ec(3),pg(s.t().prune.heading),ec(2),Wm(`label`,s.t().prune.auto)(`on`,l.autoPrune),ec(2),pg(s.t().prune.hint),ec(),kE(l.autoPrune?42:-1),ec(4),pg(s.t().update.heading),ec(),kE((e=s.appUpdate())?47:-1,e),ec(),kE(s.updateState()===`ready`?48:s.updateState()!==`unavailable`?49:-1),ec(2),kE(s.updateState()!==`unavailable`?50:-1),ec(2),pg(s.updateText()),ec(6),pg(s.t().assistant.model),ec(2),Tc(s.models),ec(3),pg(s.t().assistant.modelHint),ec(),kE((t=s.assistant())?64:-1,t)}}var ce;var Ye;var me;f(()=>{Kr();le();sk();lk();K();dk();x();pe();Kr();ce=(a,n)=>n.value;Ye={"claude-opus-5":`Opus 5`,"claude-sonnet-5":`Sonnet 5`,"claude-haiku-4-5":`Haiku 4.5`},me=class a{t=Ot(()=>ok().settings);common=Ot(()=>ok().common);languages=Object.keys(JF).map(n=>({value:n,name:JF[n]}));models=se.map(n=>({value:n,name:Ye[n]}));settings=wt(null);problem=wt(null);appUpdate=wt(null);assistant=wt(null);keyDraft=wt(``);keyProblem=wt(null);updateState=Ot(()=>this.appUpdate()?.status.state??`unavailable`);updateText=Ot(()=>{let n=this.appUpdate()?.status??{state:`unavailable`},e=this.t().update;switch(n.state){case`unavailable`:return e.unavailable;case`idle`:return e.idle;case`checking`:return e.checking;case`upToDate`:return e.upToDate(new Date(n.checkedAt).toLocaleTimeString(ik(),{hour:`2-digit`,minute:`2-digit`}));case`downloading`:return e.downloading(n.version,n.percent);case`ready`:return e.ready(n.version);case`error`:return e.error(n.problem)}});constructor(){this.load(),this.loadAppUpdate(),this.loadAssistant();let n=window.electron.appUpdate.onChange(e=>this.appUpdate.set(e));C(ve).onDestroy(n)}async check(){try{this.appUpdate.set(await window.electron.appUpdate.check())}catch(n){this.problem.set(eH(n))}}async install(){try{await window.electron.appUpdate.install()}catch(n){this.problem.set(eH(n))}}lastPrune(n){let e=this.t().prune;return n===null?e.never:e.last(new Intl.DateTimeFormat(ik(),{dateStyle:`long`,timeStyle:`short`}).format(n))}async update(n){try{this.settings.set(await window.electron.settings.update(n)),this.problem.set(null)}catch(e){this.problem.set(eH(e)),await this.load()}}async chooseLanguage(n){Ty(n),await this.update({language:n}),Ty(this.settings()?.language??n)}async saveKey(n){n.preventDefault();try{let e=await window.electron.assistant.setKey(this.keyDraft());if(!e.ok){this.keyProblem.set(e.problem);return}this.keyDraft.set(``),this.keyProblem.set(null),await this.loadAssistant()}catch(e){this.keyProblem.set(eH(e))}}async clearKey(){try{this.assistant.set(await window.electron.assistant.clearKey()),this.keyProblem.set(null)}catch(n){this.keyProblem.set(eH(n))}}async loadAssistant(){try{this.assistant.set(await window.electron.assistant.status())}catch(n){this.problem.set(eH(n))}}async loadAppUpdate(){try{this.appUpdate.set(await window.electron.appUpdate.get())}catch(n){this.problem.set(eH(n))}}async load(){try{this.settings.set(await window.electron.settings.get())}catch(n){this.problem.set(eH(n))}}static ɵfac=function(e){return new(e||a)};static ɵcmp=wc({type:a,selectors:[[`app-settings-page`]],decls:5,vars:3,consts:[[1,`h-full`,`overflow-y-auto`,`px-6`,`pt-5`,`pb-8`],[1,`text-xl`,`font-semibold`,`tracking-tight`,`text-ink-100`],[3,`problem`],[1,`mt-4`,`grid`,`max-w-6xl`,`items-start`,`gap-4`,`lg:grid-cols-2`],[1,`space-y-4`],[`data-testid`,`setting-language`,1,`rounded-lg`,`border`,`border-ink-700`,`bg-ink-850`,`px-4`,`py-3`],[1,`text-[13px]`,`font-medium`,`text-ink-200`],[1,`mt-3`,`flex`,`items-center`,`gap-3`],[`for`,`setting-language`,1,`text-[13px]`,`text-ink-300`],[`id`,`setting-language`,1,`mx-focus`,`rounded-md`,`border`,`border-ink-700`,`bg-ink-800`,`px-2.5`,`py-1.5`,`text-[13px]`,`text-ink-100`,3,`change`],[3,`value`,`selected`],[1,`mt-2`,`text-[12px]`,`text-ink-500`],[1,`rounded-lg`,`border`,`border-ink-700`,`bg-ink-850`,`px-4`,`py-3`],[`data-testid`,`setting-start-at-login`,1,`mt-3`],[3,`onChange`,`label`,`on`,`disabled`],[`data-testid`,`setting-palette-shortcut`,1,`mt-3`],[3,`onChange`,`label`,`on`],[`data-testid`,`shortcut-taken`,1,`mt-2`,`text-[12px]`,`text-warn`],[1,`mt-3`,`space-y-2.5`],[`data-testid`,`setting-notify-crash`],[`data-testid`,`setting-notify-unhealthy`],[`data-testid`,`setting-notify-wiring`],[`data-testid`,`setting-auto-prune`,1,`mt-3`],[`data-testid`,`auto-prune-last`,1,`mt-1`,`text-[12px]`,`text-ink-400`],[`data-testid`,`app-update`,1,`rounded-lg`,`border`,`border-ink-700`,`bg-ink-850`,`px-4`,`py-3`],[1,`flex`,`items-center`,`gap-3`],[1,`font-mono`,`text-[12px]`,`text-ink-500`],[`type`,`button`,`data-testid`,`app-update-install`,1,`mx-btn`,`mx-focus`,`ml-auto`],[`type`,`button`,`data-testid`,`app-update-check`,1,`mx-btn`,`mx-focus`,`ml-auto`,3,`disabled`],[`data-testid`,`setting-auto-update`,1,`mt-3`],[`data-testid`,`app-update-status`,1,`mt-2`,`text-[12px]`,`text-ink-500`],[`data-testid`,`assistant-settings`,1,`rounded-lg`,`border`,`border-ink-700`,`bg-ink-850`,`px-4`,`py-3`],[`data-testid`,`setting-assistant-model`,1,`mt-3`,`flex`,`items-center`,`gap-3`],[`for`,`setting-assistant-model`,1,`text-[13px]`,`text-ink-300`],[`id`,`setting-assistant-model`,1,`mx-focus`,`rounded-md`,`border`,`border-ink-700`,`bg-ink-800`,`px-2.5`,`py-1.5`,`text-[13px]`,`text-ink-100`,3,`change`],[`type`,`button`,`data-testid`,`app-update-install`,1,`mx-btn`,`mx-focus`,`ml-auto`,3,`click`],[`type`,`button`,`data-testid`,`app-update-check`,1,`mx-btn`,`mx-focus`,`ml-auto`,3,`click`,`disabled`],[1,`mt-3`,`flex`,`gap-2`],[1,`mt-2`,`text-[12px]`,`text-danger`],[1,`text-[13px]`,`text-ink-300`],[`type`,`button`,`data-testid`,`assistant-clear-key`,1,`mx-btn`,`mx-focus`,`ml-auto`,3,`click`],[`name`,`trash`,3,`size`],[1,`mt-3`,`flex`,`gap-2`,3,`submit`],[`for`,`assistant-key`,1,`sr-only`],[`id`,`assistant-key`,`type`,`password`,`placeholder`,`sk-ant-…`,`autocomplete`,`off`,`spellcheck`,`false`,1,`mx-focus`,`min-w-0`,`flex-1`,`rounded-md`,`border`,`border-ink-700`,`bg-ink-800`,`px-3`,`py-1.5`,`font-mono`,`text-[13px]`,`text-ink-100`,`placeholder:text-ink-500`,3,`input`,`value`,`disabled`],[`type`,`submit`,`data-testid`,`assistant-save-key`,1,`mx-btn`,`mx-focus`,3,`disabled`]],template:function(e,t){if(e&1&&(Oi(0,`section`,0)(1,`h1`,1),fS(2),Nc(),Gm(3,`app-page-messages`,2),SE(4,Xe,66,32,`div`,3),Nc()),e&2){let l;ec(2),pg(t.t().title),ec(),Wm(`problem`,t.problem()),ec(),kE((l=t.settings())?4:-1,l)}},dependencies:[P,u$1,My,L],encapsulation:2})}})();export{me as SettingsPage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{$n as sk,Bn as ok,Cr as zE,D as HE,Dn as kc,En as kE,F as Jm,G as Nc,L as Kr,Pn as mj,Pt as Wm,Q as Oi,Qn as sg,Sn as hj,St as Tc,Tn as jc,Z as Od,a as Ar,cn as f,et as Ot,gt as SS,ht as SE,ir as tg,l as C,ln as fS,lt as RE,mr as wc,qt as ag,r as Ac,s as Br,sn as ec,st as Qm,t as $I,ur as vj,w as Gm,z as Ld}from"./chunk-JmNJabM7.js";import{i as Ie,o as Ne}from"./chunk-Bz7JmGk-.js";function U(t,n){return this.trackKey()(n)}function W(t,n){t&1&&Gm(0,`col`,1)}function X(t,n){if(t&1&&Gm(0,`col`),t&2){let e=n.$implicit;sg(`width`,e.width??null)}}function Y(t,n){if(t&1){let e=RE();Oi(0,`th`,4)(1,`input`,6),Jm(`change`,function(){Ld(e);return Od(HE().toggleAll())}),Nc()()}if(t&2){let e=HE();ec(),Wm(`checked`,e.allSelected())(`indeterminate`,e.someSelected()),Br(`aria-label`,e.allSelected()?e.t().clearSelection:e.t().selectAll)}}function Z(t,n){if(t&1&&(Oi(0,`th`,7),fS(1),Nc()),t&2){let e=n.$implicit;ag(`text-right`,e.align===`right`),ec(),Ac(` `,e.label,` `)}}function ee(t,n){if(t&1&&(Oi(0,`tr`,8)(1,`td`,10),Qm(2,11),Nc()()),t&2){let e=HE().$implicit,a=HE();ec(),Br(`colspan`,a.columnCount()),ec(),Wm(`ngTemplateOutlet`,a.groupHeader().template)(`ngTemplateOutletContext`,SS(3,I,e))}}function te(t,n){if(t&1){let e=RE();Oi(0,`td`,10)(1,`input`,13),Jm(`change`,function(){Ld(e);let d=HE().$implicit,$=HE(2);return Od($.toggleOne($.trackKey()(d)))}),Nc()()}if(t&2){let e=HE().$implicit,a=HE(2);ec(),Wm(`checked`,a.selected().has(a.trackKey()(e))),Br(`aria-label`,a.t().select(a.trackKey()(e)))}}function ne(t,n){if(t&1&&(Oi(0,`td`,10),Qm(1,11),Nc()),t&2){let e=n.$implicit,a=HE().$implicit,d=HE(2);ag(`text-right`,e.align===`right`),ec(),Wm(`ngTemplateOutlet`,d.cellFor(e.key))(`ngTemplateOutletContext`,SS(4,I,a))}}function ae(t,n){if(t&1&&(Oi(0,`tr`,9),SE(1,te,2,2,`td`,10),kc(2,ne,2,6,`td`,12,_),Nc()),t&2){let e=HE(2);ec(),kE(e.selectable()?1:-1),ec(),Tc(e.columns())}}function ie(t,n){if(t&1&&(SE(0,ee,3,5,`tr`,8),kc(1,ae,4,1,`tr`,9,U,!0)),t&2){let e=n.$implicit;kE(HE().showHeaders()?0:-1),ec(),Tc(e.rows)}}function le(t,n){if(t&1&&(Oi(0,`tr`)(1,`td`,14),fS(2),Nc()()),t&2){let e=HE();ec(),Br(`colspan`,e.columnCount()),ec(),Ac(` `,e.emptyMessage()??e.t().empty,` `)}}var I;var _;var x;var h;var z;var oe=f(()=>{Ne();Kr();sk();Kr();I=t=>({$implicit:t}),_=(t,n)=>n.key;x=class t{appCell=jc.required();template=C(Ar);static ɵfac=function(e){return new(e||t)};static ɵdir=$I({type:t,selectors:[[`ng-template`,`appCell`,``]],inputs:{appCell:[1,`appCell`]}})},h=class t{template=C(Ar);static ɵfac=function(e){return new(e||t)};static ɵdir=$I({type:t,selectors:[[`ng-template`,`appGroupHeader`,``]]})},z=class t{columns=jc.required();rows=jc.required();trackKey=jc.required();selectable=jc(!0);emptyMessage=jc(null);selected=mj(new Set);groups=jc(null);cells=vj(x);groupHeader=hj(h);t=Ot(()=>ok().shell.dataTable);blocks=Ot(()=>this.groups()??[{key:``,rows:this.rows()}]);showHeaders=Ot(()=>this.groups()!==null&&this.groupHeader()!==void 0);isEmpty=Ot(()=>this.blocks().length===0||!this.showHeaders()&&this.rows().length===0);cellsByKey=Ot(()=>new Map(this.cells().map(n=>[n.appCell(),n.template])));columnCount=Ot(()=>this.columns().length+(this.selectable()?1:0));allSelected=Ot(()=>this.rows().length>0&&this.selected().size===this.rows().length);someSelected=Ot(()=>this.selected().size>0&&!this.allSelected());cellFor(n){return this.cellsByKey().get(n)??null}toggleAll(){this.selected.set(this.allSelected()?new Set:new Set(this.rows().map(n=>this.trackKey()(n))))}toggleOne(n){let e=new Set(this.selected());e.delete(n)||e.add(n),this.selected.set(e)}static ɵfac=function(e){return new(e||t)};static ɵcmp=wc({type:t,selectors:[[`app-data-table`]],contentQueries:function(e,a,d){e&1&&tg(d,a.cells,x,4)(d,a.groupHeader,h,5),e&2&&zE(2)},inputs:{columns:[1,`columns`],rows:[1,`rows`],trackKey:[1,`trackKey`],selectable:[1,`selectable`],emptyMessage:[1,`emptyMessage`],selected:[1,`selected`],groups:[1,`groups`]},outputs:{selected:`selectedChange`},decls:14,vars:3,consts:[[1,`w-full`,`table-fixed`,`border-collapse`,`text-[13px]`],[1,`w-10`],[3,`width`],[1,`border-b`,`border-ink-700`,`text-left`,`text-ink-400`],[1,`px-3`,`py-2`],[`scope`,`col`,1,`truncate`,`px-3`,`py-2`,`font-medium`,3,`text-right`],[`type`,`checkbox`,1,`mx-focus`,`accent-accent`,3,`change`,`checked`,`indeterminate`],[`scope`,`col`,1,`truncate`,`px-3`,`py-2`,`font-medium`],[1,`border-b`,`border-ink-800`,`bg-ink-850`],[1,`border-b`,`border-ink-800`,`transition-colors`,`hover:bg-ink-850`],[1,`px-3`,`py-1.5`],[3,`ngTemplateOutlet`,`ngTemplateOutletContext`],[1,`px-3`,`py-1.5`,3,`text-right`],[`type`,`checkbox`,1,`mx-focus`,`accent-accent`,3,`change`,`checked`],[1,`px-3`,`py-10`,`text-center`,`text-ink-400`]],template:function(e,a){e&1&&(Oi(0,`table`,0)(1,`colgroup`),SE(2,W,1,0,`col`,1),kc(3,X,1,2,`col`,2,_),Nc(),Oi(5,`thead`)(6,`tr`,3),SE(7,Y,2,3,`th`,4),kc(8,Z,2,3,`th`,5,_),Nc()(),Oi(10,`tbody`),kc(11,ie,3,1,null,null,_),SE(13,le,3,2,`tr`),Nc()()),e&2&&(ec(2),kE(a.selectable()?2:-1),ec(),Tc(a.columns()),ec(4),kE(a.selectable()?7:-1),ec(),Tc(a.columns()),ec(3),Tc(a.blocks()),ec(2),kE(a.isEmpty()?13:-1))},dependencies:[Ie],encapsulation:2})}});export{z as i,oe as n,x as r,h as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{B as M,C as Gi,It as Ws,L as Kr,Mt as Vr,N as Iw,R as LI,Rt as X,X as OE,cn as f,dt as Rc,l as C$1,mn as ge$1,mt as S,n as $e,t as $I,tn as br,tt as PE,vt as Se$1}from"./chunk-JmNJabM7.js";function T(){return te}function ge(e){te??=e}var te;var $;var O;var ne;var U=f(()=>{Kr();Kr();te=null;$=class{},O=(()=>{class e{historyGo(t){throw new Error(``)}static ɵfac=function(n){return new(n||e)};static ɵprov=X({token:e,factory:()=>C$1(ne),providedIn:`platform`})}return e})(),ne=(()=>{class e extends O{_location;_history;_doc=C$1(br);constructor(){super(),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return T().getBaseHref(this._doc)}onPopState(t){let n=T().getGlobalEventTarget(this._doc,`window`);return n.addEventListener(`popstate`,t,!1),()=>n.removeEventListener(`popstate`,t)}onHashChange(t){let n=T().getGlobalEventTarget(this._doc,`window`);return n.addEventListener(`hashchange`,t,!1),()=>n.removeEventListener(`hashchange`,t)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(t){this._location.pathname=t}pushState(t,n,r){this._history.pushState(t,n,r)}replaceState(t,n,r){this._history.replaceState(t,n,r)}forward(){this._history.forward()}back(){this._history.back()}historyGo(t=0){this._history.go(t)}getState(){return this._history.state}static ɵfac=function(n){return new(n||e)};static ɵprov=X({token:e,factory:()=>new e,providedIn:`platform`})}return e})()});function se(e,i){return e?i?e.endsWith(`/`)?i.startsWith(`/`)?e+i.slice(1):e+i:i.startsWith(`/`)?e+i:`${e}/${i}`:e:i}function ie(e){let i=e.search(/#|\?|$/);return e[i-1]===`/`?e.slice(0,i-1)+e.slice(i):e}function C(e){return e&&e[0]!==`?`?`?${e}`:e}function me(){return new oe($e(R))}function Ce(e,i){if(!e||!i.startsWith(e))return i;let t=i.substring(e.length);return t===``||[`/`,`;`,`?`,`#`].includes(t[0])?t:i}function re(e){return e.replace(/\/index\.html$/,``)}function ye(e){if(new RegExp(`^(https?:)?//`).test(e)){let[,t]=e.split(/\/\/[^\/]+/);return t}return e}var R;var De;var pe;var oe;var ae=f(()=>{Kr();Kr();Ws();U();R=(()=>{class e{historyGo(t){throw new Error(``)}static ɵfac=function(n){return new(n||e)};static ɵprov=X({token:e,factory:()=>C$1(pe),providedIn:`root`})}return e})(),De=new M(``),pe=(()=>{class e extends R{_platformLocation;_baseHref;_removeListenerFns=[];constructor(t,n){super(),this._platformLocation=t,this._baseHref=n??this._platformLocation.getBaseHrefFromDOM()??C$1(br).location?.origin??``}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(t){this._removeListenerFns.push(this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t))}getBaseHref(){return this._baseHref}prepareExternalUrl(t){return se(this._baseHref,t)}path(t=!1){let n=this._platformLocation.pathname+C(this._platformLocation.search),r=this._platformLocation.hash;return r&&t?`${n}${r}`:n}pushState(t,n,r,s){let o=this.prepareExternalUrl(r+C(s));this._platformLocation.pushState(t,n,o)}replaceState(t,n,r,s){let o=this.prepareExternalUrl(r+C(s));this._platformLocation.replaceState(t,n,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(t=0){this._platformLocation.historyGo?.(t)}static ɵfac=function(n){return new(n||e)($e(O),$e(De,8))};static ɵprov=X({token:e,factory:e.ɵfac,providedIn:`root`})}return e})(),oe=(()=>{class e{_subject=new ge$1;_basePath;_locationStrategy;_urlChangeListeners=[];_urlChangeSubscription=null;constructor(t){this._locationStrategy=t;let n=this._locationStrategy.getBaseHref();this._basePath=ye(ie(re(n))),this._locationStrategy.onPopState(r=>{let s={url:this.path(!0),pop:!0,state:r.state,type:r.type};r.hasUAVisualTransition&&(s.hasUAVisualTransition=!0),this._subject.next(s)})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(t=!1){return this.normalize(this._locationStrategy.path(t))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(t,n=``){return this.path()==this.normalize(t+C(n))}normalize(t){return e.stripTrailingSlash(Ce(this._basePath,re(t)))}prepareExternalUrl(t){return t&&t[0]!==`/`&&(t=`/`+t),this._locationStrategy.prepareExternalUrl(t)}go(t,n=``,r=null){this._locationStrategy.pushState(r,``,t,n),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+C(n)),r)}replaceState(t,n=``,r=null){this._locationStrategy.replaceState(r,``,t,n),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+C(n)),r)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(t=0){this._locationStrategy.historyGo?.(t)}onUrlChange(t){return this._urlChangeListeners.push(t),this._urlChangeSubscription??=this.subscribe(n=>{this._notifyUrlChangeListeners(n.url,n.state)}),()=>{let n=this._urlChangeListeners.indexOf(t);this._urlChangeListeners.splice(n,1),this._urlChangeListeners.length===0&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(t=``,n){this._urlChangeListeners.forEach(r=>r(t,n))}subscribe(t,n,r){return this._subject.subscribe({next:t,error:n??void 0,complete:r??void 0})}static normalizeQueryParams=C;static joinWithSlash=se;static stripTrailingSlash=ie;static ɵfac=function(n){return new(n||e)($e(R))};static ɵprov=X({token:e,factory:()=>me(),providedIn:`root`})}return e})()});function A(e,i){let t=OE(e),n=t[PE.NumberSymbols][i];if(typeof n>`u`){if(i===h.CurrencyDecimal)return t[PE.NumberSymbols][h.Decimal];if(i===h.CurrencyGroup)return t[PE.NumberSymbols][h.Group]}return n}function ce(e,i){return OE(e)[PE.NumberFormats][i]}function Ae(e,i,t,n,r,s,o=!1){let u=``,D=!1;if(!isFinite(e))u=A(t,Number.isNaN(e)?h.NaN:h.Infinity);else{let d=ve(e);o&&(d=_e(d));let l=i.minInt,a=i.minFrac,f=i.maxFrac;if(s){let w=s.match(Fe);if(w===null)throw new S(2306,!1);let H=w[1],B=w[3],W=w[5];H!=null&&(l=z(H)),B!=null&&(a=z(B)),W!=null?f=z(W):B!=null&&a>f&&(f=a);let N=100;if(l>N||a>N||f>N)throw new S(2306,!1)}be(d,a,f);let c=d.digits,g=d.integerLen,G=d.exponent,I=[];for(D=c.every(w=>!w);g<l;g++)c.unshift(0);for(;g<0;g++)c.unshift(0);g>0?I=c.splice(g,c.length):(I=c,c=[0]);let L=[];for(c.length>=i.lgSize&&L.unshift(c.splice(-i.lgSize,c.length).join(``));c.length>i.gSize;)L.unshift(c.splice(-i.gSize,c.length).join(``));c.length&&L.unshift(c.join(``)),u=L.join(A(t,n)),I.length&&(u+=A(t,r)+I.join(``)),G&&(u+=A(t,h.Exponential)+`+`+G)}return e<0&&!D?u=i.negPre+u+i.negSuf:u=i.posPre+u+i.posSuf,u}function de(e,i,t){return Ae(e,Se(ce(i,V.Decimal),A(i,h.MinusSign)),i,h.Group,h.Decimal,t)}function Se(e,i=`-`){let t={minInt:1,minFrac:0,maxFrac:0,posPre:``,posSuf:``,negPre:``,negSuf:``,gSize:0,lgSize:0},n=e.split(Ee),r=n[0],s=n[1],o=r.indexOf(P)!==-1?r.split(P):[r.substring(0,r.lastIndexOf(b)+1),r.substring(r.lastIndexOf(b)+1)],u=o[0],D=o[1]||``;t.posPre=u.substring(0,u.indexOf(j));for(let l=0;l<D.length;l++){let a=D.charAt(l);a===b?t.minFrac=t.maxFrac=l+1:a===j?t.maxFrac=l+1:t.posSuf+=a}let d=u.split(we);if(t.gSize=d[1]?d[1].length:0,t.lgSize=d[2]||d[1]?(d[2]||d[1]).length:0,s){let l=r.length-t.posPre.length-t.posSuf.length,a=s.indexOf(j);t.negPre=s.substring(0,a).replace(/'/g,``),t.negSuf=s.slice(a+l).replace(/'/g,``)}else t.negPre=i+t.posPre,t.negSuf=t.posSuf;return t}function _e(e){if(e.digits[0]===0)return e;let i=e.digits.length-e.integerLen;return e.exponent?e.exponent+=2:(i===0?e.digits.push(0,0):i===1&&e.digits.push(0),e.integerLen+=2),e}function ve(e){let i=Math.abs(e)+``,t=0,n,r,s,o,u;for((r=i.indexOf(P))>-1&&(i=i.replace(P,``)),(s=i.search(/e/i))>0?(r<0&&(r=s),r+=+i.slice(s+1),i=i.substring(0,s)):r<0&&(r=i.length),s=0;i.charAt(s)===b;s++);if(s===(u=i.length))n=[0],r=1;else{for(u--;i.charAt(u)===b;)u--;for(r-=s,n=[],o=0;s<=u;s++,o++)n[o]=Number(i.charAt(s))}return r>ue&&(n=n.splice(0,ue-1),t=r-1,r=1),{digits:n,exponent:t,integerLen:r}}function be(e,i,t){if(i>t)throw new S(2307,!1);let n=e.digits,r=n.length-e.integerLen,s=Math.min(Math.max(i,r),t),o=s+e.integerLen,u=n[o];if(o>0){n.splice(Math.max(e.integerLen,o));for(let a=o;a<n.length;a++)n[a]=0}else{r=Math.max(0,r),e.integerLen=1,n.length=Math.max(1,o=s+1),n[0]=0;for(let a=1;a<o;a++)n[a]=0}if(u>=5)if(o-1<0){for(let a=0;a>o;a--)n.unshift(0),e.integerLen++;n.unshift(1),e.integerLen++}else n[o-1]++;for(;r<Math.max(0,s);r++)n.push(0);let D=s!==0,d=i+e.integerLen,l=n.reduceRight(function(a,f,c,g){return f=f+a,g[c]=f<10?f:f-10,D&&(g[c]===0&&c>=d?g.pop():D=!1),f>=10?1:0},0);l&&(n.unshift(l),e.integerLen++)}function z(e){let i=parseInt(e);if(isNaN(i))throw new S(2305,!1);return i}function Le(e,i){return new S(2100,!1)}function Te(e){return!(e==null||e===``||e!==e)}function Oe(e){if(typeof e==`string`&&!isNaN(Number(e)-parseFloat(e)))return Number(e);if(typeof e!=`number`)throw new S(2309,!1);return e}var V;var h;var Fe;var ue;var P;var b;var Ee;var we;var j;var Ie;var Me;var le=f(()=>{Kr();Kr();V=(function(e){return e[e.Decimal=0]=`Decimal`,e[e.Percent=1]=`Percent`,e[e.Currency=2]=`Currency`,e[e.Scientific=3]=`Scientific`,e})(V||{}),h={Decimal:0,Group:1,List:2,PercentSign:3,PlusSign:4,MinusSign:5,Exponential:6,SuperscriptingExponent:7,PerMille:8,Infinity:9,NaN:10,TimeSeparator:11,CurrencyDecimal:12,CurrencyGroup:13};Fe=/^(\d+)?\.((\d+)(-(\d+))?)?$/,ue=22,P=`.`,b=`0`,Ee=`;`,we=`,`,j=`#`;Ie=(()=>{class e{_viewContainerRef;_viewRef=null;ngTemplateOutletContext=null;ngTemplateOutlet=null;ngTemplateOutletInjector=null;injector=C$1(Se$1);constructor(t){this._viewContainerRef=t}ngOnChanges(t){if(this._shouldRecreateView(t)){let n=this._viewContainerRef;if(this._viewRef&&n.remove(n.indexOf(this._viewRef)),!this.ngTemplateOutlet){this._viewRef=null;return}let r=this._createContextForwardProxy();this._viewRef=n.createEmbeddedView(this.ngTemplateOutlet,r,{injector:this._getInjector()})}}_getInjector(){return this.ngTemplateOutletInjector===`outlet`?this.injector:this.ngTemplateOutletInjector??void 0}_shouldRecreateView(t){return!!t.ngTemplateOutlet||!!t.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(t,n,r)=>this.ngTemplateOutletContext?Reflect.set(this.ngTemplateOutletContext,n,r):!1,get:(t,n,r)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,n,r)}})}static ɵfac=function(n){return new(n||e)(Vr(Gi))};static ɵdir=$I({type:e,selectors:[[``,`ngTemplateOutlet`,``]],inputs:{ngTemplateOutletContext:`ngTemplateOutletContext`,ngTemplateOutlet:`ngTemplateOutlet`,ngTemplateOutletInjector:`ngTemplateOutletInjector`},features:[Iw]})}return e})();Me=(()=>{class e{_locale;constructor(t){this._locale=t}transform(t,n,r){if(!Te(t))return null;r||=this._locale;try{return de(Oe(t),r,n)}catch(s){throw Le(e,s.message)}}static ɵfac=function(n){return new(n||e)(Vr(Rc,16))};static ɵpipe=LI({name:`number`,type:e,pure:!0})}return e})()});function Re(e,i){i=encodeURIComponent(i);for(let t of e.split(`;`)){let n=t.indexOf(`=`),[r,s]=n==-1?[t,``]:[t.slice(0,n),t.slice(n+1)];if(r.trim()!==i)continue;let o=s;try{o=decodeURIComponent(s)}catch{}return o.length>1&&o[0]===`"`&&o[o.length-1]===`"`&&(o=o.slice(1,-1)),o}return null}var fe=f(()=>{});function $n(e){return e===Be}var Be;var Ne=f(()=>{ae();le();U();Kr();fe();Be=`browser`});export{Me as a,Re as c,oe as d,Ie as i,T as l,$n as n,Ne as o,Be as r,R as s,$ as t,ge as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{$n as sk,Bn as ok,D as HE,F as Jm,G as Nc,Gn as pj,Gt as _m,L as Kr,Pn as mj,Pt as Wm,Q as Oi,Tn as jc,U as My,Wn as pg,Z as Od,cn as f,et as Ot,ln as fS,lr as vg,lt as RE,mr as wc,or as vS,r as Ac,rn as dk,sn as ec,w as Gm,xn as hg,z as Ld}from"./chunk-JmNJabM7.js";import{a as Ni,c as Ri,h as ki,i as Mi,n as Ii,o as Oi$1,p as ho,s as Pi,t as Ai}from"./chunk-6D7_x-nR.js";function H(o,u){if(o&1){let e=RE();Gm(0,`div`,2),Oi(1,`div`,3)(2,`div`,4)(3,`div`,5)(4,`span`,6),Gm(5,`app-icon`,7),Nc(),Oi(6,`div`,8)(7,`h2`,9),fS(8),Nc(),Oi(9,`p`,10),fS(10),Nc()()(),Oi(11,`div`,11)(12,`button`,12),Gm(13,`app-icon`,13),fS(14),Nc(),Oi(15,`button`,14),Jm(`click`,function(){Ld(e);return Od(HE().accept())}),Gm(16,`app-icon`,15),fS(17),Nc()()()()}if(o&2){let e=HE();ec(5),Wm(`size`,20),ec(3),pg(e.title()),ec(2),pg(e.description()),ec(3),Wm(`size`,14),ec(),Ac(` `,e.cancelLabel(),` `),ec(2),Wm(`name`,e.confirmIcon())(`size`,14),ec(),Ac(` `,e.shownConfirmLabel(),` `)}}var W;var J=f(()=>{Kr();ho();sk();dk();Kr();W=class o{open=mj(!1);title=jc.required();description=jc.required();confirmLabel=jc(null);confirmIcon=jc(`trash`);confirmed=pj();cancelLabel=Ot(()=>ok().common.cancel);shownConfirmLabel=Ot(()=>this.confirmLabel()??ok().shell.confirmDialog.confirm);accept(){this.open.set(!1),this.confirmed.emit()}static ɵfac=function(e){return new(e||o)};static ɵcmp=wc({type:o,selectors:[[`app-confirm-dialog`]],inputs:{open:[1,`open`],title:[1,`title`],description:[1,`description`],confirmLabel:[1,`confirmLabel`],confirmIcon:[1,`confirmIcon`]},outputs:{open:`openChange`,confirmed:`confirmed`},decls:2,vars:1,consts:[[`rdxAlertDialogRoot`,``,3,`openChange`,`open`],[`rdxAlertDialogPortal`,``],[`rdxAlertDialogBackdrop`,``,1,`fixed`,`inset-0`,`z-40`,`bg-black/50`],[`rdxAlertDialogViewport`,``,`rdxDialogViewport`,``,1,`fixed`,`inset-0`,`z-50`,`grid`,`place-items-center`,`p-4`],[`rdxAlertDialogPopup`,``,1,`w-full`,`max-w-md`,`rounded-lg`,`border`,`border-ink-700`,`bg-ink-850`,`p-5`,`shadow-2xl`],[1,`flex`,`gap-3`],[1,`mt-0.5`,`text-danger`],[`name`,`warning`,3,`size`],[1,`min-w-0`],[`rdxAlertDialogTitle`,``,1,`text-[15px]`,`font-semibold`,`text-ink-100`],[`rdxAlertDialogDescription`,``,1,`mt-1.5`,`text-[13px]`,`text-ink-300`],[1,`mt-5`,`flex`,`justify-end`,`gap-2`],[`type`,`button`,`rdxAlertDialogClose`,``,1,`mx-btn`,`mx-focus`],[`name`,`close`,3,`size`],[`type`,`button`,1,`mx-btn`,`mx-focus`,`border-danger`,`bg-danger`,`text-white`,`hover:border-danger`,`hover:bg-danger`,`hover:text-white`,3,`click`],[3,`name`,`size`]],template:function(e,d){e&1&&(Oi(0,`div`,0),vg(`openChange`,function(c){return vS(d.open,c)||(d.open=c),c}),_m(1,H,18,8,`ng-template`,1),Nc()),e&2&&hg(`open`,d.open)},dependencies:[Ni,Ai,Oi$1,ki,Ii,Pi,Mi,Ri,My],encapsulation:2})}});export{W as n,J as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{A as IS,F as Jm,G as Nc,Gn as pj,I as Km,L as Kr,Pn as mj,Pt as Wm,Q as Oi,Tn as jc,Wn as pg,Xn as rf,cn as f,et as Ot,g as Dj,gr as wt,l as C,ln as fS,mr as wc,s as Br,sn as ec,t as $I,vr as xm,w as Gm,wn as jI}from"./chunk-JmNJabM7.js";import{E as tn,S as or,c as Ln,i as Gn,m as Zn,r as Et,s as Kn,u as Tt}from"./chunk-DCF2sSJN.js";var X;var G;var J;var p;var E;var j=f(()=>{Kr();Kr();tn();tn();[X,G]=Gn(`RdxSwitchContext`,`components/switch`),J=()=>{let i=C(p),f=Ln();return{checked:i.checkedState,disabled:Ot(()=>!!f.disabled()),readonly:i.readonly,required:i.required,name:i.name,form:i.form,value:i.submitValue,ariaLabel:i.ariaLabel,ariaLabelledBy:i.ariaLabelledBy,registerNativeInput:n=>i.registerNativeInput(n),markAsTouched:()=>i.markAsTouched()}},p=(()=>{class i extends Kn{constructor(){super(),this.cva=Ln(),this.id=jc(Tt(`rdx-switch-`)),this.defaultChecked=jc(void 0,{transform:e=>e===void 0?void 0:Dj(e)}),this.checked=mj(!1),this.disabled=jc(!1,{transform:Dj}),this.readonly=jc(!1,{transform:Dj}),this.required=jc(!1,{transform:Dj}),this.name=jc(),this.form=jc(),this.submitValue=jc(`on`,{alias:`value`}),this.uncheckedValue=jc(),this.ariaLabelledBy=jc(void 0,{alias:`aria-labelledby`}),this.ariaLabel=jc(void 0,{alias:`aria-label`}),this.onCheckedChange=pj(),this.checkedState=Ot(()=>!!this.cva.value()),this.isDisabled=Ot(()=>!!this.cva.disabled()),this.nativeInput=wt(null),this.nativeInputOwnsValue=Ot(()=>this.nativeInput()!==null&&(this.checkedState()||this.uncheckedValue()===void 0)),this.invalidState=this.formUi.invalidState,this.touchedState=this.formUi.touchedState,this.dirtyState=this.formUi.dirtyState,or({name:this.name,form:this.form,disabled:this.isDisabled,value:this.checkedState,serialize:e=>{let t=e?this.submitValue():this.uncheckedValue();return t===void 0?[]:[t]},hasNativeControl:this.nativeInputOwnsValue,syncNativeControl:()=>{let e=this.nativeInput();e&&(e.checked=this.checkedState())},defaultValue:()=>this.defaultChecked()??this.checkedState(),onReset:e=>{this.checked.set(e),this.resetNgControl(e)||this.cva.writeValue(e),this.formUi.resetInteractionState?.()}});let n=!1;rf(()=>{let e=this.defaultChecked();!n&&e!==void 0&&(n=!0,this.checked.set(e),this.cva.setValue(e))})}formUiTouchTarget(){return Ln()}markAsTouched(){this.formUi.markAsTouched()}toggle(n){if(this.isDisabled()||this.readonly())return;let e=!this.cva.value(),t=n?.currentTarget instanceof HTMLElement?n.currentTarget:void 0,{eventDetails:d}=Zn(`none`,n??new Event(`switch.checked-change`),t);this.onCheckedChange.emit({checked:e,eventDetails:d}),!d.isCanceled()&&(this.checked.set(e),this.cva.setValue(e),this.formUi.markDirty())}registerNativeInput(n){return this.nativeInput.set(n),()=>{this.nativeInput()===n&&this.nativeInput.set(null)}}static{this.ɵfac=function(e){return new(e||i)}}static{this.ɵdir=$I({type:i,selectors:[[`button`,`rdxSwitchRoot`,``]],hostAttrs:[`role`,`switch`,`type`,`button`],hostVars:15,hostBindings:function(e,t){e&1&&Jm(`click`,function(O){return t.toggle(O)})(`blur`,function(){return t.markAsTouched()}),e&2&&(Km(`id`,t.id()),Br(`aria-checked`,t.checkedState())(`aria-required`,t.required()?`true`:void 0)(`aria-readonly`,t.readonly()?`true`:void 0)(`aria-invalid`,t.displayValid()===!1?`true`:void 0)(`data-checked`,t.checkedState()?``:void 0)(`data-unchecked`,t.checkedState()?void 0:``)(`data-disabled`,t.isDisabled()?``:void 0)(`data-readonly`,t.readonly()?``:void 0)(`data-required`,t.required()?``:void 0)(`data-invalid`,t.displayValid()===!1?``:void 0)(`data-valid`,t.displayValid()===!0?``:void 0)(`data-touched`,t.touchedState()?``:void 0)(`data-dirty`,t.dirtyState()?``:void 0)(`disabled`,t.isDisabled()?``:void 0))},inputs:{id:[1,`id`],defaultChecked:[1,`defaultChecked`],checked:[1,`checked`],disabled:[1,`disabled`],readonly:[1,`readonly`],required:[1,`required`],name:[1,`name`],form:[1,`form`],submitValue:[1,`value`,`submitValue`],uncheckedValue:[1,`uncheckedValue`],ariaLabelledBy:[1,`aria-labelledby`,`ariaLabelledBy`],ariaLabel:[1,`aria-label`,`ariaLabel`]},outputs:{checked:`checkedChange`,onCheckedChange:`onCheckedChange`},exportAs:[`rdxSwitchRoot`],features:[IS([G(J)]),jI([{directive:Et,inputs:[`value`,`checked`,`disabled`,`disabled`]}]),xm]})}}return i})(),E=(()=>{class i{constructor(){this.rootContext=X()}static{this.ɵfac=function(e){return new(e||i)}}static{this.ɵdir=$I({type:i,selectors:[[`span`,`rdxSwitchThumb`,``]],hostVars:5,hostBindings:function(e,t){e&2&&Br(`data-checked`,t.rootContext.checked()?``:void 0)(`data-unchecked`,t.rootContext.checked()?void 0:``)(`data-disabled`,t.rootContext.disabled()?``:void 0)(`data-readonly`,t.rootContext.readonly()?``:void 0)(`data-required`,t.rootContext.required()?``:void 0)},exportAs:[`rdxSwitchThumb`]})}}return i})()});var P;var K=f(()=>{Kr();j();Kr();P=class i{label=jc.required();on=mj.required();disabled=jc(!1);static ɵfac=function(n){return new(n||i)};static ɵcmp=wc({type:i,selectors:[[`app-filter-switch`]],hostAttrs:[1,`flex`,`items-center`,`gap-2`,`text-[13px]`,`text-ink-300`],inputs:{label:[1,`label`],on:[1,`on`],disabled:[1,`disabled`]},outputs:{on:`onChange`},decls:4,vars:4,consts:[[`type`,`button`,`rdxSwitchRoot`,``,1,`mx-focus`,`relative`,`h-5`,`w-9`,`shrink-0`,`cursor-pointer`,`rounded-full`,`border`,`border-ink-700`,`bg-ink-800`,`transition-colors`,`data-[checked]:border-accent`,`data-[checked]:bg-accent`,`disabled:cursor-not-allowed`,`disabled:opacity-50`,3,`onCheckedChange`,`checked`,`disabled`],[`rdxSwitchThumb`,``,1,`block`,`size-3.5`,`translate-x-[3px]`,`rounded-full`,`bg-ink-400`,`transition-transform`,`data-[checked]:translate-x-[19px]`,`data-[checked]:bg-white`]],template:function(n,e){n&1&&(Oi(0,`button`,0),Jm(`onCheckedChange`,function(d){return e.on.set(d.checked)}),Gm(1,`span`,1),Nc(),Oi(2,`span`),fS(3),Nc()),n&2&&(Wm(`checked`,e.on())(`disabled`,e.disabled()),Br(`aria-label`,e.label()),ec(3),pg(e.label()))},dependencies:[p,E],encapsulation:2})}});export{P as n,K as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{$n as sk,Bn as ok,Cr as zE,D as HE,Dn as kc,En as kE,F as Jm,Fn as nS,G as Nc,Gn as pj,L as Kr,Pt as Wm,Q as Oi,St as Tc,Tn as jc,U as My,Z as Od,Zn as rg,cn as f,et as Ot,fr as wD,g as Dj,gn as gj,gr as wt,ht as SE,it as Pr,l as C,ln as fS,lt as RE,mr as wc,r as Ac,rn as dk,s as Br,sn as ec,w as Gm,z as Ld}from"./chunk-JmNJabM7.js";function $(i,e){i&1&&Gm(0,`li`,6)}function j(i,e){if(i&1){let t=RE();SE(0,$,1,0,`li`,6),Oi(1,`li`,7)(2,`button`,8),Jm(`click`,function(){let o=Ld(t).$implicit;return Od(HE(2).pick(o))})(`keydown`,function(o){Ld(t);return Od(HE(2).onItemKey(o))}),Gm(3,`app-icon`,9),fS(4),Nc()()}if(i&2){let t=e.$implicit,n=HE(2);kE(t.separated?0:-1),ec(),Br(`title`,t.hint??null),ec(),nS(t.danger?n.dangerClass:n.normalClass),Wm(`disabled`,t.disabled===!0),Br(`data-testid`,`menu-`+t.id),ec(),Wm(`name`,t.icon)(`size`,14),ec(),Ac(` `,t.label,` `)}}function P(i,e){if(i&1&&(Oi(0,`ul`,5),kc(1,j,5,9,null,null,U),Nc()),i&2){let t=HE();nS(t.upward()?`bottom-full mb-1.5`:`top-full mt-1.5`),Br(`aria-label`,t.shownLabel()),ec(),Tc(t.items())}}var Q;var U;var V;var G=f(()=>{Kr();sk();dk();Kr();Q=[`trigger`],U=(i,e)=>e.id;V=class i{items=jc.required();label=jc(null);compact=jc(!1,{transform:Dj});picked=pj();shownLabel=Ot(()=>this.label()??ok().shell.actionMenu.label);host=C(Pr);trigger=gj(`trigger`);open=wt(!1);upward=wt(!1);compactTriggerClass=`mx-focus cursor-pointer rounded p-1 text-ink-400 transition-colors hover:bg-ink-800 hover:text-ink-100`;normalClass=`text-ink-200 hover:bg-ink-750 hover:text-ink-100 focus-visible:bg-ink-750 focus-visible:text-ink-100`;dangerClass=`text-danger hover:bg-danger/15 focus-visible:bg-danger/15`;toggle(){let e=!this.open();e&&this.placeMenu(),this.open.set(e),e&&setTimeout(()=>this.focusItem(0))}onOutside(e){this.open()&&!this.host.nativeElement.contains(e.target)&&this.open.set(!1)}onTriggerKey(e){e.key!==`ArrowDown`&&e.key!==`ArrowUp`||(e.preventDefault(),this.placeMenu(),this.open.set(!0),setTimeout(()=>this.focusItem(e.key===`ArrowUp`?-1:0)))}onItemKey(e){if(e.key===`Escape`||e.key===`Tab`){e.key===`Escape`&&e.preventDefault(),this.close();return}if(e.key!==`ArrowDown`&&e.key!==`ArrowUp`)return;e.preventDefault();let n=this.enabledItems().indexOf(document.activeElement);this.focusItem(n===-1?0:n+(e.key===`ArrowDown`?1:-1))}pick(e){this.close(),this.picked.emit(e.id)}placeMenu(){let e=this.trigger()?.nativeElement;if(e===void 0)return;let t=e.getBoundingClientRect(),n=this.items().length*32+24,o=window.innerHeight-t.bottom;this.upward.set(o<n&&t.top>o)}close(){this.open.set(!1),this.trigger()?.nativeElement.focus()}enabledItems(){return[...this.host.nativeElement.querySelectorAll(`[role="menuitem"]:not(:disabled)`)]}focusItem(e){let t=this.enabledItems();t.length!==0&&t[(e+t.length)%t.length].focus()}static ɵfac=function(t){return new(t||i)};static ɵcmp=wc({type:i,selectors:[[`app-action-menu`]],viewQuery:function(t,n){t&1&&rg(n.trigger,Q,5),t&2&&zE()},hostBindings:function(t,n){t&1&&Jm(`pointerdown`,function(a){return n.onOutside(a)},wD)},inputs:{items:[1,`items`],label:[1,`label`],compact:[1,`compact`]},outputs:{picked:`picked`},decls:5,vars:7,consts:[[`trigger`,``],[1,`relative`],[`type`,`button`,`aria-haspopup`,`menu`,`data-testid`,`action-menu`,3,`click`,`keydown`,`title`],[`name`,`menu`,3,`size`],[`role`,`menu`,1,`absolute`,`right-0`,`z-50`,`w-56`,`rounded-md`,`border`,`border-ink-700`,`bg-panel`,`py-1`,`shadow-2xl`,3,`class`],[`role`,`menu`,1,`absolute`,`right-0`,`z-50`,`w-56`,`rounded-md`,`border`,`border-ink-700`,`bg-panel`,`py-1`,`shadow-2xl`],[`role`,`separator`,1,`my-1`,`border-t`,`border-ink-700`],[`role`,`none`],[`type`,`button`,`role`,`menuitem`,1,`mx-focus`,`flex`,`w-full`,`cursor-pointer`,`items-center`,`gap-2`,`px-3`,`py-1.5`,`text-left`,`text-[13px]`,`transition-colors`,`focus-visible:outline-none`,`disabled:cursor-not-allowed`,`disabled:opacity-40`,`disabled:hover:bg-transparent`,3,`click`,`keydown`,`disabled`],[3,`name`,`size`]],template:function(t,n){t&1&&(Oi(0,`div`,1)(1,`button`,2,0),Jm(`click`,function(){return n.toggle()})(`keydown`,function(a){return n.onTriggerKey(a)}),Gm(3,`app-icon`,3),Nc(),SE(4,P,3,3,`ul`,4),Nc()),t&2&&(ec(),nS(n.compact()?n.compactTriggerClass:`mx-btn mx-focus`),Wm(`title`,n.shownLabel()),Br(`aria-expanded`,n.open())(`aria-label`,n.shownLabel()),ec(2),Wm(`size`,n.compact()?15:16),ec(),kE(n.open()?4:-1))},dependencies:[My],encapsulation:2})}});export{V as n,G as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{A as IS,An as lf,B as M,Ct as Tg,F as Jm,Gn as pj,In as nf,It as Ws,L as Kr,Mt as Vr,N as Iw,Nt as W,O as Ho,Pn as mj,Rt as X,Sr as yc,Tn as jc,Vn as on,Xn as rf,Y as OD,_n as gl,cn as f,cr as ve,en as bj,er as sw,et as Ot$1,g as Dj,gr as wt$1,it as Pr,kt as Uw,l as C,nr as te,pn as gb,q as Nn,rt as PS,s as Br,t as $I,tn as br,vr as xm,vt as Se,y as Ej}from"./chunk-JmNJabM7.js";import{l as T$1,n as $n$1,o as Ne}from"./chunk-Bz7JmGk-.js";function at(){let n=T$1()?T$1().getUserAgent():``;return/android (\d+)/.test(n.toLowerCase())}function ut(n){return n==null||ct(n)===0}function ct(n){return n==null?null:Array.isArray(n)||typeof n==`string`?n.length:n instanceof Set?n.size:null}function ht(n){return ut(n.value)?{required:!0}:null}function Ie(n){return null}function ke(n){return n!=null}function ft(n){return yc(n)?on(n):n}function Pe(n){let e={};return n.forEach(t=>{e=t!=null?W(W({},e),t):e}),Object.keys(e).length===0?null:e}function je(n,e){return e.map(t=>t(n))}function mt(n){return!n.validate}function Le(n){return n.map(e=>mt(e)?e:t=>e.validate(t))}function gt(n){if(!n)return null;let e=n.filter(ke);return e.length==0?null:function(t){return Pe(je(t,e))}}function yt(n){return n!=null?gt(Le(n)):null}function pt(n){if(!n)return null;let e=n.filter(ke);return e.length==0?null:function(t){return gb(je(t,e).map(ft)).pipe(Nn(Pe))}}function vt(n){return n!=null?pt(Le(n)):null}function _t(n){return n.tagName===`INPUT`||n.tagName===`SELECT`||n.tagName===`TEXTAREA`}function Ct(n,e,t,r){switch(t){case`name`:n.setAttribute(e,t,r);break;case`disabled`:case`readonly`:case`required`:r?n.setAttribute(e,t,``):n.removeAttribute(e,t);break;case`max`:case`min`:case`minLength`:case`maxLength`:r!==void 0?n.setAttribute(e,t,r.toString()):n.removeAttribute(e,t);break}}function Vt(n){return Object.getPrototypeOf(n.constructor)===ot}function wt(n,e){if(!e)return null;let t,r,i;return e.forEach(o=>{o.constructor===Te?t=o:Vt(o)?r=o:i=o}),i||r||t||null}var Re;var ot;var ae;var st;var lt;var Te;var dt;var ie;var oe;var q;var se;var bt;var Dt;var Be;var z;var Ge=f(()=>{Kr();Kr();Ws();lf();Ne();Re=(()=>{class n{_renderer;_elementRef;onChange=t=>{};onTouched=()=>{};constructor(t,r){this._renderer=t,this._elementRef=r}setProperty(t,r){this._renderer.setProperty(this._elementRef.nativeElement,t,r)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty(`disabled`,t)}static ɵfac=function(r){return new(r||n)(Vr(gl),Vr(Pr))};static ɵdir=$I({type:n})}return n})(),ot=(()=>{class n extends Re{static ɵfac=(()=>{let t;return function(i){return(t||(t=Uw(n)))(i||n)}})();static ɵdir=$I({type:n,features:[xm]})}return n})(),ae=new M(``),st={provide:ae,useExisting:Ho(()=>Te),multi:!0};lt=new M(``),Te=(()=>{class n extends Re{_compositionMode;_composing=!1;constructor(t,r,i){super(t,r),this._compositionMode=i,this._compositionMode??=!at()}writeValue(t){let r=t??``;this.setProperty(`value`,r)}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}static ɵfac=function(r){return new(r||n)(Vr(gl),Vr(Pr),Vr(lt,8))};static ɵdir=$I({type:n,selectors:[[`input`,`formControlName`,``,3,`type`,`checkbox`,3,`ngNoCva`,``],[`textarea`,`formControlName`,``,3,`ngNoCva`,``],[`input`,`formControl`,``,3,`type`,`checkbox`,3,`ngNoCva`,``],[`textarea`,`formControl`,``,3,`ngNoCva`,``],[`input`,`ngModel`,``,3,`type`,`checkbox`,3,`ngNoCva`,``],[`textarea`,`ngModel`,``,3,`ngNoCva`,``],[``,`ngDefaultControl`,``]],hostBindings:function(r,i){r&1&&Jm(`input`,function(s){return i._handleInput(s.target.value)})(`blur`,function(){return i.onTouched()})(`compositionstart`,function(){return i._compositionStart()})(`compositionend`,function(s){return i._compositionEnd(s.target.value)})},standalone:!1,features:[IS([st]),xm]})}return n})();dt=new M(``);ie=class{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(e){this._rawValidators=e||[],this._composedValidatorFn=yt(this._rawValidators)}_setAsyncValidators(e){this._rawAsyncValidators=e||[],this._composedAsyncValidatorFn=vt(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(e){this._onDestroyCallbacks.push(e)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(e=>e()),this._onDestroyCallbacks=[]}reset(e=void 0){this.control?.reset(e)}hasError(e,t){return this.control?this.control.hasError(e,t):!1}getError(e,t){return this.control?this.control.getError(e,t):null}},oe=class{},q=class extends oe{source;constructor(e){super(),this.source=e}};se=class{kind;context;control;message;constructor({kind:e,context:t,control:r}){this.kind=e,this.context=t,this.control=r}},bt=(()=>{class n{_validator=Ie;_onChange;_enabled;ngOnChanges(t){if(this.inputName in t){let r=this.normalizeInput(t[this.inputName].currentValue);this._enabled=this.enabled(r),this._validator=this._enabled?this.createValidator(r):Ie,this._onChange?.()}}validate(t){return this._validator(t)}registerOnValidatorChange(t){this._onChange=t}enabled(t){return t!=null}static ɵfac=function(r){return new(r||n)};static ɵdir=$I({type:n,features:[Iw]})}return n})(),Dt={provide:dt,useExisting:Ho(()=>Be),multi:!0},Be=(()=>{class n extends bt{required;inputName=`required`;normalizeInput=Dj;createValidator=t=>ht;enabled(t){return t}static ɵfac=(()=>{let t;return function(i){return(t||(t=Uw(n)))(i||n)}})();static ɵdir=$I({type:n,selectors:[[``,`required`,``,`formControlName`,``,3,`type`,`checkbox`],[``,`required`,``,`formControl`,``,3,`type`,`checkbox`],[``,`required`,``,`ngModel`,``,3,`type`,`checkbox`]],hostVars:1,hostBindings:function(r,i){r&2&&Br(`required`,i._enabled?``:null)},inputs:{required:`required`},standalone:!1,features:[IS([Dt]),xm]})}return n})();z=class extends ie{_parent=null;name=null;valueAccessor=null;isCustomControlBased=!1;userOnReset;resetSubscription;set onReset(e){this.userOnReset=e,this.resetSubscription?.unsubscribe(),this.resetSubscription=void 0,this.control&&(this.resetSubscription=this.control.events.subscribe(t=>{t instanceof q&&this.control&&this.userOnReset?.(this.control.value)}),this.subscription?.add(this.resetSubscription))}isNativeFormElement=!1;rawValueAccessors;_selectedValueAccessor=null;get selectedValueAccessor(){return this._selectedValueAccessor??=wt(this,this.rawValueAccessors)}parseErrorsValidator=null;renderer;injector;requiredValidatorViaDi;subscription;customControlBindings=null;constructor(e,t,r){super(),this.injector=e,this.renderer=t,this.rawValueAccessors=r,this.injector?.get(ve)?.onDestroy(()=>{this.removeParseErrorsValidator(this.control),this.subscription?.unsubscribe()})}setupCustomControl(){this.subscription?.unsubscribe();let e=this.injector?.get(bj);if(!this.control||!e)return;let t=e.markForCheck.bind(e);this.subscription=new te,this.subscription.add(this.control.valueChanges.subscribe(t)),this.subscription.add(this.control.statusChanges.subscribe(t)),this.resetSubscription?.unsubscribe(),this.resetSubscription=void 0,this.userOnReset&&(this.resetSubscription=this.control.events.subscribe(r=>{r instanceof q&&this.control&&this.userOnReset?.(this.control.value)}),this.subscription.add(this.resetSubscription)),this.parseErrorsValidator&&this.control.addValidators(this.parseErrorsValidator)}ngControlCreate(e){!e.nativeElement.hasAttribute?.(`ngNoCva`)&&(this.rawValueAccessors&&this.rawValueAccessors.length>0||this.valueAccessor!==null)||!e.customControl||(this.isCustomControlBased=!0,e.listenToCustomControlModel(i=>{this.control?.markAsDirty(),this.control?.setValue(i,{emitModelToViewChange:!1}),this.viewToModelUpdate(i)}),e.listenToCustomControlOutput(`touch`,()=>{this.control?.markAsTouched()}),this.customControlBindings={},this.isNativeFormElement=_t(e.nativeElement),this.requiredValidatorViaDi=this._rawValidators.find(i=>i instanceof Be))}ngControlUpdate(e,t){if(!this.isCustomControlBased)return;let r=this.control,i=this.customControlBindings;Object.is(i.value,r.value)||(i.value=r.value,e.setCustomControlModelInput(r.value)),this.bindControlProperty(e,i,`touched`,r.touched),this.bindControlProperty(e,i,`dirty`,r.dirty),this.bindControlProperty(e,i,`valid`,r.valid),this.bindControlProperty(e,i,`invalid`,r.invalid),this.bindControlProperty(e,i,`pending`,r.pending),this.bindControlProperty(e,i,`disabled`,r.disabled),this.shouldBindRequired&&this.bindControlProperty(e,i,`required`,this.isRequired);let o=r.errors;if(i.errors!==o){i.errors=o;let s=this._convertErrors(o);e.setInputOnDirectives(`errors`,s)}}get isRequired(){return(this.requiredValidatorViaDi?._enabled||this.control?._hasRequired())??!1}get shouldBindRequired(){return!0}bindControlProperty(e,t,r,i){if(t[r]===i)return;t[r]=i;let o=e.setInputOnDirectives(r,i);this.isNativeFormElement&&!o&&(r===`disabled`||r===`required`)&&this.renderer&&Ct(this.renderer,e.nativeElement,r,i)}_convertErrors(e){if(e===null)return[];let t=this.control;return Object.entries(e).map(([r,i])=>new se({context:i,kind:r,control:t}))}setParseErrorSource(e){if(e===void 0)return;let t=null,r=Ot$1(()=>{let i=e();return i.length===0?null:i.reduce((o,s)=>(o[s.kind]=s,o),{})});this.parseErrorsValidator=(()=>t).bind(this),rf(()=>{t=r(),this.control?.updateValueAndValidity({emitEvent:!1})},{injector:this.injector})}removeParseErrorsValidator(e){this.parseErrorsValidator&&(e?.removeValidators(this.parseErrorsValidator),e?.updateValueAndValidity({emitEvent:!1}))}}});function At(n){return{provide:ae,useExisting:Ho(()=>n),multi:!0}}function Ln(){return C(Et)}function Mt(n){return n?Object.entries(n).map(([e,t])=>{let r=typeof t==`string`?t:t&&typeof t==`object`&&typeof t.message==`string`?t.message:void 0;return r===void 0?{kind:e}:{kind:e,message:r}}):[]}function St(){let n=C(Se),e=C(ve),t=wt$1(!1,{debugName:`RdxNgControlState.connected`}),r=wt$1(void 0,{debugName:`RdxNgControlState.name`}),i=wt$1(void 0,{debugName:`RdxNgControlState.value`}),o=wt$1(!1,{debugName:`RdxNgControlState.valid`}),s=wt$1(!1,{debugName:`RdxNgControlState.invalid`}),a=wt$1(!1,{debugName:`RdxNgControlState.pending`}),h=wt$1(!1,{debugName:`RdxNgControlState.disabled`}),f=wt$1(null,{debugName:`RdxNgControlState.rawErrors`}),m=Ot$1(()=>Mt(f()),{debugName:`RdxNgControlState.errors`}),l=wt$1(!1,{debugName:`RdxNgControlState.dirty`}),d=wt$1(!1,{debugName:`RdxNgControlState.touched`}),u=!1,g,y;return queueMicrotask(()=>{if(u)return;let D=n.get(z,null,{self:!0,optional:!0}),p=D?.control;if(!p||typeof p.events?.subscribe!=`function`)return;y=v=>p.reset(v);let F=()=>{r.set(D.name==null?void 0:String(D.name)),i.set(p.value),o.set(p.valid),s.set(p.invalid),a.set(p.pending),h.set(p.disabled),f.set(p.errors),l.set(p.dirty),d.set(p.touched)};F();let C=p.events.subscribe(F);g=()=>C.unsubscribe(),t.set(!0)}),e.onDestroy(()=>{u=!0,g?.()}),{connected:t.asReadonly(),name:r.asReadonly(),value:i.asReadonly(),valid:o.asReadonly(),invalid:s.asReadonly(),pending:a.asReadonly(),disabled:h.asReadonly(),errors:m,dirty:l.asReadonly(),touched:d.asReadonly(),reset:D=>y?(y(D),!0):!1}}function Ye(n){return`${Nt}/${n}.md`}function Xe(n,e,t){return`[rdx:${n}] ${e}${t?` See ${Ye(t)}`:``}`}function Bn(n,e,t){!Ej()||Ue.has(n)||(Ue.add(n),console.warn(Xe(n,e,t)))}function N(n,e,t){throw new Error(Xe(n,e,t))}function Gn(n,e){let t=`${n.replace(/\s*Context$/,``)}Context`,r=new M(t);return[(s=!1)=>{let a=C(r,{optional:!0});if(a==null&&!s){let h=e?` See ${Ye(e)} for the required part hierarchy.`:``;throw new Error(`No \`${t}\` found. This part must be placed inside the directive that provides \`${t}\` (usually the primitive's root).${h}`)}return a},s=>({provide:r,useFactory:s})]}function Tt(n){return C(Rt).getId(n)}function kt(n){let e=wt$1(!1),t=Ot$1(()=>{let s=n.errors()??[],a=n.ngControlState?.connected()?n.ngControlState.errors():[];return a.length>0?[...s,...a]:s}),r=Ot$1(()=>n.invalid()||t().length>0||!!(n.ngControlState?.connected()&&n.ngControlState.invalid())),i=Ot$1(()=>(n.pending?.()??!1)||!!(n.ngControlState?.connected()&&n.ngControlState.pending()));return{invalidState:r,pendingState:i,validState:Ot$1(()=>i()?null:r()?!1:n.ngControlState?.connected()&&n.ngControlState.disabled()?null:!0),errorsState:t,touchedState:Ot$1(()=>n.ngControlState?.connected()?n.ngControlState.touched():n.touched()),dirtyState:Ot$1(()=>n.ngControlState?.connected()?n.ngControlState.dirty():n.dirty()||e()),markDirty:()=>e.set(!0),markAsTouched:()=>{n.cva?.markAsTouched(),n.touched.set(!0),n.touch.emit()},resetInteractionState:()=>{n.touched.set(!1),e.set(!1)},resetDirtyState:()=>e.set(!1)}}function Zn(n,e,t){let r=!1,i=!1,o=!1;return{eventDetails:{reason:n,event:e,trigger:t,cancel:()=>{r=!0},isCanceled:()=>r,allowPropagation:()=>{i=!0},get isPropagationAllowed(){return i},preventUnmountOnClose:()=>{o=!0}},shouldPreventUnmountOnClose:()=>o}}function Ze(){let n=new Map;return{emit(e,t){let r=n.get(e);if(r)for(let i of[...r])i(t)},on(e,t){let r=n.get(e);r||(r=new Set,n.set(e,r)),r.add(t)},off(e,t){n.get(e)?.delete(t)}}}function Lt(){return[{provide:k,useFactory:()=>new k},{provide:Je,useExisting:k}]}function Bt(n){return n.context?.open()??!1}function Jn(){return{provide:ce,useFactory:()=>C(ce,{optional:!0,skipSelf:!0})??new ue}}function Qn(n){return{provide:et,useFactory:n}}function Gt(n){return n!==null&&typeof n.nodeType==`number`}function tr(n){return new he(n)}function Wt(n){return`polygon(0% 0%,100% 0%,100% 100%,0% 100%,0% 0%,${n.left}px ${n.top}px,${n.left}px ${n.bottom}px,${n.right}px ${n.bottom}px,${n.right}px ${n.top}px,${n.left}px ${n.top}px)`}function nr(n,e,t){let r=n.ownerDocument,i=t.marker??Ht,o=null,s=()=>{o?.remove(),o=null},a=rf(()=>{let h=t.isOpen(),f=t.shouldRender();if(f&&!o){o=r.createElement(`div`),o.setAttribute(`role`,`presentation`),o.setAttribute(i,``),o.style.position=`fixed`,o.style.inset=`0px`,o.style.userSelect=`none`,o.style.webkitUserSelect=`none`;let m=t.cutout?.()??null;m&&(o.style.clipPath=Wt(m.getBoundingClientRect())),n.parentElement?.insertBefore(o,n)}else f||s();o&&(o.style.pointerEvents=t.passThrough?.()?`none`:``,h?o.removeAttribute(`inert`):o.setAttribute(`inert`,``))},{injector:e});e.get(ve).onDestroy(()=>{a.destroy(),s()})}function $t(n){let{maxTouchPoints:e,webkitBackdropFilter:t}=n,r=n.userAgent.toLowerCase(),i=n.platform.toLowerCase(),o=t,s=!o&&r.includes(`firefox`),a=!o&&r.includes(`chrom`),h=/^i(os$|p)/.test(i)||i===`macintel`&&e>1||/ip(ad|hone|od)/.test(r),f=i===`android`||r.includes(`android`),m=!h&&i.startsWith(`mac`),l=i.startsWith(`win`),d=!f&&/^(linux|chrome os)/.test(i),u=m||h;return{engine:{webkit:o,gecko:s,blink:a},os:{ios:h,android:f,mac:m,windows:l,linux:d,apple:u},screenReader:{voiceOver:u},env:{jsdom:/jsdom|happydom/.test(r)}}}function qt(){let n=typeof navigator>`u`?void 0:navigator;return{userAgent:n?.userAgent??``,platform:n?.platform??``,maxTouchPoints:n?.maxTouchPoints??0,webkitBackdropFilter:typeof CSS<`u`&&CSS.supports?.(`-webkit-backdrop-filter:none`)===!0}}function rr(n=document){let e=n.activeElement;if(e==null)return null;for(;e!=null&&e.shadowRoot!=null&&e.shadowRoot.activeElement!=null;)e=e.shadowRoot.activeElement;return e}function ir(n){return me.engine.webkit&&n.movementX===0&&n.movementY===0}function or(n){let e=C(Pr).nativeElement,t=e.ownerDocument,r=C(ve);if(!t||!$n$1(C(sw)))return zt;let i=[],o,s=[],a=!1,h=!0,f=!1,m=()=>{let u=n.form(),g=u?t.getElementById(u):typeof e.closest==`function`?e.closest(`form`):e.parentElement?.closest(`form`);return g?.localName===`form`?g:null},l=()=>{n.syncNativeControl?.();let u=n.name(),g=n.form(),y=n.disabled(),P=n.hasNativeControl?.()??!1,D=n.value&&n.serialize?n.serialize(n.value()):[];if(!f)return;let F=!!(u&&n.serialize&&!P)?D.length:0;for(;i.length>F;)i.pop()?.remove();for(;i.length<F;){let C=t.createElement(`input`);C.type=`hidden`;let v=i.at(-1);e.parentNode?.insertBefore(C,v?v.nextSibling:e.nextSibling),i.push(C)}for(let C=0;C<i.length;C++){let v=i[C];v.name=u,v.value=D[C],v.disabled=y,g?v.setAttribute(`form`,g):v.removeAttribute(`form`),v.hasAttribute(`data-rdx-native-form-control`)||(v.defaultValue=s[C]??D[C],v.setAttribute(`data-rdx-native-form-control`,``))}};rf(()=>{!a&&n.defaultValue&&(o=n.defaultValue(),s=n.serialize?n.serialize(o):[],a=!0)}),rf(l),OD(()=>{f=!0,Tg(l)});let d=u=>{u.target!==m()||!n.onReset||!a||queueMicrotask(()=>{h&&!u.defaultPrevented&&Tg(()=>n.onReset(o))})};return t.addEventListener(`reset`,d,!0),r.onDestroy(()=>{h=!1,t.removeEventListener(`reset`,d,!0);for(let u of i)u.remove()}),{ownerForm:m,sync:l,requestSubmit:()=>{Tg(l),m()?.requestSubmit()}}}function ge(n){let e=n.ownerDocument.defaultView;if(!e)return!1;let{overflow:t,overflowX:r,overflowY:i,display:o}=e.getComputedStyle(n);return/auto|scroll|overlay|hidden|clip/.test(t+i+r)&&![`inline`,`contents`].includes(o)}function Yt(n){let e=n.defaultView;return e?e.innerWidth-n.documentElement.clientWidth>0:!1}function Xt(n){if(!n.defaultView||typeof CSS>`u`||!CSS.supports||!CSS.supports(`scrollbar-gutter`,`stable`))return!1;let t=n.documentElement,r=ge(t)?t:n.body,i=r.style.overflowY,o=t.style.scrollbarGutter;t.style.scrollbarGutter=`stable`,r.style.overflowY=`scroll`;let s=r.offsetWidth;r.style.overflowY=`hidden`;let a=r.offsetWidth;return r.style.overflowY=i,t.style.scrollbarGutter=o,s===a}function Kt(n){let e=n.documentElement,t=ge(e)?e:n.body,r={overflowX:t.style.overflowX,overflowY:t.style.overflowY};return t.style.overflowX=`hidden`,t.style.overflowY=`hidden`,()=>{t.style.overflowX=r.overflowX,t.style.overflowY=r.overflowY}}function Zt(n){let e=n.documentElement,t=n.body,r=n.defaultView;if(!r)return()=>{};if(me.engine.webkit&&(r.visualViewport?.scale??1)!==1)return()=>{};let i=0,o=0,s=!1,a={},h={},f=``,m=0,l=()=>{let g=r.getComputedStyle(e),y=r.getComputedStyle(t),D=(g.scrollbarGutter||``).includes(`both-edges`)?`stable both-edges`:`stable`;i=e.scrollTop,o=e.scrollLeft,a={scrollbarGutter:e.style.scrollbarGutter,overflowY:e.style.overflowY,overflowX:e.style.overflowX},f=e.style.scrollBehavior,h={position:t.style.position,height:t.style.height,width:t.style.width,boxSizing:t.style.boxSizing,overflowY:t.style.overflowY,overflowX:t.style.overflowX,scrollBehavior:t.style.scrollBehavior};let p=e.scrollHeight>e.clientHeight,F=e.scrollWidth>e.clientWidth,C=g.overflowY===`scroll`||y.overflowY===`scroll`,v=g.overflowX===`scroll`||y.overflowX===`scroll`,ye=Math.max(0,r.innerWidth-t.clientWidth),pe=Math.max(0,r.innerHeight-t.clientHeight),ve=(parseFloat(y.marginTop)||0)+(parseFloat(y.marginBottom)||0),_e=(parseFloat(y.marginLeft)||0)+(parseFloat(y.marginRight)||0),Ce=ge(e)?e:t;if(s=Xt(n),s){e.style.scrollbarGutter=D,Ce.style.overflowY=`hidden`,Ce.style.overflowX=`hidden`;return}Object.assign(e.style,{scrollbarGutter:D,overflowY:`hidden`,overflowX:`hidden`}),(p||C)&&(e.style.overflowY=`scroll`),(F||v)&&(e.style.overflowX=`scroll`),Object.assign(t.style,{position:`relative`,height:ve||pe?`calc(100dvh - ${ve+pe}px)`:`100dvh`,width:_e||ye?`calc(100vw - ${_e+ye}px)`:`100vw`,boxSizing:`border-box`,overflowY:`hidden`,overflowX:`hidden`,scrollBehavior:`unset`}),t.scrollTop=i,t.scrollLeft=o,e.style.scrollBehavior=`unset`},d=()=>{Object.assign(e.style,a),Object.assign(t.style,h),s||(e.scrollTop=i,e.scrollLeft=o,e.style.scrollBehavior=f)},u=()=>{d(),m=r.requestAnimationFrame(l)};return l(),r.addEventListener(`resize`,u),()=>{m&&r.cancelAnimationFrame(m),d(),r.removeEventListener(`resize`,u)}}function Jt(n){let e=$e.get(n);return e||(e=new fe(n),$e.set(n,e)),e}function sr(n,e={}){let t=C(br),r=$n$1(C(sw)),i=null,o=null,s=()=>{i?.(),i=null,o=null};rf(()=>{if(!r)return;let a=e.referenceElement?.()?.ownerDocument??t;n()?(!i||o!==a)&&(s(),i=Jt(a).acquire(),o=a):i&&s()}),r&&C(ve).onDestroy(s)}function ar(n){let e=C(Se),t=C(ve),r=wt$1(void 0),i,o,s,a=0,h=()=>{s!==void 0&&(cancelAnimationFrame(s),s=void 0),o!==void 0&&(clearTimeout(o),o=void 0)},f=(l,d)=>{d===a&&(h(),r.set(void 0),t.destroyed||n(l))},m=(l,d)=>{let u=i,g=u?en(u):0;if(!u||g===0){f(l,d);return}let y=typeof u.getAnimations==`function`?u.getAnimations():[];o=setTimeout(()=>f(l,d),g+Qt),y.length!==0&&Promise.all(y.map(P=>P.finished.catch(()=>{}))).then(()=>f(l,d))};return t.onDestroy(h),{status:r.asReadonly(),registerElement:l=>(i=l,()=>{i===l&&(i=void 0)}),start:l=>{let d=++a;h(),r.set(l?`starting`:`ending`),OD(()=>{t.destroyed||d!==a||(l?s=requestAnimationFrame(()=>{s=void 0,!(t.destroyed||d!==a)&&(r.set(void 0),m(l,d))}):m(l,d))},{injector:e})}}}function en(n){let e=getComputedStyle(n);return Math.max(qe(e.transitionDuration,e.transitionDelay),qe(e.animationDuration,e.animationDelay))}function qe(n,e){let t=n.split(`,`).map(ze),r=e.split(`,`).map(ze);return t.reduce((i,o,s)=>Math.max(i,o+r[s%r.length]),0)}function ze(n){let e=n.trim(),t=Number.parseFloat(e);return Number.isFinite(t)?e.endsWith(`ms`)?t:t*1e3:0}var Et;var Nt;var Ue;var Ft;var Ke;var xt;var Ot;var It;var Wn;var $n;var qn;var zn;var Yn;var Xn;var He;var Rt;var Pt;var Kn;var jt;var k;var Je;var B;var Qe;var le;var T;var ue;var ce;var et;var er;var de;var Ut;var he;var Ht;var me;var zt;var We;var fe;var $e;var Qt;var tn=f(()=>{Kr();Kr();Ge();Ne();Et=(()=>{class n{constructor(){this.valueInput=jc(void 0,{alias:`value`}),this.disabledInput=jc(!1,{alias:`disabled`,transform:Dj}),this.valueChange=pj(),this._value=PS(()=>this.valueInput()),this.value=this._value.asReadonly(),this._disabled=PS(()=>this.disabledInput()),this.disabled=this._disabled.asReadonly()}writeValue(t){Tg(()=>this._value.set(t))}registerOnChange(t){this.onChange=t}registerOnTouched(t){this.onTouched=t}setDisabledState(t){this._disabled.set(t)}setValue(t){this._value.set(t),this.valueChange.emit(t),this.onChange?.(t)}markAsTouched(){this.onTouched?.()}static{this.ɵfac=function(r){return new(r||n)}}static{this.ɵdir=$I({type:n,inputs:{valueInput:[1,`value`,`valueInput`],disabledInput:[1,`disabled`,`disabledInput`]},outputs:{valueChange:`valueChange`},exportAs:[`rdxControlValueAccessor`],features:[IS([At(n)])]})}}return n})();Nt=`https://radix-ng.com`;Ue=new Set;Ft=[`day`,`month`,`year`],Ke=[`hour`,`minute`,`second`,`dayPeriod`],xt=[`literal`,`timeZoneName`],Ot=[...Ft,...Ke],[...Ke],It=[...Ot,...xt],It.filter(n=>n!==`literal`),Wn=`ArrowDown`,$n=`ArrowLeft`,qn=`ArrowRight`,zn=`ArrowUp`,Yn=`End`,Xn=`Home`,He=new Map,Rt=(()=>{class n{constructor(){this.appId=C(nf)}getId(t){let r=this.appId===`ng`?t:t+this.appId,i=He.get(r)??0;return He.set(r,i+1),`${r}${i}`}static{this.ɵfac=function(r){return new(r||n)}}static{this.ɵprov=X({token:n,factory:n.ɵfac,providedIn:`root`})}}return n})();Pt=new M(`RdxFieldValidity`),Kn=(()=>{class n{constructor(){this.invalid=jc(!1,{transform:Dj}),this.pending=jc(!1,{transform:Dj}),this.touched=mj(!1),this.dirty=jc(!1,{transform:Dj}),this.errors=jc([]),this.touch=pj(),this.ngControlState=St(),this.formUi=kt({invalid:this.invalid,pending:this.pending,errors:this.errors,touched:this.touched,touch:this.touch,dirty:this.dirty,ngControlState:this.ngControlState,cva:this.formUiTouchTarget()}),this.validationErrors=this.formUi.errorsState,this.fieldValidity=C(Pt,{optional:!0}),this.displayValid=Ot$1(()=>this.fieldValidity?this.fieldValidity():this.formUi.validState()),rf(()=>{if(this.ngControlState.connected()){this.touched.set(this.ngControlState.touched()),this.ngControlState.dirty()||this.formUi.resetDirtyState?.();return}this.dirty()||this.formUi.resetDirtyState?.()},{debugName:`RdxFormUiControlBase.syncInteractionState`})}formUiTouchTarget(){return null}resetNgControl(t){return this.ngControlState.reset(t)}reset(){this.formUi.resetInteractionState?.()}static{this.ɵfac=function(r){return new(r||n)}}static{this.ɵdir=$I({type:n,inputs:{invalid:[1,`invalid`],pending:[1,`pending`],touched:[1,`touched`],dirty:[1,`dirty`],errors:[1,`errors`]},outputs:{touched:`touchedChange`,touch:`touch`}})}}return n})();jt=`utils/floating-tree`,k=class{constructor(){this._state=wt$1({status:`pending`}),this.status=Ot$1(()=>this._state().status),this.tree=Ot$1(()=>{let e=this._state();return e.status===`registered`?e.tree:null}),this.node=Ot$1(()=>{let e=this._state();return e.status===`registered`?e.node:null})}register(e,t){t.tree!==e&&N(`floating/registration-mismatch`,`register(tree, node): node.tree must equal tree. Node "${t.id}" belongs to a different tree.`,jt),this._state.set({status:`registered`,tree:e,node:t})}markDetached(){this._state.set({status:`detached`})}clear(){this._state.set({status:`pending`})}},Je=new M(`RdxFloatingRegistration`);B=new WeakMap,Qe=Symbol(`RdxFloatingNode`),le=class{constructor(e,t,r,i,o){this.id=t,e!==Qe&&N(`floating/direct-node-construction`,`RdxFloatingNode is created only by RdxFloatingTree.register().`,T),this.tree=r,B.set(this,{parent:i,context:o})}get parent(){return B.get(this).parent}get context(){return B.get(this).context}},T=`utils/floating-tree`;ue=class{constructor(){this.events=Ze(),this.nodeSet=new Set,this.childrenOf=new Map}register(e){this.assertRegisterableParent(e.parent),Ej()&&this.assertContextDocument(e.context,this.nearestContext(e.parent));let t=new le(Qe,e.id,this,e.parent,e.context);return this.nodeSet.add(t),this.addToChildrenOf(e.parent,t),t}unregister(e){Ej()&&this.assertOwnedNode(e),this.nodeSet.delete(e),this.removeFromChildrenOf(e.parent,e)}setContext(e,t){if(this.assertOwnedNode(e),Ej()&&t!==null){this.assertContextDocument(t,this.nearestContext(e.parent));for(let r of this.descendantContexts(e))this.assertContextDocument(t,r)}B.get(e).context=t}setParent(e,t){if(this.assertOwnedNode(e),this.assertRegisterableParent(t),e.parent===t)return;for(let i=t;i!==null&&this.nodeSet.has(i);i=i.parent)i===e&&N(`floating/parent-cycle`,`Reparenting node "${e.id}" under "${t?.id}" creates an ancestry cycle.`,T);Ej()&&this.assertSubtreeDocuments(e,t);let r=e.parent;B.get(e).parent=t,this.removeFromChildrenOf(r,e),this.addToChildrenOf(t,e)}children(e,t={}){Ej()&&this.assertOwnedNode(e);let r=t.onlyOpen??!0,i=[],o=s=>{for(let a of this.directChildren(s))(!r||Bt(a))&&i.push(a),o(a)};return o(e),i}ancestors(e){Ej()&&this.assertOwnedNode(e);let t=[];for(let r=e.parent;r!==null&&this.nodeSet.has(r);r=r.parent)t.push(r);return t}get all(){return[...this.nodeSet]}directChildren(e){return this.childrenOf.get(e)??[]}addToChildrenOf(e,t){let r=this.childrenOf.get(e);r||(r=[],this.childrenOf.set(e,r)),r.push(t)}removeFromChildrenOf(e,t){let r=this.childrenOf.get(e);if(!r)return;let i=r.indexOf(t);i!==-1&&r.splice(i,1),r.length===0&&this.childrenOf.delete(e)}nearestContext(e){for(let t=e;t!==null&&this.nodeSet.has(t);t=t.parent)if(t.context!==null)return t.context;return null}descendantContexts(e){return this.children(e,{onlyOpen:!1}).map(t=>t.context).filter(t=>t!==null)}assertSubtreeDocuments(e,t){let r=this.nearestContext(t);this.assertContextDocument(e.context,r);for(let i of this.descendantContexts(e))this.assertContextDocument(i,r)}isRegistered(e){return this.nodeSet.has(e)}assertOwnedNode(e){(e.tree!==this||!this.nodeSet.has(e))&&N(`floating/foreign-node`,`This node does not belong to this tree (or was already unregistered).`,T)}assertRegisterableParent(e){e!==null&&(e.tree!==this&&N(`floating/cross-tree-parent`,`A floating node parent must belong to the same tree.`,T),this.nodeSet.has(e)||N(`floating/unregistered-parent`,`A floating node parent must be currently registered in the tree.`,T))}assertContextDocument(e,t){e!==null&&t!==null&&e.ownerDocument!==t.ownerDocument&&N(`floating/cross-document-parent`,`A floating node must share the same ownerDocument as its ancestry/subtree.`,T)}},ce=new M(`RdxFloatingTree`);et=new M(`RdxFloatingRootContext`);er=(()=>{class n{constructor(){this.externalTree=jc(null),this.parentOverride=jc({kind:`inherit`}),this.selfReg=C(k),this.parentReg=C(Je,{optional:!0,skipSelf:!0}),this.ambientTree=C(ce,{optional:!0}),this.rootContext=C(et,{optional:!0}),this.nodeId=Tt(`rdx-floating-node-`),this.node=this.selfReg.node,this.status=this.selfReg.status,this.tree=this.selfReg.tree,rf(t=>{let r=this.parentOverride();if(r.kind===`inherit`&&this.parentReg?.status()===`pending`)return;let i=r.kind===`node`?r.parent:r.kind===`root`?null:this.parentReg?.node()??null,o=(r.kind===`node`?r.parent.tree:null)??this.externalTree()??this.parentReg?.tree()??this.ambientTree;if(!o){this.selfReg.markDetached();return}let s=o.register({id:this.nodeId,parent:i,context:this.rootContext});this.selfReg.register(o,s),t(()=>{o.unregister(s),this.selfReg.clear()})})}static{this.ɵfac=function(r){return new(r||n)}}static{this.ɵdir=$I({type:n,selectors:[[``,`rdxFloatingNode`,``]],inputs:{externalTree:[1,`externalTree`],parentOverride:[1,`parentOverride`]},exportAs:[`rdxFloatingNode`],features:[IS([Lt()])]})}}return n})(),de=class{constructor(){this.elements=new Set}add(e){this.elements.add(e)}delete(e){this.elements.delete(e)}hasElement(e){return e!==null&&this.elements.has(e)}hasMatchingElement(e){if(!e)return!1;for(let t of this.elements)if(t.contains(e))return!0;return!1}contains(e){return this.hasElement(e)?!0:this.hasMatchingElement(Gt(e)?e:null)}};Ut=`utils/floating-tree`,he=class{constructor(e){this.triggers=new de,this.events=Ze(),this.floatingElementRef=null,this.referenceElementRef=null,this.floatingElementsRef=new Set,this.ownerDocument=e.ownerDocument,this.open=e.open??(()=>!1),e.floatingElement!==void 0&&this.setFloatingElement(e.floatingElement),e.referenceElement!==void 0&&this.setReferenceElement(e.referenceElement)}get floatingElement(){return this.floatingElementRef}get referenceElement(){return this.referenceElementRef}get floatingElements(){return this.floatingElementsRef}setFloatingElement(e){this.assertSameDocument(e),this.floatingElementRef&&this.floatingElementsRef.delete(this.floatingElementRef),this.floatingElementRef=e,e&&this.floatingElementsRef.add(e)}addFloatingElement(e){this.assertSameDocument(e),this.floatingElementsRef.add(e)}removeFloatingElement(e){this.floatingElementsRef.delete(e)}setReferenceElement(e){this.assertSameDocument(e),this.referenceElementRef=e}assertSameDocument(e){Ej()&&e!==null&&e.ownerDocument!==this.ownerDocument&&N(`floating/cross-document-element`,`A floating element must share its root context's ownerDocument.`,Ut)}};Ht=`data-rdx-internal-backdrop`;me=$t(qt());zt={ownerForm:()=>null,sync:()=>{},requestSubmit:()=>{}};We=`data-rdx-scroll-locked`;fe=class{constructor(e){this.doc=e,this.lockCount=0,this.restore=null,this.release=()=>{this.lockCount!==0&&(this.lockCount-=1,this.lockCount===0&&this.restore&&(this.restore(),this.restore=null))}}acquire(){return this.lockCount+=1,this.lockCount===1&&this.restore===null&&this.lock(),this.release}lock(){let e=this.doc.documentElement,t=this.doc.defaultView,r=t?t.getComputedStyle(e).overflowY:``;if(r===`hidden`||r===`clip`)this.restore=()=>{};else{let s=me.os.ios||!Yt(this.doc)?Kt(this.doc):Zt(this.doc);this.restore=s}e.setAttribute(We,``);let i=this.restore;this.restore=()=>{i(),e.removeAttribute(We)}}},$e=new WeakMap;Qt=50});export{qn as C,tr as D,tn as E,zn as O,or as S,sr as T,er as _,Je as a,me as b,Ln as c,Wn as d,Xn as f,en as g,ar as h,Gn as i,Qn as l,Zn as m,Bn as n,Jn as o,Yn as p,Et as r,Kn as s,$n as t,Tt as u,et as v,rr as w,nr as x,ir as y};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./chunk-JmNJabM7.js";import"./chunk-CRyY-2KM.js";import{n as ro,t as Ql}from"./chunk-DSQAF8Vk.js";Ql();export{ro as TerminalView};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{$n as sk,A as IS,B as M,Bn as ok,Cn as ik,Ct as Tg,D as HE,Dn as kc,En as kE,F as Jm,G as Nc,Gn as pj,I as Km,L as Kr,Nt as W$1,Pn as mj,Pt as Wm,Q as Oi,St as Tc,Tn as jc,U as My,Wn as pg,Xn as rf,Y as OD,Z as Od,bt as TE,cn as f,cr as ve$1,et as Ot$1,f as Cj,g as Dj,gr as wt,ht as SE,it as Pr,jn as lk,l as C,ln as fS,lt as RE,mr as wc,on as eH,r as Ac,rn as dk,rt as PS,s as Br,sn as ec,t as $I,w as Gm,wn as jI,x as G,y as Ej,z as Ld}from"./chunk-JmNJabM7.js";import{n as he$1,t as W$2}from"./chunk-ZkkhKXw6.js";import{C as qn,E as tn,O as zn,d as Wn,f as Xn,h as ar,i as Gn,m as Zn,n as Bn,p as Yn,t as $n,u as Tt,y as ir}from"./chunk-DCF2sSJN.js";import{r as g,t as L}from"./chunk-BFURpTzq.js";function Ft(e){let n=C(ie);return Ot$1(()=>e?.()??n())}var ie;var Pt=f(()=>{Kr();ie=new M(`RDX_DIRECTION`,{providedIn:`root`,factory:()=>Ot$1(()=>`ltr`)})});function Kt(){return C(St,{optional:!0,self:!0})}function Bt(e){return{provide:St,useFactory:e}}function Wt(e,n){let t=e.compareDocumentPosition(n);return t&Node.DOCUMENT_POSITION_FOLLOWING||t&Node.DOCUMENT_POSITION_CONTAINED_BY?-1:t&Node.DOCUMENT_POSITION_PRECEDING||t&Node.DOCUMENT_POSITION_CONTAINS?1:0}function de(e){return[...e].filter(n=>n.element.isConnected).sort((n,t)=>Wt(n.element,t.element))}function le(e){let n=new Set;for(let t=1;t<e.length;t+=1){let i=ue(e[t-1],e[t]);i&&n.add(i)}return n}function ue(e,n){let t=e.parentElement;for(;t&&!t.contains(n);)t=t.parentElement;return t}function ce(e){let n=new Set;for(let t of e){for(let i=0;i<t.addedNodes.length;i+=1)if(n.has(t.addedNodes[i]))return!0;for(let i=0;i<t.removedNodes.length;i+=1)n.add(t.removedNodes[i])}for(let t of n)if(t.isConnected)return!0;return!1}function he(e,n){return re.some(t=>!n.includes(t)&&e.getModifierState(t))}function At(e){if(!(e instanceof HTMLElement))return!1;if(e.tagName===`TEXTAREA`)return!0;if(e.tagName!==`INPUT`)return!1;try{return e.selectionStart!=null}catch{return!1}}function zt(e,n){let t=n===`rtl`?$n:qn,i=n===`rtl`?qn:$n;return{forwardKeys:e===`horizontal`?[t]:e===`vertical`?[Wn]:[t,Wn],backwardKeys:e===`horizontal`?[i]:e===`vertical`?[zn]:[i,zn]}}function me(e,n,t,i){let{forwardKeys:o,backwardKeys:s}=zt(t,i),a=n.selectionStart,l=n.selectionEnd,r=n.value??``;return!!(a==null||l==null||e.shiftKey||a!==l||!s.includes(e.key)&&a<r.length||!o.includes(e.key)&&a>0)}function Lt(e,n){return n<0||n>=e.length}function Vt(e,n){return ot(e,{startingIndex:-1,disabledIndices:n})}function pe(e,n){return ot(e,{startingIndex:e.length,decrement:!0,disabledIndices:n})}function ot(e,n={}){let{startingIndex:t=-1,decrement:i=!1,disabledIndices:o}=n,s=i?-1:1;for(let a=t+s;a>=0&&a<e.length;a+=s)if(!$t(e,a,o))return a;return-1}function $t(e,n,t){if(t?.includes(n))return!0;let i=e[n];return i?!ge(i)||i.matches(`:disabled`)?!0:t===void 0&&(i.hasAttribute(`disabled`)||i.getAttribute(`aria-disabled`)===`true`):!1}function fe(e){return e===null||e.hasAttribute(`disabled`)||e.getAttribute(`aria-disabled`)===`true`}function ge(e){if(!e||!e.isConnected)return!1;if(typeof Element<`u`&&!(e instanceof Element))return!0;let n;try{n=getComputedStyle(e)}catch{return!0}return n.visibility!==`hidden`&&n.visibility!==`collapse`}function be(e,n,t,i){if(!e||!n||typeof e.scrollTo!=`function`)return;let o=e.clientWidth<e.scrollWidth,s=e.clientHeight<e.scrollHeight,a=e.scrollLeft,l=e.scrollTop;if(o&&i!==`vertical`){let r=Ot(e,n,`left`),d=J(e),p=J(n);t===`ltr`&&(r+n.offsetWidth+p.scrollMarginRight>e.scrollLeft+e.clientWidth-d.scrollPaddingRight?a=r+n.offsetWidth+p.scrollMarginRight-e.clientWidth+d.scrollPaddingRight:r-p.scrollMarginLeft<e.scrollLeft+d.scrollPaddingLeft&&(a=r-p.scrollMarginLeft-d.scrollPaddingLeft)),t===`rtl`&&(r-p.scrollMarginRight<e.scrollLeft+d.scrollPaddingLeft?a=r-p.scrollMarginLeft-d.scrollPaddingLeft:r+n.offsetWidth+p.scrollMarginRight>e.scrollLeft+e.clientWidth-d.scrollPaddingRight&&(a=r+n.offsetWidth+p.scrollMarginRight-e.clientWidth+d.scrollPaddingRight))}if(s&&i!==`horizontal`){let r=Ot(e,n,`top`),d=J(e),p=J(n);r-p.scrollMarginTop<e.scrollTop+d.scrollPaddingTop?l=r-p.scrollMarginTop-d.scrollPaddingTop:r+n.offsetHeight+p.scrollMarginBottom>e.scrollTop+e.clientHeight-d.scrollPaddingBottom&&(l=r+n.offsetHeight+p.scrollMarginBottom-e.clientHeight+d.scrollPaddingBottom)}e.scrollTo({left:a,top:l,behavior:`auto`})}function Ot(e,n,t){let i=t===`left`?`offsetLeft`:`offsetTop`,o=0,s=n;for(;s?.offsetParent&&(o+=s[i],s.offsetParent!==e);)s=s.offsetParent;return o}function J(e){let n=getComputedStyle(e);return{scrollMarginTop:parseFloat(n.scrollMarginTop)||0,scrollMarginRight:parseFloat(n.scrollMarginRight)||0,scrollMarginBottom:parseFloat(n.scrollMarginBottom)||0,scrollMarginLeft:parseFloat(n.scrollMarginLeft)||0,scrollPaddingTop:parseFloat(n.scrollPaddingTop)||0,scrollPaddingRight:parseFloat(n.scrollPaddingRight)||0,scrollPaddingBottom:parseFloat(n.scrollPaddingBottom)||0,scrollPaddingLeft:parseFloat(n.scrollPaddingLeft)||0}}var St;var se;var jt;var ae;var re;var ve;var st;var xe;var W;var O;var ye;var at;var Ie;var z;var Z;var rt=f(()=>{Kr();Kr();tn();Pt();St=new M(`RdxCompositeItemOwner`);se=`data-composite-item-active`,jt=new Set([zn,Wn,$n,qn]),ae=new Set([...jt,Xn,Yn]),re=[`Shift`,`Control`,`Alt`,`Meta`];ve=()=>{let e=C(W);return{listElement:e.elementRef.nativeElement,items:e.items,itemMap:e.itemMap,registerItem:n=>e.registerItem(n),indexOf:n=>e.indexOf(n)}},[st,xe]=Gn(`RdxCompositeListContext`,`utils/composite`),W=(()=>{class e{constructor(){this.elementRef=C(Pr),this.registrations=new Map,this.registrationTick=wt(0),this.reorderTick=wt(0),this.onMapChange=pj(),this.items=Ot$1(()=>(this.reorderTick(),this.registrationTick(),de([...this.registrations.values()]))),this.indexMap=Ot$1(()=>{let t=new Map;return this.items().forEach((i,o)=>{t.set(i.element,o)}),t}),this.itemMap=Ot$1(()=>{let t=new Map;return this.items().forEach((i,o)=>{t.set(i.element,G(W$1({},i.metadata()??{}),{index:o}))}),t}),rf(()=>{this.onMapChange.emit(this.itemMap())}),this.observeItemReordering()}observeItemReordering(){typeof MutationObserver==`function`&&rf(t=>{let i=this.items().map(a=>a.element);if(i.length<2)return;let o=le(i);if(o.size===0)return;let s=new MutationObserver(a=>{if(!ce(a))return;let l=null;for(let r of i)if(r.isConnected){if(l&&Wt(l,r)>0){s.disconnect(),this.reorderTick.update(d=>d+1);return}l=r}});o.forEach(a=>s.observe(a,{childList:!0})),t(()=>s.disconnect())})}registerItem(t){return this.registrations.set(t.element,t),this.registrationTick.update(i=>i+1),()=>{this.registrations.get(t.element)===t&&(this.registrations.delete(t.element),this.registrationTick.update(i=>i+1))}}indexOf(t){return this.indexMap().get(t)??-1}elements(){return this.items().map(t=>t.element)}static{this.ɵfac=function(i){return new(i||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxCompositeList`,``]],outputs:{onMapChange:`onMapChange`},exportAs:[`rdxCompositeList`],features:[IS([xe(ve)])]})}}return e})(),O=(()=>{class e{constructor(){this.owner=Kt(),this.injectedListContext=this.owner?null:st(!0),this.elementRef=C(Pr),this.hasRendered=wt(!1),this.listContext=Ot$1(()=>this.owner?this.owner.listContext():this.injectedListContext),this.metadataInput=jc(void 0,{alias:`metadata`}),this._metadata=PS(()=>this.metadataInput()),this.index=Ot$1(()=>this.listContext()?.indexOf(this.elementRef.nativeElement)??-1),this.inListElement=Ot$1(()=>this.isInListElement(this.listContext())),OD(()=>{this.hasRendered.set(!0)}),rf(t=>{let i=this.listContext();if(!i||!this.hasRendered()||!this.isInListElement(i))return;let o=this.elementRef.nativeElement;t(Tg(()=>i.registerItem({element:o,metadata:this._metadata.asReadonly()})))})}setMetadata(t){this._metadata.set(t)}isInListElement(t){return!!t&&t.listElement.contains(this.elementRef.nativeElement)}static{this.ɵfac=function(i){return new(i||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxCompositeListItem`,``]],inputs:{metadataInput:[1,`metadata`,`metadataInput`]},exportAs:[`rdxCompositeListItem`]})}}return e})(),ye=()=>{let e=C(z);return{rootElement:e.elementRef.nativeElement,highlightedIndex:e.highlightedIndex.asReadonly(),highlightItemOnHover:e.highlightItemOnHover,orientation:e.orientation,dir:e.dir,isIndexDisabled:n=>e.isIndexDisabled(n),setHighlightedIndex:(n,t)=>e.setHighlightedIndex(n,t),relayKeyboardEvent:n=>e.relayKeyboardEvent(n)}},[at,Ie]=Gn(`RdxCompositeRootContext`,`utils/composite`),z=(()=>{class e{constructor(){this.elementRef=C(Pr),this.compositeList=C(W,{self:!0}),this.hasSetInitialIndex=!1,this.orientationInput=jc(`both`,{alias:`orientation`}),this._orientation=PS(()=>this.orientationInput()),this.orientation=this._orientation.asReadonly(),this.dirInput=jc(void 0,{alias:`dir`}),this.effectiveDir=Ft(this.dirInput),this._dir=PS(()=>this.effectiveDir()),this.dir=this._dir.asReadonly(),this.loopFocusInput=jc(!0,{alias:`loopFocus`,transform:Dj}),this._loopFocus=PS(()=>this.loopFocusInput()),this.loopFocus=this._loopFocus.asReadonly(),this.enableHomeAndEndKeysInput=jc(!1,{alias:`enableHomeAndEndKeys`,transform:Dj}),this._enableHomeAndEndKeys=PS(()=>this.enableHomeAndEndKeysInput()),this.enableHomeAndEndKeys=this._enableHomeAndEndKeys.asReadonly(),this.disabledIndicesInput=jc(void 0,{alias:`disabledIndices`}),this._disabledIndices=PS(()=>this.disabledIndicesInput()),this.disabledIndices=this._disabledIndices.asReadonly(),this.modifierKeysInput=jc([],{alias:`modifierKeys`}),this._modifierKeys=PS(()=>this.modifierKeysInput()),this.modifierKeys=this._modifierKeys.asReadonly(),this.highlightItemOnHover=jc(!1,{transform:Dj}),this.stopEventPropagation=jc(!0,{transform:Dj}),this.highlightedIndex=mj(0),this.onHighlightedIndexChange=pj(),this.onMapChange=pj(),this.items=this.compositeList.items,this.itemMap=this.compositeList.itemMap,rf(()=>{let t=this.items();if(t.length!==0){if(!this.hasSetInitialIndex){this.hasSetInitialIndex=!0;let i=t.findIndex(o=>o.element.hasAttribute(se));if(i!==-1){this.setHighlightedIndex(i,!0);return}this.moveHighlightOffDisabledItem();return}this.disabledIndices()!=null&&this.moveHighlightOffDisabledItem()}}),rf(()=>{this.onMapChange.emit(this.itemMap())})}moveHighlightOffDisabledItem(){if(!this.isIndexDisabled(this.highlightedIndex()))return;let t=this.elements(),i=Vt(t,this.disabledIndices());Lt(t,i)||this.setHighlightedIndex(i)}indexOf(t){return this.compositeList.indexOf(t)}setOrientation(t){this._orientation.set(t)}setLoopFocus(t){this._loopFocus.set(t)}setDir(t){this._dir.set(t)}setEnableHomeAndEndKeys(t){this._enableHomeAndEndKeys.set(t)}setDisabledIndices(t){this._disabledIndices.set(t)}setModifierKeys(t){this._modifierKeys.set(t)}isIndexDisabled(t){return $t(this.elements(),t,this.disabledIndices())}setHighlightedIndex(t,i=!1){this.highlightedIndex()!==t&&(this.highlightedIndex.set(t),this.onHighlightedIndexChange.emit(t)),i&&be(this.elementRef.nativeElement,this.elements()[t],this.dir(),this.orientation())}relayKeyboardEvent(t){this.handleCompositeKeydown(t,!0)}handleKeydown(t){this.handleCompositeKeydown(t,!1)}handleFocusIn(t){let i=t.target;At(i)&&i.setSelectionRange(0,i.value.length)}handleCompositeKeydown(t,i){if(!(this.enableHomeAndEndKeys()?ae:jt).has(t.key)||he(t,this.modifierKeys()))return;let s=t.target,a=this.elementRef.nativeElement;if(!i&&s instanceof HTMLElement){let d=s.closest(`[rdxCompositeRoot]`);if(d&&d!==a)return}if(At(s)&&!fe(s))try{if(me(t,s,this.orientation(),this.dir()))return}catch{return}let l=this.elements();if(l.length===0)return;let r=this.getNextIndex(t,l);r===this.highlightedIndex()||Lt(l,r)||(this.stopEventPropagation()&&t.stopPropagation(),t.preventDefault(),this.setHighlightedIndex(r,!0),queueMicrotask(()=>{this.elements()[r]?.focus()}))}getNextIndex(t,i){let o=this.highlightedIndex(),s=Vt(i,this.disabledIndices()),a=pe(i,this.disabledIndices());if(this.enableHomeAndEndKeys()){if(t.key===`Home`)return s;if(t.key===`End`)return a}let{forwardKeys:l,backwardKeys:r}=zt(this.orientation(),this.dir()),d=l.includes(t.key),p=r.includes(t.key);if(!d&&!p)return o;let E=p,Xt=E?s:a,Yt=E?a:s;return this.loopFocus()&&o===Xt?Yt:ot(i,{startingIndex:o,decrement:E,disabledIndices:this.disabledIndices()})}elements(){return this.compositeList.elements()}static{this.ɵfac=function(i){return new(i||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxCompositeRoot`,``]],hostBindings:function(i,o){i&1&&Jm(`keydown`,function(a){return o.handleKeydown(a)})(`focusin`,function(a){return o.handleFocusIn(a)})},inputs:{orientationInput:[1,`orientation`,`orientationInput`],dirInput:[1,`dir`,`dirInput`],loopFocusInput:[1,`loopFocus`,`loopFocusInput`],enableHomeAndEndKeysInput:[1,`enableHomeAndEndKeys`,`enableHomeAndEndKeysInput`],disabledIndicesInput:[1,`disabledIndices`,`disabledIndicesInput`],modifierKeysInput:[1,`modifierKeys`,`modifierKeysInput`],highlightItemOnHover:[1,`highlightItemOnHover`],stopEventPropagation:[1,`stopEventPropagation`],highlightedIndex:[1,`highlightedIndex`]},outputs:{highlightedIndex:`highlightedIndexChange`,onHighlightedIndexChange:`onHighlightedIndexChange`,onMapChange:`onMapChange`},exportAs:[`rdxCompositeRoot`],features:[IS([Ie(ye)]),jI([W])]})}}return e})(),Z=(()=>{class e{constructor(){this.owner=Kt(),this.injectedRootContext=this.owner?null:at(!0),this.listItem=C(O,{self:!0}),this.elementRef=C(Pr),this.rootContext=Ot$1(()=>this.owner?this.owner.rootContext():this.injectedRootContext),this.index=this.listItem.index,this.tabIndex=Ot$1(()=>{let t=this.rootContext();if(!this.isInRootElement(t))return null;let i=this.index();return i!==-1&&t.highlightedIndex()===i&&!t.isIndexDisabled(i)?0:-1})}setMetadata(t){this.listItem.setMetadata(t)}handleFocus(){let t=this.rootContext(),i=this.index();i!==-1&&this.isInRootElement(t)&&t.setHighlightedIndex(i)}handleMouseMove(t){if(ir(t))return;let i=this.rootContext(),o=this.index();!this.isInRootElement(i)||o===-1||!i.highlightItemOnHover()||i.highlightedIndex()===o||i.isIndexDisabled(o)||this.elementRef.nativeElement.focus()}isInRootElement(t){return!!t&&t.rootElement.contains(this.elementRef.nativeElement)}static{this.ɵfac=function(i){return new(i||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxCompositeItem`,``]],hostVars:1,hostBindings:function(i,o){i&1&&Jm(`focus`,function(){return o.handleFocus()})(`mousemove`,function(a){return o.handleMouseMove(a)}),i&2&&Br(`tabindex`,o.tabIndex())},exportAs:[`rdxCompositeItem`],features:[jI([{directive:O,inputs:[`metadata`,`metadata`]}])]})}}return e})()});function qt(e,n){return`${e}-tab-${n}`}function Ut(e,n){return`${e}-panel-${n}`}function De(e){return typeof e.disabled==`boolean`&&typeof e.id==`string`&&Object.prototype.hasOwnProperty.call(e,`value`)}function Te(e,n){for(let t of e.values())if(t.value===n)return t}function Ne(e){for(let n of e.values())if(!n.disabled)return n.value}function ke(e,n,t,i){if(e==null||n==null)return`none`;let o=null,s=null,a=-1,l=-1;for(let[p,E]of i.entries())if(E.value===e&&(o=p,a=E.index),E.value===n&&(s=p,l=E.index),o&&s)break;if(!o||!s||a===l)return Fe(e,n,t);let r=o.getBoundingClientRect(),d=s.getBoundingClientRect();return t===`horizontal`?d.left<r.left?`left`:d.left>r.left||l>a?`right`:`left`:d.top<r.top?`up`:d.top>r.top||l>a?`down`:`up`}function Fe(e,n,t){return e!==n&&typeof e==`number`&&typeof n==`number`||e!==n&&typeof e==`string`&&typeof n==`string`?t===`horizontal`?n>e?`right`:`left`:n>e?`down`:`up`:`none`}function Ae(){return Bt(Pe)}var tt;var Me;var fi;var Re;var _e;var Ee;var we;var Pe;var gi;var Le=f(()=>{Kr();Kr();tn();rt();rt();g();[tt,Me]=Gn(`RdxTabsRootContext`,`components/tabs`);fi=(()=>{class e{constructor(){this.rootContext=tt(),this.elementRef=C(Pr),this.compositeRoot=C(z,{self:!0}),this.compositeRootContext=at(),this.compositeListContext=st(),this.activateOnFocus=jc(!1,{transform:Dj}),this.loopFocus=jc(!0,{transform:Dj}),this.tabMap=Ot$1(()=>{let i=new Map;return this.compositeRoot.itemMap().forEach((o,s)=>{De(o)&&i.set(s,o)}),i}),this.tabMetadata=Ot$1(()=>Array.from(this.tabMap().values())),this.disabledIndices=Ot$1(()=>this.tabMetadata().filter(i=>i.disabled).map(i=>i.index)),this.activeIndex=Ot$1(()=>{let i=this.rootContext.value();return this.tabMetadata().find(s=>s.value===i)?.index??-1});let t=this.rootContext.registerTabList(this.elementRef.nativeElement,this.compositeRootContext,this.compositeListContext);C(ve$1).onDestroy(t),this.compositeRoot.setEnableHomeAndEndKeys(!0),this.compositeRoot.setDisabledIndices([]),rf(()=>{this.compositeRoot.setOrientation(this.rootContext.orientation()),this.compositeRoot.setLoopFocus(this.loopFocus())}),rf(()=>{this.rootContext.setTabMap(this.tabMap())}),rf(()=>{let i=this.activeIndex();if(i===-1)return;let o=this.elementRef.nativeElement,s=o.ownerDocument.activeElement;if(!(s&&o.contains(s))){if(this.disabledIndices().includes(i)){let a=this.tabMetadata().find(l=>!l.disabled)?.index;a!==void 0&&this.compositeRoot.setHighlightedIndex(a);return}this.compositeRoot.setHighlightedIndex(i)}}),rf(()=>this.rootContext.setActivateOnFocus(this.activateOnFocus()))}static{this.ɵfac=function(i){return new(i||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxTabsList`,``]],hostAttrs:[`role`,`tablist`],hostVars:3,hostBindings:function(i,o){i&2&&Br(`aria-orientation`,o.rootContext.orientation()===`vertical`?`vertical`:void 0)(`data-orientation`,o.rootContext.orientation())(`data-activation-direction`,o.rootContext.activationDirection())},inputs:{activateOnFocus:[1,`activateOnFocus`],loopFocus:[1,`loopFocus`]},exportAs:[`rdxTabsList`],features:[jI([z])]})}}return e})();Re=()=>({present:C(_e).present}),_e=(()=>{class e{constructor(){this.elementRef=C(Pr),this.listItem=C(O,{self:!0}),this.rootContext=tt(),this.value=jc.required(),this.keepMounted=jc(!1,{transform:Dj}),this.transition=ar(()=>{}),this.transitionStatus=this.transition.status,this.panelId=Ot$1(()=>Ut(this.rootContext.baseId,this.value())),this.tabId=Ot$1(()=>{let i=this.value();for(let o of this.rootContext.tabMap().values())if(o.value===i)return o.id;return qt(this.rootContext.baseId,i)}),this.active=Ot$1(()=>this.rootContext.value()===this.value()),this.hasPresence=wt(!1),this.present=Ot$1(()=>this.keepMounted()||this.active()),this.hidden=Ot$1(()=>!this.active()&&this.transitionStatus()!==`ending`&&(!this.hasPresence()||this.keepMounted())),this.index=this.listItem.index,this.previousActive=!1,this.isFirstRun=!0;let t=this.transition.registerElement(this.elementRef.nativeElement);C(ve$1).onDestroy(t),rf(()=>{this.listItem.setMetadata({id:this.panelId(),value:this.value()})}),rf(()=>{let i=this.active();if(this.isFirstRun){this.isFirstRun=!1,this.previousActive=i;return}i!==this.previousActive&&(this.previousActive=i,Tg(()=>this.transition.start(i)))})}markHasPresence(){this.hasPresence.set(!0)}static{this.ɵfac=function(i){return new(i||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxTabsPanel`,``]],hostAttrs:[`role`,`tabpanel`],hostVars:10,hostBindings:function(i,o){i&2&&(Km(`hidden`,o.hidden()),Br(`id`,o.panelId())(`tabindex`,o.active()?0:-1)(`aria-labelledby`,o.tabId())(`data-orientation`,o.rootContext.orientation())(`data-activation-direction`,o.rootContext.activationDirection())(`data-index`,o.index())(`data-hidden`,o.active()?void 0:``)(`data-starting-style`,o.transitionStatus()===`starting`?``:void 0)(`data-ending-style`,o.transitionStatus()===`ending`?``:void 0))},inputs:{value:[1,`value`],keepMounted:[1,`keepMounted`]},exportAs:[`rdxTabsPanel`],features:[IS([L(Re)]),jI([O])]})}}return e})(),Ee=()=>{let e=C(we);return{baseId:e.baseId,value:e.value,orientation:e.orientation,activationDirection:e.activationDirection.asReadonly(),activateOnFocus:e.activateOnFocus.asReadonly(),tabListElement:e.tabListElement.asReadonly(),tabMap:e.tabMap.asReadonly(),tabCompositeRoot:e.tabCompositeRoot.asReadonly(),tabCompositeList:e.tabCompositeList.asReadonly(),setValue:(n,t,i)=>e.setValue(n,t,i),setActivateOnFocus:n=>e.activateOnFocus.set(n),registerTabList:(n,t,i)=>e.registerTabList(n,t,i),setTabMap:n=>e.tabMap.set(n)}},we=(()=>{class e{constructor(){this.baseId=Tt(`rdx-tabs-`),this.value=mj(),this.defaultValue=jc(void 0),this.orientation=jc(`horizontal`),this.onValueChange=pj(),this.activateOnFocus=wt(!1),this.tabListElement=wt(null),this.tabMap=wt(new Map),this.tabCompositeRoot=wt(null),this.tabCompositeList=wt(null),this.activationDirection=wt(`none`),this.externallyControlled=wt(!1),this.hasObservedValue=!1,this.internalValueCommit=!1,this.hasAppliedDefaultValue=!1,this.shouldNotifyInitialValueChange=!0,this.shouldHonorDisabledDefaultValue=!1,this.didRegisterTabs=!1,rf(()=>{let t=this.value();if(this.internalValueCommit){this.internalValueCommit=!1,this.hasObservedValue=!0,this.previousObservedValue=t;return}if(!this.hasObservedValue){this.hasObservedValue=!0,this.previousObservedValue=t,t!==void 0&&this.externallyControlled.set(!0);return}t!==this.previousObservedValue&&(this.externallyControlled.set(!0),this.previousObservedValue=t)}),rf(()=>{if(this.hasAppliedDefaultValue||Tg(this.value)!==void 0)return;let t=this.defaultValue(),i=t!==void 0;this.hasAppliedDefaultValue=!0,this.initialDefaultValue=t??0,this.shouldNotifyInitialValueChange=!i,this.shouldHonorDisabledDefaultValue=i,Tg(()=>this.commitValue(this.initialDefaultValue))}),rf(()=>{let t=this.tabMap(),i=this.value();if(this.externallyControlled())return;if(t.size===0){this.didRegisterTabs&&i!==null&&!this.lastKnownTabElement?.isConnected&&Tg(()=>this.commitAutomaticValueChange(null,`missing`));return}this.didRegisterTabs=!0,this.lastKnownTabElement=t.keys().next().value;let o=Te(t,i),s=Ne(t),a=o?.disabled,l=o==null&&i!==null;if(!a&&i===this.initialDefaultValue&&(this.shouldHonorDisabledDefaultValue=!1),this.shouldHonorDisabledDefaultValue&&a&&i===this.initialDefaultValue)return;let r=this.shouldNotifyInitialValueChange;if(a||l){let d=s??null;if(i===d){this.shouldNotifyInitialValueChange=!1;return}let p=`missing`;r?p=`initial`:a&&(p=`disabled`),Tg(()=>this.commitAutomaticValueChange(d,p));return}r&&o!=null&&(Tg(()=>this.notifyAutomaticValueChange(i,`initial`)),this.shouldNotifyInitialValueChange=!1)})}setValue(t,i,o=`none`){let s=this.value();if(s===t)return;let a=i?.currentTarget instanceof HTMLElement?i.currentTarget:void 0,{eventDetails:l}=Zn(o,i??new Event(`tabs.value-change`),a),r=l,d=ke(s,t,this.orientation(),this.tabMap());r.activationDirection=d,this.onValueChange.emit({value:t,eventDetails:r}),!r.isCanceled()&&(this.activationDirection.set(d),this.commitValue(t))}registerTabList(t,i,o){return this.tabListElement.set(t),this.tabCompositeRoot.set(i),this.tabCompositeList.set(o),()=>{this.tabCompositeRoot()!==i||this.tabCompositeList()!==o||(this.tabListElement.set(null),this.tabCompositeRoot.set(null),this.tabCompositeList.set(null),this.activateOnFocus.set(!1))}}commitValue(t){this.internalValueCommit=!0,this.value.set(t)}commitAutomaticValueChange(t,i){this.activationDirection.set(`none`),this.commitValue(t),this.notifyAutomaticValueChange(t,i),this.shouldNotifyInitialValueChange=!1}notifyAutomaticValueChange(t,i){if(t===void 0)return;let{eventDetails:o}=Zn(i,new Event(`tabs.value-change`)),s=o;s.activationDirection=`none`,this.onValueChange.emit({value:t,eventDetails:s})}static{this.ɵfac=function(i){return new(i||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxTabsRoot`,``]],hostVars:2,hostBindings:function(i,o){i&2&&Br(`data-orientation`,o.orientation())(`data-activation-direction`,o.activationDirection())},inputs:{value:[1,`value`],defaultValue:[1,`defaultValue`],orientation:[1,`orientation`]},outputs:{value:`valueChange`,onValueChange:`onValueChange`},exportAs:[`rdxTabsRoot`],features:[IS([Me(Ee)]),jI([W])]})}}return e})();Pe=()=>{let e=tt();return{rootContext:e.tabCompositeRoot,listContext:e.tabCompositeList}};gi=(()=>{class e{constructor(){this.rootContext=tt(),this.compositeItem=C(Z,{self:!0}),this.elementRef=C(Pr),this.value=jc.required(),this.disabled=jc(!1,{transform:Dj}),this.nativeButton=jc(!0,{transform:Dj}),this.id=jc(void 0),this.tabId=Ot$1(()=>this.id()??qt(this.rootContext.baseId,this.value())),this.panelId=Ot$1(()=>Ut(this.rootContext.baseId,this.value())),this.active=Ot$1(()=>this.rootContext.value()===this.value()),this.isPressing=!1,this.isMainButton=!1,Ej()&&Cj(()=>{let t=this.rootContext.tabCompositeList();t&&!t.listElement.contains(this.elementRef.nativeElement)&&Bn(`tabs/tab-outside-list`,'`rdxTabsTab` is rendered outside its `rdxTabsList`, so it gets no roving tabindex, arrow keys cannot reach it, and its `role="tab"` sits outside the `role="tablist"`. Move the tab inside the list, or project it there with `<ng-content>`.',`components/tabs`)}),rf(()=>{this.compositeItem.setMetadata({disabled:this.disabled(),id:this.tabId(),value:this.value()})})}onClick(t){this.active()||this.disabled()||this.rootContext.setValue(this.value(),t,`none`)}onKeyDown(t){!this.disabled()&&(t.key===` `||t.key===`Enter`)&&this.rootContext.setValue(this.value(),t,`none`)}onPointerDown(t){if(this.active()||this.disabled())return;this.isPressing=!0,this.isMainButton=t.button===0;let i=t.currentTarget instanceof HTMLElement?t.currentTarget.ownerDocument:document;i.addEventListener(`pointerup`,()=>{this.isPressing=!1,this.isMainButton=!1},{once:!0}),i.addEventListener(`pointercancel`,()=>{this.isPressing=!1,this.isMainButton=!1},{once:!0}),i.addEventListener(`blur`,()=>{this.isPressing=!1,this.isMainButton=!1},{once:!0})}onFocus(t){this.active()||this.disabled()||this.rootContext.activateOnFocus()&&(!this.isPressing||this.isMainButton)&&this.rootContext.setValue(this.value(),t,`none`)}static{this.ɵfac=function(i){return new(i||e)}}static{this.ɵdir=$I({type:e,selectors:[[``,`rdxTabsTab`,``]],hostAttrs:[`role`,`tab`],hostVars:11,hostBindings:function(i,o){i&1&&Jm(`click`,function(a){return o.onClick(a)})(`keydown`,function(a){return o.onKeyDown(a)})(`pointerdown`,function(a){return o.onPointerDown(a)})(`focus`,function(a){return o.onFocus(a)}),i&2&&Br(`type`,o.nativeButton()?`button`:void 0)(`id`,o.tabId())(`aria-selected`,o.active())(`aria-controls`,o.panelId())(`aria-disabled`,o.disabled()?`true`:void 0)(`disabled`,null)(`data-composite-item-active`,o.active()?``:void 0)(`data-orientation`,o.rootContext.orientation())(`data-activation-direction`,o.rootContext.activationDirection())(`data-active`,o.active()?``:void 0)(`data-disabled`,o.disabled()?``:void 0)},inputs:{value:[1,`value`],disabled:[1,`disabled`],nativeButton:[1,`nativeButton`],id:[1,`id`]},exportAs:[`rdxTabsTab`],features:[IS([Ae()]),jI([Z])]})}}return e})()});function Ve(e,n){if(e&1&&(Oi(0,`p`,8),fS(1),Nc()),e&2){let t=HE(2);ec(),pg(t.t().introHost)}}function Oe(e,n){if(e&1&&(Oi(0,`p`,8),fS(1),Nc()),e&2){let t=HE(2);ec(),pg(t.t().introContainer)}}function He(e,n){if(e&1&&SE(0,Ve,2,1,`p`,8)(1,Oe,2,1,`p`,8),e&2)kE(HE().containerId()===null?0:1)}function Se(e,n){if(e&1&&(Oi(0,`p`,9),fS(1),Nc()),e&2){let t=HE().$implicit;ec(),pg(t.text)}}function Ke(e,n){if(e&1&&Gm(0,`app-answer-text`,10),e&2){let t=HE().$implicit;Wm(`text`,t.text)}}function Be(e,n){if(e&1&&(Oi(0,`p`,11),Gm(1,`app-icon`,15),fS(2),Nc()),e&2){let t=HE().$implicit;ec(),Wm(`size`,12),ec(),Ac(` `,t.label,` `)}}function je(e,n){if(e&1&&(Oi(0,`pre`,17),fS(1),Nc()),e&2){let t=HE(2).$implicit;ec(),pg(t.proposal.command)}}function We(e,n){if(e&1&&(Oi(0,`span`,21),fS(1),Nc()),e&2){let t=HE(2).$implicit,i=HE();ec(),pg(t.proposal.kind===`command`?i.t().onPrompt:i.t().done)}}function ze(e,n){if(e&1&&(Oi(0,`span`,22),fS(1),Nc()),e&2){let t=HE(2).$implicit;ec(),pg(t.problem)}}function $e(e,n){if(e&1){let t=RE();Oi(0,`div`,12)(1,`p`,16),fS(2),Nc(),SE(3,je,2,1,`pre`,17),Oi(4,`div`,18)(5,`button`,19),Jm(`click`,function(){Ld(t);let o=HE(),s=o.$implicit,a=o.$index;return Od(HE().carryOut(a,s.proposal))}),Gm(6,`app-icon`,20),fS(7),Nc(),SE(8,We,2,1,`span`,21)(9,ze,2,1,`span`,22),Nc()()}if(e&2){let t=HE().$implicit,i=HE();ec(2),pg(t.proposal.reason),ec(),kE(t.proposal.kind===`command`?3:-1),ec(2),Wm(`disabled`,t.state===`busy`||t.state===`done`&&t.proposal.kind!==`command`),ec(),Wm(`name`,i.proposalIcon(t.proposal))(`size`,14),ec(),Ac(` `,i.proposalLabel(t.proposal),` `),ec(),kE(t.state===`done`?8:t.state===`failed`?9:-1)}}function qe(e,n){if(e&1&&(Oi(0,`p`,13),fS(1),Nc()),e&2){let t=HE().$implicit;ec(),pg(t.text)}}function Ue(e,n){if(e&1&&(Oi(0,`p`,14),fS(1),Nc()),e&2){let t=HE().$implicit;ec(),Ac(` `,t.problem,` `)}}function Qe(e,n){if(e&1&&SE(0,Se,2,1,`p`,9)(1,Ke,1,1,`app-answer-text`,10)(2,Be,3,2,`p`,11)(3,$e,10,7,`div`,12)(4,qe,2,1,`p`,13)(5,Ue,2,1,`p`,14),e&2){let t,i=n.$implicit;kE((t=i.kind)===`question`?0:t===`answer`?1:t===`tool`?2:t===`proposal`?3:t===`usage`?4:t===`error`?5:-1)}}function Xe(e,n){if(e&1&&(Oi(0,`p`,2),fS(1),Nc()),e&2){let t=HE();ec(),pg(t.t().thinking)}}function dt(e){return e.toLocaleString(ik())}var Qt;var Ye=f(()=>{Kr();lk();he$1();dk();sk();Kr();Qt=class e{containerId=jc(null);commandChosen=pj();entries=wt([]);busy=wt(!1);draft=wt(``);t=Ot$1(()=>ok().containers.assistant);defaultQuestion=Ot$1(()=>this.containerId()===null?this.t().defaultHostQuestion:this.t().defaultQuestion);conversationId=null;unsubscribe=null;destroyed=!1;constructor(){C(ve$1).onDestroy(()=>{this.destroyed=!0,this.unsubscribe?.(),this.conversationId!==null&&window.electron.assistant.close(this.conversationId)})}async submit(n){n.preventDefault();let t=this.draft().trim()||(this.entries().length===0?this.defaultQuestion():``);if(!(t===``||this.busy())){this.draft.set(``),this.busy.set(!0),this.append({kind:`question`,text:t});try{let i=await this.conversation();await window.electron.assistant.ask(i,t)}catch(i){this.append({kind:`error`,problem:eH(i)})}finally{this.busy.set(!1)}}}proposalLabel(n){let t=this.t();return n.kind===`command`?t.putInTerminal:n.kind===`compose`?t.composeUp(n.project):t[n.action](n.containerName)}proposalIcon(n){return n.kind===`command`?`terminal`:n.kind===`compose`?`play`:{start:`play`,stop:`stop`,restart:`refresh`}[n.action]}async carryOut(n,t){if(t.kind===`command`){this.commandChosen.emit(t.command),this.updateProposal(n,{state:`done`});return}this.updateProposal(n,{state:`busy`});try{let i=t.kind===`compose`?await window.electron.compose.up(t.project):await window.electron.containers.action(t.action,t.containerId);this.updateProposal(n,i.ok?{state:`done`}:{state:`failed`,problem:i.problem})}catch(i){this.updateProposal(n,{state:`failed`,problem:eH(i)})}}async conversation(){if(this.conversationId!==null)return this.conversationId;let n=await window.electron.assistant.start(this.containerId());if(this.destroyed)throw window.electron.assistant.close(n),new Error(this.t().panelClosed);return this.conversationId=n,this.unsubscribe=window.electron.assistant.onEvent(n,t=>this.receive(t)),n}receive(n){switch(n.type){case`text`:this.entries.update(t=>{let i=t.at(-1);return i?.kind===`answer`?[...t.slice(0,-1),{kind:`answer`,text:i.text+n.text}]:n.text.trim()===``?t:[...t,{kind:`answer`,text:n.text}]});break;case`tool`:this.append({kind:`tool`,label:n.label});break;case`proposal`:this.append({kind:`proposal`,proposal:n.proposal,state:`open`});break;case`done`:this.append({kind:`usage`,text:this.t().usage(dt(n.inputTokens),dt(n.cachedTokens),dt(n.outputTokens))});break;case`error`:this.append({kind:`error`,problem:n.problem});break}}append(n){this.entries.update(t=>[...t,n])}updateProposal(n,t){this.entries.update(i=>i.map((o,s)=>s===n&&o.kind===`proposal`?W$1(W$1({},o),t):o))}static ɵfac=function(t){return new(t||e)};static ɵcmp=wc({type:e,selectors:[[`app-assistant-view`]],hostAttrs:[1,`flex`,`h-full`,`flex-col`],inputs:{containerId:[1,`containerId`]},outputs:{commandChosen:`commandChosen`},decls:13,vars:9,consts:[[`data-testid`,`assistant-log`,1,`min-h-0`,`flex-1`,`overflow-y-auto`,`px-6`,`py-4`],[1,`max-w-3xl`,`space-y-3`],[1,`text-[12px]`,`text-ink-500`],[1,`flex`,`shrink-0`,`gap-2`,`border-t`,`border-ink-700`,`px-6`,`py-3`,3,`submit`],[`for`,`assistant-question`,1,`sr-only`],[`id`,`assistant-question`,`type`,`text`,`autocomplete`,`off`,1,`mx-focus`,`min-w-0`,`flex-1`,`rounded-md`,`border`,`border-ink-700`,`bg-ink-800`,`px-3`,`py-1.5`,`text-[13px]`,`text-ink-100`,`placeholder:text-ink-500`,3,`input`,`placeholder`,`value`,`disabled`],[`type`,`submit`,`data-testid`,`assistant-ask`,1,`mx-btn`,`mx-focus`,3,`disabled`],[`name`,`sparkle`,3,`size`],[1,`max-w-2xl`,`text-[13px]`,`text-ink-400`],[1,`rounded-md`,`bg-ink-800`,`px-3`,`py-2`,`text-[13px]`,`text-ink-100`],[`data-testid`,`assistant-answer`,1,`text-[13px]`,`leading-relaxed`,`text-ink-200`,3,`text`],[`data-testid`,`assistant-tool`,1,`flex`,`items-center`,`gap-1.5`,`text-[12px]`,`text-ink-500`],[`data-testid`,`assistant-proposal`,1,`rounded-md`,`border`,`border-ink-700`,`bg-ink-850`,`px-3`,`py-2`],[`data-testid`,`assistant-usage`,1,`text-[11px]`,`text-ink-600`],[`data-testid`,`assistant-error`,1,`rounded-md`,`border`,`border-danger/40`,`bg-danger/10`,`px-3`,`py-2`,`text-[13px]`,`text-danger`],[`name`,`search`,3,`size`],[1,`text-[12px]`,`text-ink-400`],[1,`mt-2`,`overflow-x-auto`,`rounded`,`bg-ink-900`,`px-2`,`py-1`,`font-mono`,`text-[12px]`,`text-ink-100`],[1,`mt-2`,`flex`,`items-center`,`gap-2`],[`type`,`button`,1,`mx-btn`,`mx-focus`,3,`click`,`disabled`],[3,`name`,`size`],[1,`text-[12px]`,`text-ok`],[1,`text-[12px]`,`text-danger`]],template:function(t,i){t&1&&(Oi(0,`div`,0),SE(1,He,2,1),Oi(2,`div`,1),kc(3,Qe,6,1,null,null,TE),SE(5,Xe,2,1,`p`,2),Nc()(),Oi(6,`form`,3),Jm(`submit`,function(s){return i.submit(s)}),Oi(7,`label`,4),fS(8),Nc(),Oi(9,`input`,5),Jm(`input`,function(s){return i.draft.set(s.target.value)}),Nc(),Oi(10,`button`,6),Gm(11,`app-icon`,7),fS(12),Nc()()),t&2&&(ec(),kE(i.entries().length===0?1:-1),ec(2),Tc(i.entries()),ec(2),kE(i.busy()?5:-1),ec(3),pg(i.t().questionLabel),ec(),Wm(`placeholder`,i.entries().length===0?i.defaultQuestion():i.t().followUp)(`value`,i.draft())(`disabled`,i.busy()),ec(),Wm(`disabled`,i.busy()),ec(),Wm(`size`,14),ec(),Ac(` `,i.t().ask,` `))},dependencies:[W$2,My],encapsulation:2})}});export{fi as a,_e as i,Qt as n,gi as o,Ye as r,we as s,Le as t};
|