@ory/elements-react 1.0.0-next.10 → 1.0.0-next.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.js +2 -0
- package/CHANGELOG.md +47 -0
- package/api-report/elements-react-theme.api.json +25 -70
- package/api-report/elements-react-theme.api.md +15 -12
- package/api-report/elements-react.api.json +1380 -1920
- package/api-report/elements-react.api.md +237 -216
- package/api-report/temp/elements-react-theme.api.md +1 -0
- package/api-report/temp/elements-react.api.md +103 -20
- package/dist/index.d.mts +414 -2009
- package/dist/index.d.ts +414 -2009
- package/dist/index.js +6776 -857
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +6755 -826
- package/dist/index.mjs.map +1 -1
- package/dist/theme/default/index.css +292 -29
- package/dist/theme/default/index.css.map +1 -1
- package/dist/theme/default/index.d.mts +9 -9
- package/dist/theme/default/index.d.ts +9 -9
- package/dist/theme/default/index.js +1034 -295
- package/dist/theme/default/index.js.map +1 -1
- package/dist/theme/default/index.mjs +1028 -266
- package/dist/theme/default/index.mjs.map +1 -1
- package/jest.config.ts +4 -3
- package/package.json +13 -8
- package/tailwind.config.ts +6 -1
- package/tsconfig.json +5 -5
|
@@ -340,9 +340,9 @@ function useCardHeaderText(nodes, opts) {
|
|
|
340
340
|
// src/theme/default/components/card/header.tsx
|
|
341
341
|
var import_jsx_runtime5 = require("react/jsx-runtime");
|
|
342
342
|
function InnerCardHeader({ title, text }) {
|
|
343
|
-
const {
|
|
343
|
+
const { Card } = (0, import_elements_react2.useComponents)();
|
|
344
344
|
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("header", { className: "flex flex-col gap-8 antialiased", children: [
|
|
345
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
345
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Card.Logo, {}),
|
|
346
346
|
/* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { children: [
|
|
347
347
|
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("h2", { className: "font-semibold text-lg text-dialog-fg-default leading-normal", children: title }),
|
|
348
348
|
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: "text-sm leading-normal text-dialog-fg-subtle", children: text })
|
|
@@ -366,19 +366,13 @@ function DefaultCardLogo() {
|
|
|
366
366
|
if (flow.config.logoUrl) {
|
|
367
367
|
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("img", { src: flow.config.logoUrl, width: 100, height: 36, alt: "Logo" });
|
|
368
368
|
}
|
|
369
|
-
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
370
|
-
"h1",
|
|
371
|
-
{
|
|
372
|
-
className: "text-xl font-semibold leading-normal text-dialog-fg-default",
|
|
373
|
-
children: flow.config.name
|
|
374
|
-
}
|
|
375
|
-
);
|
|
369
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("h1", { className: "text-xl font-semibold leading-normal text-dialog-fg-default", children: flow.config.name });
|
|
376
370
|
}
|
|
377
371
|
|
|
378
372
|
// src/theme/default/components/card/index.tsx
|
|
379
373
|
var import_jsx_runtime7 = require("react/jsx-runtime");
|
|
380
374
|
function DefaultCard({ children }) {
|
|
381
|
-
return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { className: "font-sans", children: /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "grid grid-cols-1 max-w-sm md:max-w-[480px] md:w-[480px] gap-8 bg-dialog-bg-default px-8 md:px-12 py-12 md:py-14 relative rounded-border-radius-cards border border-dialog-border-default", children: [
|
|
375
|
+
return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { className: "flex-1 flex-col flex justify-center items-center font-sans", children: /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "grid grid-cols-1 max-w-sm md:max-w-[480px] md:w-[480px] gap-8 bg-dialog-bg-default px-8 md:px-12 py-12 md:py-14 relative rounded-border-radius-cards border border-dialog-border-default", children: [
|
|
382
376
|
children,
|
|
383
377
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Badge, {})
|
|
384
378
|
] }) });
|
|
@@ -392,8 +386,9 @@ function cn(...inputs) {
|
|
|
392
386
|
}
|
|
393
387
|
|
|
394
388
|
// src/theme/default/components/form/index.tsx
|
|
395
|
-
var import_elements_react4 = require("@ory/elements-react");
|
|
396
389
|
var import_react_intl3 = require("react-intl");
|
|
390
|
+
var import_elements_react4 = require("@ory/elements-react");
|
|
391
|
+
var import_client_fetch3 = require("@ory/client-fetch");
|
|
397
392
|
var import_jsx_runtime8 = require("react/jsx-runtime");
|
|
398
393
|
function DefaultFormContainer({
|
|
399
394
|
children,
|
|
@@ -414,10 +409,19 @@ function DefaultFormContainer({
|
|
|
414
409
|
);
|
|
415
410
|
}
|
|
416
411
|
function DefaultMessageContainer({ children }) {
|
|
412
|
+
const { flowType } = (0, import_elements_react4.useOryFlow)();
|
|
417
413
|
if (!children || Array.isArray(children) && children.length === 0) {
|
|
418
414
|
return null;
|
|
419
415
|
}
|
|
420
|
-
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
416
|
+
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
417
|
+
"section",
|
|
418
|
+
{
|
|
419
|
+
className: cn(
|
|
420
|
+
flowType === import_client_fetch3.FlowType.Settings ? "text-center" : "text-left"
|
|
421
|
+
),
|
|
422
|
+
children
|
|
423
|
+
}
|
|
424
|
+
);
|
|
421
425
|
}
|
|
422
426
|
function DefaultMessage({ message }) {
|
|
423
427
|
const intl = (0, import_react_intl3.useIntl)();
|
|
@@ -429,11 +433,14 @@ function DefaultMessage({ message }) {
|
|
|
429
433
|
"text-forms-fg-default": message.type === "info",
|
|
430
434
|
"text-forms-fg-success": message.type === "success"
|
|
431
435
|
}),
|
|
432
|
-
children: (0, import_elements_react4.
|
|
436
|
+
children: (0, import_elements_react4.uiTextToFormattedMessage)(message, intl)
|
|
433
437
|
}
|
|
434
438
|
);
|
|
435
439
|
}
|
|
436
440
|
|
|
441
|
+
// src/theme/default/components/card/auth-methods.tsx
|
|
442
|
+
var import_react_intl4 = require("react-intl");
|
|
443
|
+
|
|
437
444
|
// src/theme/default/assets/icons/code.svg
|
|
438
445
|
var React3 = __toESM(require("react"));
|
|
439
446
|
var import_jsx_runtime9 = require("react/jsx-runtime");
|
|
@@ -470,8 +477,12 @@ var SvgWebauthn = (props) => {
|
|
|
470
477
|
};
|
|
471
478
|
var webauthn_default = SvgWebauthn;
|
|
472
479
|
|
|
480
|
+
// src/theme/default/utils/form.ts
|
|
481
|
+
function isGroupImmediateSubmit(group) {
|
|
482
|
+
return group === "code";
|
|
483
|
+
}
|
|
484
|
+
|
|
473
485
|
// src/theme/default/components/card/auth-methods.tsx
|
|
474
|
-
var import_react_intl4 = require("react-intl");
|
|
475
486
|
var import_jsx_runtime13 = require("react/jsx-runtime");
|
|
476
487
|
var iconsMap = {
|
|
477
488
|
code: code_default,
|
|
@@ -488,8 +499,9 @@ function DefaultAuthMethodListItem({
|
|
|
488
499
|
return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { className: "w-full hover:bg-forms-bg-hover px-2 py-1 rounded", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
|
|
489
500
|
"button",
|
|
490
501
|
{
|
|
491
|
-
className: "flex text-left py-2 gap-3 cursor-pointer
|
|
502
|
+
className: "flex text-left py-2 gap-3 cursor-pointer",
|
|
492
503
|
onClick,
|
|
504
|
+
type: isGroupImmediateSubmit(group) ? "submit" : "button",
|
|
493
505
|
children: [
|
|
494
506
|
/* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { className: "flex-none w-4 h-4 mt-[2px]", children: Icon && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Icon, { size: 20, className: "text-forms-fg-default" }) }),
|
|
495
507
|
/* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: "flex-1 text-sm leading-normal", children: [
|
|
@@ -502,6 +514,8 @@ function DefaultAuthMethodListItem({
|
|
|
502
514
|
}
|
|
503
515
|
|
|
504
516
|
// src/theme/default/components/form/button.tsx
|
|
517
|
+
var import_client_fetch4 = require("@ory/client-fetch");
|
|
518
|
+
var import_elements_react5 = require("@ory/elements-react");
|
|
505
519
|
var import_react_hook_form = require("react-hook-form");
|
|
506
520
|
var import_react_intl5 = require("react-intl");
|
|
507
521
|
|
|
@@ -514,7 +528,7 @@ function Spinner({ className }) {
|
|
|
514
528
|
"aria-hidden": "true",
|
|
515
529
|
role: "status",
|
|
516
530
|
className: cn(
|
|
517
|
-
"absolute inset-0 mx-auto my-auto w-8 h-8
|
|
531
|
+
"absolute pointer-events-none inset-0 mx-auto my-auto w-8 h-8 animate-spin",
|
|
518
532
|
className
|
|
519
533
|
),
|
|
520
534
|
viewBox: "0 0 34 34",
|
|
@@ -545,14 +559,50 @@ function Spinner({ className }) {
|
|
|
545
559
|
}
|
|
546
560
|
|
|
547
561
|
// src/theme/default/components/form/button.tsx
|
|
548
|
-
var
|
|
549
|
-
var
|
|
562
|
+
var import_elements_react6 = require("@ory/elements-react");
|
|
563
|
+
var import_class_variance_authority = require("class-variance-authority");
|
|
550
564
|
var import_jsx_runtime15 = require("react/jsx-runtime");
|
|
565
|
+
var buttonStyles = (0, import_class_variance_authority.cva)(
|
|
566
|
+
[
|
|
567
|
+
"ring-1 relative overflow-hidden ring-inset rounded text-sm leading-none flex gap-3 justify-center",
|
|
568
|
+
"disabled:cursor-not-allowed loading:before:pointer-events-none loading:cursor-wait",
|
|
569
|
+
"transition-colors ease-linear duration-100"
|
|
570
|
+
],
|
|
571
|
+
{
|
|
572
|
+
variants: {
|
|
573
|
+
intent: {
|
|
574
|
+
primary: [
|
|
575
|
+
"bg-button-primary-bg-default text-button-primary-fg-default ring-button-primary-border-default",
|
|
576
|
+
"hover:bg-button-primary-bg-hover hover:text-button-primary-fg-hover hover:ring-button-primary-border-hover",
|
|
577
|
+
"disabled:bg-button-primary-bg-disabled disabled:text-button-primary-fg-disabled disabled:ring-button-primary-border-disabled",
|
|
578
|
+
"loading:bg-button-primary-bg-default loading:text-button-primary-fg-default loading:ring-button-primary-border-default",
|
|
579
|
+
"loading:before:absolute loading:before:content-[''] loading:before:inset-0 loading:before:bg-button-primary-bg-default loading:before:opacity-80"
|
|
580
|
+
],
|
|
581
|
+
secondary: [
|
|
582
|
+
"bg-button-secondary-bg-default text-button-secondary-fg-default ring-button-secondary-border-default",
|
|
583
|
+
"hover:bg-button-secondary-bg-hover hover:text-button-secondary-fg-hover hover:ring-button-secondary-border-hover",
|
|
584
|
+
"disabled:bg-button-secondary-bg-disabled disabled:text-button-secondary-fg-disabled disabled:ring-button-secondary-border-disabled",
|
|
585
|
+
"loading:bg-button-secondary-bg-default loading:text-button-secondary-fg-default loading:ring-button-secondary-border-default",
|
|
586
|
+
"loading:before:absolute loading:before:content-[''] loading:before:inset-0 loading:before:bg-button-secondary-bg-default loading:before:opacity-80"
|
|
587
|
+
]
|
|
588
|
+
},
|
|
589
|
+
size: {
|
|
590
|
+
default: ["px-4 py-3"],
|
|
591
|
+
large: ["px-4 py-4.5 max-md:py-3"]
|
|
592
|
+
},
|
|
593
|
+
defaultVariants: {
|
|
594
|
+
intent: "primary",
|
|
595
|
+
size: "default"
|
|
596
|
+
}
|
|
597
|
+
}
|
|
598
|
+
}
|
|
599
|
+
);
|
|
551
600
|
var DefaultButton = ({
|
|
552
601
|
attributes,
|
|
553
602
|
node,
|
|
554
603
|
onClick
|
|
555
604
|
}) => {
|
|
605
|
+
var _a;
|
|
556
606
|
const {
|
|
557
607
|
type,
|
|
558
608
|
name,
|
|
@@ -565,12 +615,14 @@ var DefaultButton = ({
|
|
|
565
615
|
...rest
|
|
566
616
|
} = attributes;
|
|
567
617
|
const intl = (0, import_react_intl5.useIntl)();
|
|
568
|
-
const label = (0,
|
|
618
|
+
const label = (0, import_client_fetch4.getNodeLabel)(node);
|
|
619
|
+
const { flowType } = (0, import_elements_react6.useOryFlow)();
|
|
569
620
|
const {
|
|
570
621
|
formState: { isSubmitting },
|
|
571
622
|
setValue
|
|
572
623
|
} = (0, import_react_hook_form.useFormContext)();
|
|
573
|
-
const isPrimary = attributes.name === "method" || attributes.name.includes("passkey") || attributes.name.includes("webauthn");
|
|
624
|
+
const isPrimary = attributes.name === "method" || attributes.name.includes("passkey") || attributes.name.includes("webauthn") || attributes.name.includes("lookup_secret");
|
|
625
|
+
const isSmall = flowType === import_client_fetch4.FlowType.Settings && attributes.name !== "webauthn_register_trigger";
|
|
574
626
|
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
|
|
575
627
|
"button",
|
|
576
628
|
{
|
|
@@ -582,38 +634,20 @@ var DefaultButton = ({
|
|
|
582
634
|
setValue(name, value);
|
|
583
635
|
},
|
|
584
636
|
onClick: (e) => {
|
|
585
|
-
|
|
586
|
-
onClick(e);
|
|
587
|
-
}
|
|
637
|
+
onClick == null ? void 0 : onClick(e);
|
|
588
638
|
if (type !== "button") {
|
|
589
639
|
setValue(name, value);
|
|
590
640
|
}
|
|
591
641
|
},
|
|
592
|
-
className:
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
"bg-button-secondary-bg-default hover:bg-button-secondary-bg-hover text-button-secondary-fg-default hover:text-button-secondary-fg-hover border-button-secondary-border-default": !isPrimary
|
|
599
|
-
},
|
|
600
|
-
{}
|
|
601
|
-
),
|
|
642
|
+
className: buttonStyles({
|
|
643
|
+
intent: isPrimary ? "primary" : "secondary",
|
|
644
|
+
size: isSmall ? "default" : "large"
|
|
645
|
+
}),
|
|
646
|
+
disabled: (_a = rest.disabled) != null ? _a : true,
|
|
647
|
+
"data-loading": isSubmitting,
|
|
602
648
|
children: [
|
|
603
649
|
isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Spinner, {}) : null,
|
|
604
|
-
|
|
605
|
-
"span",
|
|
606
|
-
{
|
|
607
|
-
className: cn(
|
|
608
|
-
"transition-colors ease-linear duration-100 leading-none text-button-primary-fg-default/20",
|
|
609
|
-
{
|
|
610
|
-
"text-button-primary-fg-default opacity-20 transition-opacity": isSubmitting && isPrimary,
|
|
611
|
-
"text-button-secondary-fg-default/20": isSubmitting && !isPrimary
|
|
612
|
-
}
|
|
613
|
-
),
|
|
614
|
-
children: (0, import_elements_react5.formatMessage)(label, intl)
|
|
615
|
-
}
|
|
616
|
-
)
|
|
650
|
+
label ? (0, import_elements_react5.uiTextToFormattedMessage)(label, intl) : ""
|
|
617
651
|
]
|
|
618
652
|
}
|
|
619
653
|
);
|
|
@@ -621,14 +655,112 @@ var DefaultButton = ({
|
|
|
621
655
|
DefaultButton.displayName = "DefaultButton";
|
|
622
656
|
|
|
623
657
|
// src/theme/default/components/form/checkbox.tsx
|
|
658
|
+
var import_client_fetch5 = require("@ory/client-fetch");
|
|
659
|
+
var import_elements_react7 = require("@ory/elements-react");
|
|
624
660
|
var import_react = require("react");
|
|
625
661
|
var import_react_hook_form2 = require("react-hook-form");
|
|
662
|
+
var import_react_intl7 = require("react-intl");
|
|
663
|
+
|
|
664
|
+
// src/theme/default/components/ui/checkbox-label.tsx
|
|
626
665
|
var import_react_intl6 = require("react-intl");
|
|
627
|
-
|
|
628
|
-
|
|
666
|
+
|
|
667
|
+
// src/util/i18n/index.ts
|
|
668
|
+
var uiTextToFormattedMessage3 = ({ id, context = {}, text }, intl) => {
|
|
669
|
+
const contextInjectedMessage = Object.entries(context).reduce(
|
|
670
|
+
(accumulator, [key, value]) => {
|
|
671
|
+
if (Array.isArray(value)) {
|
|
672
|
+
return {
|
|
673
|
+
...accumulator,
|
|
674
|
+
[key]: value,
|
|
675
|
+
[key + "_list"]: intl.formatList(value)
|
|
676
|
+
};
|
|
677
|
+
} else if (key.endsWith("_unix")) {
|
|
678
|
+
if (typeof value === "number") {
|
|
679
|
+
return {
|
|
680
|
+
...accumulator,
|
|
681
|
+
[key]: intl.formatDate(new Date(value * 1e3)),
|
|
682
|
+
[key + "_since"]: intl.formatDateTimeRange(
|
|
683
|
+
new Date(value),
|
|
684
|
+
/* @__PURE__ */ new Date()
|
|
685
|
+
),
|
|
686
|
+
[key + "_since_minutes"]: Math.abs(
|
|
687
|
+
(value - (/* @__PURE__ */ new Date()).getTime() / 1e3) / 60
|
|
688
|
+
).toFixed(2),
|
|
689
|
+
[key + "_until"]: intl.formatDateTimeRange(
|
|
690
|
+
/* @__PURE__ */ new Date(),
|
|
691
|
+
new Date(value)
|
|
692
|
+
),
|
|
693
|
+
[key + "_until_minutes"]: Math.abs(
|
|
694
|
+
((/* @__PURE__ */ new Date()).getTime() / 1e3 - value) / 60
|
|
695
|
+
).toFixed(2)
|
|
696
|
+
};
|
|
697
|
+
}
|
|
698
|
+
}
|
|
699
|
+
return {
|
|
700
|
+
...accumulator,
|
|
701
|
+
[key]: value
|
|
702
|
+
};
|
|
703
|
+
},
|
|
704
|
+
{}
|
|
705
|
+
);
|
|
706
|
+
return intl.formatMessage(
|
|
707
|
+
{
|
|
708
|
+
id: `identities.messages.${id}`,
|
|
709
|
+
defaultMessage: text
|
|
710
|
+
},
|
|
711
|
+
contextInjectedMessage
|
|
712
|
+
);
|
|
713
|
+
};
|
|
714
|
+
|
|
715
|
+
// src/theme/default/components/ui/checkbox-label.tsx
|
|
629
716
|
var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
717
|
+
var linkRegex = /\[([^\]]+)\]\(([^)]+)\)/g;
|
|
718
|
+
function computeLabelElements(labelText) {
|
|
719
|
+
const elements = [];
|
|
720
|
+
let lastIndex = 0;
|
|
721
|
+
for (const match of labelText.matchAll(linkRegex)) {
|
|
722
|
+
const linkText = match[1];
|
|
723
|
+
const url = match[2];
|
|
724
|
+
const matchStart = match.index;
|
|
725
|
+
if (typeof matchStart === "undefined") {
|
|
726
|
+
continue;
|
|
727
|
+
}
|
|
728
|
+
if (matchStart > lastIndex) {
|
|
729
|
+
elements.push(labelText.slice(lastIndex, matchStart));
|
|
730
|
+
}
|
|
731
|
+
elements.push(
|
|
732
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
733
|
+
"a",
|
|
734
|
+
{
|
|
735
|
+
href: url,
|
|
736
|
+
target: "_blank",
|
|
737
|
+
rel: "noopener noreferrer",
|
|
738
|
+
className: "text-links-link-default hover:text-links-link-hover hover:underline",
|
|
739
|
+
children: linkText
|
|
740
|
+
},
|
|
741
|
+
matchStart
|
|
742
|
+
)
|
|
743
|
+
);
|
|
744
|
+
lastIndex = matchStart + match[0].length;
|
|
745
|
+
}
|
|
746
|
+
if (lastIndex < labelText.length) {
|
|
747
|
+
elements.push(labelText.slice(lastIndex));
|
|
748
|
+
}
|
|
749
|
+
return elements;
|
|
750
|
+
}
|
|
751
|
+
function CheckboxLabel({ label }) {
|
|
752
|
+
const intl = (0, import_react_intl6.useIntl)();
|
|
753
|
+
if (!label) {
|
|
754
|
+
return null;
|
|
755
|
+
}
|
|
756
|
+
const labelText = uiTextToFormattedMessage3(label, intl);
|
|
757
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_jsx_runtime16.Fragment, { children: computeLabelElements(labelText) });
|
|
758
|
+
}
|
|
759
|
+
|
|
760
|
+
// src/theme/default/components/form/checkbox.tsx
|
|
761
|
+
var import_jsx_runtime17 = require("react/jsx-runtime");
|
|
630
762
|
function CheckboxSVG() {
|
|
631
|
-
return /* @__PURE__ */ (0,
|
|
763
|
+
return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
|
|
632
764
|
"svg",
|
|
633
765
|
{
|
|
634
766
|
className: "absolute w-4 h-4 hidden peer-checked:block",
|
|
@@ -638,14 +770,14 @@ function CheckboxSVG() {
|
|
|
638
770
|
viewBox: "0 0 16 16",
|
|
639
771
|
fill: "none",
|
|
640
772
|
children: [
|
|
641
|
-
/* @__PURE__ */ (0,
|
|
773
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
642
774
|
"path",
|
|
643
775
|
{
|
|
644
776
|
d: "M0 4C0 1.79086 1.79086 0 4 0H12C14.2091 0 16 1.79086 16 4V12C16 14.2091 14.2091 16 12 16H4C1.79086 16 0 14.2091 0 12V4Z",
|
|
645
777
|
fill: "#0F172A"
|
|
646
778
|
}
|
|
647
779
|
),
|
|
648
|
-
/* @__PURE__ */ (0,
|
|
780
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
649
781
|
"path",
|
|
650
782
|
{
|
|
651
783
|
fillRule: "evenodd",
|
|
@@ -668,14 +800,15 @@ var DefaultCheckbox = ({
|
|
|
668
800
|
// Button does not support these attributes, so we skip them
|
|
669
801
|
autocomplete: _autocomplete,
|
|
670
802
|
onclick: _onclick,
|
|
803
|
+
maxlength: _max,
|
|
671
804
|
// End of skipped attributes
|
|
672
805
|
...attributes
|
|
673
806
|
} = initialAttributes;
|
|
674
|
-
const intl = (0,
|
|
675
|
-
const label = (0,
|
|
807
|
+
const intl = (0, import_react_intl7.useIntl)();
|
|
808
|
+
const label = (0, import_client_fetch5.getNodeLabel)(node);
|
|
676
809
|
const [checked, setChecked] = (0, import_react.useState)(Boolean(value));
|
|
677
810
|
const { register } = (0, import_react_hook_form2.useForm)();
|
|
678
|
-
return /* @__PURE__ */ (0,
|
|
811
|
+
return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
|
|
679
812
|
"div",
|
|
680
813
|
{
|
|
681
814
|
className: "flex antialiased gap-3 self-stretch item-start",
|
|
@@ -683,8 +816,8 @@ var DefaultCheckbox = ({
|
|
|
683
816
|
setChecked(!checked);
|
|
684
817
|
},
|
|
685
818
|
children: [
|
|
686
|
-
/* @__PURE__ */ (0,
|
|
687
|
-
/* @__PURE__ */ (0,
|
|
819
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsxs)("div", { className: "flex h-5 items-center", children: [
|
|
820
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
688
821
|
"input",
|
|
689
822
|
{
|
|
690
823
|
...attributes,
|
|
@@ -699,16 +832,16 @@ var DefaultCheckbox = ({
|
|
|
699
832
|
...register(name, { value })
|
|
700
833
|
}
|
|
701
834
|
),
|
|
702
|
-
/* @__PURE__ */ (0,
|
|
835
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(CheckboxSVG, {})
|
|
703
836
|
] }),
|
|
704
|
-
/* @__PURE__ */ (0,
|
|
705
|
-
/* @__PURE__ */ (0,
|
|
706
|
-
node.messages.map((message) => /* @__PURE__ */ (0,
|
|
837
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsxs)("div", { className: "text-sm items-center", children: [
|
|
838
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)("label", { className: "text-sm font-normal leading-normal text-forms-fg-default", children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(CheckboxLabel, { label }) }),
|
|
839
|
+
node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
707
840
|
"span",
|
|
708
841
|
{
|
|
709
842
|
className: "text-sm text-red-900 mt-1",
|
|
710
|
-
...(0,
|
|
711
|
-
children: (0,
|
|
843
|
+
...(0, import_elements_react7.messageTestId)(message),
|
|
844
|
+
children: (0, import_elements_react7.uiTextToFormattedMessage)(message, intl)
|
|
712
845
|
},
|
|
713
846
|
message.id
|
|
714
847
|
))
|
|
@@ -719,50 +852,48 @@ var DefaultCheckbox = ({
|
|
|
719
852
|
};
|
|
720
853
|
|
|
721
854
|
// src/theme/default/components/form/group-container.tsx
|
|
722
|
-
var
|
|
723
|
-
function DefaultGroupContainer({
|
|
724
|
-
children
|
|
725
|
-
}) {
|
|
726
|
-
return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", { className: "grid grid-cols-1 gap-6", children });
|
|
855
|
+
var import_jsx_runtime18 = require("react/jsx-runtime");
|
|
856
|
+
function DefaultGroupContainer({ children }) {
|
|
857
|
+
return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "grid grid-cols-1 gap-6", children });
|
|
727
858
|
}
|
|
728
859
|
|
|
729
860
|
// src/theme/default/components/form/horizontal-divider.tsx
|
|
730
|
-
var
|
|
861
|
+
var import_jsx_runtime19 = require("react/jsx-runtime");
|
|
731
862
|
function DefaultHorizontalDivider() {
|
|
732
|
-
return /* @__PURE__ */ (0,
|
|
863
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("hr", { className: "border-dialog-border-default" });
|
|
733
864
|
}
|
|
734
865
|
|
|
735
866
|
// src/theme/default/components/form/image.tsx
|
|
736
|
-
var
|
|
867
|
+
var import_jsx_runtime20 = require("react/jsx-runtime");
|
|
737
868
|
function DefaultImage({ attributes }) {
|
|
738
|
-
return /* @__PURE__ */ (0,
|
|
869
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("figure", { children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("img", { ...attributes }) });
|
|
739
870
|
}
|
|
740
871
|
|
|
741
872
|
// src/theme/default/components/form/input.tsx
|
|
742
|
-
var
|
|
743
|
-
var
|
|
873
|
+
var import_client_fetch6 = require("@ory/client-fetch");
|
|
874
|
+
var import_elements_react8 = require("@ory/elements-react");
|
|
744
875
|
var import_react_hook_form3 = require("react-hook-form");
|
|
745
|
-
var
|
|
746
|
-
var
|
|
876
|
+
var import_react_intl8 = require("react-intl");
|
|
877
|
+
var import_jsx_runtime21 = require("react/jsx-runtime");
|
|
747
878
|
var DefaultInput = ({
|
|
748
879
|
node,
|
|
749
880
|
attributes,
|
|
750
881
|
onClick
|
|
751
882
|
}) => {
|
|
752
|
-
const label = (0,
|
|
883
|
+
const label = (0, import_client_fetch6.getNodeLabel)(node);
|
|
753
884
|
const { register } = (0, import_react_hook_form3.useFormContext)();
|
|
754
885
|
const { value, autocomplete, name, maxlength, ...rest } = attributes;
|
|
755
|
-
const intl = (0,
|
|
886
|
+
const intl = (0, import_react_intl8.useIntl)();
|
|
756
887
|
const formattedLabel = label ? intl.formatMessage(
|
|
757
888
|
{
|
|
758
889
|
id: "input.placeholder",
|
|
759
890
|
defaultMessage: "Enter your {placeholder}"
|
|
760
891
|
},
|
|
761
892
|
{
|
|
762
|
-
placeholder: (0,
|
|
893
|
+
placeholder: (0, import_elements_react8.uiTextToFormattedMessage)(label, intl)
|
|
763
894
|
}
|
|
764
895
|
) : "";
|
|
765
|
-
return /* @__PURE__ */ (0,
|
|
896
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
766
897
|
"input",
|
|
767
898
|
{
|
|
768
899
|
...rest,
|
|
@@ -770,43 +901,42 @@ var DefaultInput = ({
|
|
|
770
901
|
maxLength: maxlength,
|
|
771
902
|
autoComplete: autocomplete,
|
|
772
903
|
placeholder: formattedLabel,
|
|
773
|
-
className: "antialiased bg-forms-bg-default rounded-border-radius-forms border px-3 py-2.5 md:px-4 md:py-4 border-forms-border-default leading-tight hover:border-forms-border-hover transition-colors text-sm",
|
|
904
|
+
className: "antialiased disabled:text-forms-fg-disabled disabled:bg-forms-bg-disabled bg-forms-bg-default rounded-border-radius-forms border px-3 py-2.5 md:px-4 md:py-4 border-forms-border-default leading-tight hover:border-forms-border-hover transition-colors text-sm",
|
|
774
905
|
...register(name, { value })
|
|
775
906
|
}
|
|
776
907
|
);
|
|
777
908
|
};
|
|
778
909
|
|
|
779
910
|
// src/theme/default/components/form/label.tsx
|
|
780
|
-
var
|
|
781
|
-
var import_react_intl8 = require("react-intl");
|
|
782
|
-
var import_elements_react8 = require("@ory/elements-react");
|
|
911
|
+
var import_client_fetch7 = require("@ory/client-fetch");
|
|
783
912
|
var import_elements_react9 = require("@ory/elements-react");
|
|
784
|
-
var
|
|
913
|
+
var import_react_intl9 = require("react-intl");
|
|
914
|
+
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
785
915
|
function DefaultLabel({
|
|
786
916
|
node,
|
|
787
917
|
children,
|
|
788
918
|
attributes,
|
|
789
919
|
...rest
|
|
790
920
|
}) {
|
|
791
|
-
const intl = (0,
|
|
792
|
-
const label = (0,
|
|
793
|
-
const { config, flowType } = (0,
|
|
921
|
+
const intl = (0, import_react_intl9.useIntl)();
|
|
922
|
+
const label = (0, import_client_fetch7.getNodeLabel)(node);
|
|
923
|
+
const { config, flowType } = (0, import_elements_react9.useOryFlow)();
|
|
794
924
|
const isPassword = attributes.type === "password";
|
|
795
925
|
const isCode = attributes.name === "code";
|
|
796
|
-
return /* @__PURE__ */ (0,
|
|
797
|
-
label && /* @__PURE__ */ (0,
|
|
798
|
-
/* @__PURE__ */ (0,
|
|
926
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("span", { className: "flex flex-col antialiased gap-1", children: [
|
|
927
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("span", { className: "inline-flex justify-between", children: [
|
|
928
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
799
929
|
"label",
|
|
800
930
|
{
|
|
801
931
|
...(0, import_elements_react9.messageTestId)(label),
|
|
802
932
|
className: "text-sm font-medium leading-normal",
|
|
803
933
|
htmlFor: attributes.name,
|
|
804
934
|
...rest,
|
|
805
|
-
children: (0, import_elements_react9.
|
|
935
|
+
children: (0, import_elements_react9.uiTextToFormattedMessage)(label, intl)
|
|
806
936
|
}
|
|
807
937
|
),
|
|
808
|
-
isPassword && config.project.recovery_enabled && flowType ===
|
|
809
|
-
/* @__PURE__ */ (0,
|
|
938
|
+
isPassword && config.project.recovery_enabled && flowType === import_client_fetch7.FlowType.Login && // TODO: make it possible to override with a custom component
|
|
939
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
810
940
|
"a",
|
|
811
941
|
{
|
|
812
942
|
href: config.project.recovery_ui_url,
|
|
@@ -817,17 +947,19 @@ function DefaultLabel({
|
|
|
817
947
|
})
|
|
818
948
|
}
|
|
819
949
|
),
|
|
820
|
-
isCode && /* @__PURE__ */ (0,
|
|
821
|
-
"
|
|
950
|
+
isCode && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
951
|
+
"button",
|
|
822
952
|
{
|
|
823
953
|
type: "submit",
|
|
824
|
-
|
|
825
|
-
|
|
954
|
+
name: "method",
|
|
955
|
+
value: "code",
|
|
956
|
+
className: "text-links-link-default hover:underline hover:text-link-hover transition-colors text-sm font-medium cursor-pointer",
|
|
957
|
+
children: intl.formatMessage({ id: "identities.messages.1070008" })
|
|
826
958
|
}
|
|
827
959
|
)
|
|
828
960
|
] }),
|
|
829
961
|
children,
|
|
830
|
-
node.messages.map((message) => /* @__PURE__ */ (0,
|
|
962
|
+
node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
831
963
|
"span",
|
|
832
964
|
{
|
|
833
965
|
className: cn("text-sm leading-normal", {
|
|
@@ -836,7 +968,7 @@ function DefaultLabel({
|
|
|
836
968
|
"text-forms-fg-success": message.type === "success"
|
|
837
969
|
}),
|
|
838
970
|
...(0, import_elements_react9.messageTestId)(message),
|
|
839
|
-
children: (0, import_elements_react9.
|
|
971
|
+
children: (0, import_elements_react9.uiTextToFormattedMessage)(message, intl)
|
|
840
972
|
},
|
|
841
973
|
message.id
|
|
842
974
|
))
|
|
@@ -844,24 +976,24 @@ function DefaultLabel({
|
|
|
844
976
|
}
|
|
845
977
|
|
|
846
978
|
// src/theme/default/components/form/link-button.tsx
|
|
847
|
-
var
|
|
848
|
-
var import_react_intl9 = require("react-intl");
|
|
979
|
+
var import_client_fetch8 = require("@ory/client-fetch");
|
|
849
980
|
var import_elements_react10 = require("@ory/elements-react");
|
|
850
|
-
var
|
|
851
|
-
var
|
|
981
|
+
var import_react2 = require("react");
|
|
982
|
+
var import_react_intl10 = require("react-intl");
|
|
983
|
+
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
852
984
|
var DefaultLinkButton = (0, import_react2.forwardRef)(({ attributes, node }, ref) => {
|
|
853
|
-
const intl = (0,
|
|
854
|
-
const label = (0,
|
|
855
|
-
return /* @__PURE__ */ (0,
|
|
985
|
+
const intl = (0, import_react_intl10.useIntl)();
|
|
986
|
+
const label = (0, import_client_fetch8.getNodeLabel)(node);
|
|
987
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
856
988
|
"a",
|
|
857
989
|
{
|
|
858
990
|
...attributes,
|
|
859
991
|
ref,
|
|
860
|
-
title: (0, import_elements_react10.
|
|
992
|
+
title: label ? (0, import_elements_react10.uiTextToFormattedMessage)(label, intl) : "",
|
|
861
993
|
className: cn(
|
|
862
994
|
"antialiased rounded cursor-pointer text-center border border-transparent gap-3 leading-none bg-button-primary-bg-default hover:bg-button-primary-bg-hover transition-colors text-button-primary-fg-default hover:text-button-primary-fg-hover px-4 py-4.5 text-sm font-medium"
|
|
863
995
|
),
|
|
864
|
-
children: (0, import_elements_react10.
|
|
996
|
+
children: label ? (0, import_elements_react10.uiTextToFormattedMessage)(label, intl) : ""
|
|
865
997
|
}
|
|
866
998
|
);
|
|
867
999
|
});
|
|
@@ -873,8 +1005,8 @@ var import_react_hook_form4 = require("react-hook-form");
|
|
|
873
1005
|
// src/theme/default/components/form/shadcn/otp-input.tsx
|
|
874
1006
|
var import_input_otp = require("input-otp");
|
|
875
1007
|
var React7 = __toESM(require("react"));
|
|
876
|
-
var
|
|
877
|
-
var InputOTP = React7.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ (0,
|
|
1008
|
+
var import_jsx_runtime24 = require("react/jsx-runtime");
|
|
1009
|
+
var InputOTP = React7.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
878
1010
|
import_input_otp.OTPInput,
|
|
879
1011
|
{
|
|
880
1012
|
ref,
|
|
@@ -887,12 +1019,12 @@ var InputOTP = React7.forwardRef(({ className, containerClassName, ...props }, r
|
|
|
887
1019
|
}
|
|
888
1020
|
));
|
|
889
1021
|
InputOTP.displayName = "InputOTP";
|
|
890
|
-
var InputOTPGroup = React7.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
1022
|
+
var InputOTPGroup = React7.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { ref, className: cn("flex items-center", className), ...props }));
|
|
891
1023
|
InputOTPGroup.displayName = "InputOTPGroup";
|
|
892
1024
|
var InputOTPSlot = React7.forwardRef(({ index, className, ...props }, ref) => {
|
|
893
1025
|
const inputOTPContext = React7.useContext(import_input_otp.OTPInputContext);
|
|
894
1026
|
const { char, hasFakeCaret, isActive } = inputOTPContext.slots[index];
|
|
895
|
-
return /* @__PURE__ */ (0,
|
|
1027
|
+
return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
|
|
896
1028
|
"div",
|
|
897
1029
|
{
|
|
898
1030
|
ref,
|
|
@@ -904,7 +1036,7 @@ var InputOTPSlot = React7.forwardRef(({ index, className, ...props }, ref) => {
|
|
|
904
1036
|
...props,
|
|
905
1037
|
children: [
|
|
906
1038
|
char,
|
|
907
|
-
hasFakeCaret && /* @__PURE__ */ (0,
|
|
1039
|
+
hasFakeCaret && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "h-4 w-px animate-caret-blink bg-branding-bg-default duration-750" }) })
|
|
908
1040
|
]
|
|
909
1041
|
}
|
|
910
1042
|
);
|
|
@@ -912,7 +1044,7 @@ var InputOTPSlot = React7.forwardRef(({ index, className, ...props }, ref) => {
|
|
|
912
1044
|
InputOTPSlot.displayName = "InputOTPSlot";
|
|
913
1045
|
|
|
914
1046
|
// src/theme/default/components/form/pin-code-input.tsx
|
|
915
|
-
var
|
|
1047
|
+
var import_jsx_runtime25 = require("react/jsx-runtime");
|
|
916
1048
|
var DefaultPinCodeInput = ({ attributes }) => {
|
|
917
1049
|
const { setValue, watch } = (0, import_react_hook_form4.useFormContext)();
|
|
918
1050
|
const { maxlength, name } = attributes;
|
|
@@ -921,27 +1053,21 @@ var DefaultPinCodeInput = ({ attributes }) => {
|
|
|
921
1053
|
setValue(name, v);
|
|
922
1054
|
};
|
|
923
1055
|
const value = watch(name);
|
|
924
|
-
return /* @__PURE__ */ (0,
|
|
925
|
-
|
|
1056
|
+
return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
1057
|
+
InputOTP,
|
|
926
1058
|
{
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
1059
|
+
maxLength: maxlength != null ? maxlength : 6,
|
|
1060
|
+
onChange: handleInputChange,
|
|
1061
|
+
name,
|
|
1062
|
+
value,
|
|
1063
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(InputOTPGroup, { className: "w-full space-x-2 justify-between", children: [...Array(elements)].map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
1064
|
+
InputOTPSlot,
|
|
930
1065
|
{
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
InputOTPSlot,
|
|
937
|
-
{
|
|
938
|
-
index,
|
|
939
|
-
className: "text-center px-1.5 py-2.5 h-10 w-11 md:w-14 md:h-12 border border-radius border-solid rounded-border-radius-forms border-forms-border-default bg-forms-bg-default"
|
|
940
|
-
},
|
|
941
|
-
index
|
|
942
|
-
)) })
|
|
943
|
-
}
|
|
944
|
-
)
|
|
1066
|
+
index,
|
|
1067
|
+
className: "text-center px-1.5 py-2.5 h-10 w-11 md:w-14 md:h-12 border border-radius border-solid rounded-border-radius-forms border-forms-border-default bg-forms-bg-default"
|
|
1068
|
+
},
|
|
1069
|
+
index
|
|
1070
|
+
)) })
|
|
945
1071
|
}
|
|
946
1072
|
);
|
|
947
1073
|
};
|
|
@@ -951,162 +1077,162 @@ var import_elements_react11 = require("@ory/elements-react");
|
|
|
951
1077
|
|
|
952
1078
|
// src/theme/default/provider-logos/apple.svg
|
|
953
1079
|
var React8 = __toESM(require("react"));
|
|
954
|
-
var
|
|
1080
|
+
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
955
1081
|
var SvgApple = (props) => {
|
|
956
1082
|
var _a, _b;
|
|
957
|
-
return /* @__PURE__ */ (0,
|
|
958
|
-
/* @__PURE__ */ (0,
|
|
959
|
-
/* @__PURE__ */ (0,
|
|
1083
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("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: [
|
|
1084
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", { fill: "#283544", d: "M30 16c0 7.728-6.265 14-14 14S2 23.728 2 16C2 8.265 8.265 2 16 2s14 6.265 14 14" }),
|
|
1085
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", { fill: "#fff", d: "M22.562 12.457c-.076.045-1.895.986-1.895 3.07.086 2.38 2.295 3.213 2.333 3.213-.038.045-.334 1.136-1.21 2.28-.694.986-1.466 1.98-2.637 1.98-1.114 0-1.514-.657-2.8-.657-1.381 0-1.772.657-2.829.657-1.171 0-2-1.047-2.733-2.023-.952-1.278-1.761-3.284-1.79-5.21-.02-1.02.19-2.023.724-2.875.752-1.19 2.095-1.997 3.561-2.023 1.124-.036 2.124.719 2.81.719.657 0 1.885-.72 3.275-.72.6.001 2.2.17 3.191 1.59m-6.561-1.792c-.2-.932.352-1.864.866-2.458.657-.72 1.695-1.207 2.59-1.207a3.33 3.33 0 0 1-.952 2.511c-.58.72-1.58 1.26-2.504 1.154" })
|
|
960
1086
|
] });
|
|
961
1087
|
};
|
|
962
1088
|
var apple_default = SvgApple;
|
|
963
1089
|
|
|
964
1090
|
// src/theme/default/provider-logos/auth0.svg
|
|
965
1091
|
var React9 = __toESM(require("react"));
|
|
966
|
-
var
|
|
1092
|
+
var import_jsx_runtime27 = require("react/jsx-runtime");
|
|
967
1093
|
var SvgAuth0 = (props) => {
|
|
968
1094
|
var _a, _b;
|
|
969
|
-
return /* @__PURE__ */ (0,
|
|
1095
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 64 64", 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_runtime27.jsx)("path", { fill: "#eb5424", d: "M49.012 51.774 42.514 32l17.008-12.22h-21.02L32.005 0h21.032l6.506 19.78c3.767 11.468-.118 24.52-10.53 31.993zm-34.023 0L31.998 64l17.015-12.226-17.008-12.22zm-10.516-32c-3.976 12.1.64 24.917 10.5 32.007v-.007L21.482 32 4.474 19.774l21.025.007L31.998 0H10.972z" }) });
|
|
970
1096
|
};
|
|
971
1097
|
var auth0_default = SvgAuth0;
|
|
972
1098
|
|
|
973
1099
|
// src/theme/default/provider-logos/discord.svg
|
|
974
1100
|
var React10 = __toESM(require("react"));
|
|
975
|
-
var
|
|
1101
|
+
var import_jsx_runtime28 = require("react/jsx-runtime");
|
|
976
1102
|
var SvgDiscord = (props) => {
|
|
977
1103
|
var _a, _b;
|
|
978
|
-
return /* @__PURE__ */ (0,
|
|
979
|
-
/* @__PURE__ */ (0,
|
|
980
|
-
/* @__PURE__ */ (0,
|
|
1104
|
+
return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("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: [
|
|
1105
|
+
/* @__PURE__ */ (0, import_jsx_runtime28.jsx)("path", { d: "M2 11.6c0-3.36 0-5.04.654-6.324a6 6 0 0 1 2.622-2.622C6.56 2 8.24 2 11.6 2h8.8c3.36 0 5.04 0 6.324.654a6 6 0 0 1 2.622 2.622C30 6.56 30 8.24 30 11.6v8.8c0 3.36 0 5.04-.654 6.324a6 6 0 0 1-2.622 2.622C25.44 30 23.76 30 20.4 30h-8.8c-3.36 0-5.04 0-6.324-.654a6 6 0 0 1-2.622-2.622C2 25.44 2 23.76 2 20.4z" }),
|
|
1106
|
+
/* @__PURE__ */ (0, import_jsx_runtime28.jsx)("path", { fill: "#5865F2", d: "M23.636 9.34A18.8 18.8 0 0 0 19.097 8c-.195.332-.424.779-.581 1.134a17.7 17.7 0 0 0-5.03 0A12 12 0 0 0 12.897 8a18.7 18.7 0 0 0-4.542 1.343c-2.872 4.078-3.65 8.055-3.262 11.975a18.6 18.6 0 0 0 5.567 2.68c.448-.58.848-1.195 1.192-1.844a12 12 0 0 1-1.877-.859 9 9 0 0 0 .46-.342c3.62 1.59 7.553 1.59 11.13 0q.225.178.46.342c-.595.337-1.225.626-1.88.86q.516.974 1.191 1.845a18.6 18.6 0 0 0 5.57-2.682c.457-4.544-.78-8.484-3.27-11.978m-11.29 9.567c-1.087 0-1.978-.953-1.978-2.113s.872-2.116 1.977-2.116c1.106 0 1.997.953 1.978 2.116.002 1.16-.872 2.113-1.978 2.113m7.308 0c-1.086 0-1.977-.953-1.977-2.113s.872-2.116 1.977-2.116c1.106 0 1.997.953 1.978 2.116 0 1.16-.872 2.113-1.978 2.113" })
|
|
981
1107
|
] });
|
|
982
1108
|
};
|
|
983
1109
|
var discord_default = SvgDiscord;
|
|
984
1110
|
|
|
985
1111
|
// src/theme/default/provider-logos/facebook.svg
|
|
986
1112
|
var React11 = __toESM(require("react"));
|
|
987
|
-
var
|
|
1113
|
+
var import_jsx_runtime29 = require("react/jsx-runtime");
|
|
988
1114
|
var SvgFacebook = (props) => {
|
|
989
1115
|
var _a, _b;
|
|
990
|
-
return /* @__PURE__ */ (0,
|
|
991
|
-
/* @__PURE__ */ (0,
|
|
992
|
-
/* @__PURE__ */ (0,
|
|
993
|
-
/* @__PURE__ */ (0,
|
|
1116
|
+
return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("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: [
|
|
1117
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("g", { clipPath: "url(#facebook_svg__a)", children: [
|
|
1118
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("path", { fill: "#1877F2", d: "M24 12c0-6.627-5.373-12-12-12C5.372 0 0 5.374 0 12c0 5.99 4.388 10.954 10.125 11.854V15.47H7.078V12h3.047V9.357c0-3.008 1.791-4.669 4.532-4.669 1.313 0 2.686.234 2.686.234v2.953H15.83c-1.49 0-1.955.925-1.955 1.874V12h3.328l-.532 3.469h-2.796v8.385c5.736-.9 10.124-5.864 10.124-11.854" }),
|
|
1119
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("path", { fill: "#fff", d: "M16.67 15.469 17.204 12h-3.328V9.75c0-.95.465-1.875 1.955-1.875h1.513V4.922s-1.373-.234-2.686-.234c-2.74 0-4.532 1.661-4.532 4.669V12H7.078v3.469h3.047v8.385a12.1 12.1 0 0 0 3.75 0V15.47z" })
|
|
994
1120
|
] }),
|
|
995
|
-
/* @__PURE__ */ (0,
|
|
1121
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("clipPath", { id: "facebook_svg__a", children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("rect", { fill: "#fff" }) }) })
|
|
996
1122
|
] });
|
|
997
1123
|
};
|
|
998
1124
|
var facebook_default = SvgFacebook;
|
|
999
1125
|
|
|
1000
1126
|
// src/theme/default/provider-logos/generic.svg
|
|
1001
1127
|
var React12 = __toESM(require("react"));
|
|
1002
|
-
var
|
|
1128
|
+
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
1003
1129
|
var SvgGeneric = (props) => {
|
|
1004
1130
|
var _a, _b;
|
|
1005
|
-
return /* @__PURE__ */ (0,
|
|
1006
|
-
/* @__PURE__ */ (0,
|
|
1007
|
-
/* @__PURE__ */ (0,
|
|
1008
|
-
/* @__PURE__ */ (0,
|
|
1131
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, className: "generic_svg__icon generic_svg__icon-tabler generic_svg__icon-tabler-brand-oauth", 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: [
|
|
1132
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)("path", { stroke: "none", d: "M0 0h24v24H0z" }),
|
|
1133
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)("path", { d: "M2 12a10 10 0 1 0 20 0 10 10 0 1 0-20 0" }),
|
|
1134
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)("path", { d: "M12.556 6c.65 0 1.235.373 1.508.947l2.839 7.848a1.646 1.646 0 0 1-1.01 2.108 1.673 1.673 0 0 1-2.068-.851L13.365 15h-2.73l-.398.905A1.67 1.67 0 0 1 8.26 16.95l-.153-.047a1.647 1.647 0 0 1-1.056-1.956l2.824-7.852a1.66 1.66 0 0 1 1.409-1.087z" })
|
|
1009
1135
|
] });
|
|
1010
1136
|
};
|
|
1011
1137
|
var generic_default = SvgGeneric;
|
|
1012
1138
|
|
|
1013
1139
|
// src/theme/default/provider-logos/github.svg
|
|
1014
1140
|
var React13 = __toESM(require("react"));
|
|
1015
|
-
var
|
|
1141
|
+
var import_jsx_runtime31 = require("react/jsx-runtime");
|
|
1016
1142
|
var SvgGithub = (props) => {
|
|
1017
1143
|
var _a, _b;
|
|
1018
|
-
return /* @__PURE__ */ (0,
|
|
1144
|
+
return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", 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_runtime31.jsx)("path", { d: "M12 0C5.374 0 0 5.373 0 12c0 5.302 3.438 9.8 8.207 11.387.599.111.793-.261.793-.577v-2.234c-3.338.726-4.033-1.416-4.033-1.416-.546-1.387-1.333-1.756-1.333-1.756-1.089-.745.083-.729.083-.729 1.205.084 1.839 1.237 1.839 1.237 1.07 1.834 2.807 1.304 3.492.997.107-.775.418-1.305.762-1.604-2.665-.305-5.467-1.334-5.467-5.931 0-1.311.469-2.381 1.236-3.221-.124-.303-.535-1.524.117-3.176 0 0 1.008-.322 3.301 1.23A11.5 11.5 0 0 1 12 5.803c1.02.005 2.047.138 3.006.404 2.291-1.552 3.297-1.23 3.297-1.23.653 1.653.242 2.874.118 3.176.77.84 1.235 1.911 1.235 3.221 0 4.609-2.807 5.624-5.479 5.921.43.372.823 1.102.823 2.222v3.293c0 .319.192.694.801.576C20.566 21.797 24 17.3 24 12c0-6.627-5.373-12-12-12" }) });
|
|
1019
1145
|
};
|
|
1020
1146
|
var github_default = SvgGithub;
|
|
1021
1147
|
|
|
1022
1148
|
// src/theme/default/provider-logos/gitlab.svg
|
|
1023
1149
|
var React14 = __toESM(require("react"));
|
|
1024
|
-
var
|
|
1150
|
+
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
1025
1151
|
var SvgGitlab = (props) => {
|
|
1026
1152
|
var _a, _b;
|
|
1027
|
-
return /* @__PURE__ */ (0,
|
|
1028
|
-
/* @__PURE__ */ (0,
|
|
1029
|
-
/* @__PURE__ */ (0,
|
|
1030
|
-
/* @__PURE__ */ (0,
|
|
1031
|
-
/* @__PURE__ */ (0,
|
|
1153
|
+
return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)("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: [
|
|
1154
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)("path", { fill: "#E24329", d: "m22.708 10.691-.031-.072-3.015-7.167a.74.74 0 0 0-.31-.34.87.87 0 0 0-.923.045.73.73 0 0 0-.268.37L16.125 9.2H7.881L5.845 3.527a.72.72 0 0 0-.268-.371.87.87 0 0 0-.923-.045.74.74 0 0 0-.31.34l-3.021 7.164-.03.072a4.67 4.67 0 0 0-.153 3.23c.335 1.063 1.04 1.998 2.01 2.664l.01.007.028.018 4.594 3.132 2.272 1.567 1.384.952c.162.112.36.172.563.172s.401-.06.563-.172l1.384-.952 2.273-1.567 4.62-3.151.012-.009c.968-.666 1.671-1.6 2.006-2.661a4.67 4.67 0 0 0-.15-3.226" }),
|
|
1155
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)("path", { fill: "#FC6D26", d: "m22.708 10.691-.031-.072a10.7 10.7 0 0 0-4.055 1.66L12 16.839l4.218 2.904 4.621-3.152.012-.008c.969-.666 1.674-1.601 2.008-2.664a4.67 4.67 0 0 0-.15-3.228" }),
|
|
1156
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)("path", { fill: "#FCA326", d: "m7.781 19.743 2.273 1.566 1.384.952c.162.112.36.172.563.172s.401-.06.563-.172l1.384-.952 2.273-1.566S14.255 18.389 12 16.839c-2.255 1.55-4.219 2.904-4.219 2.904" }),
|
|
1157
|
+
/* @__PURE__ */ (0, import_jsx_runtime32.jsx)("path", { fill: "#FC6D26", d: "M5.376 12.279a10.7 10.7 0 0 0-4.053-1.664l-.03.072a4.67 4.67 0 0 0-.153 3.23c.335 1.063 1.04 1.998 2.01 2.664l.01.007.028.018 4.594 3.132L12 16.836z" })
|
|
1032
1158
|
] });
|
|
1033
1159
|
};
|
|
1034
1160
|
var gitlab_default = SvgGitlab;
|
|
1035
1161
|
|
|
1036
1162
|
// src/theme/default/provider-logos/google.svg
|
|
1037
1163
|
var React15 = __toESM(require("react"));
|
|
1038
|
-
var
|
|
1164
|
+
var import_jsx_runtime33 = require("react/jsx-runtime");
|
|
1039
1165
|
var SvgGoogle = (props) => {
|
|
1040
1166
|
var _a, _b;
|
|
1041
|
-
return /* @__PURE__ */ (0,
|
|
1042
|
-
/* @__PURE__ */ (0,
|
|
1043
|
-
/* @__PURE__ */ (0,
|
|
1044
|
-
/* @__PURE__ */ (0,
|
|
1045
|
-
/* @__PURE__ */ (0,
|
|
1167
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("svg", { xmlns: "http://www.w3.org/2000/svg", 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: [
|
|
1168
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)("path", { fill: "#4285F4", d: "M23.745 12.27c0-.79-.07-1.54-.19-2.27h-11.3v4.51h6.47c-.29 1.48-1.14 2.73-2.4 3.58v3h3.86c2.26-2.09 3.56-5.17 3.56-8.82" }),
|
|
1169
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)("path", { fill: "#34A853", d: "M12.255 24c3.24 0 5.95-1.08 7.93-2.91l-3.86-3c-1.08.72-2.45 1.16-4.07 1.16-3.13 0-5.78-2.11-6.73-4.96h-3.98v3.09C3.515 21.3 7.565 24 12.255 24" }),
|
|
1170
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)("path", { fill: "#FBBC05", d: "M5.525 14.29c-.25-.72-.38-1.49-.38-2.29s.14-1.57.38-2.29V6.62h-3.98a11.86 11.86 0 0 0 0 10.76z" }),
|
|
1171
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)("path", { fill: "#EA4335", d: "M12.255 4.75c1.77 0 3.35.61 4.6 1.8l3.42-3.42C18.205 1.19 15.495 0 12.255 0c-4.69 0-8.74 2.7-10.71 6.62l3.98 3.09c.95-2.85 3.6-4.96 6.73-4.96" })
|
|
1046
1172
|
] });
|
|
1047
1173
|
};
|
|
1048
1174
|
var google_default = SvgGoogle;
|
|
1049
1175
|
|
|
1050
1176
|
// src/theme/default/provider-logos/linkedin.svg
|
|
1051
1177
|
var React16 = __toESM(require("react"));
|
|
1052
|
-
var
|
|
1178
|
+
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
1053
1179
|
var SvgLinkedin = (props) => {
|
|
1054
1180
|
var _a, _b;
|
|
1055
|
-
return /* @__PURE__ */ (0,
|
|
1056
|
-
/* @__PURE__ */ (0,
|
|
1057
|
-
/* @__PURE__ */ (0,
|
|
1181
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("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: [
|
|
1182
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("rect", { x: 2, y: 2, fill: "#1275B1", rx: 14 }),
|
|
1183
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("path", { fill: "#fff", d: "M12.619 9.692c0 .935-.81 1.692-1.81 1.692C9.81 11.384 9 10.627 9 9.692S9.81 8 10.81 8c.999 0 1.809.758 1.809 1.692M9.247 12.628h3.093V22H9.247zM17.32 12.628h-3.093V22h3.093v-4.795c0-1.107.378-2.22 1.886-2.22 1.705 0 1.695 1.45 1.687 2.572-.01 1.467.014 2.965.014 4.443H24v-4.946c-.026-3.159-.85-4.614-3.557-4.614-1.608 0-2.604.73-3.123 1.39z" })
|
|
1058
1184
|
] });
|
|
1059
1185
|
};
|
|
1060
1186
|
var linkedin_default = SvgLinkedin;
|
|
1061
1187
|
|
|
1062
1188
|
// src/theme/default/provider-logos/microsoft.svg
|
|
1063
1189
|
var React17 = __toESM(require("react"));
|
|
1064
|
-
var
|
|
1190
|
+
var import_jsx_runtime35 = require("react/jsx-runtime");
|
|
1065
1191
|
var SvgMicrosoft = (props) => {
|
|
1066
1192
|
var _a, _b;
|
|
1067
|
-
return /* @__PURE__ */ (0,
|
|
1068
|
-
/* @__PURE__ */ (0,
|
|
1069
|
-
/* @__PURE__ */ (0,
|
|
1070
|
-
/* @__PURE__ */ (0,
|
|
1071
|
-
/* @__PURE__ */ (0,
|
|
1193
|
+
return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 23 23", 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: [
|
|
1194
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("path", { fill: "#F35325", d: "M1 1h10v10H1z" }),
|
|
1195
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("path", { fill: "#81BC06", d: "M12 1h10v10H12z" }),
|
|
1196
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("path", { fill: "#05A6F0", d: "M1 12h10v10H1z" }),
|
|
1197
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("path", { fill: "#FFBA08", d: "M12 12h10v10H12z" })
|
|
1072
1198
|
] });
|
|
1073
1199
|
};
|
|
1074
1200
|
var microsoft_default = SvgMicrosoft;
|
|
1075
1201
|
|
|
1076
1202
|
// src/theme/default/provider-logos/slack.svg
|
|
1077
1203
|
var React18 = __toESM(require("react"));
|
|
1078
|
-
var
|
|
1204
|
+
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
1079
1205
|
var SvgSlack = (props) => {
|
|
1080
1206
|
var _a, _b;
|
|
1081
|
-
return /* @__PURE__ */ (0,
|
|
1082
|
-
/* @__PURE__ */ (0,
|
|
1083
|
-
/* @__PURE__ */ (0,
|
|
1084
|
-
/* @__PURE__ */ (0,
|
|
1085
|
-
/* @__PURE__ */ (0,
|
|
1207
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("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: [
|
|
1208
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)("path", { fill: "#2EB67D", d: "M26.5 15a2.5 2.5 0 1 0-2.5-2.5V15zm-7 0a2.5 2.5 0 0 0 2.5-2.5v-7a2.5 2.5 0 0 0-5 0v7a2.5 2.5 0 0 0 2.5 2.5" }),
|
|
1209
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)("path", { fill: "#E01E5A", d: "M5.5 17A2.5 2.5 0 1 0 8 19.5V17zm7 0a2.5 2.5 0 0 0-2.5 2.5v7a2.5 2.5 0 0 0 5 0v-7a2.5 2.5 0 0 0-2.5-2.5" }),
|
|
1210
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)("path", { fill: "#ECB22E", d: "M17 26.5a2.5 2.5 0 1 0 2.5-2.5H17zm0-7a2.5 2.5 0 0 0 2.5 2.5h7a2.5 2.5 0 0 0 0-5h-7a2.5 2.5 0 0 0-2.5 2.5" }),
|
|
1211
|
+
/* @__PURE__ */ (0, import_jsx_runtime36.jsx)("path", { fill: "#36C5F0", d: "M15 5.5A2.5 2.5 0 1 0 12.5 8H15zm0 7a2.5 2.5 0 0 0-2.5-2.5h-7a2.5 2.5 0 0 0 0 5h7a2.5 2.5 0 0 0 2.5-2.5" })
|
|
1086
1212
|
] });
|
|
1087
1213
|
};
|
|
1088
1214
|
var slack_default = SvgSlack;
|
|
1089
1215
|
|
|
1090
1216
|
// src/theme/default/provider-logos/spotify.svg
|
|
1091
1217
|
var React19 = __toESM(require("react"));
|
|
1092
|
-
var
|
|
1218
|
+
var import_jsx_runtime37 = require("react/jsx-runtime");
|
|
1093
1219
|
var SvgSpotify = (props) => {
|
|
1094
1220
|
var _a, _b;
|
|
1095
|
-
return /* @__PURE__ */ (0,
|
|
1096
|
-
/* @__PURE__ */ (0,
|
|
1097
|
-
/* @__PURE__ */ (0,
|
|
1221
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("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: [
|
|
1222
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)("circle", { cx: 16, cy: 16, r: 14, fill: "#1ED760" }),
|
|
1223
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)("path", { fill: "#fff", d: "M22.364 21.623c-.239.38-.75.486-1.148.258-3.141-1.822-7.08-2.232-11.736-1.23-.446.091-.893-.167-.988-.592a.786.786 0 0 1 .621-.94c5.087-1.11 9.456-.639 12.964 1.41a.77.77 0 0 1 .287 1.094m1.627-3.461c-.303.47-.941.607-1.435.334-3.588-2.11-9.058-2.718-13.299-1.488-.558.152-1.132-.137-1.292-.653-.16-.531.144-1.078.702-1.23 4.848-1.396 10.875-.728 15.005 1.686.462.273.622.88.319 1.35m.143-3.613c-4.305-2.43-11.4-2.657-15.515-1.473-.654.197-1.355-.152-1.563-.79-.207-.622.176-1.29.83-1.487 4.72-1.366 12.565-1.093 17.508 1.7.59.334.781 1.063.43 1.625-.334.576-1.1.774-1.69.425" })
|
|
1098
1224
|
] });
|
|
1099
1225
|
};
|
|
1100
1226
|
var spotify_default = SvgSpotify;
|
|
1101
1227
|
|
|
1102
1228
|
// src/theme/default/provider-logos/yandex.svg
|
|
1103
1229
|
var React20 = __toESM(require("react"));
|
|
1104
|
-
var
|
|
1230
|
+
var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
1105
1231
|
var SvgYandex = (props) => {
|
|
1106
1232
|
var _a, _b;
|
|
1107
|
-
return /* @__PURE__ */ (0,
|
|
1108
|
-
/* @__PURE__ */ (0,
|
|
1109
|
-
/* @__PURE__ */ (0,
|
|
1233
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("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: [
|
|
1234
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)("circle", { cx: 16, cy: 16, r: 14, fill: "#fff" }),
|
|
1235
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)("path", { fill: "#FC3F1D", d: "M21 25h-3.143V9.435h-1.402c-2.572 0-3.922 1.294-3.922 3.211 0 2.175.935 3.185 2.857 4.48l1.584 1.063L12.403 25H9l4.104-6.086c-2.363-1.684-3.688-3.316-3.688-6.087C9.416 9.357 11.83 7 16.429 7H21z" })
|
|
1110
1236
|
] });
|
|
1111
1237
|
};
|
|
1112
1238
|
var yandex_default = SvgYandex;
|
|
@@ -1130,8 +1256,8 @@ var logos = {
|
|
|
1130
1256
|
var provider_logos_default = logos;
|
|
1131
1257
|
|
|
1132
1258
|
// src/theme/default/components/form/social.tsx
|
|
1133
|
-
var
|
|
1134
|
-
var
|
|
1259
|
+
var import_react_intl11 = require("react-intl");
|
|
1260
|
+
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
1135
1261
|
function extractProvider(context) {
|
|
1136
1262
|
if (context && typeof context === "object" && "provider" in context && typeof context.provider === "string") {
|
|
1137
1263
|
return context.provider;
|
|
@@ -1141,7 +1267,8 @@ function extractProvider(context) {
|
|
|
1141
1267
|
function DefaultButtonSocial({
|
|
1142
1268
|
attributes,
|
|
1143
1269
|
node,
|
|
1144
|
-
onClick
|
|
1270
|
+
onClick,
|
|
1271
|
+
showLabel: _showLabel
|
|
1145
1272
|
}) {
|
|
1146
1273
|
var _a, _b, _c;
|
|
1147
1274
|
const {
|
|
@@ -1153,12 +1280,12 @@ function DefaultButtonSocial({
|
|
|
1153
1280
|
const {
|
|
1154
1281
|
flow: { ui }
|
|
1155
1282
|
} = (0, import_elements_react11.useOryFlow)();
|
|
1156
|
-
const intl = (0,
|
|
1283
|
+
const intl = (0, import_react_intl11.useIntl)();
|
|
1157
1284
|
const oidcNodeCount = (_a = ui.nodes.filter((node2) => node2.group === "oidc").length) != null ? _a : 0;
|
|
1158
1285
|
const Logo = provider_logos_default[attributes.value];
|
|
1159
|
-
const showLabel = oidcNodeCount % 3 !== 0 && oidcNodeCount % 4 !== 0;
|
|
1286
|
+
const showLabel = _showLabel != null ? _showLabel : oidcNodeCount % 3 !== 0 && oidcNodeCount % 4 !== 0;
|
|
1160
1287
|
const provider = (_c = extractProvider((_b = node.meta.label) == null ? void 0 : _b.context)) != null ? _c : "";
|
|
1161
|
-
return /* @__PURE__ */ (0,
|
|
1288
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
|
|
1162
1289
|
"button",
|
|
1163
1290
|
{
|
|
1164
1291
|
className: cn(
|
|
@@ -1171,14 +1298,14 @@ function DefaultButtonSocial({
|
|
|
1171
1298
|
...props,
|
|
1172
1299
|
onClick,
|
|
1173
1300
|
children: [
|
|
1174
|
-
/* @__PURE__ */ (0,
|
|
1301
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "w-5 h-5", children: Logo ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
1175
1302
|
Logo,
|
|
1176
1303
|
{
|
|
1177
1304
|
size: 20,
|
|
1178
1305
|
className: "object-fill w-full h-full"
|
|
1179
1306
|
}
|
|
1180
|
-
) : /* @__PURE__ */ (0,
|
|
1181
|
-
showLabel ? /* @__PURE__ */ (0,
|
|
1307
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "rounded-full aspect-square border flex items-center justify-center text-xs", children: provider.slice(0, 2) }) }),
|
|
1308
|
+
showLabel && node.meta.label ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "text-sm text-left leading-none font-medium text-forms-fg-default flex-grow", children: (0, import_elements_react11.uiTextToFormattedMessage)(node.meta.label, intl) }) : null
|
|
1182
1309
|
]
|
|
1183
1310
|
}
|
|
1184
1311
|
);
|
|
@@ -1187,7 +1314,7 @@ function DefaultSocialButtonContainer({
|
|
|
1187
1314
|
children,
|
|
1188
1315
|
nodes
|
|
1189
1316
|
}) {
|
|
1190
|
-
return /* @__PURE__ */ (0,
|
|
1317
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
1191
1318
|
"div",
|
|
1192
1319
|
{
|
|
1193
1320
|
className: cn("grid gap-3", {
|
|
@@ -1202,29 +1329,29 @@ function DefaultSocialButtonContainer({
|
|
|
1202
1329
|
}
|
|
1203
1330
|
|
|
1204
1331
|
// src/theme/default/components/form/text.tsx
|
|
1205
|
-
var import_react_intl11 = require("react-intl");
|
|
1206
1332
|
var import_elements_react12 = require("@ory/elements-react");
|
|
1207
|
-
var
|
|
1333
|
+
var import_react_intl12 = require("react-intl");
|
|
1334
|
+
var import_jsx_runtime40 = require("react/jsx-runtime");
|
|
1208
1335
|
function DefaultText({ node, attributes }) {
|
|
1209
1336
|
var _a;
|
|
1210
|
-
const intl = (0,
|
|
1211
|
-
return /* @__PURE__ */ (0,
|
|
1212
|
-
/* @__PURE__ */ (0,
|
|
1213
|
-
(_a = attributes.text.context.secrets) == null ? void 0 : _a.map((text, index) => /* @__PURE__ */ (0,
|
|
1337
|
+
const intl = (0, import_react_intl12.useIntl)();
|
|
1338
|
+
return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_jsx_runtime40.Fragment, { children: [
|
|
1339
|
+
/* @__PURE__ */ (0, import_jsx_runtime40.jsx)("p", { "data-testid": `node/text/${attributes.id}/label`, children: node.meta.label ? (0, import_elements_react12.uiTextToFormattedMessage)(node.meta.label, intl) : "" }),
|
|
1340
|
+
(_a = attributes.text.context.secrets) == null ? void 0 : _a.map((text, index) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("pre", { "data-testid": `node/text/lookup_secret_codes/text`, children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("code", { children: text ? (0, import_elements_react12.uiTextToFormattedMessage)(text, intl) : "" }) }, index))
|
|
1214
1341
|
] });
|
|
1215
1342
|
}
|
|
1216
1343
|
|
|
1217
1344
|
// src/theme/default/assets/icons/arrow-left.svg
|
|
1218
1345
|
var React21 = __toESM(require("react"));
|
|
1219
|
-
var
|
|
1346
|
+
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
1220
1347
|
var SvgArrowLeft = (props) => {
|
|
1221
1348
|
var _a, _b;
|
|
1222
|
-
return /* @__PURE__ */ (0,
|
|
1349
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.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_runtime41.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M5 12.325h14m-14 0 6 6m-6-6 6-6" }) });
|
|
1223
1350
|
};
|
|
1224
1351
|
var arrow_left_default = SvgArrowLeft;
|
|
1225
1352
|
|
|
1226
1353
|
// src/theme/default/components/card/current-identifier-button.tsx
|
|
1227
|
-
var
|
|
1354
|
+
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
1228
1355
|
function DefaultCurrentIdentifierButton({
|
|
1229
1356
|
attributes,
|
|
1230
1357
|
onClick,
|
|
@@ -1232,7 +1359,7 @@ function DefaultCurrentIdentifierButton({
|
|
|
1232
1359
|
href
|
|
1233
1360
|
}) {
|
|
1234
1361
|
const Element = onClick ? "button" : "a";
|
|
1235
|
-
return /* @__PURE__ */ (0,
|
|
1362
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
|
|
1236
1363
|
Element,
|
|
1237
1364
|
{
|
|
1238
1365
|
className: "cursor-pointer py-1.5 px-3 rounded-full border border-button-identifier-border-default bg-button-identifier-bg-default hover:border-button-identifier-border-hover hover:bg-button-identifier-bg-hover transition-colors inline-flex gap-1 items-center",
|
|
@@ -1241,176 +1368,788 @@ function DefaultCurrentIdentifierButton({
|
|
|
1241
1368
|
href,
|
|
1242
1369
|
type,
|
|
1243
1370
|
children: [
|
|
1244
|
-
/* @__PURE__ */ (0,
|
|
1245
|
-
/* @__PURE__ */ (0,
|
|
1371
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(arrow_left_default, { size: 16, className: "text-button-identifier-fg-subtle" }),
|
|
1372
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "text-sm font-medium leading-none text-button-identifier-fg-default", children: attributes.value })
|
|
1246
1373
|
]
|
|
1247
1374
|
}
|
|
1248
1375
|
) });
|
|
1249
1376
|
}
|
|
1250
1377
|
|
|
1378
|
+
// src/theme/default/components/form/section.tsx
|
|
1379
|
+
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
1380
|
+
var DefaultFormSection = ({ children }) => {
|
|
1381
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "flex flex-col w-80 md:w-[712px] lg:w-[802px] xl:w-[896px]", children });
|
|
1382
|
+
};
|
|
1383
|
+
var DefaultFormSectionContent = ({
|
|
1384
|
+
title,
|
|
1385
|
+
description,
|
|
1386
|
+
children
|
|
1387
|
+
}) => {
|
|
1388
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "border rounded-t-xl border-b-0 border-dialog-border-default bg-forms-bg-default px-6 py-8 flex flex-col gap-8", children: [
|
|
1389
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "flex flex-col gap-2", children: [
|
|
1390
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("h3", { className: "font-medium text-dialog-fg-default", children: title }),
|
|
1391
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "text-sm text-dialog-fg-subtle", children: description })
|
|
1392
|
+
] }),
|
|
1393
|
+
children
|
|
1394
|
+
] });
|
|
1395
|
+
};
|
|
1396
|
+
var DefaultFormSectionFooter = ({ children }) => {
|
|
1397
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "rounded-b-xl gap-2 flex justify-end px-6 py-4 bg-dialog-bg-subtle border border-dialog-border-default text-sm text-dialog-fg-mute items-center [&>span]:mr-auto min-h-[72px]", children });
|
|
1398
|
+
};
|
|
1399
|
+
|
|
1400
|
+
// src/theme/default/assets/icons/download.svg
|
|
1401
|
+
var React22 = __toESM(require("react"));
|
|
1402
|
+
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
1403
|
+
var SvgDownload = (props) => {
|
|
1404
|
+
var _a, _b;
|
|
1405
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.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_runtime44.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" }) });
|
|
1406
|
+
};
|
|
1407
|
+
var download_default = SvgDownload;
|
|
1408
|
+
|
|
1409
|
+
// src/theme/default/assets/icons/eye.svg
|
|
1410
|
+
var React23 = __toESM(require("react"));
|
|
1411
|
+
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
1412
|
+
var SvgEye = (props) => {
|
|
1413
|
+
var _a, _b;
|
|
1414
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.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_runtime45.jsxs)("g", { strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
1415
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("path", { stroke: "currentColor", d: "M10 12a2 2 0 1 0 4 0 2 2 0 0 0-4 0" }),
|
|
1416
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("path", { stroke: "#64748B", d: "M21 12q-3.6 6-9 6t-9-6q3.6-6 9-6t9 6" })
|
|
1417
|
+
] }) });
|
|
1418
|
+
};
|
|
1419
|
+
var eye_default = SvgEye;
|
|
1420
|
+
|
|
1421
|
+
// src/theme/default/assets/icons/refresh.svg
|
|
1422
|
+
var React24 = __toESM(require("react"));
|
|
1423
|
+
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
1424
|
+
var SvgRefresh = (props) => {
|
|
1425
|
+
var _a, _b;
|
|
1426
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.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_runtime46.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" }) });
|
|
1427
|
+
};
|
|
1428
|
+
var refresh_default = SvgRefresh;
|
|
1429
|
+
|
|
1430
|
+
// src/theme/default/components/settings/settings-recovery-codes.tsx
|
|
1431
|
+
var import_jsx_runtime47 = require("react/jsx-runtime");
|
|
1432
|
+
function DefaultSettingsRecoveryCodes({
|
|
1433
|
+
codes,
|
|
1434
|
+
regnerateButton,
|
|
1435
|
+
revealButton
|
|
1436
|
+
}) {
|
|
1437
|
+
const onDownload = () => {
|
|
1438
|
+
const element = document.createElement("a");
|
|
1439
|
+
const file = new Blob([codes.join("\n")], {
|
|
1440
|
+
type: "text/plain"
|
|
1441
|
+
});
|
|
1442
|
+
element.href = URL.createObjectURL(file);
|
|
1443
|
+
element.download = "recovery-codes.txt";
|
|
1444
|
+
document.body.appendChild(element);
|
|
1445
|
+
element.click();
|
|
1446
|
+
};
|
|
1447
|
+
const hasCodes = codes.length >= 1;
|
|
1448
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1449
|
+
/* @__PURE__ */ (0, import_jsx_runtime47.jsx)(DefaultHorizontalDivider, {}),
|
|
1450
|
+
/* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex justify-end gap-4", children: [
|
|
1451
|
+
regnerateButton && /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1452
|
+
"button",
|
|
1453
|
+
{
|
|
1454
|
+
...regnerateButton.attributes,
|
|
1455
|
+
type: "submit",
|
|
1456
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1457
|
+
refresh_default,
|
|
1458
|
+
{
|
|
1459
|
+
size: 24,
|
|
1460
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
1461
|
+
}
|
|
1462
|
+
)
|
|
1463
|
+
}
|
|
1464
|
+
),
|
|
1465
|
+
revealButton && /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1466
|
+
"button",
|
|
1467
|
+
{
|
|
1468
|
+
...revealButton.attributes,
|
|
1469
|
+
type: "submit",
|
|
1470
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1471
|
+
eye_default,
|
|
1472
|
+
{
|
|
1473
|
+
size: 24,
|
|
1474
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
1475
|
+
}
|
|
1476
|
+
)
|
|
1477
|
+
}
|
|
1478
|
+
),
|
|
1479
|
+
hasCodes ? /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1480
|
+
download_default,
|
|
1481
|
+
{
|
|
1482
|
+
size: 24,
|
|
1483
|
+
onClick: onDownload,
|
|
1484
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
1485
|
+
}
|
|
1486
|
+
) : null
|
|
1487
|
+
] }),
|
|
1488
|
+
hasCodes ? /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "rounded-border-radius-cards bg-bg-default ring-1 ring-dialog-border-default p-6", children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "grid grid-cols-6 gap-4 flex-wrap text-dialog-fg-default text-sm", children: codes.map((code) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("p", { children: code }, code)) }) }) : null
|
|
1489
|
+
] });
|
|
1490
|
+
}
|
|
1491
|
+
|
|
1492
|
+
// src/theme/default/assets/icons/qrcode.svg
|
|
1493
|
+
var React25 = __toESM(require("react"));
|
|
1494
|
+
var import_jsx_runtime48 = require("react/jsx-runtime");
|
|
1495
|
+
var SvgQrcode = (props) => {
|
|
1496
|
+
var _a, _b;
|
|
1497
|
+
return /* @__PURE__ */ (0, import_jsx_runtime48.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_runtime48.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" }) });
|
|
1498
|
+
};
|
|
1499
|
+
var qrcode_default = SvgQrcode;
|
|
1500
|
+
|
|
1501
|
+
// src/theme/default/assets/icons/trash.svg
|
|
1502
|
+
var React26 = __toESM(require("react"));
|
|
1503
|
+
var import_jsx_runtime49 = require("react/jsx-runtime");
|
|
1504
|
+
var SvgTrash = (props) => {
|
|
1505
|
+
var _a, _b;
|
|
1506
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.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_runtime49.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" }) });
|
|
1507
|
+
};
|
|
1508
|
+
var trash_default = SvgTrash;
|
|
1509
|
+
|
|
1510
|
+
// src/theme/default/components/settings/settings-top.tsx
|
|
1511
|
+
var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
1512
|
+
function DefaultSettingsTotp(props) {
|
|
1513
|
+
var _a;
|
|
1514
|
+
if ("totpUnlink" in props && props.totpUnlink) {
|
|
1515
|
+
const {
|
|
1516
|
+
type,
|
|
1517
|
+
autocomplete: _ignoredAutocomplete,
|
|
1518
|
+
label: _ignoredLabel,
|
|
1519
|
+
node_type: _ignoredNodeType,
|
|
1520
|
+
...buttonAttrs
|
|
1521
|
+
} = (_a = props.totpUnlink) == null ? void 0 : _a.attributes;
|
|
1522
|
+
return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-8", children: [
|
|
1523
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DefaultHorizontalDivider, {}) }),
|
|
1524
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "flex gap-6 items-center col-span-full", children: [
|
|
1525
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "size-8 aspect-square ", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(qrcode_default, { size: 32 }) }),
|
|
1526
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "flex flex-col mr-auto", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("p", { className: "text-dialog-fg-subtle text-sm font-medium", children: "Authenticator app" }) }),
|
|
1527
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1528
|
+
"button",
|
|
1529
|
+
{
|
|
1530
|
+
type: type === "button" ? "button" : "submit",
|
|
1531
|
+
...buttonAttrs,
|
|
1532
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1533
|
+
trash_default,
|
|
1534
|
+
{
|
|
1535
|
+
size: 24,
|
|
1536
|
+
className: "text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
1537
|
+
}
|
|
1538
|
+
)
|
|
1539
|
+
}
|
|
1540
|
+
)
|
|
1541
|
+
] })
|
|
1542
|
+
] });
|
|
1543
|
+
}
|
|
1544
|
+
if ("totpSecret" in props) {
|
|
1545
|
+
return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-8", children: [
|
|
1546
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DefaultHorizontalDivider, {}) }),
|
|
1547
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "bg-dialog-bg-subtle p-8 rounded-xl flex justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "h-44 aspect-square bg-[white] rounded", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "mix-blend-multiply -m-3 antialiased", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1548
|
+
DefaultImage,
|
|
1549
|
+
{
|
|
1550
|
+
node: props.totpImage,
|
|
1551
|
+
attributes: {
|
|
1552
|
+
...props.totpImage.attributes
|
|
1553
|
+
}
|
|
1554
|
+
}
|
|
1555
|
+
) }) }) }),
|
|
1556
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "flex flex-col gap-6", children: [
|
|
1557
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1558
|
+
DefaultLabel,
|
|
1559
|
+
{
|
|
1560
|
+
node: props.totpSecret,
|
|
1561
|
+
attributes: props.totpSecret.attributes,
|
|
1562
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1563
|
+
DefaultInput,
|
|
1564
|
+
{
|
|
1565
|
+
node: props.totpSecret,
|
|
1566
|
+
attributes: {
|
|
1567
|
+
disabled: true,
|
|
1568
|
+
name: "totp_secret_key",
|
|
1569
|
+
node_type: "input",
|
|
1570
|
+
type: "text",
|
|
1571
|
+
value: props.totpSecret.attributes.text.text
|
|
1572
|
+
}
|
|
1573
|
+
}
|
|
1574
|
+
)
|
|
1575
|
+
}
|
|
1576
|
+
),
|
|
1577
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1578
|
+
DefaultLabel,
|
|
1579
|
+
{
|
|
1580
|
+
attributes: props.totpInput.attributes,
|
|
1581
|
+
node: props.totpInput,
|
|
1582
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1583
|
+
DefaultInput,
|
|
1584
|
+
{
|
|
1585
|
+
node: props.totpInput,
|
|
1586
|
+
attributes: props.totpInput.attributes
|
|
1587
|
+
}
|
|
1588
|
+
)
|
|
1589
|
+
}
|
|
1590
|
+
)
|
|
1591
|
+
] })
|
|
1592
|
+
] });
|
|
1593
|
+
}
|
|
1594
|
+
}
|
|
1595
|
+
|
|
1596
|
+
// src/theme/default/components/settings/settings-oidc.tsx
|
|
1597
|
+
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
1598
|
+
function DefaultSettingsOidc({
|
|
1599
|
+
linkButtons,
|
|
1600
|
+
unlinkButtons
|
|
1601
|
+
}) {
|
|
1602
|
+
const hasLinkButtons = linkButtons.length > 0;
|
|
1603
|
+
const hasUnlinkButtons = unlinkButtons.length > 0;
|
|
1604
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1605
|
+
hasLinkButtons && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "flex gap-3 items-start [&>button]:w-[79px]", children: linkButtons.map((button) => {
|
|
1606
|
+
const attrs = button.attributes;
|
|
1607
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
1608
|
+
DefaultButtonSocial,
|
|
1609
|
+
{
|
|
1610
|
+
showLabel: false,
|
|
1611
|
+
node: button,
|
|
1612
|
+
attributes: attrs
|
|
1613
|
+
},
|
|
1614
|
+
attrs.value
|
|
1615
|
+
);
|
|
1616
|
+
}) }),
|
|
1617
|
+
hasUnlinkButtons && hasLinkButtons ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(DefaultHorizontalDivider, {}) : null,
|
|
1618
|
+
unlinkButtons.map((button) => {
|
|
1619
|
+
var _a, _b;
|
|
1620
|
+
const attrs = button.attributes;
|
|
1621
|
+
const provider = (_b = extractProvider((_a = button.meta.label) == null ? void 0 : _a.context)) != null ? _b : "";
|
|
1622
|
+
const Logo = provider_logos_default[attrs.value];
|
|
1623
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex justify-between", children: [
|
|
1624
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex gap-6 items-center", children: [
|
|
1625
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Logo, { size: 32 }),
|
|
1626
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("p", { className: "text-dialog-fg-subtle text-sm font-medium", children: provider })
|
|
1627
|
+
] }),
|
|
1628
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("button", { ...attrs, type: "submit", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(trash_default, { className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover" }) })
|
|
1629
|
+
] }, attrs.value);
|
|
1630
|
+
})
|
|
1631
|
+
] });
|
|
1632
|
+
}
|
|
1633
|
+
|
|
1634
|
+
// src/theme/default/assets/icons/key.svg
|
|
1635
|
+
var React27 = __toESM(require("react"));
|
|
1636
|
+
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
1637
|
+
var SvgKey = (props) => {
|
|
1638
|
+
var _a, _b;
|
|
1639
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.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_runtime52.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" }) });
|
|
1640
|
+
};
|
|
1641
|
+
var key_default = SvgKey;
|
|
1642
|
+
|
|
1643
|
+
// src/theme/default/components/settings/settings-webauthn.tsx
|
|
1644
|
+
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
1645
|
+
function DefaultSettingsWebauthn({
|
|
1646
|
+
nameInput,
|
|
1647
|
+
triggerButton,
|
|
1648
|
+
removeButtons
|
|
1649
|
+
}) {
|
|
1650
|
+
const hasRemoveButtons = removeButtons.length > 0;
|
|
1651
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1652
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex gap-3 items-end max-w-[60%]", children: [
|
|
1653
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "flex-1", children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1654
|
+
DefaultLabel,
|
|
1655
|
+
{
|
|
1656
|
+
node: nameInput,
|
|
1657
|
+
attributes: nameInput.attributes,
|
|
1658
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1659
|
+
DefaultInput,
|
|
1660
|
+
{
|
|
1661
|
+
node: nameInput,
|
|
1662
|
+
attributes: nameInput.attributes
|
|
1663
|
+
}
|
|
1664
|
+
)
|
|
1665
|
+
}
|
|
1666
|
+
) }),
|
|
1667
|
+
triggerButton ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1668
|
+
DefaultButton,
|
|
1669
|
+
{
|
|
1670
|
+
node: triggerButton,
|
|
1671
|
+
attributes: triggerButton.attributes,
|
|
1672
|
+
onClick: triggerButton.onClick
|
|
1673
|
+
}
|
|
1674
|
+
) : null
|
|
1675
|
+
] }),
|
|
1676
|
+
hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1677
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(DefaultHorizontalDivider, {}),
|
|
1678
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "flex flex-col gap-2", children: removeButtons.map((node, i) => {
|
|
1679
|
+
var _a, _b;
|
|
1680
|
+
const context = (_b = (_a = node.meta.label) == null ? void 0 : _a.context) != null ? _b : {};
|
|
1681
|
+
const addedAt = "added_at" in context ? context.added_at : null;
|
|
1682
|
+
const diaplyName = "display_name" in context ? context.display_name : null;
|
|
1683
|
+
const keyId = "value" in node.attributes ? node.attributes.value : null;
|
|
1684
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
|
|
1685
|
+
"div",
|
|
1686
|
+
{
|
|
1687
|
+
className: "flex justify-between gap-6",
|
|
1688
|
+
children: [
|
|
1689
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(key_default, { size: 32, className: "text-dialog-fg-default" }),
|
|
1690
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex-1 flex-col", children: [
|
|
1691
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("p", { className: "text-sm font-medium text-dialog-fg-subtle", children: diaplyName }),
|
|
1692
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "text-sm text-dialog-fg-mute", children: keyId })
|
|
1693
|
+
] }),
|
|
1694
|
+
addedAt && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("p", { className: "text-sm self-center text-dialog-fg-mute", children: new Date(addedAt).toLocaleDateString() }),
|
|
1695
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1696
|
+
"button",
|
|
1697
|
+
{
|
|
1698
|
+
...node.attributes,
|
|
1699
|
+
type: "submit",
|
|
1700
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover",
|
|
1701
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(trash_default, { size: 20 })
|
|
1702
|
+
}
|
|
1703
|
+
)
|
|
1704
|
+
]
|
|
1705
|
+
},
|
|
1706
|
+
`webauthn-remove-button-${i}`
|
|
1707
|
+
);
|
|
1708
|
+
}) })
|
|
1709
|
+
] }) : null
|
|
1710
|
+
] });
|
|
1711
|
+
}
|
|
1712
|
+
|
|
1713
|
+
// src/theme/default/components/settings/settings-passkey.tsx
|
|
1714
|
+
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
1715
|
+
function DefaultSettingsPasskey({
|
|
1716
|
+
triggerButton,
|
|
1717
|
+
removeButtons
|
|
1718
|
+
}) {
|
|
1719
|
+
const hasRemoveButtons = removeButtons.length > 0;
|
|
1720
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1721
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex gap-3 items-end max-w-[60%]", children: triggerButton ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1722
|
+
DefaultButton,
|
|
1723
|
+
{
|
|
1724
|
+
node: triggerButton,
|
|
1725
|
+
attributes: triggerButton.attributes,
|
|
1726
|
+
onClick: triggerButton.onClick
|
|
1727
|
+
}
|
|
1728
|
+
) : null }),
|
|
1729
|
+
hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1730
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(DefaultHorizontalDivider, {}),
|
|
1731
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex flex-col gap-2", children: removeButtons.map((node, i) => {
|
|
1732
|
+
var _a, _b;
|
|
1733
|
+
const context = (_b = (_a = node.meta.label) == null ? void 0 : _a.context) != null ? _b : {};
|
|
1734
|
+
const addedAt = "added_at" in context ? context.added_at : null;
|
|
1735
|
+
const diaplyName = "display_name" in context ? context.display_name : null;
|
|
1736
|
+
const keyId = "value" in node.attributes ? node.attributes.value : null;
|
|
1737
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
|
|
1738
|
+
"div",
|
|
1739
|
+
{
|
|
1740
|
+
className: "flex justify-between gap-6",
|
|
1741
|
+
children: [
|
|
1742
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(passkey_default, { size: 32, className: "text-dialog-fg-default" }),
|
|
1743
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex-1 flex-col", children: [
|
|
1744
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("p", { className: "text-sm font-medium text-dialog-fg-subtle", children: diaplyName }),
|
|
1745
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "text-sm text-dialog-fg-mute", children: keyId })
|
|
1746
|
+
] }),
|
|
1747
|
+
addedAt && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("p", { className: "text-sm self-center text-dialog-fg-mute", children: new Date(addedAt).toLocaleDateString() }),
|
|
1748
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1749
|
+
"button",
|
|
1750
|
+
{
|
|
1751
|
+
...node.attributes,
|
|
1752
|
+
type: "submit",
|
|
1753
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover",
|
|
1754
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(trash_default, { size: 20 })
|
|
1755
|
+
}
|
|
1756
|
+
)
|
|
1757
|
+
]
|
|
1758
|
+
},
|
|
1759
|
+
`webauthn-remove-button-${i}`
|
|
1760
|
+
);
|
|
1761
|
+
}) })
|
|
1762
|
+
] }) : null
|
|
1763
|
+
] });
|
|
1764
|
+
}
|
|
1765
|
+
|
|
1766
|
+
// src/theme/default/components/generic/page-header.tsx
|
|
1767
|
+
var import_elements_react14 = require("@ory/elements-react");
|
|
1768
|
+
|
|
1769
|
+
// src/theme/default/components/ui/user-menu.tsx
|
|
1770
|
+
var import_react_dropdown_menu = require("@radix-ui/react-dropdown-menu");
|
|
1771
|
+
var import_react5 = require("react");
|
|
1772
|
+
var import_elements_react13 = require("@ory/elements-react");
|
|
1773
|
+
|
|
1774
|
+
// src/util/client.ts
|
|
1775
|
+
var import_client_fetch9 = require("@ory/client-fetch");
|
|
1776
|
+
function frontendClient(sdkUrl, opts = {}) {
|
|
1777
|
+
const config = new import_client_fetch9.Configuration({
|
|
1778
|
+
...opts,
|
|
1779
|
+
basePath: sdkUrl,
|
|
1780
|
+
headers: {
|
|
1781
|
+
Accept: "application/json",
|
|
1782
|
+
...opts.headers
|
|
1783
|
+
}
|
|
1784
|
+
});
|
|
1785
|
+
return new import_client_fetch9.FrontendApi(config);
|
|
1786
|
+
}
|
|
1787
|
+
|
|
1788
|
+
// src/theme/default/assets/icons/logout.svg
|
|
1789
|
+
var React28 = __toESM(require("react"));
|
|
1790
|
+
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
1791
|
+
var SvgLogout = (props) => {
|
|
1792
|
+
var _a, _b;
|
|
1793
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.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_runtime55.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" }) });
|
|
1794
|
+
};
|
|
1795
|
+
var logout_default = SvgLogout;
|
|
1796
|
+
|
|
1797
|
+
// src/theme/default/assets/icons/settings.svg
|
|
1798
|
+
var React29 = __toESM(require("react"));
|
|
1799
|
+
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
1800
|
+
var SvgSettings = (props) => {
|
|
1801
|
+
var _a, _b;
|
|
1802
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.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_runtime56.jsxs)("g", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
1803
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.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" }),
|
|
1804
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)("path", { d: "M6 8a2 2 0 1 0 4 0 2 2 0 0 0-4 0" })
|
|
1805
|
+
] }) });
|
|
1806
|
+
};
|
|
1807
|
+
var settings_default = SvgSettings;
|
|
1808
|
+
|
|
1809
|
+
// src/theme/default/utils/user.ts
|
|
1810
|
+
var getUserInitials = (session) => {
|
|
1811
|
+
var _a, _b;
|
|
1812
|
+
const avatar = "";
|
|
1813
|
+
let primary = "";
|
|
1814
|
+
let secondary = "";
|
|
1815
|
+
if (!((_a = session == null ? void 0 : session.identity) == null ? void 0 : _a.traits)) {
|
|
1816
|
+
return {
|
|
1817
|
+
primary,
|
|
1818
|
+
secondary,
|
|
1819
|
+
avatar
|
|
1820
|
+
};
|
|
1821
|
+
}
|
|
1822
|
+
const traits = (_b = session.identity) == null ? void 0 : _b.traits;
|
|
1823
|
+
if (traits.email) {
|
|
1824
|
+
secondary = traits.email;
|
|
1825
|
+
}
|
|
1826
|
+
if (traits.name) {
|
|
1827
|
+
if (typeof traits.name === "string") {
|
|
1828
|
+
primary = traits.name;
|
|
1829
|
+
}
|
|
1830
|
+
if (traits.name.first && traits.name.last) {
|
|
1831
|
+
primary = traits.name.first + " " + traits.name.last;
|
|
1832
|
+
}
|
|
1833
|
+
}
|
|
1834
|
+
if (primary === "") {
|
|
1835
|
+
primary = secondary;
|
|
1836
|
+
secondary = "";
|
|
1837
|
+
}
|
|
1838
|
+
return {
|
|
1839
|
+
primary,
|
|
1840
|
+
secondary,
|
|
1841
|
+
avatar
|
|
1842
|
+
};
|
|
1843
|
+
};
|
|
1844
|
+
|
|
1845
|
+
// src/theme/default/components/ui/dropdown-menu.tsx
|
|
1846
|
+
var import_react3 = require("react");
|
|
1847
|
+
var DropdownMenuPrimitive = __toESM(require("@radix-ui/react-dropdown-menu"));
|
|
1848
|
+
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
1849
|
+
var DropdownMenu = DropdownMenuPrimitive.Root;
|
|
1850
|
+
var DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
|
|
1851
|
+
var DropdownMenuContent = (0, import_react3.forwardRef)(({ className, sideOffset = 16, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
1852
|
+
DropdownMenuPrimitive.Content,
|
|
1853
|
+
{
|
|
1854
|
+
ref,
|
|
1855
|
+
sideOffset,
|
|
1856
|
+
align: "end",
|
|
1857
|
+
className: cn(
|
|
1858
|
+
"z-50 min-w-[19rem] overflow-hidden data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
|
|
1859
|
+
"border border-dialog-border-default bg-dialog-bg-default rounded-border-radius-cards",
|
|
1860
|
+
className
|
|
1861
|
+
),
|
|
1862
|
+
...props
|
|
1863
|
+
}
|
|
1864
|
+
) }));
|
|
1865
|
+
DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
|
|
1866
|
+
var DropdownMenuItem = (0, import_react3.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
1867
|
+
DropdownMenuPrimitive.Item,
|
|
1868
|
+
{
|
|
1869
|
+
ref,
|
|
1870
|
+
className: cn(
|
|
1871
|
+
"relative flex cursor-pointer select-none items-center outline-none transition-colors data-[disabled]:pointer-events-none",
|
|
1872
|
+
"px-8 py-3 lg:py-4.5 text-sm gap-6",
|
|
1873
|
+
"first:border-0 border-t border-button-secondary-border-default hover:border-button-social-border-hover data-[disabled]:border-button-secondary-border-disabled",
|
|
1874
|
+
"text-button-secondary-fg-default bg-button-secondary-bg-default",
|
|
1875
|
+
"hover:text-button-secondary-fg-hover hover:bg-button-secondary-bg-hover",
|
|
1876
|
+
"data-[disabled]:text-button-secondary-fg-disabled data-[disabled]:bg-button-secondary-bg-disabled",
|
|
1877
|
+
inset && "pl-8",
|
|
1878
|
+
className
|
|
1879
|
+
),
|
|
1880
|
+
...props
|
|
1881
|
+
}
|
|
1882
|
+
));
|
|
1883
|
+
DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
|
|
1884
|
+
var DropdownMenuLabel = (0, import_react3.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
1885
|
+
DropdownMenuPrimitive.Label,
|
|
1886
|
+
{
|
|
1887
|
+
ref,
|
|
1888
|
+
className: cn(
|
|
1889
|
+
"px-2 py-1.5 text-sm font-semibold",
|
|
1890
|
+
inset && "pl-8",
|
|
1891
|
+
className
|
|
1892
|
+
),
|
|
1893
|
+
...props
|
|
1894
|
+
}
|
|
1895
|
+
));
|
|
1896
|
+
DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
|
|
1897
|
+
|
|
1898
|
+
// src/theme/default/components/ui/user-avater.tsx
|
|
1899
|
+
var import_react4 = require("react");
|
|
1900
|
+
|
|
1901
|
+
// src/theme/default/assets/icons/user.svg
|
|
1902
|
+
var React30 = __toESM(require("react"));
|
|
1903
|
+
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
1904
|
+
var SvgUser = (props) => {
|
|
1905
|
+
var _a, _b;
|
|
1906
|
+
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: "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" }) });
|
|
1907
|
+
};
|
|
1908
|
+
var user_default = SvgUser;
|
|
1909
|
+
|
|
1910
|
+
// src/theme/default/components/ui/user-avater.tsx
|
|
1911
|
+
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
1912
|
+
var UserAvatar = (0, import_react4.forwardRef)(
|
|
1913
|
+
({ initials, ...rest }, ref) => {
|
|
1914
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
1915
|
+
"button",
|
|
1916
|
+
{
|
|
1917
|
+
ref,
|
|
1918
|
+
className: "size-10 relative flex overflow-hidden items-center justify-center rounded-full bg-button-primary-bg-default disabled:hover:bg-button-primary-bg-default hover:bg-button-primary-bg-hover",
|
|
1919
|
+
...rest,
|
|
1920
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "relative size-full flex items-center justify-center", children: initials.avatar ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
1921
|
+
"img",
|
|
1922
|
+
{
|
|
1923
|
+
src: initials.avatar,
|
|
1924
|
+
alt: initials.primary,
|
|
1925
|
+
className: "w-full object-contain"
|
|
1926
|
+
}
|
|
1927
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(user_default, { size: 24, className: "text-button-primary-fg-default" }) })
|
|
1928
|
+
}
|
|
1929
|
+
);
|
|
1930
|
+
}
|
|
1931
|
+
);
|
|
1932
|
+
UserAvatar.displayName = "UserAvatar";
|
|
1933
|
+
|
|
1934
|
+
// src/theme/default/components/ui/user-menu.tsx
|
|
1935
|
+
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
1936
|
+
var UserMenu = ({ session }) => {
|
|
1937
|
+
const { config } = (0, import_elements_react13.useOryFlow)();
|
|
1938
|
+
const initials = getUserInitials(session);
|
|
1939
|
+
const [logoutFlow, setLogoutFlow] = (0, import_react5.useState)();
|
|
1940
|
+
const fetchLogoutFlow = (0, import_react5.useCallback)(async () => {
|
|
1941
|
+
const flow = await frontendClient(config.sdk.url).createBrowserLogoutFlow();
|
|
1942
|
+
setLogoutFlow(flow);
|
|
1943
|
+
}, [config.sdk.url]);
|
|
1944
|
+
(0, import_react5.useEffect)(() => {
|
|
1945
|
+
void fetchLogoutFlow();
|
|
1946
|
+
}, [fetchLogoutFlow]);
|
|
1947
|
+
return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(DropdownMenu, { children: [
|
|
1948
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(UserAvatar, { initials }) }),
|
|
1949
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(DropdownMenuContent, { children: [
|
|
1950
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(import_react_dropdown_menu.DropdownMenuLabel, { className: "px-5 py-4.5 flex gap-3", children: [
|
|
1951
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(UserAvatar, { disabled: true, initials }),
|
|
1952
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex flex-col text-sm leading-tight justify-center", children: [
|
|
1953
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "text-dialog-fg-default", children: initials.primary }),
|
|
1954
|
+
initials.secondary && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "text-dialog-fg-mute", children: initials.secondary })
|
|
1955
|
+
] })
|
|
1956
|
+
] }),
|
|
1957
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("a", { href: "/settings", children: [
|
|
1958
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(settings_default, { size: 16 }),
|
|
1959
|
+
" User settings"
|
|
1960
|
+
] }) }),
|
|
1961
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DropdownMenuItem, { asChild: true, disabled: !(logoutFlow == null ? void 0 : logoutFlow.logout_url), children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("a", { href: logoutFlow == null ? void 0 : logoutFlow.logout_url, children: [
|
|
1962
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(logout_default, { size: 16 }),
|
|
1963
|
+
" Logout"
|
|
1964
|
+
] }) })
|
|
1965
|
+
] })
|
|
1966
|
+
] });
|
|
1967
|
+
};
|
|
1968
|
+
|
|
1969
|
+
// src/theme/default/components/generic/page-header.tsx
|
|
1970
|
+
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
1971
|
+
var DefaultPageHeader = (_props) => {
|
|
1972
|
+
const { Card } = (0, import_elements_react14.useComponents)();
|
|
1973
|
+
const { session } = (0, import_elements_react14.useSession)();
|
|
1974
|
+
return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "flex max-w-[896px] flex-col w-full gap-3 mt-16", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "flex flex-col gap-12", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex gap-2 max-h-10 justify-between flex-1", children: [
|
|
1975
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "h-10 flex-1 relative", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(Card.Logo, {}) }),
|
|
1976
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)(UserMenu, { session })
|
|
1977
|
+
] }) }) });
|
|
1978
|
+
};
|
|
1979
|
+
|
|
1251
1980
|
// src/theme/default/components/default-components.tsx
|
|
1252
1981
|
var OryDefaultComponents = {
|
|
1253
|
-
Card:
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1982
|
+
Card: {
|
|
1983
|
+
Root: DefaultCard,
|
|
1984
|
+
Footer: DefaultCardFooter,
|
|
1985
|
+
Header: DefaultCardHeader,
|
|
1986
|
+
Content: DefaultCardContent,
|
|
1987
|
+
Logo: DefaultCardLogo,
|
|
1988
|
+
Divider: DefaultHorizontalDivider,
|
|
1989
|
+
AuthMethodListItem: DefaultAuthMethodListItem,
|
|
1990
|
+
SettingsSection: DefaultFormSection,
|
|
1991
|
+
SettingsSectionContent: DefaultFormSectionContent,
|
|
1992
|
+
SettingsSectionFooter: DefaultFormSectionFooter
|
|
1993
|
+
},
|
|
1994
|
+
Node: {
|
|
1995
|
+
Button: DefaultButton,
|
|
1996
|
+
OidcButton: DefaultButtonSocial,
|
|
1997
|
+
CurrentIdentifierButton: DefaultCurrentIdentifierButton,
|
|
1998
|
+
Input: DefaultInput,
|
|
1999
|
+
CodeInput: DefaultPinCodeInput,
|
|
2000
|
+
Image: DefaultImage,
|
|
2001
|
+
Label: DefaultLabel,
|
|
2002
|
+
Checkbox: DefaultCheckbox,
|
|
2003
|
+
Text: DefaultText,
|
|
2004
|
+
Anchor: DefaultLinkButton
|
|
2005
|
+
},
|
|
2006
|
+
Form: {
|
|
2007
|
+
Root: DefaultFormContainer,
|
|
2008
|
+
Group: DefaultGroupContainer,
|
|
2009
|
+
OidcRoot: DefaultSocialButtonContainer,
|
|
2010
|
+
RecoveryCodesSettings: DefaultSettingsRecoveryCodes,
|
|
2011
|
+
TotpSettings: DefaultSettingsTotp,
|
|
2012
|
+
OidcSettings: DefaultSettingsOidc,
|
|
2013
|
+
WebauthnSettings: DefaultSettingsWebauthn,
|
|
2014
|
+
PasskeySettings: DefaultSettingsPasskey
|
|
2015
|
+
},
|
|
2016
|
+
Message: {
|
|
2017
|
+
Root: DefaultMessageContainer,
|
|
2018
|
+
Content: DefaultMessage
|
|
2019
|
+
},
|
|
2020
|
+
Page: {
|
|
2021
|
+
Header: DefaultPageHeader
|
|
2022
|
+
}
|
|
1277
2023
|
};
|
|
1278
2024
|
|
|
1279
2025
|
// src/theme/default/flows/error.tsx
|
|
1280
|
-
var
|
|
2026
|
+
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
1281
2027
|
function Error2({
|
|
1282
2028
|
error,
|
|
1283
2029
|
children
|
|
1284
2030
|
}) {
|
|
1285
|
-
return /* @__PURE__ */ (0,
|
|
2031
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { children: JSON.stringify(error) || children });
|
|
1286
2032
|
}
|
|
1287
2033
|
|
|
1288
2034
|
// src/theme/default/flows/login.tsx
|
|
1289
|
-
var
|
|
1290
|
-
var
|
|
1291
|
-
var
|
|
2035
|
+
var import_client_fetch10 = require("@ory/client-fetch");
|
|
2036
|
+
var import_elements_react15 = require("@ory/elements-react");
|
|
2037
|
+
var import_lodash = __toESM(require("lodash.merge"));
|
|
2038
|
+
var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
1292
2039
|
function Login({
|
|
1293
2040
|
flow,
|
|
1294
2041
|
config,
|
|
1295
2042
|
children,
|
|
1296
2043
|
components: flowOverrideComponents
|
|
1297
2044
|
}) {
|
|
1298
|
-
const components = {
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
};
|
|
1302
|
-
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
1303
|
-
import_elements_react13.OryProvider,
|
|
2045
|
+
const components = flowOverrideComponents ? (0, import_lodash.default)({}, OryDefaultComponents, flowOverrideComponents) : OryDefaultComponents;
|
|
2046
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
2047
|
+
import_elements_react15.OryProvider,
|
|
1304
2048
|
{
|
|
1305
2049
|
config,
|
|
1306
2050
|
flow,
|
|
1307
|
-
flowType:
|
|
2051
|
+
flowType: import_client_fetch10.FlowType.Login,
|
|
1308
2052
|
components,
|
|
1309
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2053
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_elements_react15.OryTwoStepCard, {})
|
|
1310
2054
|
}
|
|
1311
2055
|
);
|
|
1312
2056
|
}
|
|
1313
2057
|
|
|
1314
2058
|
// src/theme/default/flows/recovery.tsx
|
|
1315
|
-
var
|
|
1316
|
-
var
|
|
1317
|
-
var
|
|
2059
|
+
var import_client_fetch11 = require("@ory/client-fetch");
|
|
2060
|
+
var import_elements_react16 = require("@ory/elements-react");
|
|
2061
|
+
var import_lodash2 = __toESM(require("lodash.merge"));
|
|
2062
|
+
var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
1318
2063
|
function Recovery({
|
|
1319
2064
|
flow,
|
|
1320
2065
|
config,
|
|
1321
2066
|
children,
|
|
1322
2067
|
components: flowOverrideComponents
|
|
1323
2068
|
}) {
|
|
1324
|
-
const components = {
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
};
|
|
1328
|
-
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
1329
|
-
import_elements_react14.OryProvider,
|
|
2069
|
+
const components = flowOverrideComponents ? (0, import_lodash2.default)({}, OryDefaultComponents, flowOverrideComponents) : OryDefaultComponents;
|
|
2070
|
+
return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
|
|
2071
|
+
import_elements_react16.OryProvider,
|
|
1330
2072
|
{
|
|
1331
2073
|
config,
|
|
1332
2074
|
flow,
|
|
1333
|
-
flowType:
|
|
2075
|
+
flowType: import_client_fetch11.FlowType.Recovery,
|
|
1334
2076
|
components,
|
|
1335
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2077
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_elements_react16.OryTwoStepCard, {})
|
|
1336
2078
|
}
|
|
1337
2079
|
);
|
|
1338
2080
|
}
|
|
1339
2081
|
|
|
1340
2082
|
// src/theme/default/flows/registration.tsx
|
|
1341
|
-
var
|
|
1342
|
-
var
|
|
1343
|
-
var
|
|
2083
|
+
var import_client_fetch12 = require("@ory/client-fetch");
|
|
2084
|
+
var import_elements_react17 = require("@ory/elements-react");
|
|
2085
|
+
var import_lodash3 = __toESM(require("lodash.merge"));
|
|
2086
|
+
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
1344
2087
|
function Registration({
|
|
1345
2088
|
flow,
|
|
1346
2089
|
children,
|
|
1347
2090
|
components: flowOverrideComponents,
|
|
1348
2091
|
config
|
|
1349
2092
|
}) {
|
|
1350
|
-
const components = {
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
};
|
|
1354
|
-
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
1355
|
-
import_elements_react15.OryProvider,
|
|
2093
|
+
const components = flowOverrideComponents ? (0, import_lodash3.default)({}, OryDefaultComponents, flowOverrideComponents) : OryDefaultComponents;
|
|
2094
|
+
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
2095
|
+
import_elements_react17.OryProvider,
|
|
1356
2096
|
{
|
|
1357
2097
|
config,
|
|
1358
2098
|
flow,
|
|
1359
|
-
flowType:
|
|
2099
|
+
flowType: import_client_fetch12.FlowType.Registration,
|
|
1360
2100
|
components,
|
|
1361
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2101
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_elements_react17.OryTwoStepCard, {})
|
|
1362
2102
|
}
|
|
1363
2103
|
);
|
|
1364
2104
|
}
|
|
1365
2105
|
|
|
1366
2106
|
// src/theme/default/flows/settings.tsx
|
|
1367
|
-
var
|
|
1368
|
-
var
|
|
1369
|
-
var
|
|
2107
|
+
var import_client_fetch13 = require("@ory/client-fetch");
|
|
2108
|
+
var import_elements_react18 = require("@ory/elements-react");
|
|
2109
|
+
var import_lodash4 = __toESM(require("lodash.merge"));
|
|
2110
|
+
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
1370
2111
|
function Settings({
|
|
1371
2112
|
flow,
|
|
1372
2113
|
config,
|
|
1373
2114
|
children,
|
|
1374
2115
|
components: flowOverrideComponents
|
|
1375
2116
|
}) {
|
|
1376
|
-
const components = {
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
};
|
|
1380
|
-
return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
|
|
1381
|
-
import_elements_react16.OryProvider,
|
|
2117
|
+
const components = flowOverrideComponents ? (0, import_lodash4.default)({}, OryDefaultComponents, flowOverrideComponents) : OryDefaultComponents;
|
|
2118
|
+
return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
|
|
2119
|
+
import_elements_react18.OryProvider,
|
|
1382
2120
|
{
|
|
1383
2121
|
config,
|
|
1384
2122
|
flow,
|
|
1385
|
-
flowType:
|
|
2123
|
+
flowType: import_client_fetch13.FlowType.Settings,
|
|
1386
2124
|
components,
|
|
1387
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2125
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)(import_jsx_runtime66.Fragment, { children: [
|
|
2126
|
+
/* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_elements_react18.HeadlessPageHeader, {}),
|
|
2127
|
+
/* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_elements_react18.OrySettingsCard, {})
|
|
2128
|
+
] })
|
|
1388
2129
|
}
|
|
1389
2130
|
);
|
|
1390
2131
|
}
|
|
1391
2132
|
|
|
1392
2133
|
// src/theme/default/flows/verification.tsx
|
|
1393
|
-
var
|
|
1394
|
-
var
|
|
1395
|
-
var
|
|
2134
|
+
var import_client_fetch14 = require("@ory/client-fetch");
|
|
2135
|
+
var import_elements_react19 = require("@ory/elements-react");
|
|
2136
|
+
var import_lodash5 = __toESM(require("lodash.merge"));
|
|
2137
|
+
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
1396
2138
|
function Verification({
|
|
1397
2139
|
flow,
|
|
1398
2140
|
config,
|
|
1399
2141
|
children,
|
|
1400
2142
|
components: flowOverrideComponents
|
|
1401
2143
|
}) {
|
|
1402
|
-
const components = {
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
};
|
|
1406
|
-
return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1407
|
-
import_elements_react17.OryProvider,
|
|
2144
|
+
const components = flowOverrideComponents ? (0, import_lodash5.default)({}, OryDefaultComponents, flowOverrideComponents) : OryDefaultComponents;
|
|
2145
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
2146
|
+
import_elements_react19.OryProvider,
|
|
1408
2147
|
{
|
|
1409
2148
|
config,
|
|
1410
2149
|
flow,
|
|
1411
|
-
flowType:
|
|
2150
|
+
flowType: import_client_fetch14.FlowType.Verification,
|
|
1412
2151
|
components,
|
|
1413
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2152
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_elements_react19.OryTwoStepCard, {})
|
|
1414
2153
|
}
|
|
1415
2154
|
);
|
|
1416
2155
|
}
|