@ory/elements-react 0.0.0-pr.4a28a8f → 0.0.0-pr.7af5f16

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.
@@ -29,8 +29,9 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
29
29
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
30
30
 
31
31
  // src/theme/default/index.ts
32
- var default_exports = {};
33
- __export(default_exports, {
32
+ var index_exports = {};
33
+ __export(index_exports, {
34
+ Consent: () => Consent,
34
35
  DefaultButtonSocial: () => DefaultButtonSocial,
35
36
  DefaultCard: () => DefaultCard,
36
37
  DefaultCardContent: () => DefaultCardContent,
@@ -50,7 +51,7 @@ __export(default_exports, {
50
51
  Verification: () => Verification,
51
52
  getOryComponents: () => getOryComponents
52
53
  });
53
- module.exports = __toCommonJS(default_exports);
54
+ module.exports = __toCommonJS(index_exports);
54
55
 
55
56
  // src/theme/default/assets/ory-badge-horizontal.svg
56
57
  var React = __toESM(require("react"));
@@ -91,9 +92,8 @@ function DefaultCardContent({ children }) {
91
92
  }
92
93
 
93
94
  // src/theme/default/components/card/footer.tsx
94
- var import_client_fetch3 = require("@ory/client-fetch");
95
+ var import_client_fetch4 = require("@ory/client-fetch");
95
96
  var import_elements_react = require("@ory/elements-react");
96
- var import_react_hook_form = require("react-hook-form");
97
97
  var import_react_intl = require("react-intl");
98
98
 
99
99
  // src/theme/default/utils/url.ts
@@ -142,6 +142,7 @@ function appendRefresh(url, refresh) {
142
142
 
143
143
  // src/util/ui/index.ts
144
144
  var import_client_fetch2 = require("@ory/client-fetch");
145
+ var import_client_fetch3 = require("@ory/client-fetch");
145
146
  var import_react2 = require("react");
146
147
 
147
148
  // src/context/component.tsx
@@ -178,33 +179,45 @@ function nodesToAuthMethodGroups(nodes, excludeAuthMethods = []) {
178
179
  groupNodes.push(node);
179
180
  groups[node.group] = groupNodes;
180
181
  }
181
- return Object.values(import_client_fetch2.UiNodeGroupEnum).filter((group) => {
182
+ return Object.values(import_client_fetch3.UiNodeGroupEnum).filter((group) => {
182
183
  var _a2;
183
184
  return (_a2 = groups[group]) == null ? void 0 : _a2.length;
184
185
  }).filter(
185
186
  (group) => ![
186
- import_client_fetch2.UiNodeGroupEnum.Default,
187
- import_client_fetch2.UiNodeGroupEnum.IdentifierFirst,
188
- import_client_fetch2.UiNodeGroupEnum.Profile,
189
- import_client_fetch2.UiNodeGroupEnum.Captcha,
187
+ import_client_fetch3.UiNodeGroupEnum.Default,
188
+ import_client_fetch3.UiNodeGroupEnum.IdentifierFirst,
189
+ import_client_fetch3.UiNodeGroupEnum.Profile,
190
+ import_client_fetch3.UiNodeGroupEnum.Captcha,
190
191
  ...excludeAuthMethods
191
192
  ].includes(group)
192
193
  );
193
194
  }
195
+ var findNode = (nodes, opt) => nodes.find((n) => {
196
+ return n.attributes.node_type === opt.node_type && (opt.group instanceof RegExp ? n.group.match(opt.group) : n.group === opt.group) && (opt.name && n.attributes.node_type === "input" ? opt.name instanceof RegExp ? n.attributes.name.match(opt.name) : n.attributes.name === opt.name : !opt.name);
197
+ });
198
+
199
+ // src/util/nodes.ts
200
+ function findScreenSelectionButton(nodes) {
201
+ return nodes.find(
202
+ (node) => node.attributes.node_type === "input" && node.attributes.type === "submit" && node.attributes.name === "screen"
203
+ );
204
+ }
194
205
 
195
206
  // src/theme/default/components/card/footer.tsx
196
207
  var import_jsx_runtime5 = require("react/jsx-runtime");
197
208
  function DefaultCardFooter() {
198
- const { flowType } = (0, import_elements_react.useOryFlow)();
199
- switch (flowType) {
200
- case import_client_fetch3.FlowType.Login:
209
+ const oryFlow = (0, import_elements_react.useOryFlow)();
210
+ switch (oryFlow.flowType) {
211
+ case import_client_fetch4.FlowType.Login:
201
212
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(LoginCardFooter, {});
202
- case import_client_fetch3.FlowType.Registration:
213
+ case import_client_fetch4.FlowType.Registration:
203
214
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RegistrationCardFooter, {});
204
- case import_client_fetch3.FlowType.Recovery:
215
+ case import_client_fetch4.FlowType.Recovery:
205
216
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(RecoveryCardFooter, {});
206
- case import_client_fetch3.FlowType.Verification:
217
+ case import_client_fetch4.FlowType.Verification:
207
218
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(VerificationCardFooter, {});
219
+ case import_client_fetch4.FlowType.OAuth2Consent:
220
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ConsentCardFooter, { flow: oryFlow.flow });
208
221
  default:
209
222
  return null;
210
223
  }
@@ -213,7 +226,7 @@ function LoginCardFooter() {
213
226
  const { config, formState, flow, flowType } = (0, import_elements_react.useOryFlow)();
214
227
  const intl = (0, import_react_intl.useIntl)();
215
228
  const authMethods = nodesToAuthMethodGroups(flow.ui.nodes);
216
- if (flowType === import_client_fetch3.FlowType.Login && flow.refresh) {
229
+ if (flowType === import_client_fetch4.FlowType.Login && flow.refresh) {
217
230
  return null;
218
231
  }
219
232
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
@@ -261,7 +274,7 @@ function LoginCardFooter() {
261
274
  })
262
275
  }
263
276
  ) }),
264
- flowType === import_client_fetch3.FlowType.Login && flow.requested_aal === "aal2" && (formState.current === "select_method" || authMethods.length === 0) && /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "font-normal leading-normal antialiased text-interface-foreground-default-primary", children: [
277
+ flowType === import_client_fetch4.FlowType.Login && flow.requested_aal === "aal2" && (formState.current === "select_method" || authMethods.length === 0) && /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "font-normal leading-normal antialiased text-interface-foreground-default-primary", children: [
265
278
  intl.formatMessage({
266
279
  id: "login.2fa.go-back"
267
280
  }),
@@ -283,60 +296,45 @@ function LoginCardFooter() {
283
296
  ] })
284
297
  ] });
285
298
  }
286
- function findScreenSelectionButton(nodes) {
287
- return nodes.find(
288
- (node) => node.attributes.node_type === "input" && node.attributes.type === "submit" && node.attributes.name === "screen"
289
- );
290
- }
291
299
  function RegistrationCardFooter() {
292
300
  const intl = (0, import_react_intl.useIntl)();
293
301
  const { config, flow, formState } = (0, import_elements_react.useOryFlow)();
294
- const { setValue } = (0, import_react_hook_form.useFormContext)();
295
- if (formState.current === "select_method") {
296
- return null;
297
- }
298
302
  const screenSelectionNode = findScreenSelectionButton(flow.ui.nodes);
299
- function handleScreenSelection() {
300
- setValue("method", "profile");
301
- if (screenSelectionNode) {
302
- setValue(
303
- screenSelectionNode.attributes.name,
304
- screenSelectionNode.attributes.value
305
- );
306
- }
303
+ switch (formState.current) {
304
+ case "method_active":
305
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "font-normal leading-normal antialiased", children: screenSelectionNode && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
306
+ "a",
307
+ {
308
+ className: "font-medium text-button-link-brand-brand hover:text-button-link-brand-brand-hover",
309
+ href: "",
310
+ children: intl.formatMessage({
311
+ id: "card.footer.select-another-method",
312
+ defaultMessage: "Select another method"
313
+ })
314
+ }
315
+ ) });
316
+ case "select_method":
317
+ default:
318
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "font-normal leading-normal antialiased", children: [
319
+ intl.formatMessage({
320
+ id: "registration.login-label",
321
+ defaultMessage: "Already have an account?"
322
+ }),
323
+ " ",
324
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
325
+ "a",
326
+ {
327
+ className: "text-button-link-brand-brand transition-colors hover:text-button-link-brand-brand-hover underline",
328
+ href: initFlowUrl(config.sdk.url, "login", flow),
329
+ "data-testid": "ory/screen/registration/action/login",
330
+ children: intl.formatMessage({
331
+ id: "registration.login-button",
332
+ defaultMessage: "Sign in"
333
+ })
334
+ }
335
+ )
336
+ ] });
307
337
  }
308
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "font-normal leading-normal antialiased", children: formState.current === "method_active" ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_jsx_runtime5.Fragment, { children: screenSelectionNode && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
309
- "button",
310
- {
311
- className: "font-medium text-button-link-brand-brand hover:text-button-link-brand-brand-hover",
312
- type: "submit",
313
- name: screenSelectionNode.attributes.name,
314
- value: screenSelectionNode.attributes.value,
315
- onClick: handleScreenSelection,
316
- children: intl.formatMessage({
317
- id: "card.footer.select-another-method",
318
- defaultMessage: "Select another method"
319
- })
320
- }
321
- ) }) : /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
322
- intl.formatMessage({
323
- id: "registration.login-label",
324
- defaultMessage: "Already have an account?"
325
- }),
326
- " ",
327
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
328
- "a",
329
- {
330
- className: "text-button-link-brand-brand transition-colors hover:text-button-link-brand-brand-hover underline",
331
- href: initFlowUrl(config.sdk.url, "login", flow),
332
- "data-testid": "ory/screen/registration/action/login",
333
- children: intl.formatMessage({
334
- id: "registration.login-button",
335
- defaultMessage: "Sign in"
336
- })
337
- }
338
- )
339
- ] }) });
340
338
  }
341
339
  function RecoveryCardFooter() {
342
340
  return null;
@@ -344,12 +342,57 @@ function RecoveryCardFooter() {
344
342
  function VerificationCardFooter() {
345
343
  return null;
346
344
  }
345
+ function ConsentCardFooter({ flow }) {
346
+ var _a, _b;
347
+ const { Node: Node2 } = (0, import_elements_react.useComponents)();
348
+ const rememberNode = findNode(flow.ui.nodes, {
349
+ group: "oauth2_consent",
350
+ node_type: "input",
351
+ name: "remember"
352
+ });
353
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: "flex gap-8 flex-col", children: [
354
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { children: [
355
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("p", { className: "text-interface-foreground-default-secondary leading-normal font-medium", children: [
356
+ "Make sure you trust ",
357
+ (_a = flow.consent_request.client) == null ? void 0 : _a.client_name
358
+ ] }),
359
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "text-interface-foreground-default-secondary leading-normal", children: "You may be sharing sensitive information with this site or application." })
360
+ ] }),
361
+ rememberNode && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
362
+ Node2.Checkbox,
363
+ {
364
+ attributes: rememberNode.attributes,
365
+ node: rememberNode
366
+ }
367
+ ),
368
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-2", children: flow.ui.nodes.filter(
369
+ (n) => n.attributes.node_type === "input" && n.attributes.type === "submit"
370
+ ).map((n) => {
371
+ const attributes = n.attributes;
372
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
373
+ Node2.Button,
374
+ {
375
+ node: n,
376
+ attributes
377
+ },
378
+ attributes.value
379
+ );
380
+ }) }),
381
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("p", { className: "text-sm", children: [
382
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "text-interface-foreground-default-tertiary", children: [
383
+ "Authorizing will redirect to",
384
+ " "
385
+ ] }),
386
+ (_b = flow.consent_request.client) == null ? void 0 : _b.client_name
387
+ ] })
388
+ ] });
389
+ }
347
390
 
348
391
  // src/theme/default/components/card/header.tsx
349
392
  var import_elements_react3 = require("@ory/elements-react");
350
393
 
351
394
  // src/theme/default/utils/constructCardHeader.ts
352
- var import_client_fetch4 = require("@ory/client-fetch");
395
+ var import_client_fetch5 = require("@ory/client-fetch");
353
396
  var import_react_intl2 = require("react-intl");
354
397
  function joinWithCommaOr(list, orText = "or") {
355
398
  if (list.length === 0) {
@@ -362,11 +405,11 @@ function joinWithCommaOr(list, orText = "or") {
362
405
  }
363
406
  }
364
407
  function useCardHeaderText(container, opts) {
365
- var _a, _b, _c;
408
+ var _a, _b, _c, _d, _e, _f;
366
409
  const nodes = container.nodes;
367
410
  const intl = (0, import_react_intl2.useIntl)();
368
411
  switch (opts.flowType) {
369
- case import_client_fetch4.FlowType.Recovery:
412
+ case import_client_fetch5.FlowType.Recovery:
370
413
  if (nodes.find(
371
414
  (node) => "name" in node.attributes && node.attributes.name === "code"
372
415
  )) {
@@ -387,7 +430,7 @@ function useCardHeaderText(container, opts) {
387
430
  id: "recovery.subtitle"
388
431
  })
389
432
  };
390
- case import_client_fetch4.FlowType.Settings:
433
+ case import_client_fetch5.FlowType.Settings:
391
434
  return {
392
435
  title: intl.formatMessage({
393
436
  id: "settings.title"
@@ -396,7 +439,7 @@ function useCardHeaderText(container, opts) {
396
439
  id: "settings.subtitle"
397
440
  })
398
441
  };
399
- case import_client_fetch4.FlowType.Verification:
442
+ case import_client_fetch5.FlowType.Verification:
400
443
  if (nodes.find(
401
444
  (node) => "name" in node.attributes && node.attributes.name === "code"
402
445
  )) {
@@ -417,7 +460,7 @@ function useCardHeaderText(container, opts) {
417
460
  id: "verification.subtitle"
418
461
  })
419
462
  };
420
- case import_client_fetch4.FlowType.Login: {
463
+ case import_client_fetch5.FlowType.Login: {
421
464
  const accountLinkingMessage = (_a = container.messages) == null ? void 0 : _a.find(
422
465
  (m) => m.id === 1010016
423
466
  );
@@ -439,7 +482,7 @@ function useCardHeaderText(container, opts) {
439
482
  const parts = [];
440
483
  if (nodes.find((node) => node.group === "password")) {
441
484
  switch (opts.flowType) {
442
- case import_client_fetch4.FlowType.Registration:
485
+ case import_client_fetch5.FlowType.Registration:
443
486
  parts.push(
444
487
  intl.formatMessage(
445
488
  { id: "card.header.parts.password.registration" },
@@ -476,7 +519,7 @@ function useCardHeaderText(container, opts) {
476
519
  }
477
520
  if (nodes.find((node) => node.group === "identifier_first")) {
478
521
  const identifier = nodes.find(
479
- (node) => (0, import_client_fetch4.isUiNodeInputAttributes)(node.attributes) && node.attributes.name.startsWith("identifier") && node.attributes.type !== "hidden"
522
+ (node) => (0, import_client_fetch5.isUiNodeInputAttributes)(node.attributes) && node.attributes.name.startsWith("identifier") && node.attributes.type !== "hidden"
480
523
  );
481
524
  if (identifier) {
482
525
  parts.push(
@@ -492,7 +535,7 @@ function useCardHeaderText(container, opts) {
492
535
  }
493
536
  }
494
537
  switch (opts.flowType) {
495
- case import_client_fetch4.FlowType.Login:
538
+ case import_client_fetch5.FlowType.Login:
496
539
  if (opts.flow.refresh) {
497
540
  return {
498
541
  title: intl.formatMessage({
@@ -533,7 +576,7 @@ function useCardHeaderText(container, opts) {
533
576
  }
534
577
  ) : ""
535
578
  };
536
- case import_client_fetch4.FlowType.Registration:
579
+ case import_client_fetch5.FlowType.Registration:
537
580
  return {
538
581
  title: intl.formatMessage({
539
582
  id: "registration.title"
@@ -550,6 +593,25 @@ function useCardHeaderText(container, opts) {
550
593
  }
551
594
  ) : ""
552
595
  };
596
+ case import_client_fetch5.FlowType.OAuth2Consent:
597
+ return {
598
+ title: intl.formatMessage(
599
+ {
600
+ id: "consent.title"
601
+ },
602
+ {
603
+ party: (_d = opts.flow.consent_request.client) == null ? void 0 : _d.client_name
604
+ }
605
+ ),
606
+ description: intl.formatMessage(
607
+ {
608
+ id: "consent.subtitle"
609
+ },
610
+ {
611
+ identifier: (_f = (_e = opts.flow.session.identity) == null ? void 0 : _e.traits.email) != null ? _f : ""
612
+ }
613
+ )
614
+ };
553
615
  }
554
616
  return {
555
617
  title: "Error",
@@ -558,7 +620,7 @@ function useCardHeaderText(container, opts) {
558
620
  }
559
621
 
560
622
  // src/theme/default/components/card/current-identifier-button.tsx
561
- var import_client_fetch5 = require("@ory/client-fetch");
623
+ var import_client_fetch6 = require("@ory/client-fetch");
562
624
  var import_elements_react2 = require("@ory/elements-react");
563
625
 
564
626
  // src/theme/default/assets/icons/arrow-left.svg
@@ -580,36 +642,90 @@ function omit(obj, keys) {
580
642
  }
581
643
 
582
644
  // src/theme/default/components/card/current-identifier-button.tsx
645
+ var import_react_hook_form = require("react-hook-form");
583
646
  var import_jsx_runtime7 = require("react/jsx-runtime");
584
647
  function DefaultCurrentIdentifierButton() {
585
648
  const { flow, flowType, config, formState } = (0, import_elements_react2.useOryFlow)();
649
+ const { setValue } = (0, import_react_hook_form.useFormContext)();
586
650
  const ui = flow.ui;
587
651
  if (formState.current === "provide_identifier") {
588
652
  return null;
589
653
  }
590
- if (flowType === import_client_fetch5.FlowType.Login && flow.requested_aal === "aal2") {
654
+ if (flowType === import_client_fetch6.FlowType.Login && flow.requested_aal === "aal2") {
591
655
  return null;
592
656
  }
593
- const nodeBackButton = getBackButtonNode(flowType, ui.nodes);
594
- if ((nodeBackButton == null ? void 0 : nodeBackButton.attributes.node_type) !== "input" || !nodeBackButton.attributes.value) {
657
+ const nodeBackButton = getBackButtonNodeAttributes(flowType, ui.nodes);
658
+ if (!nodeBackButton) {
595
659
  return null;
596
660
  }
597
661
  const initFlowUrl2 = restartFlowUrl(
598
662
  flow,
599
663
  `${config.sdk.url}/self-service/${flowType}/browser`
600
664
  );
601
- const attributes = omit(nodeBackButton.attributes, [
665
+ const attributes = omit(nodeBackButton, [
602
666
  "autocomplete",
603
667
  "node_type",
604
668
  "maxlength"
605
669
  ]);
670
+ const screenSelectionNode = findScreenSelectionButton(flow.ui.nodes);
671
+ if (screenSelectionNode) {
672
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("form", { action: flow.ui.action, method: flow.ui.method, children: [
673
+ flow.ui.nodes.filter((n) => {
674
+ if ((0, import_client_fetch6.isUiNodeInputAttributes)(n.attributes)) {
675
+ return n.attributes.type === "hidden";
676
+ }
677
+ return false;
678
+ }).map((n) => {
679
+ const attrs = n.attributes;
680
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
681
+ "input",
682
+ {
683
+ type: "hidden",
684
+ name: attrs.name,
685
+ value: attrs.value
686
+ },
687
+ attrs.name
688
+ );
689
+ }),
690
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
691
+ "button",
692
+ {
693
+ className: "group inline-flex max-w-full cursor-pointer items-center gap-1 self-start rounded-identifier border px-[11px] py-[5px] transition-colors border-button-identifier-border-border-default bg-button-identifier-background-default hover:border-button-identifier-border-border-hover hover:bg-button-identifier-background-hover",
694
+ ...attributes,
695
+ type: "submit",
696
+ onClick: () => {
697
+ setValue(
698
+ screenSelectionNode.attributes.name,
699
+ screenSelectionNode.attributes.value
700
+ );
701
+ setValue("method", "profile");
702
+ },
703
+ name: screenSelectionNode.attributes.name,
704
+ value: screenSelectionNode.attributes.value,
705
+ title: `Adjust ${nodeBackButton == null ? void 0 : nodeBackButton.value}`,
706
+ "data-testid": "ory/screen/login/action/restart",
707
+ children: /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("span", { className: "inline-flex min-h-5 items-center gap-2 overflow-hidden text-ellipsis", children: [
708
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
709
+ arrow_left_default,
710
+ {
711
+ size: 16,
712
+ stroke: "1",
713
+ className: "shrink-0 text-button-identifier-foreground-default group-hover:text-button-identifier-foreground-hover"
714
+ }
715
+ ),
716
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "overflow-hidden text-ellipsis text-nowrap text-sm font-medium text-button-identifier-foreground-default group-hover:text-button-identifier-foreground-hover", children: nodeBackButton == null ? void 0 : nodeBackButton.value })
717
+ ] })
718
+ }
719
+ )
720
+ ] });
721
+ }
606
722
  return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
607
723
  "a",
608
724
  {
609
725
  className: "group inline-flex max-w-full cursor-pointer items-center gap-1 self-start rounded-identifier border px-[11px] py-[5px] transition-colors border-button-identifier-border-border-default bg-button-identifier-background-default hover:border-button-identifier-border-border-hover hover:bg-button-identifier-background-hover",
610
726
  ...attributes,
611
727
  href: initFlowUrl2,
612
- title: `Adjust ${nodeBackButton == null ? void 0 : nodeBackButton.attributes.value}`,
728
+ title: `Adjust ${nodeBackButton == null ? void 0 : nodeBackButton.value}`,
613
729
  "data-testid": "ory/screen/login/action/restart",
614
730
  children: /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("span", { className: "inline-flex min-h-5 items-center gap-2 overflow-hidden text-ellipsis", children: [
615
731
  /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
@@ -620,30 +736,34 @@ function DefaultCurrentIdentifierButton() {
620
736
  className: "shrink-0 text-button-identifier-foreground-default group-hover:text-button-identifier-foreground-hover"
621
737
  }
622
738
  ),
623
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "overflow-hidden text-ellipsis text-nowrap text-sm font-medium text-button-identifier-foreground-default group-hover:text-button-identifier-foreground-hover", children: nodeBackButton == null ? void 0 : nodeBackButton.attributes.value })
739
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "overflow-hidden text-ellipsis text-nowrap text-sm font-medium text-button-identifier-foreground-default group-hover:text-button-identifier-foreground-hover", children: nodeBackButton == null ? void 0 : nodeBackButton.value })
624
740
  ] })
625
741
  }
626
742
  );
627
743
  }
628
- function getBackButtonNode(flowType, nodes) {
629
- let nodeBackButton;
744
+ function getBackButtonNodeAttributes(flowType, nodes) {
745
+ var _a, _b;
746
+ let nodeBackButtonAttributes;
630
747
  switch (flowType) {
631
- case import_client_fetch5.FlowType.Login:
632
- nodeBackButton = nodes.find(
633
- (node) => "name" in node.attributes && node.attributes.name === "identifier" && ["default", "identifier_first"].includes(node.group)
634
- );
748
+ case import_client_fetch6.FlowType.Login:
749
+ nodeBackButtonAttributes = (_a = nodes.find(
750
+ (node) => (0, import_client_fetch6.isUiNodeInputAttributes)(node.attributes) && node.attributes.name === "identifier" && ["default", "identifier_first"].includes(node.group)
751
+ )) == null ? void 0 : _a.attributes;
635
752
  break;
636
- case import_client_fetch5.FlowType.Registration:
637
- nodeBackButton = guessRegistrationBackButton(nodes);
753
+ case import_client_fetch6.FlowType.Registration:
754
+ nodeBackButtonAttributes = guessRegistrationBackButton(nodes);
638
755
  break;
639
- case import_client_fetch5.FlowType.Recovery:
640
- case import_client_fetch5.FlowType.Verification:
641
- nodeBackButton = nodes.find(
642
- (n) => "name" in n.attributes && n.attributes.name === "email"
643
- );
756
+ case import_client_fetch6.FlowType.Recovery:
757
+ case import_client_fetch6.FlowType.Verification:
758
+ nodeBackButtonAttributes = (_b = nodes.find(
759
+ (n) => (0, import_client_fetch6.isUiNodeInputAttributes)(n.attributes) && n.attributes.name === "email"
760
+ )) == null ? void 0 : _b.attributes;
644
761
  break;
645
762
  }
646
- return nodeBackButton;
763
+ if ((nodeBackButtonAttributes == null ? void 0 : nodeBackButtonAttributes.node_type) !== "input" || !(nodeBackButtonAttributes == null ? void 0 : nodeBackButtonAttributes.value)) {
764
+ return void 0;
765
+ }
766
+ return nodeBackButtonAttributes;
647
767
  }
648
768
  var backButtonCandiates = [
649
769
  "traits.email",
@@ -651,9 +771,10 @@ var backButtonCandiates = [
651
771
  "traits.phone_number"
652
772
  ];
653
773
  function guessRegistrationBackButton(uiNodes) {
654
- return uiNodes.find(
655
- (node) => "name" in node.attributes && backButtonCandiates.includes(node.attributes.name) && node.group === "default"
656
- );
774
+ var _a;
775
+ return (_a = uiNodes.find(
776
+ (node) => (0, import_client_fetch6.isUiNodeInputAttributes)(node.attributes) && backButtonCandiates.includes(node.attributes.name) && node.group === "default"
777
+ )) == null ? void 0 : _a.attributes;
657
778
  }
658
779
 
659
780
  // src/theme/default/components/card/header.tsx
@@ -711,7 +832,7 @@ function cn(...inputs) {
711
832
  // src/theme/default/components/form/index.tsx
712
833
  var import_react_intl4 = require("react-intl");
713
834
  var import_elements_react6 = require("@ory/elements-react");
714
- var import_client_fetch7 = require("@ory/client-fetch");
835
+ var import_client_fetch8 = require("@ory/client-fetch");
715
836
 
716
837
  // src/theme/default/components/form/social.tsx
717
838
  var import_elements_react5 = require("@ory/elements-react");
@@ -948,7 +1069,7 @@ function Spinner({ className }) {
948
1069
  }
949
1070
 
950
1071
  // src/theme/default/components/form/social.tsx
951
- var import_client_fetch6 = require("@ory/client-fetch");
1072
+ var import_client_fetch7 = require("@ory/client-fetch");
952
1073
  var import_jsx_runtime27 = require("react/jsx-runtime");
953
1074
  function extractProvider(context) {
954
1075
  if (context && typeof context === "object" && "provider" in context && typeof context.provider === "string") {
@@ -980,7 +1101,7 @@ function DefaultButtonSocial({
980
1101
  formState: { isSubmitting }
981
1102
  } = (0, import_react_hook_form2.useFormContext)();
982
1103
  const oidcNodeCount = (_a = ui.nodes.filter(
983
- (node2) => node2.group === import_client_fetch6.UiNodeGroupEnum.Oidc || node2.group === import_client_fetch6.UiNodeGroupEnum.Saml
1104
+ (node2) => node2.group === import_client_fetch7.UiNodeGroupEnum.Oidc || node2.group === import_client_fetch7.UiNodeGroupEnum.Saml
984
1105
  ).length) != null ? _a : 0;
985
1106
  const Logo = logos2[attributes.value.split("-")[0]];
986
1107
  const showLabel = _showLabel != null ? _showLabel : oidcNodeCount % 3 !== 0 && oidcNodeCount % 4 !== 0;
@@ -994,6 +1115,7 @@ function DefaultButtonSocial({
994
1115
  setClicked(false);
995
1116
  }
996
1117
  }, [isSubmitting, setClicked]);
1118
+ const label = node.meta.label ? (0, import_elements_react5.uiTextToFormattedMessage)(node.meta.label, intl) : "";
997
1119
  return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
998
1120
  "button",
999
1121
  {
@@ -1006,10 +1128,11 @@ function DefaultButtonSocial({
1006
1128
  onClick: localOnClick,
1007
1129
  "data-loading": clicked,
1008
1130
  disabled: isSubmitting,
1131
+ "aria-label": label,
1009
1132
  children: [
1010
1133
  /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "size-5 relative", children: !clicked ? Logo ? /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(Logo, { size: 20 }) : /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "flex aspect-square items-center justify-center rounded-[999px] border text-xs", children: provider.slice(0, 2) }) : /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(Spinner, { className: "size-5" }) }),
1011
1134
  showLabel && node.meta.label ? /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(import_jsx_runtime27.Fragment, { children: [
1012
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "grow text-center font-medium leading-none text-button-social-foreground-default", children: (0, import_elements_react5.uiTextToFormattedMessage)(node.meta.label, intl) }),
1135
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "grow text-center font-medium leading-none text-button-social-foreground-default", children: label }),
1013
1136
  /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "size-5 block" })
1014
1137
  ] }) : null
1015
1138
  ]
@@ -1041,11 +1164,13 @@ function DefaultFormContainer({
1041
1164
  children,
1042
1165
  onSubmit,
1043
1166
  action,
1044
- method
1167
+ method,
1168
+ "data-testid": dataTestId
1045
1169
  }) {
1046
1170
  return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
1047
1171
  "form",
1048
1172
  {
1173
+ "data-testid": dataTestId,
1049
1174
  onSubmit,
1050
1175
  noValidate: true,
1051
1176
  action,
@@ -1064,7 +1189,7 @@ function DefaultMessageContainer({ children }) {
1064
1189
  "section",
1065
1190
  {
1066
1191
  className: cn(
1067
- flowType === import_client_fetch7.FlowType.Settings ? "text-center" : "text-left"
1192
+ flowType === import_client_fetch8.FlowType.Settings ? "text-center" : "text-left"
1068
1193
  ),
1069
1194
  children
1070
1195
  }
@@ -1149,8 +1274,40 @@ function isGroupImmediateSubmit(group) {
1149
1274
  return group === "code";
1150
1275
  }
1151
1276
 
1152
- // src/theme/default/components/card/auth-method-list-item.tsx
1277
+ // src/theme/default/components/card/list-item.tsx
1153
1278
  var import_jsx_runtime35 = require("react/jsx-runtime");
1279
+ function ListItem({
1280
+ icon: Icon,
1281
+ as,
1282
+ title,
1283
+ description,
1284
+ children,
1285
+ className,
1286
+ ...props
1287
+ }) {
1288
+ const Comp = as || "div";
1289
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
1290
+ Comp,
1291
+ {
1292
+ ...props,
1293
+ className: cn(
1294
+ "flex cursor-pointer gap-3 text-left items-start w-full rounded-buttons p-2 hover:bg-interface-background-default-primary-hover",
1295
+ className
1296
+ ),
1297
+ children: [
1298
+ /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "mt-1", children: Icon && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Icon, { size: 16, className: "text-interface-foreground-brand-primary" }) }),
1299
+ /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("span", { className: "flex-1 leading-normal inline-flex flex-col max-w-full min-w-1", children: [
1300
+ /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "text-interface-foreground-default-primary break-words", children: title }),
1301
+ /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "text-interface-foreground-default-secondary", children: description })
1302
+ ] }),
1303
+ children
1304
+ ]
1305
+ }
1306
+ );
1307
+ }
1308
+
1309
+ // src/theme/default/components/card/auth-method-list-item.tsx
1310
+ var import_jsx_runtime36 = require("react/jsx-runtime");
1154
1311
  var iconsMap = {
1155
1312
  code: code_default,
1156
1313
  passkey: passkey_default,
@@ -1169,40 +1326,33 @@ function DefaultAuthMethodListItem({
1169
1326
  var _a;
1170
1327
  const intl = (0, import_react_intl5.useIntl)();
1171
1328
  const Icon = iconsMap[group] || null;
1172
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
1173
- "button",
1329
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
1330
+ ListItem,
1174
1331
  {
1175
- className: "flex cursor-pointer gap-3 text-left items-start w-full rounded-buttons p-2 hover:bg-interface-background-default-primary-hover",
1332
+ as: "button",
1333
+ icon: Icon,
1334
+ title: intl.formatMessage(
1335
+ { id: (_a = title == null ? void 0 : title.id) != null ? _a : `two-step.${group}.title` },
1336
+ title == null ? void 0 : title.values
1337
+ ),
1338
+ description: intl.formatMessage({
1339
+ id: `two-step.${group}.description`
1340
+ }),
1176
1341
  onClick,
1177
1342
  type: isGroupImmediateSubmit(group) ? "submit" : "button",
1178
- "data-testid": `ory/form/auth-picker/${group}`,
1179
- children: [
1180
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "mt-1", children: Icon && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Icon, { size: 16, className: "text-interface-foreground-brand-primary" }) }),
1181
- /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("span", { className: "flex-1 leading-normal inline-flex flex-col w-full", children: [
1182
- /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("span", { className: "text-interface-foreground-default-primary truncate mr-6", children: [
1183
- intl.formatMessage(
1184
- { id: (_a = title == null ? void 0 : title.id) != null ? _a : `two-step.${group}.title` },
1185
- title == null ? void 0 : title.values
1186
- ),
1187
- " "
1188
- ] }),
1189
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "text-interface-foreground-default-secondary", children: intl.formatMessage({
1190
- id: `two-step.${group}.description`
1191
- }) })
1192
- ] })
1193
- ]
1343
+ "data-testid": `ory/form/auth-picker/${group}`
1194
1344
  }
1195
1345
  );
1196
1346
  }
1197
1347
 
1198
1348
  // src/theme/default/components/form/button.tsx
1199
- var import_client_fetch8 = require("@ory/client-fetch");
1349
+ var import_client_fetch9 = require("@ory/client-fetch");
1200
1350
  var import_elements_react7 = require("@ory/elements-react");
1201
1351
  var import_class_variance_authority = require("class-variance-authority");
1202
1352
  var import_react_hook_form3 = require("react-hook-form");
1203
1353
  var import_react_intl6 = require("react-intl");
1204
1354
  var import_react4 = require("react");
1205
- var import_jsx_runtime36 = require("react/jsx-runtime");
1355
+ var import_jsx_runtime37 = require("react/jsx-runtime");
1206
1356
  var buttonStyles = (0, import_class_variance_authority.cva)(
1207
1357
  [
1208
1358
  "relative flex justify-center gap-3 overflow-hidden rounded-buttons leading-none ring-1 ring-inset font-medium",
@@ -1250,12 +1400,13 @@ var DefaultButton = ({
1250
1400
  label: _ignoredLabel,
1251
1401
  node_type: _ignoredNodeType,
1252
1402
  maxlength: _ignoredMaxLength,
1403
+ onclick: _ignoredOnClick,
1253
1404
  // End of skipped attributes
1254
1405
  ...rest
1255
1406
  } = attributes;
1256
1407
  const [clicked, setClicked] = (0, import_react4.useState)(false);
1257
1408
  const intl = (0, import_react_intl6.useIntl)();
1258
- const label = (0, import_client_fetch8.getNodeLabel)(node);
1409
+ const label = (0, import_client_fetch9.getNodeLabel)(node);
1259
1410
  const {
1260
1411
  formState: { isSubmitting },
1261
1412
  setValue
@@ -1265,8 +1416,8 @@ var DefaultButton = ({
1265
1416
  setClicked(false);
1266
1417
  }
1267
1418
  }, [isSubmitting]);
1268
- const isPrimary = attributes.name === "method" || attributes.name.includes("passkey") || attributes.name.includes("webauthn") || attributes.name.includes("lookup_secret");
1269
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
1419
+ const isPrimary = attributes.name === "method" || attributes.name.includes("passkey") || attributes.name.includes("webauthn") || attributes.name.includes("lookup_secret") || attributes.name.includes("action") && attributes.value === "accept";
1420
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
1270
1421
  "button",
1271
1422
  {
1272
1423
  ...rest,
@@ -1286,8 +1437,8 @@ var DefaultButton = ({
1286
1437
  disabled: (_a = rest.disabled) != null ? _a : isSubmitting,
1287
1438
  "data-loading": clicked,
1288
1439
  children: [
1289
- clicked ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Spinner, {}) : null,
1290
- label ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { children: (0, import_elements_react7.uiTextToFormattedMessage)(label, intl) }) : ""
1440
+ clicked ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Spinner, {}) : null,
1441
+ label ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { children: (0, import_elements_react7.uiTextToFormattedMessage)(label, intl) }) : ""
1291
1442
  ]
1292
1443
  }
1293
1444
  );
@@ -1295,7 +1446,7 @@ var DefaultButton = ({
1295
1446
  DefaultButton.displayName = "DefaultButton";
1296
1447
 
1297
1448
  // src/theme/default/components/form/checkbox.tsx
1298
- var import_client_fetch9 = require("@ory/client-fetch");
1449
+ var import_client_fetch10 = require("@ory/client-fetch");
1299
1450
  var import_elements_react8 = require("@ory/elements-react");
1300
1451
  var import_react_hook_form4 = require("react-hook-form");
1301
1452
  var import_react_intl8 = require("react-intl");
@@ -1360,7 +1511,7 @@ var uiTextToFormattedMessage4 = ({ id, context = {}, text }, intl) => {
1360
1511
  };
1361
1512
 
1362
1513
  // src/theme/default/components/ui/checkbox-label.tsx
1363
- var import_jsx_runtime37 = require("react/jsx-runtime");
1514
+ var import_jsx_runtime38 = require("react/jsx-runtime");
1364
1515
  var linkRegex = /\[([^\]]+)\]\(([^)]+)\)/g;
1365
1516
  function computeLabelElements(labelText) {
1366
1517
  const elements = [];
@@ -1376,7 +1527,7 @@ function computeLabelElements(labelText) {
1376
1527
  elements.push(labelText.slice(lastIndex, matchStart));
1377
1528
  }
1378
1529
  elements.push(
1379
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1530
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
1380
1531
  "a",
1381
1532
  {
1382
1533
  href: url,
@@ -1401,13 +1552,13 @@ function CheckboxLabel({ label }) {
1401
1552
  return null;
1402
1553
  }
1403
1554
  const labelText = uiTextToFormattedMessage4(label, intl);
1404
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_jsx_runtime37.Fragment, { children: computeLabelElements(labelText) });
1555
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_jsx_runtime38.Fragment, { children: computeLabelElements(labelText) });
1405
1556
  }
1406
1557
 
1407
1558
  // src/theme/default/components/form/checkbox.tsx
1408
- var import_jsx_runtime38 = require("react/jsx-runtime");
1559
+ var import_jsx_runtime39 = require("react/jsx-runtime");
1409
1560
  function CheckboxSVG() {
1410
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
1561
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
1411
1562
  "svg",
1412
1563
  {
1413
1564
  className: "absolute hidden size-4 peer-checked:block fill-checkbox-foreground-checked",
@@ -1416,7 +1567,7 @@ function CheckboxSVG() {
1416
1567
  height: "16",
1417
1568
  viewBox: "0 0 16 16",
1418
1569
  fill: "none",
1419
- children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
1570
+ children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
1420
1571
  "path",
1421
1572
  {
1422
1573
  fillRule: "evenodd",
@@ -1442,30 +1593,29 @@ var DefaultCheckbox = ({
1442
1593
  ...attributes
1443
1594
  } = initialAttributes;
1444
1595
  const intl = (0, import_react_intl8.useIntl)();
1445
- const label = (0, import_client_fetch9.getNodeLabel)(node);
1446
- const { register } = (0, import_react_hook_form4.useForm)();
1596
+ const label = (0, import_client_fetch10.getNodeLabel)(node);
1597
+ const { register } = (0, import_react_hook_form4.useFormContext)();
1447
1598
  const hasError = node.messages.some((m) => m.type === "error");
1448
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("label", { className: "flex items-start gap-3 self-stretch antialiased", children: [
1449
- /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("span", { className: "flex h-5 items-center", children: [
1450
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
1599
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("label", { className: "flex items-start gap-3 self-stretch antialiased", children: [
1600
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("span", { className: "flex h-5 items-center", children: [
1601
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
1451
1602
  "input",
1452
1603
  {
1453
1604
  ...attributes,
1454
- value: 1,
1455
1605
  defaultChecked: Boolean(value),
1456
1606
  type: "checkbox",
1457
1607
  className: cn(
1458
1608
  "peer size-4 border appearance-none rounded-forms bg-checkbox-background-default border-checkbox-border-checkbox-border-default checked:bg-checkbox-background-checked checked:border-checkbox-border-checkbox-border-checked",
1459
1609
  hasError && "border-interface-border-validation-danger"
1460
1610
  ),
1461
- ...register(name, { value })
1611
+ ...register(name)
1462
1612
  }
1463
1613
  ),
1464
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(CheckboxSVG, {})
1614
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(CheckboxSVG, {})
1465
1615
  ] }),
1466
- /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("span", { className: "flex flex-col", children: [
1467
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "font-normal leading-tight text-interface-foreground-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(CheckboxLabel, { label }) }),
1468
- node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
1616
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("span", { className: "flex flex-col", children: [
1617
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "font-normal leading-tight text-interface-foreground-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(CheckboxLabel, { label }) }),
1618
+ node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
1469
1619
  "span",
1470
1620
  {
1471
1621
  className: cn(
@@ -1482,59 +1632,89 @@ var DefaultCheckbox = ({
1482
1632
  };
1483
1633
 
1484
1634
  // src/theme/default/components/form/group-container.tsx
1485
- var import_jsx_runtime39 = require("react/jsx-runtime");
1635
+ var import_elements_react9 = require("@ory/elements-react");
1636
+ var import_client_fetch11 = require("@ory/client-fetch");
1637
+
1638
+ // src/util/childCounter.ts
1639
+ var import_react5 = require("react");
1640
+ function countRenderableChildren(children) {
1641
+ return import_react5.Children.toArray(children).filter((c) => {
1642
+ if ((0, import_react5.isValidElement)(c)) {
1643
+ return true;
1644
+ }
1645
+ return false;
1646
+ }).length;
1647
+ }
1648
+
1649
+ // src/theme/default/components/form/group-container.tsx
1650
+ var import_jsx_runtime40 = require("react/jsx-runtime");
1486
1651
  function DefaultGroupContainer({ children }) {
1487
- return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "grid grid-cols-1 gap-8", children });
1652
+ const { flowType } = (0, import_elements_react9.useOryFlow)();
1653
+ const count = countRenderableChildren(children);
1654
+ if (count === 0) {
1655
+ return null;
1656
+ }
1657
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
1658
+ "div",
1659
+ {
1660
+ className: cn(
1661
+ "grid",
1662
+ flowType === import_client_fetch11.FlowType.OAuth2Consent ? "grid-cols-2 gap-2" : "grid-cols-1 gap-8"
1663
+ ),
1664
+ children
1665
+ }
1666
+ );
1488
1667
  }
1489
1668
 
1490
1669
  // src/theme/default/components/form/horizontal-divider.tsx
1491
- var import_jsx_runtime40 = require("react/jsx-runtime");
1670
+ var import_jsx_runtime41 = require("react/jsx-runtime");
1492
1671
  function DefaultHorizontalDivider() {
1493
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("hr", { className: "border-interface-border-default-primary" });
1672
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("hr", { className: "border-interface-border-default-primary" });
1494
1673
  }
1495
1674
 
1496
1675
  // src/theme/default/components/form/image.tsx
1497
- var import_jsx_runtime41 = require("react/jsx-runtime");
1498
- function DefaultImage({ attributes }) {
1499
- return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("figure", { children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("img", { ...attributes }) });
1676
+ var import_jsx_runtime42 = require("react/jsx-runtime");
1677
+ function DefaultImage({ attributes, node }) {
1678
+ var _a;
1679
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("figure", { children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("img", { ...attributes, alt: ((_a = node.meta.label) == null ? void 0 : _a.text) || "" }) });
1500
1680
  }
1501
1681
 
1502
1682
  // src/theme/default/components/form/input.tsx
1503
- var import_client_fetch10 = require("@ory/client-fetch");
1504
- var import_elements_react9 = require("@ory/elements-react");
1505
- var import_react5 = require("react");
1683
+ var import_client_fetch12 = require("@ory/client-fetch");
1684
+ var import_elements_react10 = require("@ory/elements-react");
1685
+ var import_react6 = require("react");
1506
1686
  var import_react_hook_form5 = require("react-hook-form");
1507
1687
  var import_react_intl9 = require("react-intl");
1508
1688
 
1509
1689
  // src/theme/default/assets/icons/eye-off.svg
1510
1690
  var React24 = __toESM(require("react"));
1511
- var import_jsx_runtime42 = require("react/jsx-runtime");
1691
+ var import_jsx_runtime43 = require("react/jsx-runtime");
1512
1692
  var SvgEyeOff = (props) => {
1513
1693
  var _a, _b;
1514
- return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("path", { stroke: "#000", strokeLinecap: "round", strokeLinejoin: "round", d: "M10.585 10.587a2 2 0 0 0 2.829 2.828m3.267 3.258A8.7 8.7 0 0 1 12 18q-5.4 0-9-6 1.908-3.18 4.32-4.674m2.86-1.146A9 9 0 0 1 12 6q5.4 0 9 6-1 1.665-2.138 2.87M3 3l18 18" }) });
1694
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M10.585 10.587a2 2 0 0 0 2.829 2.828m3.267 3.258A8.7 8.7 0 0 1 12 18q-5.4 0-9-6 1.908-3.18 4.32-4.674m2.86-1.146A9 9 0 0 1 12 6q5.4 0 9 6-1 1.665-2.138 2.87M3 3l18 18" }) });
1515
1695
  };
1516
1696
  var eye_off_default = SvgEyeOff;
1517
1697
 
1518
1698
  // src/theme/default/assets/icons/eye.svg
1519
1699
  var React25 = __toESM(require("react"));
1520
- var import_jsx_runtime43 = require("react/jsx-runtime");
1700
+ var import_jsx_runtime44 = require("react/jsx-runtime");
1521
1701
  var SvgEye = (props) => {
1522
1702
  var _a, _b;
1523
- return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("g", { strokeLinecap: "round", strokeLinejoin: "round", children: [
1524
- /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("path", { stroke: "currentColor", d: "M10 12a2 2 0 1 0 4 0 2 2 0 0 0-4 0" }),
1525
- /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("path", { stroke: "#64748B", d: "M21 12q-3.6 6-9 6t-9-6q3.6-6 9-6t9 6" })
1703
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)("g", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", children: [
1704
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("path", { d: "M10 12a2 2 0 1 0 4 0 2 2 0 0 0-4 0" }),
1705
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("path", { d: "M21 12q-3.6 6-9 6t-9-6q3.6-6 9-6t9 6" })
1526
1706
  ] }) });
1527
1707
  };
1528
1708
  var eye_default = SvgEye;
1529
1709
 
1530
1710
  // src/theme/default/components/form/input.tsx
1531
- var import_jsx_runtime44 = require("react/jsx-runtime");
1711
+ var import_jsx_runtime45 = require("react/jsx-runtime");
1532
1712
  var DefaultInput = ({
1533
1713
  node,
1534
1714
  attributes,
1535
1715
  onClick
1536
1716
  }) => {
1537
- const label = (0, import_client_fetch10.getNodeLabel)(node);
1717
+ const label = (0, import_client_fetch12.getNodeLabel)(node);
1538
1718
  const { register } = (0, import_react_hook_form5.useFormContext)();
1539
1719
  const {
1540
1720
  value,
@@ -1545,19 +1725,19 @@ var DefaultInput = ({
1545
1725
  ...rest
1546
1726
  } = attributes;
1547
1727
  const intl = (0, import_react_intl9.useIntl)();
1548
- const { flowType } = (0, import_elements_react9.useOryFlow)();
1549
- const inputRef = (0, import_react5.useRef)(null);
1728
+ const { flowType } = (0, import_elements_react10.useOryFlow)();
1729
+ const inputRef = (0, import_react6.useRef)(null);
1550
1730
  const formattedLabel = label ? intl.formatMessage(
1551
1731
  {
1552
1732
  id: "input.placeholder",
1553
1733
  defaultMessage: "Enter your {placeholder}"
1554
1734
  },
1555
1735
  {
1556
- placeholder: (0, import_elements_react9.uiTextToFormattedMessage)(label, intl)
1736
+ placeholder: (0, import_elements_react10.uiTextToFormattedMessage)(label, intl)
1557
1737
  }
1558
1738
  ) : "";
1559
1739
  if (rest.type === "hidden") {
1560
- return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
1740
+ return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
1561
1741
  "input",
1562
1742
  {
1563
1743
  ...rest,
@@ -1571,16 +1751,16 @@ var DefaultInput = ({
1571
1751
  );
1572
1752
  }
1573
1753
  const { ref, ...restRegister } = register(name, { value });
1574
- return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
1754
+ return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
1575
1755
  "div",
1576
1756
  {
1577
1757
  className: cn(
1578
1758
  "relative flex justify-stretch",
1579
1759
  // The settings flow input fields are supposed to be dense, so we don't need the extra padding we want on the user flows.
1580
- flowType === import_client_fetch10.FlowType.Settings && "max-w-[488px]"
1760
+ flowType === import_client_fetch12.FlowType.Settings && "max-w-[488px]"
1581
1761
  ),
1582
1762
  children: [
1583
- /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
1763
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
1584
1764
  "input",
1585
1765
  {
1586
1766
  ...rest,
@@ -1604,7 +1784,7 @@ var DefaultInput = ({
1604
1784
  ...restRegister
1605
1785
  }
1606
1786
  ),
1607
- rest.type === "password" && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(PasswordToggle, { inputRef })
1787
+ rest.type === "password" && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(PasswordToggle, { inputRef })
1608
1788
  ]
1609
1789
  }
1610
1790
  );
@@ -1612,30 +1792,31 @@ var DefaultInput = ({
1612
1792
  function PasswordToggle({
1613
1793
  inputRef
1614
1794
  }) {
1615
- const [shown, setShown] = (0, import_react5.useState)(false);
1795
+ const [shown, setShown] = (0, import_react6.useState)(false);
1616
1796
  const handleClick = () => {
1617
1797
  setShown(!shown);
1618
1798
  if (inputRef.current) {
1619
1799
  inputRef.current.type = shown ? "password" : "text";
1620
1800
  }
1621
1801
  };
1622
- return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
1802
+ return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
1623
1803
  "button",
1624
1804
  {
1625
1805
  onClick: handleClick,
1626
1806
  className: "absolute right-0 h-full w-12 flex items-center justify-center",
1627
1807
  type: "button",
1628
- children: shown ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(eye_off_default, {}) : /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(eye_default, {})
1808
+ "aria-label": "Toggle password visibility",
1809
+ children: shown ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(eye_off_default, {}) : /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(eye_default, {})
1629
1810
  }
1630
1811
  );
1631
1812
  }
1632
1813
 
1633
1814
  // src/theme/default/components/form/label.tsx
1634
- var import_client_fetch11 = require("@ory/client-fetch");
1635
- var import_elements_react10 = require("@ory/elements-react");
1815
+ var import_client_fetch13 = require("@ory/client-fetch");
1816
+ var import_elements_react11 = require("@ory/elements-react");
1636
1817
  var import_react_hook_form6 = require("react-hook-form");
1637
1818
  var import_react_intl10 = require("react-intl");
1638
- var import_jsx_runtime45 = require("react/jsx-runtime");
1819
+ var import_jsx_runtime46 = require("react/jsx-runtime");
1639
1820
  function findResendNode(nodes) {
1640
1821
  return nodes.find(
1641
1822
  (n) => "name" in n.attributes && (n.attributes.name === "email" && n.attributes.type === "submit" || n.attributes.name === "resend")
@@ -1648,9 +1829,9 @@ function DefaultLabel({
1648
1829
  ...rest
1649
1830
  }) {
1650
1831
  const intl = (0, import_react_intl10.useIntl)();
1651
- const label = (0, import_client_fetch11.getNodeLabel)(node);
1652
- const { Message } = (0, import_elements_react10.useComponents)();
1653
- const { config, flowType, flow } = (0, import_elements_react10.useOryFlow)();
1832
+ const label = (0, import_client_fetch13.getNodeLabel)(node);
1833
+ const { Message } = (0, import_elements_react11.useComponents)();
1834
+ const { config, flowType, flow } = (0, import_elements_react11.useOryFlow)();
1654
1835
  const { setValue, formState } = (0, import_react_hook_form6.useFormContext)();
1655
1836
  const isPassword = attributes.type === "password";
1656
1837
  const resendNode = findResendNode(flow.ui.nodes);
@@ -1660,21 +1841,21 @@ function DefaultLabel({
1660
1841
  }
1661
1842
  };
1662
1843
  const fieldError = formState.errors[attributes.name];
1663
- return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "flex flex-col gap-1 antialiased", children: [
1664
- label && /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("span", { className: "inline-flex justify-between", children: [
1665
- /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
1844
+ return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: "flex flex-col gap-1 antialiased", children: [
1845
+ label && /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("span", { className: "inline-flex justify-between", children: [
1846
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
1666
1847
  "label",
1667
1848
  {
1668
- ...(0, import_elements_react10.messageTestId)(label),
1849
+ ...(0, import_elements_react11.messageTestId)(label),
1669
1850
  className: "leading-normal text-input-foreground-primary",
1670
1851
  htmlFor: attributes.name,
1671
1852
  "data-testid": `ory/form/node/input/label/${attributes.name}`,
1672
1853
  ...rest,
1673
- children: (0, import_elements_react10.uiTextToFormattedMessage)(label, intl)
1854
+ children: (0, import_elements_react11.uiTextToFormattedMessage)(label, intl)
1674
1855
  }
1675
1856
  ),
1676
- isPassword && config.project.recovery_enabled && flowType === import_client_fetch11.FlowType.Login && // TODO: make it possible to override with a custom component
1677
- /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
1857
+ isPassword && config.project.recovery_enabled && flowType === import_client_fetch13.FlowType.Login && // TODO: make it possible to override with a custom component
1858
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
1678
1859
  "a",
1679
1860
  {
1680
1861
  href: initFlowUrl(config.sdk.url, "recovery", flow),
@@ -1685,7 +1866,7 @@ function DefaultLabel({
1685
1866
  })
1686
1867
  }
1687
1868
  ),
1688
- (resendNode == null ? void 0 : resendNode.attributes.node_type) === "input" && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
1869
+ (resendNode == null ? void 0 : resendNode.attributes.node_type) === "input" && /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
1689
1870
  "button",
1690
1871
  {
1691
1872
  type: "submit",
@@ -1698,31 +1879,31 @@ function DefaultLabel({
1698
1879
  )
1699
1880
  ] }),
1700
1881
  children,
1701
- node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Message.Content, { message }, message.id)),
1702
- fieldError && (0, import_client_fetch11.instanceOfUiText)(fieldError) && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Message.Content, { message: fieldError })
1882
+ node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(Message.Content, { message }, message.id)),
1883
+ fieldError && (0, import_client_fetch13.instanceOfUiText)(fieldError) && /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(Message.Content, { message: fieldError })
1703
1884
  ] });
1704
1885
  }
1705
1886
 
1706
1887
  // src/theme/default/components/form/link-button.tsx
1707
- var import_client_fetch12 = require("@ory/client-fetch");
1708
- var import_elements_react11 = require("@ory/elements-react");
1709
- var import_react6 = require("react");
1888
+ var import_client_fetch14 = require("@ory/client-fetch");
1889
+ var import_elements_react12 = require("@ory/elements-react");
1890
+ var import_react7 = require("react");
1710
1891
  var import_react_intl11 = require("react-intl");
1711
- var import_jsx_runtime46 = require("react/jsx-runtime");
1712
- var DefaultLinkButton = (0, import_react6.forwardRef)(({ attributes, node }, ref) => {
1892
+ var import_jsx_runtime47 = require("react/jsx-runtime");
1893
+ var DefaultLinkButton = (0, import_react7.forwardRef)(({ attributes, node }, ref) => {
1713
1894
  const intl = (0, import_react_intl11.useIntl)();
1714
- const label = (0, import_client_fetch12.getNodeLabel)(node);
1715
- return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
1895
+ const label = (0, import_client_fetch14.getNodeLabel)(node);
1896
+ return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
1716
1897
  "a",
1717
1898
  {
1718
1899
  ...attributes,
1719
1900
  ref,
1720
- title: label ? (0, import_elements_react11.uiTextToFormattedMessage)(label, intl) : "",
1901
+ title: label ? (0, import_elements_react12.uiTextToFormattedMessage)(label, intl) : "",
1721
1902
  "data-testid": `ory/form/node/link/${attributes.id}`,
1722
1903
  className: cn(
1723
1904
  "antialiased rounded cursor-pointer text-center border gap-3 leading-none bg-button-primary-background-default hover:bg-button-primary-background-hover transition-colors text-button-primary-foreground-default hover:text-button-primary-foreground-hover p-4 font-medium"
1724
1905
  ),
1725
- children: label ? (0, import_elements_react11.uiTextToFormattedMessage)(label, intl) : ""
1906
+ children: label ? (0, import_elements_react12.uiTextToFormattedMessage)(label, intl) : ""
1726
1907
  }
1727
1908
  );
1728
1909
  });
@@ -1734,8 +1915,8 @@ var import_react_hook_form7 = require("react-hook-form");
1734
1915
  // src/theme/default/components/form/shadcn/otp-input.tsx
1735
1916
  var import_input_otp = require("input-otp");
1736
1917
  var React26 = __toESM(require("react"));
1737
- var import_jsx_runtime47 = require("react/jsx-runtime");
1738
- var InputOTP = React26.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
1918
+ var import_jsx_runtime48 = require("react/jsx-runtime");
1919
+ var InputOTP = React26.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
1739
1920
  import_input_otp.OTPInput,
1740
1921
  {
1741
1922
  ref,
@@ -1748,12 +1929,12 @@ var InputOTP = React26.forwardRef(({ className, containerClassName, ...props },
1748
1929
  }
1749
1930
  ));
1750
1931
  InputOTP.displayName = "InputOTP";
1751
- var InputOTPGroup = React26.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { ref, className: cn("flex items-center", className), ...props }));
1932
+ var InputOTPGroup = React26.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { ref, className: cn("flex items-center", className), ...props }));
1752
1933
  InputOTPGroup.displayName = "InputOTPGroup";
1753
1934
  var InputOTPSlot = React26.forwardRef(({ index, className, ...props }, ref) => {
1754
1935
  const inputOTPContext = React26.useContext(import_input_otp.OTPInputContext);
1755
1936
  const { char, hasFakeCaret, isActive } = inputOTPContext.slots[index];
1756
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(
1937
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
1757
1938
  "div",
1758
1939
  {
1759
1940
  ref,
@@ -1765,8 +1946,8 @@ var InputOTPSlot = React26.forwardRef(({ index, className, ...props }, ref) => {
1765
1946
  ),
1766
1947
  ...props,
1767
1948
  children: [
1768
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "inline-block size-4", children: char }),
1769
- hasFakeCaret && /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "h-4 w-px animate-caret-blink bg-interface-background-brand-primary duration-700" }) })
1949
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "inline-block size-4", children: char }),
1950
+ hasFakeCaret && /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "h-4 w-px animate-caret-blink bg-interface-background-brand-primary duration-700" }) })
1770
1951
  ]
1771
1952
  }
1772
1953
  );
@@ -1774,34 +1955,34 @@ var InputOTPSlot = React26.forwardRef(({ index, className, ...props }, ref) => {
1774
1955
  InputOTPSlot.displayName = "InputOTPSlot";
1775
1956
 
1776
1957
  // src/theme/default/components/form/pin-code-input.tsx
1777
- var import_elements_react12 = require("@ory/elements-react");
1778
- var import_client_fetch13 = require("@ory/client-fetch");
1779
- var import_jsx_runtime48 = require("react/jsx-runtime");
1958
+ var import_elements_react13 = require("@ory/elements-react");
1959
+ var import_client_fetch15 = require("@ory/client-fetch");
1960
+ var import_jsx_runtime49 = require("react/jsx-runtime");
1780
1961
  var DefaultPinCodeInput = ({ attributes }) => {
1781
1962
  const { setValue, watch } = (0, import_react_hook_form7.useFormContext)();
1782
1963
  const { maxlength, name } = attributes;
1783
1964
  const elements = maxlength != null ? maxlength : 6;
1784
- const { flowType } = (0, import_elements_react12.useOryFlow)();
1965
+ const { flowType } = (0, import_elements_react13.useOryFlow)();
1785
1966
  const handleInputChange = (v) => {
1786
1967
  setValue(name, v);
1787
1968
  };
1788
1969
  const value = watch(name);
1789
- return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
1970
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
1790
1971
  InputOTP,
1791
1972
  {
1792
1973
  maxLength: maxlength != null ? maxlength : 6,
1793
1974
  onChange: handleInputChange,
1794
1975
  name,
1795
1976
  value,
1796
- children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
1977
+ children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
1797
1978
  InputOTPGroup,
1798
1979
  {
1799
1980
  className: cn(
1800
1981
  "w-full flex gap-2 justify-stretch",
1801
1982
  // The settings flow input fields are supposed to be dense, so we don't need the extra padding we want on the user flows.
1802
- flowType === import_client_fetch13.FlowType.Settings && "max-w-[488px]"
1983
+ flowType === import_client_fetch15.FlowType.Settings && "max-w-[488px]"
1803
1984
  ),
1804
- children: [...Array(elements)].map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(InputOTPSlot, { index }, index))
1985
+ children: [...Array(elements)].map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(InputOTPSlot, { index }, index))
1805
1986
  }
1806
1987
  )
1807
1988
  }
@@ -1809,13 +1990,13 @@ var DefaultPinCodeInput = ({ attributes }) => {
1809
1990
  };
1810
1991
 
1811
1992
  // src/theme/default/components/form/section.tsx
1812
- var import_jsx_runtime49 = require("react/jsx-runtime");
1993
+ var import_jsx_runtime50 = require("react/jsx-runtime");
1813
1994
  var DefaultFormSection = ({
1814
1995
  children,
1815
1996
  nodes: _nodes,
1816
1997
  ...rest
1817
1998
  }) => {
1818
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
1999
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
1819
2000
  "form",
1820
2001
  {
1821
2002
  className: "flex w-full max-w-screen-sm flex-col md:max-w-[712px] lg:max-w-[802px] xl:max-w-[896px] px-4",
@@ -1829,10 +2010,10 @@ var DefaultFormSectionContent = ({
1829
2010
  description,
1830
2011
  children
1831
2012
  }) => {
1832
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "flex flex-col gap-8 rounded-t-cards border border-b-0 border-interface-border-default-primary bg-interface-background-default-primary px-6 py-8", children: [
1833
- /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "flex flex-col gap-2", children: [
1834
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("h3", { className: "font-medium text-interface-foreground-default-primary", children: title }),
1835
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "text-interface-foreground-default-secondary", children: description })
2013
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "flex flex-col gap-8 rounded-t-cards border border-b-0 border-interface-border-default-primary bg-interface-background-default-primary px-6 py-8", children: [
2014
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "flex flex-col gap-2", children: [
2015
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("h3", { className: "font-medium text-interface-foreground-default-primary", children: title }),
2016
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("span", { className: "text-interface-foreground-default-secondary", children: description })
1836
2017
  ] }),
1837
2018
  children
1838
2019
  ] });
@@ -1841,14 +2022,14 @@ var DefaultFormSectionFooter = ({
1841
2022
  children,
1842
2023
  text
1843
2024
  }) => {
1844
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
2025
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
1845
2026
  "div",
1846
2027
  {
1847
2028
  className: cn(
1848
2029
  "flex min-h-[72px] items-center justify-between gap-2 rounded-b-cards border border-interface-border-default-primary bg-interface-background-default-secondary px-6 py-4 text-interface-foreground-default-tertiary"
1849
2030
  ),
1850
2031
  children: [
1851
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { children: text }),
2032
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("span", { children: text }),
1852
2033
  children
1853
2034
  ]
1854
2035
  }
@@ -1856,74 +2037,74 @@ var DefaultFormSectionFooter = ({
1856
2037
  };
1857
2038
 
1858
2039
  // src/theme/default/components/form/text.tsx
1859
- var import_elements_react13 = require("@ory/elements-react");
2040
+ var import_elements_react14 = require("@ory/elements-react");
1860
2041
  var import_react_intl12 = require("react-intl");
1861
- var import_jsx_runtime50 = require("react/jsx-runtime");
2042
+ var import_jsx_runtime51 = require("react/jsx-runtime");
1862
2043
  function DefaultText({ node, attributes }) {
1863
2044
  var _a;
1864
2045
  const intl = (0, import_react_intl12.useIntl)();
1865
2046
  const lookup = (_a = attributes.text.context) == null ? void 0 : _a.secrets;
1866
2047
  if (lookup) {
1867
- return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_jsx_runtime50.Fragment, { children: [
1868
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("p", { "data-testid": `ory/form/node/text/${attributes.id}/label`, children: node.meta.label ? (0, import_elements_react13.uiTextToFormattedMessage)(node.meta.label, intl) : "" }),
1869
- lookup.map((text, index) => /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
2048
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_jsx_runtime51.Fragment, { children: [
2049
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("p", { "data-testid": `ory/form/node/text/${attributes.id}/label`, children: node.meta.label ? (0, import_elements_react14.uiTextToFormattedMessage)(node.meta.label, intl) : "" }),
2050
+ lookup.map((text, index) => /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
1870
2051
  "pre",
1871
2052
  {
1872
2053
  "data-testid": `ory/form/node/text/lookup_secret_codes/text`,
1873
- children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("code", { children: text ? (0, import_elements_react13.uiTextToFormattedMessage)(text, intl) : "" })
2054
+ children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("code", { children: text ? (0, import_elements_react14.uiTextToFormattedMessage)(text, intl) : "" })
1874
2055
  },
1875
2056
  index
1876
2057
  ))
1877
2058
  ] });
1878
2059
  }
1879
- return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_jsx_runtime50.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
2060
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_jsx_runtime51.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
1880
2061
  "p",
1881
2062
  {
1882
2063
  "data-testid": `ory/form/node/text/${attributes.id}/label`,
1883
2064
  id: attributes.id,
1884
2065
  children: [
1885
- node.meta.label ? /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("label", { children: (0, import_elements_react13.uiTextToFormattedMessage)(node.meta.label, intl) }) : null,
1886
- attributes.text ? (0, import_elements_react13.uiTextToFormattedMessage)(attributes.text, intl) : ""
2066
+ node.meta.label ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("label", { children: (0, import_elements_react14.uiTextToFormattedMessage)(node.meta.label, intl) }) : null,
2067
+ attributes.text ? (0, import_elements_react14.uiTextToFormattedMessage)(attributes.text, intl) : ""
1887
2068
  ]
1888
2069
  }
1889
2070
  ) });
1890
2071
  }
1891
2072
 
1892
2073
  // src/theme/default/components/generic/page-header.tsx
1893
- var import_elements_react15 = require("@ory/elements-react");
2074
+ var import_elements_react16 = require("@ory/elements-react");
1894
2075
 
1895
2076
  // src/theme/default/components/ui/user-menu.tsx
1896
- var import_elements_react14 = require("@ory/elements-react");
2077
+ var import_elements_react15 = require("@ory/elements-react");
1897
2078
  var import_react_dropdown_menu = require("@radix-ui/react-dropdown-menu");
1898
2079
 
1899
2080
  // src/theme/default/assets/icons/logout.svg
1900
2081
  var React27 = __toESM(require("react"));
1901
- var import_jsx_runtime51 = require("react/jsx-runtime");
2082
+ var import_jsx_runtime52 = require("react/jsx-runtime");
1902
2083
  var SvgLogout = (props) => {
1903
2084
  var _a, _b;
1904
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M9.333 5.334V4A1.333 1.333 0 0 0 8 2.667H3.333A1.333 1.333 0 0 0 2 4v8a1.333 1.333 0 0 0 1.333 1.334H8A1.333 1.333 0 0 0 9.333 12v-1.333M4.667 8H14m0 0-2-2m2 2-2 2" }) });
2085
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M9.333 5.334V4A1.333 1.333 0 0 0 8 2.667H3.333A1.333 1.333 0 0 0 2 4v8a1.333 1.333 0 0 0 1.333 1.334H8A1.333 1.333 0 0 0 9.333 12v-1.333M4.667 8H14m0 0-2-2m2 2-2 2" }) });
1905
2086
  };
1906
2087
  var logout_default = SvgLogout;
1907
2088
 
1908
2089
  // src/theme/default/assets/icons/settings.svg
1909
2090
  var React28 = __toESM(require("react"));
1910
- var import_jsx_runtime52 = require("react/jsx-runtime");
2091
+ var import_jsx_runtime53 = require("react/jsx-runtime");
1911
2092
  var SvgSettings = (props) => {
1912
2093
  var _a, _b;
1913
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("g", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", children: [
1914
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("path", { d: "M6.883 2.878c.284-1.17 1.95-1.17 2.234 0a1.15 1.15 0 0 0 1.715.71c1.029-.626 2.207.551 1.58 1.58a1.148 1.148 0 0 0 .71 1.715c1.17.284 1.17 1.95 0 2.234a1.15 1.15 0 0 0-.71 1.715c.626 1.029-.551 2.207-1.58 1.58a1.148 1.148 0 0 0-1.715.71c-.284 1.17-1.95 1.17-2.234 0a1.15 1.15 0 0 0-1.715-.71c-1.029.626-2.207-.551-1.58-1.58a1.15 1.15 0 0 0-.71-1.715c-1.17-.284-1.17-1.95 0-2.234a1.15 1.15 0 0 0 .71-1.715c-.626-1.029.551-2.207 1.58-1.58.667.405 1.531.047 1.715-.71" }),
1915
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("path", { d: "M6 8a2 2 0 1 0 4 0 2 2 0 0 0-4 0" })
2094
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("g", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", children: [
2095
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("path", { d: "M6.883 2.878c.284-1.17 1.95-1.17 2.234 0a1.15 1.15 0 0 0 1.715.71c1.029-.626 2.207.551 1.58 1.58a1.148 1.148 0 0 0 .71 1.715c1.17.284 1.17 1.95 0 2.234a1.15 1.15 0 0 0-.71 1.715c.626 1.029-.551 2.207-1.58 1.58a1.148 1.148 0 0 0-1.715.71c-.284 1.17-1.95 1.17-2.234 0a1.15 1.15 0 0 0-1.715-.71c-1.029.626-2.207-.551-1.58-1.58a1.15 1.15 0 0 0-.71-1.715c-1.17-.284-1.17-1.95 0-2.234a1.15 1.15 0 0 0 .71-1.715c-.626-1.029.551-2.207 1.58-1.58.667.405 1.531.047 1.715-.71" }),
2096
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("path", { d: "M6 8a2 2 0 1 0 4 0 2 2 0 0 0-4 0" })
1916
2097
  ] }) });
1917
2098
  };
1918
2099
  var settings_default = SvgSettings;
1919
2100
 
1920
2101
  // src/theme/default/utils/logout.ts
1921
- var import_react7 = require("react");
2102
+ var import_react8 = require("react");
1922
2103
 
1923
2104
  // src/util/client.ts
1924
- var import_client_fetch14 = require("@ory/client-fetch");
2105
+ var import_client_fetch16 = require("@ory/client-fetch");
1925
2106
  function frontendClient(sdkUrl, opts = {}) {
1926
- const config = new import_client_fetch14.Configuration({
2107
+ const config = new import_client_fetch16.Configuration({
1927
2108
  ...opts,
1928
2109
  basePath: sdkUrl,
1929
2110
  headers: {
@@ -1931,17 +2112,17 @@ function frontendClient(sdkUrl, opts = {}) {
1931
2112
  ...opts.headers
1932
2113
  }
1933
2114
  });
1934
- return new import_client_fetch14.FrontendApi(config);
2115
+ return new import_client_fetch16.FrontendApi(config);
1935
2116
  }
1936
2117
 
1937
2118
  // src/theme/default/utils/logout.ts
1938
2119
  function useClientLogout(config) {
1939
- const [logoutFlow, setLogoutFlow] = (0, import_react7.useState)();
1940
- const fetchLogoutFlow = (0, import_react7.useCallback)(async () => {
2120
+ const [logoutFlow, setLogoutFlow] = (0, import_react8.useState)();
2121
+ const fetchLogoutFlow = (0, import_react8.useCallback)(async () => {
1941
2122
  const flow = await frontendClient(config.sdk.url).createBrowserLogoutFlow();
1942
2123
  setLogoutFlow(flow);
1943
2124
  }, [config.sdk.url]);
1944
- (0, import_react7.useEffect)(() => {
2125
+ (0, import_react8.useEffect)(() => {
1945
2126
  void fetchLogoutFlow();
1946
2127
  }, [fetchLogoutFlow]);
1947
2128
  return logoutFlow;
@@ -1987,12 +2168,12 @@ var getUserInitials = (session) => {
1987
2168
  };
1988
2169
 
1989
2170
  // src/theme/default/components/ui/dropdown-menu.tsx
1990
- var import_react8 = require("react");
2171
+ var import_react9 = require("react");
1991
2172
  var DropdownMenuPrimitive = __toESM(require("@radix-ui/react-dropdown-menu"));
1992
- var import_jsx_runtime53 = require("react/jsx-runtime");
2173
+ var import_jsx_runtime54 = require("react/jsx-runtime");
1993
2174
  var DropdownMenu = DropdownMenuPrimitive.Root;
1994
2175
  var DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
1995
- var DropdownMenuContent = (0, import_react8.forwardRef)(({ className, sideOffset = 16, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
2176
+ var DropdownMenuContent = (0, import_react9.forwardRef)(({ className, sideOffset = 16, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
1996
2177
  DropdownMenuPrimitive.Content,
1997
2178
  {
1998
2179
  ref,
@@ -2007,7 +2188,7 @@ var DropdownMenuContent = (0, import_react8.forwardRef)(({ className, sideOffset
2007
2188
  }
2008
2189
  ) }));
2009
2190
  DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
2010
- var DropdownMenuItem = (0, import_react8.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
2191
+ var DropdownMenuItem = (0, import_react9.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
2011
2192
  DropdownMenuPrimitive.Item,
2012
2193
  {
2013
2194
  ref,
@@ -2025,7 +2206,7 @@ var DropdownMenuItem = (0, import_react8.forwardRef)(({ className, inset, ...pro
2025
2206
  }
2026
2207
  ));
2027
2208
  DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
2028
- var DropdownMenuLabel = (0, import_react8.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
2209
+ var DropdownMenuLabel = (0, import_react9.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
2029
2210
  DropdownMenuPrimitive.Label,
2030
2211
  {
2031
2212
  ref,
@@ -2040,35 +2221,35 @@ var DropdownMenuLabel = (0, import_react8.forwardRef)(({ className, inset, ...pr
2040
2221
  DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
2041
2222
 
2042
2223
  // src/theme/default/components/ui/user-avater.tsx
2043
- var import_react9 = require("react");
2224
+ var import_react10 = require("react");
2044
2225
 
2045
2226
  // src/theme/default/assets/icons/user.svg
2046
2227
  var React29 = __toESM(require("react"));
2047
- var import_jsx_runtime54 = require("react/jsx-runtime");
2228
+ var import_jsx_runtime55 = require("react/jsx-runtime");
2048
2229
  var SvgUser = (props) => {
2049
2230
  var _a, _b;
2050
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M6 21v-2a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v2M8 7a4 4 0 1 0 8 0 4 4 0 0 0-8 0" }) });
2231
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M6 21v-2a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v2M8 7a4 4 0 1 0 8 0 4 4 0 0 0-8 0" }) });
2051
2232
  };
2052
2233
  var user_default = SvgUser;
2053
2234
 
2054
2235
  // src/theme/default/components/ui/user-avater.tsx
2055
- var import_jsx_runtime55 = require("react/jsx-runtime");
2056
- var UserAvatar = (0, import_react9.forwardRef)(
2236
+ var import_jsx_runtime56 = require("react/jsx-runtime");
2237
+ var UserAvatar = (0, import_react10.forwardRef)(
2057
2238
  ({ initials, ...rest }, ref) => {
2058
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
2239
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
2059
2240
  "button",
2060
2241
  {
2061
2242
  ref,
2062
2243
  className: "relative flex size-10 items-center justify-center overflow-hidden rounded-[999px] bg-button-primary-background-default hover:bg-button-primary-background-hover",
2063
2244
  ...rest,
2064
- children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "relative flex size-full items-center justify-center", children: initials.avatar ? /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
2245
+ children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: "relative flex size-full items-center justify-center", children: initials.avatar ? /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
2065
2246
  "img",
2066
2247
  {
2067
2248
  src: initials.avatar,
2068
2249
  alt: initials.primary,
2069
2250
  className: "w-full object-contain"
2070
2251
  }
2071
- ) : /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
2252
+ ) : /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
2072
2253
  user_default,
2073
2254
  {
2074
2255
  size: 24,
@@ -2082,27 +2263,27 @@ var UserAvatar = (0, import_react9.forwardRef)(
2082
2263
  UserAvatar.displayName = "UserAvatar";
2083
2264
 
2084
2265
  // src/theme/default/components/ui/user-menu.tsx
2085
- var import_jsx_runtime56 = require("react/jsx-runtime");
2266
+ var import_jsx_runtime57 = require("react/jsx-runtime");
2086
2267
  var UserMenu = ({ session }) => {
2087
- const { config } = (0, import_elements_react14.useOryFlow)();
2268
+ const { config } = (0, import_elements_react15.useOryFlow)();
2088
2269
  const initials = getUserInitials(session);
2089
2270
  const logoutFlow = useClientLogout(config);
2090
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(DropdownMenu, { children: [
2091
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(UserAvatar, { initials }) }),
2092
- /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(DropdownMenuContent, { children: [
2093
- /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_react_dropdown_menu.DropdownMenuLabel, { className: "flex gap-3 px-5 py-4.5", children: [
2094
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(UserAvatar, { disabled: true, initials }),
2095
- /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("div", { className: "flex flex-col justify-center text-sm leading-tight", children: [
2096
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: "text-interface-foreground-default-primary leading-tight font-medium", children: initials.primary }),
2097
- initials.secondary && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: "text-interface-foreground-default-tertiary leading-tight", children: initials.secondary })
2271
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(DropdownMenu, { children: [
2272
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(UserAvatar, { initials, title: "User Menu" }) }),
2273
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(DropdownMenuContent, { children: [
2274
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(import_react_dropdown_menu.DropdownMenuLabel, { className: "flex gap-3 px-5 py-4.5", children: [
2275
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(UserAvatar, { disabled: true, initials }),
2276
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: "flex flex-col justify-center text-sm leading-tight", children: [
2277
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: "text-interface-foreground-default-primary leading-tight font-medium", children: initials.primary }),
2278
+ initials.secondary && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: "text-interface-foreground-default-tertiary leading-tight", children: initials.secondary })
2098
2279
  ] })
2099
2280
  ] }),
2100
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("a", { href: "/settings", children: [
2101
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(settings_default, { size: 16 }),
2281
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("a", { href: "/settings", children: [
2282
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(settings_default, { size: 16 }),
2102
2283
  " User settings"
2103
2284
  ] }) }),
2104
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(DropdownMenuItem, { asChild: true, disabled: !(logoutFlow == null ? void 0 : logoutFlow.logout_url), children: /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("a", { href: logoutFlow == null ? void 0 : logoutFlow.logout_url, children: [
2105
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(logout_default, { size: 16 }),
2285
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(DropdownMenuItem, { asChild: true, disabled: !(logoutFlow == null ? void 0 : logoutFlow.logout_url), children: /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("a", { href: logoutFlow == null ? void 0 : logoutFlow.logout_url, children: [
2286
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(logout_default, { size: 16 }),
2106
2287
  " Logout"
2107
2288
  ] }) })
2108
2289
  ] })
@@ -2111,42 +2292,42 @@ var UserMenu = ({ session }) => {
2111
2292
 
2112
2293
  // src/theme/default/components/generic/page-header.tsx
2113
2294
  var import_client2 = require("@ory/elements-react/client");
2114
- var import_jsx_runtime57 = require("react/jsx-runtime");
2295
+ var import_jsx_runtime58 = require("react/jsx-runtime");
2115
2296
  var DefaultPageHeader = (_props) => {
2116
- const { Card } = (0, import_elements_react15.useComponents)();
2297
+ const { Card } = (0, import_elements_react16.useComponents)();
2117
2298
  const { session } = (0, import_client2.useSession)();
2118
- return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: "mt-16 flex max-w-screen-sm w-full md:max-w-[712px] lg:max-w-[802px] xl:max-w-[896px] flex-col gap-3 px-4", children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: "flex flex-col gap-12", children: /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: "flex max-h-10 flex-1 justify-between gap-2", children: [
2119
- /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: "relative h-10 flex-1", children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Card.Logo, {}) }),
2120
- /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(UserMenu, { session })
2299
+ return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "mt-16 flex max-w-screen-sm w-full md:max-w-[712px] lg:max-w-[802px] xl:max-w-[896px] flex-col gap-3 px-4", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "flex flex-col gap-12", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex max-h-10 flex-1 justify-between gap-2", children: [
2300
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "relative h-10 flex-1", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Card.Logo, {}) }),
2301
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(UserMenu, { session })
2121
2302
  ] }) }) });
2122
2303
  };
2123
2304
 
2124
2305
  // src/theme/default/components/settings/settings-oidc.tsx
2125
- var import_react10 = require("react");
2306
+ var import_react11 = require("react");
2126
2307
  var import_react_hook_form8 = require("react-hook-form");
2127
2308
  var import_usehooks_ts2 = require("usehooks-ts");
2128
2309
 
2129
2310
  // src/theme/default/assets/icons/trash.svg
2130
2311
  var React30 = __toESM(require("react"));
2131
- var import_jsx_runtime58 = require("react/jsx-runtime");
2312
+ var import_jsx_runtime59 = require("react/jsx-runtime");
2132
2313
  var SvgTrash = (props) => {
2133
2314
  var _a, _b;
2134
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M4 7h16m-10 4v6m4-6v6M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2l1-12M9 7V4a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v3" }) });
2315
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M4 7h16m-10 4v6m4-6v6M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2l1-12M9 7V4a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v3" }) });
2135
2316
  };
2136
2317
  var trash_default = SvgTrash;
2137
2318
 
2138
2319
  // src/theme/default/components/settings/settings-oidc.tsx
2139
- var import_jsx_runtime59 = require("react/jsx-runtime");
2320
+ var import_jsx_runtime60 = require("react/jsx-runtime");
2140
2321
  function DefaultSettingsOidc({
2141
2322
  linkButtons,
2142
2323
  unlinkButtons
2143
2324
  }) {
2144
2325
  const hasLinkButtons = linkButtons.length > 0;
2145
2326
  const hasUnlinkButtons = unlinkButtons.length > 0;
2146
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex flex-col gap-8", children: [
2147
- hasLinkButtons && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "grid items-start gap-3 grid-cols-1 sm:grid-cols-2 md:grid-cols-3", children: linkButtons.map((button) => {
2327
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex flex-col gap-8", children: [
2328
+ hasLinkButtons && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "grid items-start gap-3 grid-cols-1 sm:grid-cols-2 md:grid-cols-3", children: linkButtons.map((button) => {
2148
2329
  const attrs = button.attributes;
2149
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
2330
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2150
2331
  DefaultButtonSocial,
2151
2332
  {
2152
2333
  showLabel: true,
@@ -2157,12 +2338,12 @@ function DefaultSettingsOidc({
2157
2338
  attrs.value
2158
2339
  );
2159
2340
  }) }),
2160
- hasUnlinkButtons && hasLinkButtons ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(DefaultHorizontalDivider, {}) : null,
2341
+ hasUnlinkButtons && hasLinkButtons ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DefaultHorizontalDivider, {}) : null,
2161
2342
  unlinkButtons.map((button) => {
2162
2343
  if (button.attributes.node_type !== "input") {
2163
2344
  return null;
2164
2345
  }
2165
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(UnlinkRow, { button }, button.attributes.value);
2346
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(UnlinkRow, { button }, button.attributes.value);
2166
2347
  })
2167
2348
  ] });
2168
2349
  }
@@ -2179,17 +2360,17 @@ function UnlinkRow({ button }) {
2179
2360
  button.onClick();
2180
2361
  setClicked(true);
2181
2362
  };
2182
- (0, import_react10.useEffect)(() => {
2363
+ (0, import_react11.useEffect)(() => {
2183
2364
  if (!isSubmitting) {
2184
2365
  setClicked(false);
2185
2366
  }
2186
2367
  }, [isSubmitting, setClicked]);
2187
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex justify-between", children: [
2188
- /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex items-center gap-6", children: [
2189
- Logo ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Logo, { size: 32 }) : /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(provider_logos_default.generic, { size: 32 }),
2190
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary", children: provider })
2368
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex justify-between", children: [
2369
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex items-center gap-6", children: [
2370
+ Logo ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Logo, { size: 32 }) : /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(provider_logos_default.generic, { size: 32 }),
2371
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary", children: provider })
2191
2372
  ] }),
2192
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
2373
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2193
2374
  "button",
2194
2375
  {
2195
2376
  ...attrs,
@@ -2198,7 +2379,7 @@ function UnlinkRow({ button }) {
2198
2379
  disabled: isSubmitting,
2199
2380
  className: "relative",
2200
2381
  title: `Unlink ${provider}`,
2201
- children: clicked ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Spinner, { className: "relative" }) : /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
2382
+ children: clicked ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Spinner, { className: "relative" }) : /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2202
2383
  trash_default,
2203
2384
  {
2204
2385
  className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover",
@@ -2211,9 +2392,9 @@ function UnlinkRow({ button }) {
2211
2392
  }
2212
2393
 
2213
2394
  // src/theme/default/components/settings/settings-passkey.tsx
2214
- var import_elements_react16 = require("@ory/elements-react");
2395
+ var import_elements_react17 = require("@ory/elements-react");
2215
2396
  var import_react_hook_form9 = require("react-hook-form");
2216
- var import_jsx_runtime60 = require("react/jsx-runtime");
2397
+ var import_jsx_runtime61 = require("react/jsx-runtime");
2217
2398
  function DefaultSettingsPasskey({
2218
2399
  triggerButton,
2219
2400
  removeButtons
@@ -2221,10 +2402,10 @@ function DefaultSettingsPasskey({
2221
2402
  const {
2222
2403
  formState: { isSubmitting }
2223
2404
  } = (0, import_react_hook_form9.useFormContext)();
2224
- const { Node: Node2 } = (0, import_elements_react16.useComponents)();
2405
+ const { Node: Node2 } = (0, import_elements_react17.useComponents)();
2225
2406
  const hasRemoveButtons = removeButtons.length > 0;
2226
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex flex-col gap-8", children: [
2227
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "flex max-w-[60%] items-end gap-3", children: triggerButton && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2407
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex flex-col gap-8", children: [
2408
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "flex max-w-[60%] items-end gap-3", children: triggerButton && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
2228
2409
  Node2.Button,
2229
2410
  {
2230
2411
  node: triggerButton,
@@ -2232,38 +2413,38 @@ function DefaultSettingsPasskey({
2232
2413
  onClick: triggerButton.onClick
2233
2414
  }
2234
2415
  ) }),
2235
- hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex flex-col gap-8", children: [
2236
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DefaultHorizontalDivider, {}),
2237
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "flex flex-col gap-2", children: removeButtons.map((node, i) => {
2416
+ hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex flex-col gap-8", children: [
2417
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(DefaultHorizontalDivider, {}),
2418
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "flex flex-col gap-2", children: removeButtons.map((node, i) => {
2238
2419
  var _a, _b;
2239
2420
  const context = (_b = (_a = node.meta.label) == null ? void 0 : _a.context) != null ? _b : {};
2240
2421
  const addedAt = "added_at" in context ? context.added_at : null;
2241
2422
  const displayName = "display_name" in context ? context.display_name : null;
2242
2423
  const keyId = "value" in node.attributes ? node.attributes.value : null;
2243
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
2424
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
2244
2425
  "div",
2245
2426
  {
2246
2427
  className: "flex justify-between gap-6 md:items-center",
2247
2428
  children: [
2248
- /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex gap-2 items-center flex-1 truncate", children: [
2249
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2429
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex gap-2 items-center flex-1 truncate", children: [
2430
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
2250
2431
  passkey_default,
2251
2432
  {
2252
2433
  size: 32,
2253
2434
  className: "text-interface-foreground-default-primary"
2254
2435
  }
2255
2436
  ),
2256
- /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex-1 flex-col md:flex-row md:items-center flex md:justify-between gap-4 truncate", children: [
2257
- /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex-1 flex-col truncate", children: [
2258
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary truncate", children: displayName }),
2259
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: "text-sm text-interface-foreground-default-tertiary hidden sm:block truncate", children: keyId })
2437
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex-1 flex-col md:flex-row md:items-center flex md:justify-between gap-4 truncate", children: [
2438
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex-1 flex-col truncate", children: [
2439
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary truncate", children: displayName }),
2440
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "text-sm text-interface-foreground-default-tertiary hidden sm:block truncate", children: keyId })
2260
2441
  ] }),
2261
- addedAt && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("p", { className: "text-sm text-interface-foreground-default-tertiary", children: new Intl.DateTimeFormat(void 0, {
2442
+ addedAt && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("p", { className: "text-sm text-interface-foreground-default-tertiary", children: new Intl.DateTimeFormat(void 0, {
2262
2443
  dateStyle: "long"
2263
2444
  }).format(new Date(addedAt)) })
2264
2445
  ] })
2265
2446
  ] }),
2266
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2447
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
2267
2448
  "button",
2268
2449
  {
2269
2450
  ...node.attributes,
@@ -2271,7 +2452,7 @@ function DefaultSettingsPasskey({
2271
2452
  onClick: node.onClick,
2272
2453
  disabled: isSubmitting,
2273
2454
  className: "relative",
2274
- children: isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Spinner, { className: "relative" }) : /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
2455
+ children: isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(Spinner, { className: "relative" }) : /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
2275
2456
  trash_default,
2276
2457
  {
2277
2458
  className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover",
@@ -2291,25 +2472,25 @@ function DefaultSettingsPasskey({
2291
2472
 
2292
2473
  // src/theme/default/assets/icons/download.svg
2293
2474
  var React31 = __toESM(require("react"));
2294
- var import_jsx_runtime61 = require("react/jsx-runtime");
2475
+ var import_jsx_runtime62 = require("react/jsx-runtime");
2295
2476
  var SvgDownload = (props) => {
2296
2477
  var _a, _b;
2297
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, fill: "none", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-2M7 11l5 5m0 0 5-5m-5 5V4" }) });
2478
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, fill: "none", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M4 17v2a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-2M7 11l5 5m0 0 5-5m-5 5V4" }) });
2298
2479
  };
2299
2480
  var download_default = SvgDownload;
2300
2481
 
2301
2482
  // src/theme/default/assets/icons/refresh.svg
2302
2483
  var React32 = __toESM(require("react"));
2303
- var import_jsx_runtime62 = require("react/jsx-runtime");
2484
+ var import_jsx_runtime63 = require("react/jsx-runtime");
2304
2485
  var SvgRefresh = (props) => {
2305
2486
  var _a, _b;
2306
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, fill: "none", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M20 11A8.1 8.1 0 0 0 4.5 9M4 5v4h4m-4 4a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4" }) });
2487
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, fill: "none", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M20 11A8.1 8.1 0 0 0 4.5 9M4 5v4h4m-4 4a8.1 8.1 0 0 0 15.5 2m.5 4v-4h-4" }) });
2307
2488
  };
2308
2489
  var refresh_default = SvgRefresh;
2309
2490
 
2310
2491
  // src/theme/default/components/settings/settings-recovery-codes.tsx
2311
2492
  var import_react_hook_form10 = require("react-hook-form");
2312
- var import_jsx_runtime63 = require("react/jsx-runtime");
2493
+ var import_jsx_runtime64 = require("react/jsx-runtime");
2313
2494
  function DefaultSettingsRecoveryCodes({
2314
2495
  codes,
2315
2496
  regnerateButton,
@@ -2331,12 +2512,12 @@ function DefaultSettingsRecoveryCodes({
2331
2512
  element.click();
2332
2513
  };
2333
2514
  const hasCodes = codes.length >= 1;
2334
- return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { className: "flex flex-col gap-8", children: [
2335
- codes.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(DefaultHorizontalDivider, {}),
2336
- /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { className: "flex gap-4 justify-between", children: [
2337
- /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { className: "text-interface-foreground-default-tertiary", children: revealButton && "Reveal recovery codes" }),
2338
- /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { className: "flex gap-2", children: [
2339
- regnerateButton && codes.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2515
+ return /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "flex flex-col gap-8", children: [
2516
+ codes.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(DefaultHorizontalDivider, {}),
2517
+ /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "flex gap-4 justify-between", children: [
2518
+ /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("span", { className: "text-interface-foreground-default-tertiary", children: revealButton && "Reveal recovery codes" }),
2519
+ /* @__PURE__ */ (0, import_jsx_runtime64.jsxs)("div", { className: "flex gap-2", children: [
2520
+ regnerateButton && codes.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2340
2521
  "button",
2341
2522
  {
2342
2523
  ...regnerateButton.attributes,
@@ -2345,7 +2526,7 @@ function DefaultSettingsRecoveryCodes({
2345
2526
  onClick: onRegenerate,
2346
2527
  disabled: isSubmitting,
2347
2528
  "data-loading": isSubmitting,
2348
- children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2529
+ children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2349
2530
  refresh_default,
2350
2531
  {
2351
2532
  size: 24,
@@ -2354,7 +2535,7 @@ function DefaultSettingsRecoveryCodes({
2354
2535
  )
2355
2536
  }
2356
2537
  ),
2357
- revealButton && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_jsx_runtime63.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2538
+ revealButton && /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_jsx_runtime64.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2358
2539
  "button",
2359
2540
  {
2360
2541
  ...revealButton.attributes,
@@ -2362,7 +2543,7 @@ function DefaultSettingsRecoveryCodes({
2362
2543
  className: "ml-auto",
2363
2544
  onClick: onReveal,
2364
2545
  title: "Reveal recovery codes",
2365
- children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2546
+ children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2366
2547
  eye_default,
2367
2548
  {
2368
2549
  size: 24,
@@ -2371,7 +2552,7 @@ function DefaultSettingsRecoveryCodes({
2371
2552
  )
2372
2553
  }
2373
2554
  ) }),
2374
- hasCodes && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2555
+ hasCodes && /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2375
2556
  "button",
2376
2557
  {
2377
2558
  onClick: onDownload,
@@ -2379,7 +2560,7 @@ function DefaultSettingsRecoveryCodes({
2379
2560
  className: "ml-auto",
2380
2561
  "data-testid": "ory/screen/settings/group/recovery_code/download",
2381
2562
  title: "Download recovery codes",
2382
- children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2563
+ children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2383
2564
  download_default,
2384
2565
  {
2385
2566
  size: 24,
@@ -2390,32 +2571,32 @@ function DefaultSettingsRecoveryCodes({
2390
2571
  )
2391
2572
  ] })
2392
2573
  ] }),
2393
- hasCodes ? /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "rounded-general p-6 bg-interface-background-default-secondary border-interface-border-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
2574
+ hasCodes ? /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("div", { className: "rounded-general p-6 bg-interface-background-default-secondary border-interface-border-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
2394
2575
  "div",
2395
2576
  {
2396
2577
  className: "grid grid-cols-2 sm:grid-cols-3 md:grid-cols-5 flex-wrap gap-4 text-sm text-interface-foreground-default-primary",
2397
2578
  "data-testid": "ory/screen/settings/group/recovery_code/codes",
2398
- children: codes.map((code) => /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("p", { children: code }, code))
2579
+ children: codes.map((code) => /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("p", { children: code }, code))
2399
2580
  }
2400
2581
  ) }) : null
2401
2582
  ] });
2402
2583
  }
2403
2584
 
2404
2585
  // src/theme/default/components/settings/settings-totp.tsx
2405
- var import_elements_react17 = require("@ory/elements-react");
2586
+ var import_elements_react18 = require("@ory/elements-react");
2406
2587
 
2407
2588
  // src/theme/default/assets/icons/qrcode.svg
2408
2589
  var React33 = __toESM(require("react"));
2409
- var import_jsx_runtime64 = require("react/jsx-runtime");
2590
+ var import_jsx_runtime65 = require("react/jsx-runtime");
2410
2591
  var SvgQrcode = (props) => {
2411
2592
  var _a, _b;
2412
- return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, fill: "none", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M9.333 22.667v.013m0-13.346v.013m13.333-.013v.013m0 9.32h-4v4m8-4v.013m-8 7.987h4m0-4h4v4m-21.333-20a1.333 1.333 0 0 1 1.333-1.333H12a1.333 1.333 0 0 1 1.333 1.333V12A1.334 1.334 0 0 1 12 13.334H6.666A1.334 1.334 0 0 1 5.333 12zm13.333 0A1.333 1.333 0 0 1 20 5.334h5.333a1.333 1.333 0 0 1 1.333 1.333V12a1.333 1.333 0 0 1-1.333 1.334H20A1.333 1.333 0 0 1 18.666 12zM5.333 20a1.333 1.333 0 0 1 1.333-1.333H12A1.333 1.333 0 0 1 13.333 20v5.334A1.333 1.333 0 0 1 12 26.667H6.666a1.333 1.333 0 0 1-1.333-1.334z" }) });
2593
+ return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, fill: "none", ...props, children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M9.333 22.667v.013m0-13.346v.013m13.333-.013v.013m0 9.32h-4v4m8-4v.013m-8 7.987h4m0-4h4v4m-21.333-20a1.333 1.333 0 0 1 1.333-1.333H12a1.333 1.333 0 0 1 1.333 1.333V12A1.334 1.334 0 0 1 12 13.334H6.666A1.334 1.334 0 0 1 5.333 12zm13.333 0A1.333 1.333 0 0 1 20 5.334h5.333a1.333 1.333 0 0 1 1.333 1.333V12a1.333 1.333 0 0 1-1.333 1.334H20A1.333 1.333 0 0 1 18.666 12zM5.333 20a1.333 1.333 0 0 1 1.333-1.333H12A1.333 1.333 0 0 1 13.333 20v5.334A1.333 1.333 0 0 1 12 26.667H6.666a1.333 1.333 0 0 1-1.333-1.334z" }) });
2413
2594
  };
2414
2595
  var qrcode_default = SvgQrcode;
2415
2596
 
2416
2597
  // src/theme/default/components/settings/settings-totp.tsx
2417
2598
  var import_react_hook_form11 = require("react-hook-form");
2418
- var import_jsx_runtime65 = require("react/jsx-runtime");
2599
+ var import_jsx_runtime66 = require("react/jsx-runtime");
2419
2600
  function DefaultSettingsTotp({
2420
2601
  totpImage,
2421
2602
  totpInput,
@@ -2423,7 +2604,7 @@ function DefaultSettingsTotp({
2423
2604
  totpUnlink,
2424
2605
  onUnlink
2425
2606
  }) {
2426
- const { Node: Node2, Card } = (0, import_elements_react17.useComponents)();
2607
+ const { Node: Node2, Card } = (0, import_elements_react18.useComponents)();
2427
2608
  const {
2428
2609
  formState: { isSubmitting }
2429
2610
  } = (0, import_react_hook_form11.useFormContext)();
@@ -2435,19 +2616,19 @@ function DefaultSettingsTotp({
2435
2616
  node_type: _ignoredNodeType,
2436
2617
  ...buttonAttrs
2437
2618
  } = totpUnlink.attributes;
2438
- return /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("div", { className: "grid grid-cols-1 gap-8 md:grid-cols-2", children: [
2439
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(Card.Divider, {}) }),
2440
- /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("div", { className: "col-span-full flex items-center gap-6", children: [
2441
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "aspect-square size-8 ", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(qrcode_default, { size: 32 }) }),
2442
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "mr-auto flex flex-col", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-primary", children: "Authenticator app" }) }),
2443
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
2619
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: "grid grid-cols-1 gap-8 md:grid-cols-2", children: [
2620
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(Card.Divider, {}) }),
2621
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: "col-span-full flex items-center gap-6", children: [
2622
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "aspect-square size-8 ", children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(qrcode_default, { size: 32 }) }),
2623
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "mr-auto flex flex-col", children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-primary", children: "Authenticator app" }) }),
2624
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
2444
2625
  "button",
2445
2626
  {
2446
2627
  type: type === "button" ? "button" : "submit",
2447
2628
  ...buttonAttrs,
2448
2629
  onClick: onUnlink,
2449
2630
  disabled: isSubmitting,
2450
- children: isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(Spinner, { className: "relative" }) : /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
2631
+ children: isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(Spinner, { className: "relative" }) : /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
2451
2632
  trash_default,
2452
2633
  {
2453
2634
  className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover",
@@ -2460,9 +2641,9 @@ function DefaultSettingsTotp({
2460
2641
  ] });
2461
2642
  }
2462
2643
  if (totpImage && totpSecret && totpInput) {
2463
- return /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("div", { className: "grid grid-cols-1 gap-8 md:grid-cols-2", children: [
2464
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(DefaultHorizontalDivider, {}) }),
2465
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "flex justify-center rounded-cards bg-interface-background-default-secondary p-8", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "aspect-square h-44 rounded bg-[white]", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)("div", { className: "-m-3 antialiased mix-blend-multiply", children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
2644
+ return /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: "grid grid-cols-1 gap-8 md:grid-cols-2", children: [
2645
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(DefaultHorizontalDivider, {}) }),
2646
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "flex justify-center rounded-cards bg-interface-background-default-secondary p-8", children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "aspect-square h-44 rounded bg-[white]", children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("div", { className: "-m-3 antialiased mix-blend-multiply", children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
2466
2647
  Node2.Image,
2467
2648
  {
2468
2649
  node: totpImage,
@@ -2471,13 +2652,13 @@ function DefaultSettingsTotp({
2471
2652
  }
2472
2653
  }
2473
2654
  ) }) }) }),
2474
- /* @__PURE__ */ (0, import_jsx_runtime65.jsxs)("div", { className: "flex flex-col gap-6", children: [
2475
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
2655
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { className: "flex flex-col gap-6", children: [
2656
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
2476
2657
  Node2.Label,
2477
2658
  {
2478
2659
  node: totpSecret,
2479
2660
  attributes: totpSecret.attributes,
2480
- children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
2661
+ children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
2481
2662
  Node2.Input,
2482
2663
  {
2483
2664
  node: totpSecret,
@@ -2492,12 +2673,12 @@ function DefaultSettingsTotp({
2492
2673
  )
2493
2674
  }
2494
2675
  ),
2495
- /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
2676
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
2496
2677
  Node2.Label,
2497
2678
  {
2498
2679
  attributes: totpInput.attributes,
2499
2680
  node: totpInput,
2500
- children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
2681
+ children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
2501
2682
  Node2.CodeInput,
2502
2683
  {
2503
2684
  node: totpInput,
@@ -2512,20 +2693,20 @@ function DefaultSettingsTotp({
2512
2693
  }
2513
2694
 
2514
2695
  // src/theme/default/components/settings/settings-webauthn.tsx
2515
- var import_elements_react18 = require("@ory/elements-react");
2696
+ var import_elements_react19 = require("@ory/elements-react");
2516
2697
 
2517
2698
  // src/theme/default/assets/icons/key.svg
2518
2699
  var React34 = __toESM(require("react"));
2519
- var import_jsx_runtime66 = require("react/jsx-runtime");
2700
+ var import_jsx_runtime67 = require("react/jsx-runtime");
2520
2701
  var SvgKey = (props) => {
2521
2702
  var _a, _b;
2522
- return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 32 32", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M20 12h.013m2.06-6.876 4.803 4.803a3.836 3.836 0 0 1 0 5.425l-3.524 3.524a3.835 3.835 0 0 1-5.425 0l-.402-.401-8.744 8.744a2.67 2.67 0 0 1-1.652.77L6.896 28H5.333a1.334 1.334 0 0 1-1.324-1.177L4 26.667v-1.563c0-.626.22-1.232.623-1.712l.158-.173.552-.552H8V20h2.667v-2.667l2.858-2.858-.401-.402a3.835 3.835 0 0 1 0-5.425l3.524-3.524a3.835 3.835 0 0 1 5.425 0" }) });
2703
+ return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 32 32", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M20 12h.013m2.06-6.876 4.803 4.803a3.836 3.836 0 0 1 0 5.425l-3.524 3.524a3.835 3.835 0 0 1-5.425 0l-.402-.401-8.744 8.744a2.67 2.67 0 0 1-1.652.77L6.896 28H5.333a1.334 1.334 0 0 1-1.324-1.177L4 26.667v-1.563c0-.626.22-1.232.623-1.712l.158-.173.552-.552H8V20h2.667v-2.667l2.858-2.858-.401-.402a3.835 3.835 0 0 1 0-5.425l3.524-3.524a3.835 3.835 0 0 1 5.425 0" }) });
2523
2704
  };
2524
2705
  var key_default = SvgKey;
2525
2706
 
2526
2707
  // src/theme/default/components/settings/settings-webauthn.tsx
2527
2708
  var import_react_hook_form12 = require("react-hook-form");
2528
- var import_jsx_runtime67 = require("react/jsx-runtime");
2709
+ var import_jsx_runtime68 = require("react/jsx-runtime");
2529
2710
  function DefaultSettingsWebauthn({
2530
2711
  nameInput,
2531
2712
  triggerButton,
@@ -2534,16 +2715,16 @@ function DefaultSettingsWebauthn({
2534
2715
  const {
2535
2716
  formState: { isSubmitting }
2536
2717
  } = (0, import_react_hook_form12.useFormContext)();
2537
- const { Node: Node2, Card } = (0, import_elements_react18.useComponents)();
2718
+ const { Node: Node2, Card } = (0, import_elements_react19.useComponents)();
2538
2719
  const hasRemoveButtons = removeButtons.length > 0;
2539
- return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: "flex flex-col gap-8", children: [
2540
- /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: "flex md:max-w-96 sm:items-end gap-3 flex-col sm:flex-row", children: [
2541
- /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: "flex-1", children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
2720
+ return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className: "flex flex-col gap-8", children: [
2721
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className: "flex md:max-w-96 sm:items-end gap-3 flex-col sm:flex-row", children: [
2722
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("div", { className: "flex-1", children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
2542
2723
  Node2.Label,
2543
2724
  {
2544
2725
  node: nameInput,
2545
2726
  attributes: nameInput.attributes,
2546
- children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
2727
+ children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
2547
2728
  Node2.Input,
2548
2729
  {
2549
2730
  node: nameInput,
@@ -2552,7 +2733,7 @@ function DefaultSettingsWebauthn({
2552
2733
  )
2553
2734
  }
2554
2735
  ) }),
2555
- triggerButton ? /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
2736
+ triggerButton ? /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
2556
2737
  Node2.Button,
2557
2738
  {
2558
2739
  node: triggerButton,
@@ -2561,38 +2742,38 @@ function DefaultSettingsWebauthn({
2561
2742
  }
2562
2743
  ) : null
2563
2744
  ] }),
2564
- hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: "flex flex-col gap-8", children: [
2565
- /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(Card.Divider, {}),
2566
- /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: "flex flex-col gap-4", children: removeButtons.map((node, i) => {
2745
+ hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className: "flex flex-col gap-8", children: [
2746
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Card.Divider, {}),
2747
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("div", { className: "flex flex-col gap-4", children: removeButtons.map((node, i) => {
2567
2748
  var _a, _b;
2568
2749
  const context = (_b = (_a = node.meta.label) == null ? void 0 : _a.context) != null ? _b : {};
2569
2750
  const addedAt = "added_at" in context ? context.added_at : null;
2570
2751
  const displayName = "display_name" in context ? context.display_name : null;
2571
2752
  const keyId = "value" in node.attributes ? node.attributes.value : null;
2572
- return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
2753
+ return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)(
2573
2754
  "div",
2574
2755
  {
2575
2756
  className: "flex justify-between gap-6 md:items-center",
2576
2757
  children: [
2577
- /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: "flex gap-2 items-center flex-1 truncate", children: [
2578
- /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
2758
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className: "flex gap-2 items-center flex-1 truncate", children: [
2759
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
2579
2760
  key_default,
2580
2761
  {
2581
2762
  size: 32,
2582
2763
  className: "text-interface-foreground-default-primary"
2583
2764
  }
2584
2765
  ),
2585
- /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: "flex-1 flex-col md:flex-row md:items-center flex md:justify-between gap-4 truncate", children: [
2586
- /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: "flex-1 flex-col truncate", children: [
2587
- /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary truncate", children: displayName }),
2588
- /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("span", { className: "text-sm text-interface-foreground-default-tertiary hidden sm:block truncate", children: keyId })
2766
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className: "flex-1 flex-col md:flex-row md:items-center flex md:justify-between gap-4 truncate", children: [
2767
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className: "flex-1 flex-col truncate", children: [
2768
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary truncate", children: displayName }),
2769
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { className: "text-sm text-interface-foreground-default-tertiary hidden sm:block truncate", children: keyId })
2589
2770
  ] }),
2590
- addedAt && /* @__PURE__ */ (0, import_jsx_runtime67.jsx)("p", { className: "text-sm text-interface-foreground-default-tertiary", children: new Intl.DateTimeFormat(void 0, {
2771
+ addedAt && /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("p", { className: "text-sm text-interface-foreground-default-tertiary", children: new Intl.DateTimeFormat(void 0, {
2591
2772
  dateStyle: "long"
2592
2773
  }).format(new Date(addedAt)) })
2593
2774
  ] })
2594
2775
  ] }),
2595
- /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
2776
+ /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
2596
2777
  "button",
2597
2778
  {
2598
2779
  ...node.attributes,
@@ -2600,7 +2781,7 @@ function DefaultSettingsWebauthn({
2600
2781
  onClick: node.onClick,
2601
2782
  disabled: isSubmitting,
2602
2783
  className: "relative",
2603
- children: isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(Spinner, { className: "relative" }) : /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
2784
+ children: isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Spinner, { className: "relative" }) : /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
2604
2785
  trash_default,
2605
2786
  {
2606
2787
  className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover",
@@ -2619,34 +2800,34 @@ function DefaultSettingsWebauthn({
2619
2800
  }
2620
2801
 
2621
2802
  // src/theme/default/components/card/auth-method-list-container.tsx
2622
- var import_jsx_runtime68 = require("react/jsx-runtime");
2803
+ var import_jsx_runtime69 = require("react/jsx-runtime");
2623
2804
  function DefaultAuthMethodListContainer({
2624
2805
  children
2625
2806
  }) {
2626
- return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("div", { className: "grid grid-cols-1 gap-2", children });
2807
+ return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)("div", { className: "grid grid-cols-1 gap-2", children });
2627
2808
  }
2628
2809
 
2629
2810
  // src/theme/default/components/form/captcha.tsx
2630
- var import_client_fetch15 = require("@ory/client-fetch");
2811
+ var import_client_fetch17 = require("@ory/client-fetch");
2631
2812
  var import_react_turnstile = require("@marsidev/react-turnstile");
2632
- var import_react11 = require("react");
2813
+ var import_react12 = require("react");
2633
2814
  var import_react_hook_form13 = require("react-hook-form");
2634
- var import_jsx_runtime69 = require("react/jsx-runtime");
2815
+ var import_jsx_runtime70 = require("react/jsx-runtime");
2635
2816
  var DefaultCaptcha = ({ node }) => {
2636
2817
  const { setValue } = (0, import_react_hook_form13.useFormContext)();
2637
- const ref = (0, import_react11.useRef)();
2818
+ const ref = (0, import_react12.useRef)();
2638
2819
  const nodes = [];
2639
- if ((0, import_client_fetch15.isUiNodeInputAttributes)(node.attributes)) {
2820
+ if ((0, import_client_fetch17.isUiNodeInputAttributes)(node.attributes)) {
2640
2821
  if (node.attributes.name === "transient_payload.captcha_turnstile_response") {
2641
2822
  nodes.push(
2642
- /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(DefaultInput, { node, attributes: node.attributes }, 1)
2823
+ /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(DefaultInput, { node, attributes: node.attributes }, 1)
2643
2824
  );
2644
2825
  }
2645
2826
  }
2646
- if ((0, import_client_fetch15.isUiNodeInputAttributes)(node.attributes) && node.attributes.name === "captcha_turnstile_options") {
2827
+ if ((0, import_client_fetch17.isUiNodeInputAttributes)(node.attributes) && node.attributes.name === "captcha_turnstile_options") {
2647
2828
  const options = JSON.parse(node.attributes.value);
2648
2829
  nodes.push(
2649
- /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
2830
+ /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
2650
2831
  import_react_turnstile.Turnstile,
2651
2832
  {
2652
2833
  ref,
@@ -2673,9 +2854,84 @@ var DefaultCaptcha = ({ node }) => {
2673
2854
  return nodes;
2674
2855
  };
2675
2856
 
2857
+ // src/theme/default/assets/icons/personal.svg
2858
+ var React35 = __toESM(require("react"));
2859
+ var import_jsx_runtime71 = require("react/jsx-runtime");
2860
+ var SvgPersonal = (props) => {
2861
+ var _a, _b;
2862
+ return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)("path", { stroke: "#0F172A", strokeLinecap: "round", strokeLinejoin: "round", d: "M4 14v-1.333A2.667 2.667 0 0 1 6.667 10h1m5.8 3.467 1.2 1.2m-9.334-10a2.667 2.667 0 1 0 5.334 0 2.667 2.667 0 0 0-5.334 0M10 12a2 2 0 1 0 4 0 2 2 0 0 0-4 0" }) });
2863
+ };
2864
+ var personal_default = SvgPersonal;
2865
+
2866
+ // src/theme/default/assets/icons/message.svg
2867
+ var React36 = __toESM(require("react"));
2868
+ var import_jsx_runtime72 = require("react/jsx-runtime");
2869
+ var SvgMessage = (props) => {
2870
+ var _a, _b;
2871
+ return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 25", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("path", { stroke: "#000", strokeLinecap: "round", strokeLinejoin: "round", d: "M3 7.325a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2m-18 0v10a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-10m-18 0 9 6 9-6" }) });
2872
+ };
2873
+ var message_default = SvgMessage;
2874
+
2875
+ // src/theme/default/assets/icons/phone.svg
2876
+ var React37 = __toESM(require("react"));
2877
+ var import_jsx_runtime73 = require("react/jsx-runtime");
2878
+ var SvgPhone = (props) => {
2879
+ var _a, _b;
2880
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 25", width: (props == null ? void 0 : props.width) ? props.width : (_a = props == null ? void 0 : props.size) != null ? _a : 20, height: (props == null ? void 0 : props.height) ? props.height : (_b = props == null ? void 0 : props.size) != null ? _b : 20, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M5 4.325h4l2 5-2.5 1.5a11 11 0 0 0 5 5l1.5-2.5 5 2v4a2 2 0 0 1-2 2 16 16 0 0 1-15-15 2 2 0 0 1 2-2" }) });
2881
+ };
2882
+ var phone_default = SvgPhone;
2883
+
2884
+ // src/theme/default/components/form/consent-scope-checkbox.tsx
2885
+ var import_react_intl13 = require("react-intl");
2886
+ var Switch = __toESM(require("@radix-ui/react-switch"));
2887
+ var import_jsx_runtime74 = require("react/jsx-runtime");
2888
+ var ScopeIcons = {
2889
+ openid: personal_default,
2890
+ offline_access: personal_default,
2891
+ profile: personal_default,
2892
+ email: message_default,
2893
+ phone: phone_default
2894
+ };
2895
+ function DefaultConsentScopeCheckbox({
2896
+ attributes,
2897
+ onCheckedChange
2898
+ }) {
2899
+ var _a;
2900
+ const intl = (0, import_react_intl13.useIntl)();
2901
+ const Icon = (_a = ScopeIcons[attributes.value]) != null ? _a : personal_default;
2902
+ return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
2903
+ ListItem,
2904
+ {
2905
+ as: "label",
2906
+ icon: Icon,
2907
+ title: intl.formatMessage({
2908
+ id: `consent.scope.${attributes.value}.title`,
2909
+ defaultMessage: attributes.value
2910
+ }),
2911
+ description: intl.formatMessage({
2912
+ id: `consent.scope.${attributes.value}.description`,
2913
+ defaultMessage: []
2914
+ }),
2915
+ className: "col-span-2",
2916
+ "data-testid": "ory/screen/consent/scope-checkbox-label",
2917
+ children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
2918
+ Switch.Root,
2919
+ {
2920
+ className: "relative w-7 h-4 bg-toggle-background-default rounded-identifier border-toggle-border-default border p-[3px] data-[state=checked]:bg-toggle-background-checked transition-all data-[state=checked]:border-toggle-border-checked",
2921
+ "data-testid": `ory/screen/consent/scope-checkbox`,
2922
+ value: attributes.value,
2923
+ onCheckedChange,
2924
+ defaultChecked: true,
2925
+ children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(Switch.Thumb, { className: "size-2 block bg-toggle-foreground-default rounded-identifier data-[state=checked]:bg-toggle-foreground-checked transition-all data-[state=checked]:translate-x-3" })
2926
+ }
2927
+ )
2928
+ }
2929
+ );
2930
+ }
2931
+
2676
2932
  // src/theme/default/components/default-components.tsx
2677
2933
  function getOryComponents(overrides) {
2678
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __, _$, _aa, _ba, _ca, _da, _ea, _fa, _ga, _ha, _ia, _ja;
2934
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __, _$, _aa, _ba, _ca, _da, _ea, _fa, _ga, _ha, _ia, _ja, _ka, _la;
2679
2935
  return {
2680
2936
  Card: {
2681
2937
  Root: (_b = (_a = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _a.Root) != null ? _b : DefaultCard,
@@ -2700,174 +2956,178 @@ function getOryComponents(overrides) {
2700
2956
  Checkbox: (_J = (_I = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _I.Checkbox) != null ? _J : DefaultCheckbox,
2701
2957
  Text: (_L = (_K = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _K.Text) != null ? _L : DefaultText,
2702
2958
  Anchor: (_N = (_M = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _M.Anchor) != null ? _N : DefaultLinkButton,
2703
- Captcha: (_P = (_O = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _O.Captcha) != null ? _P : DefaultCaptcha
2959
+ Captcha: (_P = (_O = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _O.Captcha) != null ? _P : DefaultCaptcha,
2960
+ ConsentScopeCheckbox: (_R = (_Q = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _Q.ConsentScopeCheckbox) != null ? _R : DefaultConsentScopeCheckbox
2704
2961
  },
2705
2962
  Form: {
2706
- Root: (_R = (_Q = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _Q.Root) != null ? _R : DefaultFormContainer,
2707
- Group: (_T = (_S = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _S.Group) != null ? _T : DefaultGroupContainer,
2708
- OidcRoot: (_V = (_U = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _U.OidcRoot) != null ? _V : DefaultSocialButtonContainer,
2709
- RecoveryCodesSettings: (_X = (_W = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _W.RecoveryCodesSettings) != null ? _X : DefaultSettingsRecoveryCodes,
2710
- TotpSettings: (_Z = (_Y = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _Y.TotpSettings) != null ? _Z : DefaultSettingsTotp,
2711
- OidcSettings: (_$ = (__ = overrides == null ? void 0 : overrides.Form) == null ? void 0 : __.OidcSettings) != null ? _$ : DefaultSettingsOidc,
2712
- WebauthnSettings: (_ba = (_aa = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _aa.WebauthnSettings) != null ? _ba : DefaultSettingsWebauthn,
2713
- PasskeySettings: (_da = (_ca = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _ca.PasskeySettings) != null ? _da : DefaultSettingsPasskey
2963
+ Root: (_T = (_S = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _S.Root) != null ? _T : DefaultFormContainer,
2964
+ Group: (_V = (_U = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _U.Group) != null ? _V : DefaultGroupContainer,
2965
+ OidcRoot: (_X = (_W = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _W.OidcRoot) != null ? _X : DefaultSocialButtonContainer,
2966
+ RecoveryCodesSettings: (_Z = (_Y = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _Y.RecoveryCodesSettings) != null ? _Z : DefaultSettingsRecoveryCodes,
2967
+ TotpSettings: (_$ = (__ = overrides == null ? void 0 : overrides.Form) == null ? void 0 : __.TotpSettings) != null ? _$ : DefaultSettingsTotp,
2968
+ OidcSettings: (_ba = (_aa = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _aa.OidcSettings) != null ? _ba : DefaultSettingsOidc,
2969
+ WebauthnSettings: (_da = (_ca = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _ca.WebauthnSettings) != null ? _da : DefaultSettingsWebauthn,
2970
+ PasskeySettings: (_fa = (_ea = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _ea.PasskeySettings) != null ? _fa : DefaultSettingsPasskey
2714
2971
  },
2715
2972
  Message: {
2716
- Root: (_fa = (_ea = overrides == null ? void 0 : overrides.Message) == null ? void 0 : _ea.Root) != null ? _fa : DefaultMessageContainer,
2717
- Content: (_ha = (_ga = overrides == null ? void 0 : overrides.Message) == null ? void 0 : _ga.Content) != null ? _ha : DefaultMessage
2973
+ Root: (_ha = (_ga = overrides == null ? void 0 : overrides.Message) == null ? void 0 : _ga.Root) != null ? _ha : DefaultMessageContainer,
2974
+ Content: (_ja = (_ia = overrides == null ? void 0 : overrides.Message) == null ? void 0 : _ia.Content) != null ? _ja : DefaultMessage
2718
2975
  },
2719
2976
  Page: {
2720
- Header: (_ja = (_ia = overrides == null ? void 0 : overrides.Page) == null ? void 0 : _ia.Header) != null ? _ja : DefaultPageHeader
2977
+ Header: (_la = (_ka = overrides == null ? void 0 : overrides.Page) == null ? void 0 : _ka.Header) != null ? _la : DefaultPageHeader
2721
2978
  }
2722
2979
  };
2723
2980
  }
2724
2981
 
2725
2982
  // src/theme/default/flows/error.tsx
2726
- var import_client_fetch34 = require("@ory/client-fetch");
2727
- var import_react15 = require("react");
2983
+ var import_client_fetch36 = require("@ory/client-fetch");
2984
+ var import_react16 = require("react");
2728
2985
 
2729
2986
  // src/context/intl-context.tsx
2730
- var import_react_intl20 = require("react-intl");
2987
+ var import_react_intl21 = require("react-intl");
2731
2988
 
2732
2989
  // src/context/flow-context.tsx
2733
- var import_react13 = require("react");
2990
+ var import_react14 = require("react");
2734
2991
 
2735
2992
  // src/context/form-state.ts
2736
- var import_client_fetch17 = require("@ory/client-fetch");
2737
- var import_react12 = require("react");
2993
+ var import_client_fetch19 = require("@ory/client-fetch");
2994
+ var import_react13 = require("react");
2738
2995
 
2739
2996
  // src/components/card/card-two-step.utils.ts
2740
- var import_client_fetch16 = require("@ory/client-fetch");
2997
+ var import_client_fetch18 = require("@ory/client-fetch");
2741
2998
 
2742
2999
  // src/context/flow-context.tsx
2743
- var import_jsx_runtime70 = require("react/jsx-runtime");
2744
- var OryFlowContext = (0, import_react13.createContext)(null);
3000
+ var import_jsx_runtime75 = require("react/jsx-runtime");
3001
+ var OryFlowContext = (0, import_react14.createContext)(null);
2745
3002
 
2746
3003
  // src/context/provider.tsx
2747
- var import_jsx_runtime71 = require("react/jsx-runtime");
3004
+ var import_jsx_runtime76 = require("react/jsx-runtime");
2748
3005
 
2749
3006
  // src/components/card/header.tsx
2750
- var import_jsx_runtime72 = require("react/jsx-runtime");
3007
+ var import_jsx_runtime77 = require("react/jsx-runtime");
2751
3008
 
2752
3009
  // src/components/form/form-provider.tsx
2753
- var import_client_fetch20 = require("@ory/client-fetch");
3010
+ var import_client_fetch22 = require("@ory/client-fetch");
2754
3011
  var import_react_hook_form14 = require("react-hook-form");
2755
3012
 
2756
3013
  // src/components/form/form-helpers.ts
2757
- var import_client_fetch18 = require("@ory/client-fetch");
3014
+ var import_client_fetch20 = require("@ory/client-fetch");
2758
3015
 
2759
3016
  // src/components/form/form-resolver.ts
2760
- var import_client_fetch19 = require("@ory/client-fetch");
3017
+ var import_client_fetch21 = require("@ory/client-fetch");
2761
3018
 
2762
3019
  // src/components/form/form-provider.tsx
2763
- var import_jsx_runtime73 = require("react/jsx-runtime");
3020
+ var import_jsx_runtime78 = require("react/jsx-runtime");
2764
3021
 
2765
3022
  // src/components/card/card.tsx
2766
- var import_jsx_runtime74 = require("react/jsx-runtime");
3023
+ var import_jsx_runtime79 = require("react/jsx-runtime");
2767
3024
 
2768
3025
  // src/components/card/footer.tsx
2769
- var import_jsx_runtime75 = require("react/jsx-runtime");
3026
+ var import_jsx_runtime80 = require("react/jsx-runtime");
2770
3027
 
2771
3028
  // src/components/card/content.tsx
2772
- var import_jsx_runtime76 = require("react/jsx-runtime");
3029
+ var import_jsx_runtime81 = require("react/jsx-runtime");
2773
3030
 
2774
3031
  // src/components/card/card-two-step.tsx
2775
- var import_client_fetch31 = require("@ory/client-fetch");
3032
+ var import_client_fetch33 = require("@ory/client-fetch");
2776
3033
  var import_react_hook_form19 = require("react-hook-form");
2777
3034
 
2778
3035
  // src/components/form/form.tsx
2779
- var import_client_fetch27 = require("@ory/client-fetch");
3036
+ var import_client_fetch29 = require("@ory/client-fetch");
2780
3037
  var import_react_hook_form16 = require("react-hook-form");
2781
- var import_react_intl13 = require("react-intl");
3038
+ var import_react_intl14 = require("react-intl");
2782
3039
 
2783
3040
  // src/components/form/useOryFormSubmit.ts
2784
- var import_client_fetch26 = require("@ory/client-fetch");
3041
+ var import_client_fetch28 = require("@ory/client-fetch");
2785
3042
  var import_react_hook_form15 = require("react-hook-form");
2786
3043
 
2787
3044
  // src/util/onSubmitLogin.ts
2788
- var import_client_fetch21 = require("@ory/client-fetch");
3045
+ var import_client_fetch23 = require("@ory/client-fetch");
2789
3046
 
2790
3047
  // src/util/onSubmitRecovery.ts
2791
- var import_client_fetch22 = require("@ory/client-fetch");
3048
+ var import_client_fetch24 = require("@ory/client-fetch");
2792
3049
 
2793
3050
  // src/util/onSubmitRegistration.ts
2794
- var import_client_fetch23 = require("@ory/client-fetch");
3051
+ var import_client_fetch25 = require("@ory/client-fetch");
2795
3052
 
2796
3053
  // src/util/onSubmitSettings.ts
2797
- var import_client_fetch24 = require("@ory/client-fetch");
3054
+ var import_client_fetch26 = require("@ory/client-fetch");
2798
3055
 
2799
3056
  // src/util/onSubmitVerification.ts
2800
- var import_client_fetch25 = require("@ory/client-fetch");
3057
+ var import_client_fetch27 = require("@ory/client-fetch");
2801
3058
 
2802
3059
  // src/components/form/form.tsx
2803
- var import_jsx_runtime77 = require("react/jsx-runtime");
3060
+ var import_jsx_runtime82 = require("react/jsx-runtime");
2804
3061
 
2805
3062
  // src/components/form/messages.tsx
2806
- var import_jsx_runtime78 = require("react/jsx-runtime");
3063
+ var import_jsx_runtime83 = require("react/jsx-runtime");
2807
3064
 
2808
3065
  // src/components/form/nodes/input.tsx
2809
- var import_client_fetch28 = require("@ory/client-fetch");
2810
- var import_react14 = require("react");
3066
+ var import_client_fetch30 = require("@ory/client-fetch");
3067
+ var import_react15 = require("react");
2811
3068
  var import_react_hook_form17 = require("react-hook-form");
2812
- var import_jsx_runtime79 = require("react/jsx-runtime");
3069
+ var import_jsx_runtime84 = require("react/jsx-runtime");
2813
3070
 
2814
3071
  // src/components/form/nodes/node.tsx
2815
- var import_client_fetch29 = require("@ory/client-fetch");
2816
- var import_jsx_runtime80 = require("react/jsx-runtime");
3072
+ var import_client_fetch31 = require("@ory/client-fetch");
3073
+ var import_jsx_runtime85 = require("react/jsx-runtime");
2817
3074
 
2818
3075
  // src/components/form/social.tsx
2819
- var import_client_fetch30 = require("@ory/client-fetch");
3076
+ var import_client_fetch32 = require("@ory/client-fetch");
2820
3077
  var import_react_hook_form18 = require("react-hook-form");
2821
- var import_jsx_runtime81 = require("react/jsx-runtime");
3078
+ var import_jsx_runtime86 = require("react/jsx-runtime");
2822
3079
 
2823
3080
  // src/components/card/card-two-step.tsx
2824
- var import_jsx_runtime82 = require("react/jsx-runtime");
3081
+ var import_jsx_runtime87 = require("react/jsx-runtime");
2825
3082
 
2826
3083
  // src/components/form/groups.tsx
2827
- var import_jsx_runtime83 = require("react/jsx-runtime");
3084
+ var import_jsx_runtime88 = require("react/jsx-runtime");
2828
3085
 
2829
3086
  // src/components/form/section.tsx
2830
3087
  var import_react_hook_form20 = require("react-hook-form");
2831
- var import_jsx_runtime84 = require("react/jsx-runtime");
3088
+ var import_jsx_runtime89 = require("react/jsx-runtime");
3089
+
3090
+ // src/components/card/card-consent.tsx
3091
+ var import_jsx_runtime90 = require("react/jsx-runtime");
2832
3092
 
2833
3093
  // src/components/generic/divider.tsx
2834
- var import_client_fetch32 = require("@ory/client-fetch");
2835
- var import_jsx_runtime85 = require("react/jsx-runtime");
3094
+ var import_client_fetch34 = require("@ory/client-fetch");
3095
+ var import_jsx_runtime91 = require("react/jsx-runtime");
2836
3096
 
2837
3097
  // src/components/generic/page-header.tsx
2838
- var import_jsx_runtime86 = require("react/jsx-runtime");
3098
+ var import_jsx_runtime92 = require("react/jsx-runtime");
2839
3099
 
2840
3100
  // src/components/settings/settings-card.tsx
2841
- var import_client_fetch33 = require("@ory/client-fetch");
2842
- var import_react_intl19 = require("react-intl");
3101
+ var import_client_fetch35 = require("@ory/client-fetch");
3102
+ var import_react_intl20 = require("react-intl");
2843
3103
 
2844
3104
  // src/components/settings/oidc-settings.tsx
2845
- var import_react_intl14 = require("react-intl");
3105
+ var import_react_intl15 = require("react-intl");
2846
3106
  var import_react_hook_form21 = require("react-hook-form");
2847
- var import_jsx_runtime87 = require("react/jsx-runtime");
3107
+ var import_jsx_runtime93 = require("react/jsx-runtime");
2848
3108
 
2849
3109
  // src/components/settings/passkey-settings.tsx
2850
3110
  var import_react_hook_form22 = require("react-hook-form");
2851
- var import_react_intl15 = require("react-intl");
2852
- var import_jsx_runtime88 = require("react/jsx-runtime");
3111
+ var import_react_intl16 = require("react-intl");
3112
+ var import_jsx_runtime94 = require("react/jsx-runtime");
2853
3113
 
2854
3114
  // src/components/settings/recovery-codes-settings.tsx
2855
- var import_react_intl16 = require("react-intl");
3115
+ var import_react_intl17 = require("react-intl");
2856
3116
  var import_react_hook_form23 = require("react-hook-form");
2857
- var import_jsx_runtime89 = require("react/jsx-runtime");
3117
+ var import_jsx_runtime95 = require("react/jsx-runtime");
2858
3118
 
2859
3119
  // src/components/settings/totp-settings.tsx
2860
3120
  var import_react_hook_form24 = require("react-hook-form");
2861
- var import_react_intl17 = require("react-intl");
2862
- var import_jsx_runtime90 = require("react/jsx-runtime");
3121
+ var import_react_intl18 = require("react-intl");
3122
+ var import_jsx_runtime96 = require("react/jsx-runtime");
2863
3123
 
2864
3124
  // src/components/settings/webauthn-settings.tsx
2865
3125
  var import_react_hook_form25 = require("react-hook-form");
2866
- var import_react_intl18 = require("react-intl");
2867
- var import_jsx_runtime91 = require("react/jsx-runtime");
3126
+ var import_react_intl19 = require("react-intl");
3127
+ var import_jsx_runtime97 = require("react/jsx-runtime");
2868
3128
 
2869
3129
  // src/components/settings/settings-card.tsx
2870
- var import_jsx_runtime92 = require("react/jsx-runtime");
3130
+ var import_jsx_runtime98 = require("react/jsx-runtime");
2871
3131
 
2872
3132
  // src/locales/en.json
2873
3133
  var en_default = {
@@ -3132,6 +3392,20 @@ var en_default = {
3132
3392
  "property.username": "username",
3133
3393
  "property.identifier": "identifier",
3134
3394
  "property.code": "code",
3395
+ "consent.title": "Authorize {party}",
3396
+ "consent.subtitle": "A third party application wants to access information associated with your account {identifier}.",
3397
+ "consent.scope.openid.title": "Identity",
3398
+ "consent.scope.openid.description": "Allows the application to verify your identity. This is required for authentication and a trusted login experience.",
3399
+ "consent.scope.offline_access.title": "Offline Access",
3400
+ "consent.scope.offline_access.description": "Allows this application to keep you signed in even when you're not actively using it.",
3401
+ "consent.scope.profile.title": "Profile Information",
3402
+ "consent.scope.profile.description": "Allows access to your basic profile details, including your username, first name, and last name.",
3403
+ "consent.scope.email.title": "Email Address",
3404
+ "consent.scope.email.description": "Retrieve your email address and its verification status.",
3405
+ "consent.scope.address.title": "Physical Address",
3406
+ "consent.scope.address.description": "Access your postal address.",
3407
+ "consent.scope.phone.title": "Phone Number",
3408
+ "consent.scope.phone.description": "Retrieve your phone number and its verification status.",
3135
3409
  "error.title.what-happened": "What happened?",
3136
3410
  "error.title.what-can-i-do": "What can I do?",
3137
3411
  "error.instructions": "Please try again in a few minutes or contact the website operator.",
@@ -3308,7 +3582,7 @@ var de_default = {
3308
3582
  "two-step.code.description": "Ein Best\xE4tigungscode wird an Ihre E-Mail gesendet.",
3309
3583
  "two-step.code.title": "E-Mail-Code",
3310
3584
  "two-step.passkey.description": "Verwenden Sie die Fingerabdruck- oder Gesichtserkennung Ihres Ger\xE4ts",
3311
- "two-step.passkey.title": "Passwort (empfohlen)",
3585
+ "two-step.passkey.title": "Passkey (empfohlen)",
3312
3586
  "two-step.password.description": "Geben Sie Ihr Passwort ein, das mit Ihrem Konto verkn\xFCpft ist",
3313
3587
  "two-step.password.title": "Passwort",
3314
3588
  "two-step.webauthn.title": "Sicherheitsschl\xFCssel",
@@ -3403,6 +3677,20 @@ var de_default = {
3403
3677
  "property.phone": "Telefon",
3404
3678
  "property.code": "Code",
3405
3679
  "property.username": "Benutzername",
3680
+ "consent.title": "Autorisieren {party}",
3681
+ "consent.subtitle": "Eine Drittanbieteranwendung m\xF6chte auf Informationen zugreifen, die mit Ihrem Konto {identifier} verkn\xFCpft sind.",
3682
+ "consent.scope.openid.title": "Identit\xE4t",
3683
+ "consent.scope.openid.description": "Erm\xF6glicht der Anwendung, Ihre Identit\xE4t zu \xFCberpr\xFCfen. Dies ist f\xFCr die Authentifizierung und eine vertrauensw\xFCrdige Login-Erfahrung erforderlich.",
3684
+ "consent.scope.offline_access.title": "Offline-Zugriff",
3685
+ "consent.scope.offline_access.description": "Erm\xF6glicht dieser Anwendung, Sie angemeldet zu lassen, auch wenn Sie sie nicht aktiv nutzen.",
3686
+ "consent.scope.profile.title": "Profilinformationen",
3687
+ "consent.scope.profile.description": "Erm\xF6glicht den Zugriff auf Ihre grundlegenden Profildetails, einschlie\xDFlich Ihres Benutzernamens, Vornamens und Nachnamens.",
3688
+ "consent.scope.email.title": "E-Mail-Adresse",
3689
+ "consent.scope.email.description": "Erm\xF6glicht den Abruf Ihrer E-Mail-Adresse und deren \xDCberpr\xFCfungsstatus.",
3690
+ "consent.scope.address.title": "Physische Adresse",
3691
+ "consent.scope.address.description": "Erm\xF6glicht den Zugriff auf Ihre Postanschrift.",
3692
+ "consent.scope.phone.title": "Telefonnummer",
3693
+ "consent.scope.phone.description": "Erm\xF6glicht den Abruf Ihrer Telefonnummer und deren \xDCberpr\xFCfungsstatus.",
3406
3694
  "error.title.what-happened": "Was ist passiert?",
3407
3695
  "error.footer.copy": "Kopieren",
3408
3696
  "error.footer.text": "Bitte f\xFCgen Sie bei der Meldung dieses Fehlers die folgenden Informationen hinzu:",
@@ -3674,6 +3962,20 @@ var es_default = {
3674
3962
  "property.password": "",
3675
3963
  "property.phone": "",
3676
3964
  "property.username": "",
3965
+ "consent.title": "Autorizar {party}",
3966
+ "consent.subtitle": "Una aplicaci\xF3n de terceros quiere acceder a la informaci\xF3n asociada a su cuenta {identifier}.",
3967
+ "consent.scope.openid.title": "Identidad",
3968
+ "consent.scope.openid.description": "Permite que la aplicaci\xF3n verifique su identidad. Esto es necesario para la autenticaci\xF3n y una experiencia de inicio de sesi\xF3n confiable.",
3969
+ "consent.scope.offline_access.title": "Acceso sin conexi\xF3n",
3970
+ "consent.scope.offline_access.description": "Permite que esta aplicaci\xF3n le mantenga conectado incluso cuando no la est\xE9 utilizando activamente.",
3971
+ "consent.scope.profile.title": "Informaci\xF3n del perfil",
3972
+ "consent.scope.profile.description": "Permite el acceso a los detalles b\xE1sicos de su perfil, incluyendo su nombre de usuario, nombre y apellido.",
3973
+ "consent.scope.email.title": "Direcci\xF3n de correo electr\xF3nico",
3974
+ "consent.scope.email.description": "Recupere su direcci\xF3n de correo electr\xF3nico y su estado de verificaci\xF3n.",
3975
+ "consent.scope.address.title": "Direcci\xF3n f\xEDsica",
3976
+ "consent.scope.address.description": "Acceda a su direcci\xF3n postal.",
3977
+ "consent.scope.phone.title": "N\xFAmero de tel\xE9fono",
3978
+ "consent.scope.phone.description": "Recupere su n\xFAmero de tel\xE9fono y su estado de verificaci\xF3n.",
3677
3979
  "error.action.go-back": "",
3678
3980
  "error.footer.copy": "",
3679
3981
  "error.footer.text": "",
@@ -3945,6 +4247,20 @@ var fr_default = {
3945
4247
  "property.password": "",
3946
4248
  "property.phone": "",
3947
4249
  "property.username": "",
4250
+ "consent.title": "Autoriser {party}",
4251
+ "consent.subtitle": "Une application tierce souhaite acc\xE9der aux informations associ\xE9es \xE0 votre compte {identifier}.",
4252
+ "consent.scope.openid.title": "Identit\xE9",
4253
+ "consent.scope.openid.description": "Permet \xE0 l'application de v\xE9rifier votre identit\xE9. Cela est n\xE9cessaire pour l'authentification et une exp\xE9rience de connexion fiable.",
4254
+ "consent.scope.offline_access.title": "Acc\xE8s hors ligne",
4255
+ "consent.scope.offline_access.description": "Permet \xE0 cette application de vous maintenir connect\xE9 m\xEAme lorsque vous ne l'utilisez pas activement.",
4256
+ "consent.scope.profile.title": "Informations de profil",
4257
+ "consent.scope.profile.description": "Permet l'acc\xE8s aux d\xE9tails de base de votre profil, y compris votre nom d'utilisateur, pr\xE9nom et nom.",
4258
+ "consent.scope.email.title": "Adresse e-mail",
4259
+ "consent.scope.email.description": "R\xE9cup\xE8re votre adresse e-mail et son statut de v\xE9rification.",
4260
+ "consent.scope.address.title": "Adresse physique",
4261
+ "consent.scope.address.description": "Acc\xE8de \xE0 votre adresse postale.",
4262
+ "consent.scope.phone.title": "Num\xE9ro de t\xE9l\xE9phone",
4263
+ "consent.scope.phone.description": "R\xE9cup\xE8re votre num\xE9ro de t\xE9l\xE9phone et son statut de v\xE9rification.",
3948
4264
  "error.action.go-back": "",
3949
4265
  "error.footer.copy": "",
3950
4266
  "error.footer.text": "",
@@ -4216,6 +4532,20 @@ var nl_default = {
4216
4532
  "property.password": "",
4217
4533
  "property.phone": "",
4218
4534
  "property.username": "",
4535
+ "consent.title": "Autoriseren {party}",
4536
+ "consent.subtitle": "Een derde partij applicatie wil toegang tot informatie die aan uw account {identifier} is gekoppeld.",
4537
+ "consent.scope.openid.title": "Identiteit",
4538
+ "consent.scope.openid.description": "Stelt de applicatie in staat uw identiteit te verifi\xEBren. Dit is vereist voor authenticatie en een betrouwbare inlogervaring.",
4539
+ "consent.scope.offline_access.title": "Offline toegang",
4540
+ "consent.scope.offline_access.description": "Stelt deze applicatie in staat u ingelogd te houden, zelfs wanneer u deze niet actief gebruikt.",
4541
+ "consent.scope.profile.title": "Profielinformatie",
4542
+ "consent.scope.profile.description": "Geeft toegang tot uw basisprofielgegevens, inclusief uw gebruikersnaam, voornaam en achternaam.",
4543
+ "consent.scope.email.title": "E-mailadres",
4544
+ "consent.scope.email.description": "Haal uw e-mailadres en de verificatiestatus ervan op.",
4545
+ "consent.scope.address.title": "Fysiek adres",
4546
+ "consent.scope.address.description": "Toegang tot uw postadres.",
4547
+ "consent.scope.phone.title": "Telefoonnummer",
4548
+ "consent.scope.phone.description": "Haal uw telefoonnummer en de verificatiestatus ervan op.",
4219
4549
  "error.action.go-back": "",
4220
4550
  "error.footer.copy": "",
4221
4551
  "error.footer.text": "",
@@ -4487,6 +4817,20 @@ var pl_default = {
4487
4817
  "property.phone": "",
4488
4818
  "property.username": "",
4489
4819
  "property.identifier": "",
4820
+ "consent.title": "Autoryzuj {party}",
4821
+ "consent.subtitle": "Aplikacja trzeciej strony chce uzyska\u0107 dost\u0119p do informacji powi\u0105zanych z Twoim kontem {identifier}.",
4822
+ "consent.scope.openid.title": "To\u017Csamo\u015B\u0107",
4823
+ "consent.scope.openid.description": "Pozwala aplikacji zweryfikowa\u0107 Twoj\u0105 to\u017Csamo\u015B\u0107. Jest to wymagane do uwierzytelniania i zapewnienia zaufanej sesji logowania.",
4824
+ "consent.scope.offline_access.title": "Dost\u0119p offline",
4825
+ "consent.scope.offline_access.description": "Pozwala aplikacji utrzyma\u0107 Twoje logowanie, nawet gdy nie korzystasz z niej aktywnie.",
4826
+ "consent.scope.profile.title": "Informacje profilowe",
4827
+ "consent.scope.profile.description": "Pozwala na dost\u0119p do podstawowych danych profilowych, w tym nazwy u\u017Cytkownika, imienia i nazwiska.",
4828
+ "consent.scope.email.title": "Adres e-mail",
4829
+ "consent.scope.email.description": "Pobierz sw\xF3j adres e-mail oraz status jego weryfikacji.",
4830
+ "consent.scope.address.title": "Adres fizyczny",
4831
+ "consent.scope.address.description": "Dost\u0119p do Twojego adresu pocztowego.",
4832
+ "consent.scope.phone.title": "Numer telefonu",
4833
+ "consent.scope.phone.description": "Pobierz sw\xF3j numer telefonu oraz status jego weryfikacji.",
4490
4834
  "error.action.go-back": "",
4491
4835
  "error.footer.copy": "",
4492
4836
  "error.footer.text": "",
@@ -4758,6 +5102,20 @@ var pt_default = {
4758
5102
  "property.password": "",
4759
5103
  "property.phone": "",
4760
5104
  "property.username": "",
5105
+ "consent.title": "Autorizar {party}",
5106
+ "consent.subtitle": "Um aplicativo de terceiros deseja acessar as informa\xE7\xF5es associadas \xE0 sua conta {identifier}.",
5107
+ "consent.scope.openid.title": "Identidade",
5108
+ "consent.scope.openid.description": "Permite que a aplica\xE7\xE3o verifique sua identidade. Isso \xE9 necess\xE1rio para a autentica\xE7\xE3o e uma experi\xEAncia de login confi\xE1vel.",
5109
+ "consent.scope.offline_access.title": "Acesso Offline",
5110
+ "consent.scope.offline_access.description": "Permite que este aplicativo mantenha voc\xEA conectado mesmo quando n\xE3o estiver usando-o ativamente.",
5111
+ "consent.scope.profile.title": "Informa\xE7\xF5es do Perfil",
5112
+ "consent.scope.profile.description": "Permite o acesso aos detalhes b\xE1sicos do seu perfil, incluindo seu nome de usu\xE1rio, primeiro nome e sobrenome.",
5113
+ "consent.scope.email.title": "Endere\xE7o de E-mail",
5114
+ "consent.scope.email.description": "Recupere seu endere\xE7o de e-mail e seu status de verifica\xE7\xE3o.",
5115
+ "consent.scope.address.title": "Endere\xE7o F\xEDsico",
5116
+ "consent.scope.address.description": "Acesse seu endere\xE7o postal.",
5117
+ "consent.scope.phone.title": "N\xFAmero de Telefone",
5118
+ "consent.scope.phone.description": "Recupere seu n\xFAmero de telefone e seu status de verifica\xE7\xE3o.",
4761
5119
  "error.action.go-back": "",
4762
5120
  "error.footer.copy": "",
4763
5121
  "error.footer.text": "",
@@ -5029,6 +5387,20 @@ var sv_default = {
5029
5387
  "property.username": "anv\xE4ndarnamn",
5030
5388
  "property.identifier": "identifier",
5031
5389
  "property.code": "kod",
5390
+ "consent.title": "Auktorisera {party}",
5391
+ "consent.subtitle": "En tredjepartsapplikation vill f\xE5 tillg\xE5ng till information kopplad till ditt konto {identifier}.",
5392
+ "consent.scope.openid.title": "Identitet",
5393
+ "consent.scope.openid.description": "G\xF6r det m\xF6jligt f\xF6r applikationen att verifiera din identitet. Detta kr\xE4vs f\xF6r autentisering och en p\xE5litlig inloggningsupplevelse.",
5394
+ "consent.scope.offline_access.title": "Offline-\xE5tkomst",
5395
+ "consent.scope.offline_access.description": "G\xF6r det m\xF6jligt f\xF6r denna applikation att h\xE5lla dig inloggad \xE4ven n\xE4r du inte aktivt anv\xE4nder den.",
5396
+ "consent.scope.profile.title": "Profilinformation",
5397
+ "consent.scope.profile.description": "Ger tillg\xE5ng till dina grundl\xE4ggande profiluppgifter, inklusive ditt anv\xE4ndarnamn, f\xF6rnamn och efternamn.",
5398
+ "consent.scope.email.title": "E-postadress",
5399
+ "consent.scope.email.description": "H\xE4mta din e-postadress och dess verifieringsstatus.",
5400
+ "consent.scope.address.title": "Fysisk adress",
5401
+ "consent.scope.address.description": "F\xE5 \xE5tkomst till din postadress.",
5402
+ "consent.scope.phone.title": "Telefonnummer",
5403
+ "consent.scope.phone.description": "H\xE4mta ditt telefonnummer och dess verifieringsstatus.",
5032
5404
  "error.action.go-back": "",
5033
5405
  "error.footer.copy": "",
5034
5406
  "error.footer.text": "",
@@ -5050,7 +5422,7 @@ var OryLocales = {
5050
5422
  };
5051
5423
 
5052
5424
  // src/context/intl-context.tsx
5053
- var import_jsx_runtime93 = require("react/jsx-runtime");
5425
+ var import_jsx_runtime99 = require("react/jsx-runtime");
5054
5426
  function mergeTranslations(customTranslations) {
5055
5427
  return Object.keys(customTranslations).reduce((acc, key) => {
5056
5428
  acc[key] = { ...OryLocales[key], ...customTranslations[key] };
@@ -5063,12 +5435,12 @@ var IntlProvider = ({
5063
5435
  customTranslations
5064
5436
  }) => {
5065
5437
  const messages = mergeTranslations(customTranslations != null ? customTranslations : {});
5066
- return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
5067
- import_react_intl20.IntlProvider,
5438
+ return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(
5439
+ import_react_intl21.IntlProvider,
5068
5440
  {
5069
5441
  onWarn: () => ({}),
5070
5442
  defaultRichTextElements: {
5071
- del: (chunks) => /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("del", { children: chunks })
5443
+ del: (chunks) => /* @__PURE__ */ (0, import_jsx_runtime99.jsx)("del", { children: chunks })
5072
5444
  },
5073
5445
  locale,
5074
5446
  messages: messages[locale],
@@ -5079,8 +5451,8 @@ var IntlProvider = ({
5079
5451
  };
5080
5452
 
5081
5453
  // src/theme/default/flows/error.tsx
5082
- var import_react_intl21 = require("react-intl");
5083
- var import_jsx_runtime94 = require("react/jsx-runtime");
5454
+ var import_react_intl22 = require("react-intl");
5455
+ var import_jsx_runtime100 = require("react/jsx-runtime");
5084
5456
  function isOAuth2Error(error) {
5085
5457
  return !!error && typeof error === "object" && "error" in error && "error_description" in error;
5086
5458
  }
@@ -5089,7 +5461,7 @@ var errorDescriptions = {
5089
5461
  5: "The server encountered an error and could not complete your request"
5090
5462
  };
5091
5463
  function useStandardize(error) {
5092
- return (0, import_react15.useMemo)(() => {
5464
+ return (0, import_react16.useMemo)(() => {
5093
5465
  var _a;
5094
5466
  if (isOAuth2Error(error)) {
5095
5467
  return {
@@ -5099,14 +5471,14 @@ function useStandardize(error) {
5099
5471
  timestamp: /* @__PURE__ */ new Date()
5100
5472
  };
5101
5473
  }
5102
- if ((0, import_client_fetch34.instanceOfFlowError)(error)) {
5474
+ if ((0, import_client_fetch36.instanceOfFlowError)(error)) {
5103
5475
  const parsed = error.error;
5104
5476
  return {
5105
5477
  ...parsed,
5106
5478
  id: error.id,
5107
5479
  timestamp: error.created_at
5108
5480
  };
5109
- } else if (error.error && (0, import_client_fetch34.instanceOfGenericError)(error.error)) {
5481
+ } else if (error.error && (0, import_client_fetch36.instanceOfGenericError)(error.error)) {
5110
5482
  return {
5111
5483
  code: (_a = error.error.code) != null ? _a : 500,
5112
5484
  message: error.error.message,
@@ -5133,47 +5505,47 @@ function Error2({
5133
5505
  const Divider = (_d = (_c = Components == null ? void 0 : Components.Card) == null ? void 0 : _c.Divider) != null ? _d : DefaultHorizontalDivider;
5134
5506
  const parsed = useStandardize(error);
5135
5507
  const description = errorDescriptions[Math.floor(parsed.code / 100)];
5136
- return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
5508
+ return /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(
5137
5509
  IntlProvider,
5138
5510
  {
5139
5511
  locale: (_f = (_e = config.intl) == null ? void 0 : _e.locale) != null ? _f : "en",
5140
5512
  customTranslations: (_g = config.intl) == null ? void 0 : _g.customTranslations,
5141
- children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(Card, { children: /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)(
5513
+ children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(Card, { children: /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)(
5142
5514
  "div",
5143
5515
  {
5144
5516
  className: "flex flex-col gap-6 antialiased",
5145
5517
  "data-testid": "ory/screen/error",
5146
5518
  children: [
5147
- /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("header", { className: "flex flex-col gap-8 antialiased", children: [
5148
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(ErrorLogo, { config }),
5149
- /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("div", { className: "flex flex-col gap-2", children: [
5150
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("h2", { className: "text-lg font-semibold leading-normal text-interface-foreground-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_intl21.FormattedMessage, { id: "error.title.what-happened" }) }),
5151
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("p", { className: "leading-normal text-interface-foreground-default-secondary", children: (_h = parsed.message) != null ? _h : description }),
5152
- parsed.reason && /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("p", { className: "leading-normal text-interface-foreground-default-secondary", children: parsed.reason })
5519
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)("header", { className: "flex flex-col gap-8 antialiased", children: [
5520
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(ErrorLogo, { config }),
5521
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)("div", { className: "flex flex-col gap-2", children: [
5522
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("h2", { className: "text-lg font-semibold leading-normal text-interface-foreground-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_react_intl22.FormattedMessage, { id: "error.title.what-happened" }) }),
5523
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("p", { className: "leading-normal text-interface-foreground-default-secondary", children: (_h = parsed.message) != null ? _h : description }),
5524
+ parsed.reason && /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("p", { className: "leading-normal text-interface-foreground-default-secondary", children: parsed.reason })
5153
5525
  ] })
5154
5526
  ] }),
5155
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(Divider, {}),
5156
- /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("div", { className: "flex flex-col gap-2", children: [
5157
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("h2", { className: "text-lg font-semibold leading-normal text-interface-foreground-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_intl21.FormattedMessage, { id: "error.title.what-can-i-do" }) }),
5158
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("p", { className: "leading-normal text-interface-foreground-default-secondary", children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_intl21.FormattedMessage, { id: "error.instructions" }) }),
5159
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { children: session ? /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(LoggedInActions, { config }) : /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(GoBackButton, { config }) })
5527
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(Divider, {}),
5528
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)("div", { className: "flex flex-col gap-2", children: [
5529
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("h2", { className: "text-lg font-semibold leading-normal text-interface-foreground-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_react_intl22.FormattedMessage, { id: "error.title.what-can-i-do" }) }),
5530
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("p", { className: "leading-normal text-interface-foreground-default-secondary", children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_react_intl22.FormattedMessage, { id: "error.instructions" }) }),
5531
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("div", { children: session ? /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(LoggedInActions, { config }) : /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(GoBackButton, { config }) })
5160
5532
  ] }),
5161
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(Divider, {}),
5162
- /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("div", { className: "font-normal leading-normal antialiased gap-2 flex flex-col", children: [
5163
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("span", { className: "text-interface-foreground-default-primary text-sm", children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_intl21.FormattedMessage, { id: "error.footer.text" }) }),
5164
- parsed.id && /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("p", { className: "text-interface-foreground-default-secondary text-sm", children: [
5533
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(Divider, {}),
5534
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)("div", { className: "font-normal leading-normal antialiased gap-2 flex flex-col", children: [
5535
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("span", { className: "text-interface-foreground-default-primary text-sm", children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_react_intl22.FormattedMessage, { id: "error.footer.text" }) }),
5536
+ parsed.id && /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)("p", { className: "text-interface-foreground-default-secondary text-sm", children: [
5165
5537
  "ID: ",
5166
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("code", { children: parsed.id })
5538
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("code", { children: parsed.id })
5167
5539
  ] }),
5168
- /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("p", { className: "text-interface-foreground-default-secondary text-sm", children: [
5540
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)("p", { className: "text-interface-foreground-default-secondary text-sm", children: [
5169
5541
  "Time: ",
5170
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("code", { children: (_i = parsed.timestamp) == null ? void 0 : _i.toUTCString() })
5542
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("code", { children: (_i = parsed.timestamp) == null ? void 0 : _i.toUTCString() })
5171
5543
  ] }),
5172
- /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("p", { className: "text-interface-foreground-default-secondary text-sm", children: [
5544
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)("p", { className: "text-interface-foreground-default-secondary text-sm", children: [
5173
5545
  "Message: ",
5174
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("code", { children: parsed.reason })
5546
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("code", { children: parsed.reason })
5175
5547
  ] }),
5176
- /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
5548
+ /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(
5177
5549
  "button",
5178
5550
  {
5179
5551
  className: "text-interface-foreground-default-primary underline",
@@ -5185,7 +5557,7 @@ ${parsed.reason ? `Message: ${parsed.reason}` : ""}
5185
5557
  `;
5186
5558
  void navigator.clipboard.writeText(text);
5187
5559
  },
5188
- children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_intl21.FormattedMessage, { id: "error.footer.copy" })
5560
+ children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_react_intl22.FormattedMessage, { id: "error.footer.copy" })
5189
5561
  }
5190
5562
  ) })
5191
5563
  ] })
@@ -5197,7 +5569,7 @@ ${parsed.reason ? `Message: ${parsed.reason}` : ""}
5197
5569
  }
5198
5570
  function LoggedInActions({ config }) {
5199
5571
  const logoutFlow = useClientLogout(config);
5200
- return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
5572
+ return /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(
5201
5573
  "a",
5202
5574
  {
5203
5575
  href: logoutFlow == null ? void 0 : logoutFlow.logout_url,
@@ -5208,12 +5580,12 @@ function LoggedInActions({ config }) {
5208
5580
  }
5209
5581
  function GoBackButton({ config }) {
5210
5582
  if ("default_redirect_url" in config.project) {
5211
- return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
5583
+ return /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(
5212
5584
  "a",
5213
5585
  {
5214
5586
  className: "text-interface-foreground-default-primary underline",
5215
5587
  href: config.project.default_redirect_url,
5216
- children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_intl21.FormattedMessage, { id: "error.action.go-back" })
5588
+ children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_react_intl22.FormattedMessage, { id: "error.action.go-back" })
5217
5589
  }
5218
5590
  );
5219
5591
  }
@@ -5221,15 +5593,15 @@ function GoBackButton({ config }) {
5221
5593
  }
5222
5594
  function ErrorLogo({ config }) {
5223
5595
  if (config.logoUrl) {
5224
- return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("img", { src: config.logoUrl, width: 100, height: 36, alt: "Logo" });
5596
+ return /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("img", { src: config.logoUrl, width: 100, height: 36, alt: "Logo" });
5225
5597
  }
5226
- return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("h1", { className: "text-xl font-semibold leading-normal text-interface-foreground-default-primary", children: config.name });
5598
+ return /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("h1", { className: "text-xl font-semibold leading-normal text-interface-foreground-default-primary", children: config.name });
5227
5599
  }
5228
5600
 
5229
5601
  // src/theme/default/flows/login.tsx
5230
- var import_client_fetch35 = require("@ory/client-fetch");
5231
- var import_elements_react19 = require("@ory/elements-react");
5232
- var import_jsx_runtime95 = require("react/jsx-runtime");
5602
+ var import_client_fetch37 = require("@ory/client-fetch");
5603
+ var import_elements_react20 = require("@ory/elements-react");
5604
+ var import_jsx_runtime101 = require("react/jsx-runtime");
5233
5605
  function Login({
5234
5606
  flow,
5235
5607
  config,
@@ -5237,22 +5609,22 @@ function Login({
5237
5609
  components: flowOverrideComponents
5238
5610
  }) {
5239
5611
  const components = getOryComponents(flowOverrideComponents);
5240
- return /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
5241
- import_elements_react19.OryProvider,
5612
+ return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(
5613
+ import_elements_react20.OryProvider,
5242
5614
  {
5243
5615
  config,
5244
5616
  flow,
5245
- flowType: import_client_fetch35.FlowType.Login,
5617
+ flowType: import_client_fetch37.FlowType.Login,
5246
5618
  components,
5247
- children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_elements_react19.OryTwoStepCard, {})
5619
+ children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(import_elements_react20.OryTwoStepCard, {})
5248
5620
  }
5249
5621
  );
5250
5622
  }
5251
5623
 
5252
5624
  // src/theme/default/flows/recovery.tsx
5253
- var import_client_fetch36 = require("@ory/client-fetch");
5254
- var import_elements_react20 = require("@ory/elements-react");
5255
- var import_jsx_runtime96 = require("react/jsx-runtime");
5625
+ var import_client_fetch38 = require("@ory/client-fetch");
5626
+ var import_elements_react21 = require("@ory/elements-react");
5627
+ var import_jsx_runtime102 = require("react/jsx-runtime");
5256
5628
  function Recovery({
5257
5629
  flow,
5258
5630
  config,
@@ -5260,22 +5632,22 @@ function Recovery({
5260
5632
  components: flowOverrideComponents
5261
5633
  }) {
5262
5634
  const components = getOryComponents(flowOverrideComponents);
5263
- return /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(
5264
- import_elements_react20.OryProvider,
5635
+ return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(
5636
+ import_elements_react21.OryProvider,
5265
5637
  {
5266
5638
  config,
5267
5639
  flow,
5268
- flowType: import_client_fetch36.FlowType.Recovery,
5640
+ flowType: import_client_fetch38.FlowType.Recovery,
5269
5641
  components,
5270
- children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(import_elements_react20.OryTwoStepCard, {})
5642
+ children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_elements_react21.OryTwoStepCard, {})
5271
5643
  }
5272
5644
  );
5273
5645
  }
5274
5646
 
5275
5647
  // src/theme/default/flows/registration.tsx
5276
- var import_client_fetch37 = require("@ory/client-fetch");
5277
- var import_elements_react21 = require("@ory/elements-react");
5278
- var import_jsx_runtime97 = require("react/jsx-runtime");
5648
+ var import_client_fetch39 = require("@ory/client-fetch");
5649
+ var import_elements_react22 = require("@ory/elements-react");
5650
+ var import_jsx_runtime103 = require("react/jsx-runtime");
5279
5651
  function Registration({
5280
5652
  flow,
5281
5653
  children,
@@ -5283,22 +5655,22 @@ function Registration({
5283
5655
  config
5284
5656
  }) {
5285
5657
  const components = getOryComponents(flowOverrideComponents);
5286
- return /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(
5287
- import_elements_react21.OryProvider,
5658
+ return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(
5659
+ import_elements_react22.OryProvider,
5288
5660
  {
5289
5661
  config,
5290
5662
  flow,
5291
- flowType: import_client_fetch37.FlowType.Registration,
5663
+ flowType: import_client_fetch39.FlowType.Registration,
5292
5664
  components,
5293
- children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(import_elements_react21.OryTwoStepCard, {})
5665
+ children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(import_elements_react22.OryTwoStepCard, {})
5294
5666
  }
5295
5667
  );
5296
5668
  }
5297
5669
 
5298
5670
  // src/theme/default/flows/settings.tsx
5299
- var import_client_fetch38 = require("@ory/client-fetch");
5300
- var import_elements_react22 = require("@ory/elements-react");
5301
- var import_jsx_runtime98 = require("react/jsx-runtime");
5671
+ var import_client_fetch40 = require("@ory/client-fetch");
5672
+ var import_elements_react23 = require("@ory/elements-react");
5673
+ var import_jsx_runtime104 = require("react/jsx-runtime");
5302
5674
  function Settings({
5303
5675
  flow,
5304
5676
  config,
@@ -5306,25 +5678,25 @@ function Settings({
5306
5678
  components: flowOverrideComponents
5307
5679
  }) {
5308
5680
  const components = getOryComponents(flowOverrideComponents);
5309
- return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(
5310
- import_elements_react22.OryProvider,
5681
+ return /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(
5682
+ import_elements_react23.OryProvider,
5311
5683
  {
5312
5684
  config,
5313
5685
  flow,
5314
- flowType: import_client_fetch38.FlowType.Settings,
5686
+ flowType: import_client_fetch40.FlowType.Settings,
5315
5687
  components,
5316
- children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime98.jsxs)(import_jsx_runtime98.Fragment, { children: [
5317
- /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(import_elements_react22.HeadlessPageHeader, {}),
5318
- /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(import_elements_react22.OrySettingsCard, {})
5688
+ children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime104.jsxs)(import_jsx_runtime104.Fragment, { children: [
5689
+ /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(import_elements_react23.HeadlessPageHeader, {}),
5690
+ /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(import_elements_react23.OrySettingsCard, {})
5319
5691
  ] })
5320
5692
  }
5321
5693
  );
5322
5694
  }
5323
5695
 
5324
5696
  // src/theme/default/flows/verification.tsx
5325
- var import_client_fetch39 = require("@ory/client-fetch");
5326
- var import_elements_react23 = require("@ory/elements-react");
5327
- var import_jsx_runtime99 = require("react/jsx-runtime");
5697
+ var import_client_fetch41 = require("@ory/client-fetch");
5698
+ var import_elements_react24 = require("@ory/elements-react");
5699
+ var import_jsx_runtime105 = require("react/jsx-runtime");
5328
5700
  function Verification({
5329
5701
  flow,
5330
5702
  config,
@@ -5332,19 +5704,192 @@ function Verification({
5332
5704
  components: flowOverrideComponents
5333
5705
  }) {
5334
5706
  const components = getOryComponents(flowOverrideComponents);
5335
- return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(
5336
- import_elements_react23.OryProvider,
5707
+ return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(
5708
+ import_elements_react24.OryProvider,
5709
+ {
5710
+ config,
5711
+ flow,
5712
+ flowType: import_client_fetch41.FlowType.Verification,
5713
+ components,
5714
+ children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_elements_react24.OryTwoStepCard, {})
5715
+ }
5716
+ );
5717
+ }
5718
+
5719
+ // src/theme/default/flows/consent.tsx
5720
+ var import_client_fetch43 = require("@ory/client-fetch");
5721
+ var import_elements_react25 = require("@ory/elements-react");
5722
+
5723
+ // src/theme/default/utils/oauth2.ts
5724
+ var import_client_fetch42 = require("@ory/client-fetch");
5725
+ var rememberCheckbox = {
5726
+ type: "input",
5727
+ group: "oauth2_consent",
5728
+ meta: {
5729
+ label: {
5730
+ id: 9999111,
5731
+ text: "Remember my decision",
5732
+ type: import_client_fetch42.UiTextTypeEnum.Info
5733
+ }
5734
+ },
5735
+ attributes: {
5736
+ node_type: "input",
5737
+ name: "remember",
5738
+ value: false,
5739
+ type: "checkbox",
5740
+ disabled: false
5741
+ },
5742
+ messages: []
5743
+ };
5744
+ var acceptButton = {
5745
+ type: "input",
5746
+ group: "oauth2_consent",
5747
+ meta: {
5748
+ label: {
5749
+ id: 9999111,
5750
+ text: "Accept",
5751
+ type: import_client_fetch42.UiTextTypeEnum.Info
5752
+ }
5753
+ },
5754
+ attributes: {
5755
+ node_type: "input",
5756
+ name: "action",
5757
+ value: "accept",
5758
+ type: "submit",
5759
+ disabled: false
5760
+ },
5761
+ messages: []
5762
+ };
5763
+ var rejectButton = {
5764
+ type: "input",
5765
+ group: "oauth2_consent",
5766
+ meta: {
5767
+ label: {
5768
+ id: 9999111,
5769
+ text: "Reject",
5770
+ type: import_client_fetch42.UiTextTypeEnum.Info
5771
+ }
5772
+ },
5773
+ attributes: {
5774
+ node_type: "input",
5775
+ name: "action",
5776
+ value: "reject",
5777
+ type: "submit",
5778
+ disabled: false
5779
+ },
5780
+ messages: []
5781
+ };
5782
+ function translateConsentChallengeToUiNodes(consentChallenge, csrfToken, formAction, session) {
5783
+ var _a;
5784
+ const ui = {
5785
+ action: formAction,
5786
+ nodes: [
5787
+ ...scopesToUiNodes((_a = consentChallenge.requested_scope) != null ? _a : []),
5788
+ rememberCheckbox,
5789
+ rejectButton,
5790
+ acceptButton,
5791
+ csrfTokenNode(csrfToken),
5792
+ challengeNode(consentChallenge.challenge)
5793
+ ],
5794
+ method: "POST",
5795
+ messages: []
5796
+ };
5797
+ return {
5798
+ id: "UNSET",
5799
+ created_at: /* @__PURE__ */ new Date(),
5800
+ expires_at: /* @__PURE__ */ new Date(),
5801
+ issued_at: /* @__PURE__ */ new Date(),
5802
+ state: "show_form",
5803
+ active: "oauth2_consent",
5804
+ ui,
5805
+ consent_request: consentChallenge,
5806
+ session
5807
+ };
5808
+ }
5809
+ function scopesToUiNodes(scopes) {
5810
+ return scopes.map((scope) => ({
5811
+ type: "input",
5812
+ group: "oauth2_consent",
5813
+ meta: {
5814
+ label: {
5815
+ id: 9999111,
5816
+ text: scope,
5817
+ type: import_client_fetch42.UiTextTypeEnum.Info
5818
+ }
5819
+ },
5820
+ attributes: {
5821
+ node_type: "input",
5822
+ name: `grant_scope`,
5823
+ value: scope,
5824
+ type: "checkbox",
5825
+ disabled: false
5826
+ },
5827
+ messages: []
5828
+ }));
5829
+ }
5830
+ function csrfTokenNode(csrfToken) {
5831
+ return {
5832
+ type: "input",
5833
+ group: "default",
5834
+ meta: {},
5835
+ attributes: {
5836
+ node_type: "input",
5837
+ name: "csrf_token",
5838
+ value: csrfToken,
5839
+ type: "hidden",
5840
+ disabled: false
5841
+ },
5842
+ messages: []
5843
+ };
5844
+ }
5845
+ function challengeNode(challenge) {
5846
+ return {
5847
+ type: "input",
5848
+ group: "oauth2_consent",
5849
+ meta: {},
5850
+ attributes: {
5851
+ node_type: "input",
5852
+ name: "consent_challenge",
5853
+ value: challenge,
5854
+ type: "hidden",
5855
+ disabled: false
5856
+ },
5857
+ messages: []
5858
+ };
5859
+ }
5860
+
5861
+ // src/theme/default/flows/consent.tsx
5862
+ var import_jsx_runtime106 = require("react/jsx-runtime");
5863
+ function Consent({
5864
+ consentChallenge,
5865
+ session,
5866
+ config,
5867
+ components: Passed,
5868
+ children,
5869
+ csrfToken,
5870
+ formActionUrl
5871
+ }) {
5872
+ const components = getOryComponents(Passed);
5873
+ const flow = translateConsentChallengeToUiNodes(
5874
+ consentChallenge,
5875
+ csrfToken,
5876
+ formActionUrl,
5877
+ session
5878
+ );
5879
+ return /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(
5880
+ import_elements_react25.OryProvider,
5337
5881
  {
5338
5882
  config,
5339
5883
  flow,
5340
- flowType: import_client_fetch39.FlowType.Verification,
5884
+ flowType: import_client_fetch43.FlowType.OAuth2Consent,
5341
5885
  components,
5342
- children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(import_elements_react23.OryTwoStepCard, {})
5886
+ children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(import_elements_react25.OryConsentCard, {})
5343
5887
  }
5344
5888
  );
5345
5889
  }
5346
5890
  // Annotate the CommonJS export names for ESM import in node:
5347
5891
  0 && (module.exports = {
5892
+ Consent,
5348
5893
  DefaultButtonSocial,
5349
5894
  DefaultCard,
5350
5895
  DefaultCardContent,