@ory/elements-react 1.0.0-next.11 → 1.0.0-next.13
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/CHANGELOG.md +56 -0
- package/api-report/elements-react-client.api.json +228 -0
- package/api-report/elements-react-client.api.md +22 -0
- package/api-report/elements-react-theme.api.json +47 -24
- package/api-report/elements-react-theme.api.md +6 -5
- package/api-report/elements-react.api.json +710 -86
- package/api-report/elements-react.api.md +86 -11
- package/api-report/temp/elements-react-client.api.md +22 -0
- package/api-report/temp/elements-react-theme.api.md +6 -5
- package/api-report/temp/elements-react.api.md +86 -11
- package/config/api-extractor-client.json +463 -0
- package/dist/client/frontendClient.d.mts +5 -0
- package/dist/client/frontendClient.d.ts +5 -0
- package/dist/client/frontendClient.js +40 -0
- package/dist/client/frontendClient.js.map +1 -0
- package/dist/client/frontendClient.mjs +19 -0
- package/dist/client/frontendClient.mjs.map +1 -0
- package/dist/client/index.d.mts +3 -0
- package/dist/client/index.d.ts +3 -0
- package/dist/client/index.js +29 -0
- package/dist/client/index.js.map +1 -0
- package/dist/client/index.mjs +5 -0
- package/dist/client/index.mjs.map +1 -0
- package/dist/client/useSession.d.mts +41 -0
- package/dist/client/useSession.d.ts +41 -0
- package/dist/client/useSession.js +79 -0
- package/dist/client/useSession.js.map +1 -0
- package/dist/client/useSession.mjs +54 -0
- package/dist/client/useSession.mjs.map +1 -0
- package/dist/index.d.mts +97 -21
- package/dist/index.d.ts +97 -21
- package/dist/index.js +718 -5691
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +712 -5687
- package/dist/index.mjs.map +1 -1
- package/dist/theme/default/index.css +295 -29
- package/dist/theme/default/index.css.map +1 -1
- package/dist/theme/default/index.d.mts +3 -3
- package/dist/theme/default/index.d.ts +3 -3
- package/dist/theme/default/index.js +1058 -292
- package/dist/theme/default/index.js.map +1 -1
- package/dist/theme/default/index.mjs +1030 -256
- package/dist/theme/default/index.mjs.map +1 -1
- package/jest.config.ts +4 -3
- package/package.json +17 -8
- package/tailwind.config.ts +6 -1
- package/tsconfig.json +5 -5
|
@@ -41,11 +41,11 @@ __export(default_exports, {
|
|
|
41
41
|
DefaultMessageContainer: () => DefaultMessageContainer,
|
|
42
42
|
Error: () => Error2,
|
|
43
43
|
Login: () => Login,
|
|
44
|
-
OryDefaultComponents: () => OryDefaultComponents,
|
|
45
44
|
Recovery: () => Recovery,
|
|
46
45
|
Registration: () => Registration,
|
|
47
46
|
Settings: () => Settings,
|
|
48
|
-
Verification: () => Verification
|
|
47
|
+
Verification: () => Verification,
|
|
48
|
+
getOryComponents: () => getOryComponents
|
|
49
49
|
});
|
|
50
50
|
module.exports = __toCommonJS(default_exports);
|
|
51
51
|
|
|
@@ -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
|
] }) });
|
|
@@ -394,6 +388,7 @@ function cn(...inputs) {
|
|
|
394
388
|
// src/theme/default/components/form/index.tsx
|
|
395
389
|
var import_react_intl3 = require("react-intl");
|
|
396
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)();
|
|
@@ -473,6 +477,11 @@ var SvgWebauthn = (props) => {
|
|
|
473
477
|
};
|
|
474
478
|
var webauthn_default = SvgWebauthn;
|
|
475
479
|
|
|
480
|
+
// src/theme/default/utils/form.ts
|
|
481
|
+
function isGroupImmediateSubmit(group) {
|
|
482
|
+
return group === "code";
|
|
483
|
+
}
|
|
484
|
+
|
|
476
485
|
// src/theme/default/components/card/auth-methods.tsx
|
|
477
486
|
var import_jsx_runtime13 = require("react/jsx-runtime");
|
|
478
487
|
var iconsMap = {
|
|
@@ -490,8 +499,9 @@ function DefaultAuthMethodListItem({
|
|
|
490
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)(
|
|
491
500
|
"button",
|
|
492
501
|
{
|
|
493
|
-
className: "flex text-left py-2 gap-3 cursor-pointer
|
|
502
|
+
className: "flex text-left py-2 gap-3 cursor-pointer",
|
|
494
503
|
onClick,
|
|
504
|
+
type: isGroupImmediateSubmit(group) ? "submit" : "button",
|
|
495
505
|
children: [
|
|
496
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" }) }),
|
|
497
507
|
/* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: "flex-1 text-sm leading-normal", children: [
|
|
@@ -504,7 +514,7 @@ function DefaultAuthMethodListItem({
|
|
|
504
514
|
}
|
|
505
515
|
|
|
506
516
|
// src/theme/default/components/form/button.tsx
|
|
507
|
-
var
|
|
517
|
+
var import_client_fetch4 = require("@ory/client-fetch");
|
|
508
518
|
var import_elements_react5 = require("@ory/elements-react");
|
|
509
519
|
var import_react_hook_form = require("react-hook-form");
|
|
510
520
|
var import_react_intl5 = require("react-intl");
|
|
@@ -518,7 +528,7 @@ function Spinner({ className }) {
|
|
|
518
528
|
"aria-hidden": "true",
|
|
519
529
|
role: "status",
|
|
520
530
|
className: cn(
|
|
521
|
-
"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",
|
|
522
532
|
className
|
|
523
533
|
),
|
|
524
534
|
viewBox: "0 0 34 34",
|
|
@@ -549,12 +559,50 @@ function Spinner({ className }) {
|
|
|
549
559
|
}
|
|
550
560
|
|
|
551
561
|
// src/theme/default/components/form/button.tsx
|
|
562
|
+
var import_elements_react6 = require("@ory/elements-react");
|
|
563
|
+
var import_class_variance_authority = require("class-variance-authority");
|
|
552
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
|
+
);
|
|
553
600
|
var DefaultButton = ({
|
|
554
601
|
attributes,
|
|
555
602
|
node,
|
|
556
603
|
onClick
|
|
557
604
|
}) => {
|
|
605
|
+
var _a;
|
|
558
606
|
const {
|
|
559
607
|
type,
|
|
560
608
|
name,
|
|
@@ -567,12 +615,14 @@ var DefaultButton = ({
|
|
|
567
615
|
...rest
|
|
568
616
|
} = attributes;
|
|
569
617
|
const intl = (0, import_react_intl5.useIntl)();
|
|
570
|
-
const label = (0,
|
|
618
|
+
const label = (0, import_client_fetch4.getNodeLabel)(node);
|
|
619
|
+
const { flowType } = (0, import_elements_react6.useOryFlow)();
|
|
571
620
|
const {
|
|
572
621
|
formState: { isSubmitting },
|
|
573
622
|
setValue
|
|
574
623
|
} = (0, import_react_hook_form.useFormContext)();
|
|
575
|
-
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";
|
|
576
626
|
return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
|
|
577
627
|
"button",
|
|
578
628
|
{
|
|
@@ -584,38 +634,20 @@ var DefaultButton = ({
|
|
|
584
634
|
setValue(name, value);
|
|
585
635
|
},
|
|
586
636
|
onClick: (e) => {
|
|
587
|
-
|
|
588
|
-
onClick(e);
|
|
589
|
-
}
|
|
637
|
+
onClick == null ? void 0 : onClick(e);
|
|
590
638
|
if (type !== "button") {
|
|
591
639
|
setValue(name, value);
|
|
592
640
|
}
|
|
593
641
|
},
|
|
594
|
-
className:
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
"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
|
|
601
|
-
},
|
|
602
|
-
{}
|
|
603
|
-
),
|
|
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,
|
|
604
648
|
children: [
|
|
605
649
|
isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Spinner, {}) : null,
|
|
606
|
-
|
|
607
|
-
"span",
|
|
608
|
-
{
|
|
609
|
-
className: cn(
|
|
610
|
-
"transition-colors ease-linear duration-100 leading-none text-button-primary-fg-default/20",
|
|
611
|
-
{
|
|
612
|
-
"text-button-primary-fg-default opacity-20 transition-opacity": isSubmitting && isPrimary,
|
|
613
|
-
"text-button-secondary-fg-default/20": isSubmitting && !isPrimary
|
|
614
|
-
}
|
|
615
|
-
),
|
|
616
|
-
children: label ? (0, import_elements_react5.uiTextToFormattedMessage)(label, intl) : ""
|
|
617
|
-
}
|
|
618
|
-
)
|
|
650
|
+
label ? (0, import_elements_react5.uiTextToFormattedMessage)(label, intl) : ""
|
|
619
651
|
]
|
|
620
652
|
}
|
|
621
653
|
);
|
|
@@ -623,14 +655,112 @@ var DefaultButton = ({
|
|
|
623
655
|
DefaultButton.displayName = "DefaultButton";
|
|
624
656
|
|
|
625
657
|
// src/theme/default/components/form/checkbox.tsx
|
|
626
|
-
var
|
|
627
|
-
var
|
|
658
|
+
var import_client_fetch5 = require("@ory/client-fetch");
|
|
659
|
+
var import_elements_react7 = require("@ory/elements-react");
|
|
628
660
|
var import_react = require("react");
|
|
629
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
|
|
630
665
|
var import_react_intl6 = require("react-intl");
|
|
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
|
|
631
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");
|
|
632
762
|
function CheckboxSVG() {
|
|
633
|
-
return /* @__PURE__ */ (0,
|
|
763
|
+
return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
|
|
634
764
|
"svg",
|
|
635
765
|
{
|
|
636
766
|
className: "absolute w-4 h-4 hidden peer-checked:block",
|
|
@@ -640,14 +770,14 @@ function CheckboxSVG() {
|
|
|
640
770
|
viewBox: "0 0 16 16",
|
|
641
771
|
fill: "none",
|
|
642
772
|
children: [
|
|
643
|
-
/* @__PURE__ */ (0,
|
|
773
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
644
774
|
"path",
|
|
645
775
|
{
|
|
646
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",
|
|
647
777
|
fill: "#0F172A"
|
|
648
778
|
}
|
|
649
779
|
),
|
|
650
|
-
/* @__PURE__ */ (0,
|
|
780
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
651
781
|
"path",
|
|
652
782
|
{
|
|
653
783
|
fillRule: "evenodd",
|
|
@@ -670,14 +800,15 @@ var DefaultCheckbox = ({
|
|
|
670
800
|
// Button does not support these attributes, so we skip them
|
|
671
801
|
autocomplete: _autocomplete,
|
|
672
802
|
onclick: _onclick,
|
|
803
|
+
maxlength: _max,
|
|
673
804
|
// End of skipped attributes
|
|
674
805
|
...attributes
|
|
675
806
|
} = initialAttributes;
|
|
676
|
-
const intl = (0,
|
|
677
|
-
const label = (0,
|
|
807
|
+
const intl = (0, import_react_intl7.useIntl)();
|
|
808
|
+
const label = (0, import_client_fetch5.getNodeLabel)(node);
|
|
678
809
|
const [checked, setChecked] = (0, import_react.useState)(Boolean(value));
|
|
679
810
|
const { register } = (0, import_react_hook_form2.useForm)();
|
|
680
|
-
return /* @__PURE__ */ (0,
|
|
811
|
+
return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
|
|
681
812
|
"div",
|
|
682
813
|
{
|
|
683
814
|
className: "flex antialiased gap-3 self-stretch item-start",
|
|
@@ -685,8 +816,8 @@ var DefaultCheckbox = ({
|
|
|
685
816
|
setChecked(!checked);
|
|
686
817
|
},
|
|
687
818
|
children: [
|
|
688
|
-
/* @__PURE__ */ (0,
|
|
689
|
-
/* @__PURE__ */ (0,
|
|
819
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsxs)("div", { className: "flex h-5 items-center", children: [
|
|
820
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
690
821
|
"input",
|
|
691
822
|
{
|
|
692
823
|
...attributes,
|
|
@@ -701,16 +832,16 @@ var DefaultCheckbox = ({
|
|
|
701
832
|
...register(name, { value })
|
|
702
833
|
}
|
|
703
834
|
),
|
|
704
|
-
/* @__PURE__ */ (0,
|
|
835
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(CheckboxSVG, {})
|
|
705
836
|
] }),
|
|
706
|
-
/* @__PURE__ */ (0,
|
|
707
|
-
/* @__PURE__ */ (0,
|
|
708
|
-
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)(
|
|
709
840
|
"span",
|
|
710
841
|
{
|
|
711
842
|
className: "text-sm text-red-900 mt-1",
|
|
712
|
-
...(0,
|
|
713
|
-
children: (0,
|
|
843
|
+
...(0, import_elements_react7.messageTestId)(message),
|
|
844
|
+
children: (0, import_elements_react7.uiTextToFormattedMessage)(message, intl)
|
|
714
845
|
},
|
|
715
846
|
message.id
|
|
716
847
|
))
|
|
@@ -721,48 +852,49 @@ var DefaultCheckbox = ({
|
|
|
721
852
|
};
|
|
722
853
|
|
|
723
854
|
// src/theme/default/components/form/group-container.tsx
|
|
724
|
-
var
|
|
855
|
+
var import_jsx_runtime18 = require("react/jsx-runtime");
|
|
725
856
|
function DefaultGroupContainer({ children }) {
|
|
726
|
-
return /* @__PURE__ */ (0,
|
|
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)();
|
|
887
|
+
const { flowType } = (0, import_elements_react8.useOryFlow)();
|
|
756
888
|
const formattedLabel = label ? intl.formatMessage(
|
|
757
889
|
{
|
|
758
890
|
id: "input.placeholder",
|
|
759
891
|
defaultMessage: "Enter your {placeholder}"
|
|
760
892
|
},
|
|
761
893
|
{
|
|
762
|
-
placeholder: (0,
|
|
894
|
+
placeholder: (0, import_elements_react8.uiTextToFormattedMessage)(label, intl)
|
|
763
895
|
}
|
|
764
896
|
) : "";
|
|
765
|
-
return /* @__PURE__ */ (0,
|
|
897
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
|
|
766
898
|
"input",
|
|
767
899
|
{
|
|
768
900
|
...rest,
|
|
@@ -770,42 +902,47 @@ var DefaultInput = ({
|
|
|
770
902
|
maxLength: maxlength,
|
|
771
903
|
autoComplete: autocomplete,
|
|
772
904
|
placeholder: formattedLabel,
|
|
773
|
-
className:
|
|
905
|
+
className: cn(
|
|
906
|
+
"antialiased disabled:text-forms-fg-disabled disabled:bg-forms-bg-disabled bg-forms-bg-default rounded-border-radius-forms border border-forms-border-default leading-tight hover:border-forms-border-hover transition-colors text-sm",
|
|
907
|
+
"px-3 py-2.5",
|
|
908
|
+
// The settings flow input fields are supposed to be dense, so we don't need the extra padding we want on the user flows.
|
|
909
|
+
flowType === import_client_fetch6.FlowType.Settings ? "max-w-[488px]" : "md:px-4 md:py-4"
|
|
910
|
+
),
|
|
774
911
|
...register(name, { value })
|
|
775
912
|
}
|
|
776
913
|
);
|
|
777
914
|
};
|
|
778
915
|
|
|
779
916
|
// src/theme/default/components/form/label.tsx
|
|
780
|
-
var
|
|
781
|
-
var
|
|
782
|
-
var
|
|
783
|
-
var
|
|
917
|
+
var import_client_fetch7 = require("@ory/client-fetch");
|
|
918
|
+
var import_elements_react9 = require("@ory/elements-react");
|
|
919
|
+
var import_react_intl9 = require("react-intl");
|
|
920
|
+
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
784
921
|
function DefaultLabel({
|
|
785
922
|
node,
|
|
786
923
|
children,
|
|
787
924
|
attributes,
|
|
788
925
|
...rest
|
|
789
926
|
}) {
|
|
790
|
-
const intl = (0,
|
|
791
|
-
const label = (0,
|
|
792
|
-
const { config, flowType } = (0,
|
|
927
|
+
const intl = (0, import_react_intl9.useIntl)();
|
|
928
|
+
const label = (0, import_client_fetch7.getNodeLabel)(node);
|
|
929
|
+
const { config, flowType } = (0, import_elements_react9.useOryFlow)();
|
|
793
930
|
const isPassword = attributes.type === "password";
|
|
794
931
|
const isCode = attributes.name === "code";
|
|
795
|
-
return /* @__PURE__ */ (0,
|
|
796
|
-
label && /* @__PURE__ */ (0,
|
|
797
|
-
/* @__PURE__ */ (0,
|
|
932
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("span", { className: "flex flex-col antialiased gap-1", children: [
|
|
933
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("span", { className: "inline-flex justify-between", children: [
|
|
934
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
798
935
|
"label",
|
|
799
936
|
{
|
|
800
|
-
...(0,
|
|
937
|
+
...(0, import_elements_react9.messageTestId)(label),
|
|
801
938
|
className: "text-sm font-medium leading-normal",
|
|
802
939
|
htmlFor: attributes.name,
|
|
803
940
|
...rest,
|
|
804
|
-
children: (0,
|
|
941
|
+
children: (0, import_elements_react9.uiTextToFormattedMessage)(label, intl)
|
|
805
942
|
}
|
|
806
943
|
),
|
|
807
|
-
isPassword && config.project.recovery_enabled && flowType ===
|
|
808
|
-
/* @__PURE__ */ (0,
|
|
944
|
+
isPassword && config.project.recovery_enabled && flowType === import_client_fetch7.FlowType.Login && // TODO: make it possible to override with a custom component
|
|
945
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
809
946
|
"a",
|
|
810
947
|
{
|
|
811
948
|
href: config.project.recovery_ui_url,
|
|
@@ -816,17 +953,19 @@ function DefaultLabel({
|
|
|
816
953
|
})
|
|
817
954
|
}
|
|
818
955
|
),
|
|
819
|
-
isCode && /* @__PURE__ */ (0,
|
|
820
|
-
"
|
|
956
|
+
isCode && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
957
|
+
"button",
|
|
821
958
|
{
|
|
822
959
|
type: "submit",
|
|
823
|
-
|
|
824
|
-
|
|
960
|
+
name: "method",
|
|
961
|
+
value: "code",
|
|
962
|
+
className: "text-links-link-default hover:underline hover:text-link-hover transition-colors text-sm font-medium cursor-pointer",
|
|
963
|
+
children: intl.formatMessage({ id: "identities.messages.1070008" })
|
|
825
964
|
}
|
|
826
965
|
)
|
|
827
966
|
] }),
|
|
828
967
|
children,
|
|
829
|
-
node.messages.map((message) => /* @__PURE__ */ (0,
|
|
968
|
+
node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
830
969
|
"span",
|
|
831
970
|
{
|
|
832
971
|
className: cn("text-sm leading-normal", {
|
|
@@ -834,8 +973,8 @@ function DefaultLabel({
|
|
|
834
973
|
"text-forms-fg-default": message.type === "info",
|
|
835
974
|
"text-forms-fg-success": message.type === "success"
|
|
836
975
|
}),
|
|
837
|
-
...(0,
|
|
838
|
-
children: (0,
|
|
976
|
+
...(0, import_elements_react9.messageTestId)(message),
|
|
977
|
+
children: (0, import_elements_react9.uiTextToFormattedMessage)(message, intl)
|
|
839
978
|
},
|
|
840
979
|
message.id
|
|
841
980
|
))
|
|
@@ -843,24 +982,24 @@ function DefaultLabel({
|
|
|
843
982
|
}
|
|
844
983
|
|
|
845
984
|
// src/theme/default/components/form/link-button.tsx
|
|
846
|
-
var
|
|
847
|
-
var
|
|
985
|
+
var import_client_fetch8 = require("@ory/client-fetch");
|
|
986
|
+
var import_elements_react10 = require("@ory/elements-react");
|
|
848
987
|
var import_react2 = require("react");
|
|
849
|
-
var
|
|
850
|
-
var
|
|
988
|
+
var import_react_intl10 = require("react-intl");
|
|
989
|
+
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
851
990
|
var DefaultLinkButton = (0, import_react2.forwardRef)(({ attributes, node }, ref) => {
|
|
852
|
-
const intl = (0,
|
|
853
|
-
const label = (0,
|
|
854
|
-
return /* @__PURE__ */ (0,
|
|
991
|
+
const intl = (0, import_react_intl10.useIntl)();
|
|
992
|
+
const label = (0, import_client_fetch8.getNodeLabel)(node);
|
|
993
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
855
994
|
"a",
|
|
856
995
|
{
|
|
857
996
|
...attributes,
|
|
858
997
|
ref,
|
|
859
|
-
title: label ? (0,
|
|
998
|
+
title: label ? (0, import_elements_react10.uiTextToFormattedMessage)(label, intl) : "",
|
|
860
999
|
className: cn(
|
|
861
1000
|
"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"
|
|
862
1001
|
),
|
|
863
|
-
children: label ? (0,
|
|
1002
|
+
children: label ? (0, import_elements_react10.uiTextToFormattedMessage)(label, intl) : ""
|
|
864
1003
|
}
|
|
865
1004
|
);
|
|
866
1005
|
});
|
|
@@ -872,8 +1011,8 @@ var import_react_hook_form4 = require("react-hook-form");
|
|
|
872
1011
|
// src/theme/default/components/form/shadcn/otp-input.tsx
|
|
873
1012
|
var import_input_otp = require("input-otp");
|
|
874
1013
|
var React7 = __toESM(require("react"));
|
|
875
|
-
var
|
|
876
|
-
var InputOTP = React7.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ (0,
|
|
1014
|
+
var import_jsx_runtime24 = require("react/jsx-runtime");
|
|
1015
|
+
var InputOTP = React7.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
877
1016
|
import_input_otp.OTPInput,
|
|
878
1017
|
{
|
|
879
1018
|
ref,
|
|
@@ -886,12 +1025,12 @@ var InputOTP = React7.forwardRef(({ className, containerClassName, ...props }, r
|
|
|
886
1025
|
}
|
|
887
1026
|
));
|
|
888
1027
|
InputOTP.displayName = "InputOTP";
|
|
889
|
-
var InputOTPGroup = React7.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
1028
|
+
var InputOTPGroup = React7.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { ref, className: cn("flex items-center", className), ...props }));
|
|
890
1029
|
InputOTPGroup.displayName = "InputOTPGroup";
|
|
891
1030
|
var InputOTPSlot = React7.forwardRef(({ index, className, ...props }, ref) => {
|
|
892
1031
|
const inputOTPContext = React7.useContext(import_input_otp.OTPInputContext);
|
|
893
1032
|
const { char, hasFakeCaret, isActive } = inputOTPContext.slots[index];
|
|
894
|
-
return /* @__PURE__ */ (0,
|
|
1033
|
+
return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
|
|
895
1034
|
"div",
|
|
896
1035
|
{
|
|
897
1036
|
ref,
|
|
@@ -903,7 +1042,7 @@ var InputOTPSlot = React7.forwardRef(({ index, className, ...props }, ref) => {
|
|
|
903
1042
|
...props,
|
|
904
1043
|
children: [
|
|
905
1044
|
char,
|
|
906
|
-
hasFakeCaret && /* @__PURE__ */ (0,
|
|
1045
|
+
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" }) })
|
|
907
1046
|
]
|
|
908
1047
|
}
|
|
909
1048
|
);
|
|
@@ -911,7 +1050,7 @@ var InputOTPSlot = React7.forwardRef(({ index, className, ...props }, ref) => {
|
|
|
911
1050
|
InputOTPSlot.displayName = "InputOTPSlot";
|
|
912
1051
|
|
|
913
1052
|
// src/theme/default/components/form/pin-code-input.tsx
|
|
914
|
-
var
|
|
1053
|
+
var import_jsx_runtime25 = require("react/jsx-runtime");
|
|
915
1054
|
var DefaultPinCodeInput = ({ attributes }) => {
|
|
916
1055
|
const { setValue, watch } = (0, import_react_hook_form4.useFormContext)();
|
|
917
1056
|
const { maxlength, name } = attributes;
|
|
@@ -920,192 +1059,186 @@ var DefaultPinCodeInput = ({ attributes }) => {
|
|
|
920
1059
|
setValue(name, v);
|
|
921
1060
|
};
|
|
922
1061
|
const value = watch(name);
|
|
923
|
-
return /* @__PURE__ */ (0,
|
|
924
|
-
|
|
1062
|
+
return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
1063
|
+
InputOTP,
|
|
925
1064
|
{
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
1065
|
+
maxLength: maxlength != null ? maxlength : 6,
|
|
1066
|
+
onChange: handleInputChange,
|
|
1067
|
+
name,
|
|
1068
|
+
value,
|
|
1069
|
+
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)(
|
|
1070
|
+
InputOTPSlot,
|
|
929
1071
|
{
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
InputOTPSlot,
|
|
936
|
-
{
|
|
937
|
-
index,
|
|
938
|
-
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"
|
|
939
|
-
},
|
|
940
|
-
index
|
|
941
|
-
)) })
|
|
942
|
-
}
|
|
943
|
-
)
|
|
1072
|
+
index,
|
|
1073
|
+
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"
|
|
1074
|
+
},
|
|
1075
|
+
index
|
|
1076
|
+
)) })
|
|
944
1077
|
}
|
|
945
1078
|
);
|
|
946
1079
|
};
|
|
947
1080
|
|
|
948
1081
|
// src/theme/default/components/form/social.tsx
|
|
949
|
-
var
|
|
1082
|
+
var import_elements_react11 = require("@ory/elements-react");
|
|
950
1083
|
|
|
951
1084
|
// src/theme/default/provider-logos/apple.svg
|
|
952
1085
|
var React8 = __toESM(require("react"));
|
|
953
|
-
var
|
|
1086
|
+
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
954
1087
|
var SvgApple = (props) => {
|
|
955
1088
|
var _a, _b;
|
|
956
|
-
return /* @__PURE__ */ (0,
|
|
957
|
-
/* @__PURE__ */ (0,
|
|
958
|
-
/* @__PURE__ */ (0,
|
|
1089
|
+
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: [
|
|
1090
|
+
/* @__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" }),
|
|
1091
|
+
/* @__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" })
|
|
959
1092
|
] });
|
|
960
1093
|
};
|
|
961
1094
|
var apple_default = SvgApple;
|
|
962
1095
|
|
|
963
1096
|
// src/theme/default/provider-logos/auth0.svg
|
|
964
1097
|
var React9 = __toESM(require("react"));
|
|
965
|
-
var
|
|
1098
|
+
var import_jsx_runtime27 = require("react/jsx-runtime");
|
|
966
1099
|
var SvgAuth0 = (props) => {
|
|
967
1100
|
var _a, _b;
|
|
968
|
-
return /* @__PURE__ */ (0,
|
|
1101
|
+
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" }) });
|
|
969
1102
|
};
|
|
970
1103
|
var auth0_default = SvgAuth0;
|
|
971
1104
|
|
|
972
1105
|
// src/theme/default/provider-logos/discord.svg
|
|
973
1106
|
var React10 = __toESM(require("react"));
|
|
974
|
-
var
|
|
1107
|
+
var import_jsx_runtime28 = require("react/jsx-runtime");
|
|
975
1108
|
var SvgDiscord = (props) => {
|
|
976
1109
|
var _a, _b;
|
|
977
|
-
return /* @__PURE__ */ (0,
|
|
978
|
-
/* @__PURE__ */ (0,
|
|
979
|
-
/* @__PURE__ */ (0,
|
|
1110
|
+
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: [
|
|
1111
|
+
/* @__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" }),
|
|
1112
|
+
/* @__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" })
|
|
980
1113
|
] });
|
|
981
1114
|
};
|
|
982
1115
|
var discord_default = SvgDiscord;
|
|
983
1116
|
|
|
984
1117
|
// src/theme/default/provider-logos/facebook.svg
|
|
985
1118
|
var React11 = __toESM(require("react"));
|
|
986
|
-
var
|
|
1119
|
+
var import_jsx_runtime29 = require("react/jsx-runtime");
|
|
987
1120
|
var SvgFacebook = (props) => {
|
|
988
1121
|
var _a, _b;
|
|
989
|
-
return /* @__PURE__ */ (0,
|
|
990
|
-
/* @__PURE__ */ (0,
|
|
991
|
-
/* @__PURE__ */ (0,
|
|
992
|
-
/* @__PURE__ */ (0,
|
|
1122
|
+
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: [
|
|
1123
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("g", { clipPath: "url(#facebook_svg__a)", children: [
|
|
1124
|
+
/* @__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" }),
|
|
1125
|
+
/* @__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" })
|
|
993
1126
|
] }),
|
|
994
|
-
/* @__PURE__ */ (0,
|
|
1127
|
+
/* @__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" }) }) })
|
|
995
1128
|
] });
|
|
996
1129
|
};
|
|
997
1130
|
var facebook_default = SvgFacebook;
|
|
998
1131
|
|
|
999
1132
|
// src/theme/default/provider-logos/generic.svg
|
|
1000
1133
|
var React12 = __toESM(require("react"));
|
|
1001
|
-
var
|
|
1134
|
+
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
1002
1135
|
var SvgGeneric = (props) => {
|
|
1003
1136
|
var _a, _b;
|
|
1004
|
-
return /* @__PURE__ */ (0,
|
|
1005
|
-
/* @__PURE__ */ (0,
|
|
1006
|
-
/* @__PURE__ */ (0,
|
|
1007
|
-
/* @__PURE__ */ (0,
|
|
1137
|
+
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: [
|
|
1138
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)("path", { stroke: "none", d: "M0 0h24v24H0z" }),
|
|
1139
|
+
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)("path", { d: "M2 12a10 10 0 1 0 20 0 10 10 0 1 0-20 0" }),
|
|
1140
|
+
/* @__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" })
|
|
1008
1141
|
] });
|
|
1009
1142
|
};
|
|
1010
1143
|
var generic_default = SvgGeneric;
|
|
1011
1144
|
|
|
1012
1145
|
// src/theme/default/provider-logos/github.svg
|
|
1013
1146
|
var React13 = __toESM(require("react"));
|
|
1014
|
-
var
|
|
1147
|
+
var import_jsx_runtime31 = require("react/jsx-runtime");
|
|
1015
1148
|
var SvgGithub = (props) => {
|
|
1016
1149
|
var _a, _b;
|
|
1017
|
-
return /* @__PURE__ */ (0,
|
|
1150
|
+
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" }) });
|
|
1018
1151
|
};
|
|
1019
1152
|
var github_default = SvgGithub;
|
|
1020
1153
|
|
|
1021
1154
|
// src/theme/default/provider-logos/gitlab.svg
|
|
1022
1155
|
var React14 = __toESM(require("react"));
|
|
1023
|
-
var
|
|
1156
|
+
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
1024
1157
|
var SvgGitlab = (props) => {
|
|
1025
1158
|
var _a, _b;
|
|
1026
|
-
return /* @__PURE__ */ (0,
|
|
1027
|
-
/* @__PURE__ */ (0,
|
|
1028
|
-
/* @__PURE__ */ (0,
|
|
1029
|
-
/* @__PURE__ */ (0,
|
|
1030
|
-
/* @__PURE__ */ (0,
|
|
1159
|
+
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: [
|
|
1160
|
+
/* @__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" }),
|
|
1161
|
+
/* @__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" }),
|
|
1162
|
+
/* @__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" }),
|
|
1163
|
+
/* @__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" })
|
|
1031
1164
|
] });
|
|
1032
1165
|
};
|
|
1033
1166
|
var gitlab_default = SvgGitlab;
|
|
1034
1167
|
|
|
1035
1168
|
// src/theme/default/provider-logos/google.svg
|
|
1036
1169
|
var React15 = __toESM(require("react"));
|
|
1037
|
-
var
|
|
1170
|
+
var import_jsx_runtime33 = require("react/jsx-runtime");
|
|
1038
1171
|
var SvgGoogle = (props) => {
|
|
1039
1172
|
var _a, _b;
|
|
1040
|
-
return /* @__PURE__ */ (0,
|
|
1041
|
-
/* @__PURE__ */ (0,
|
|
1042
|
-
/* @__PURE__ */ (0,
|
|
1043
|
-
/* @__PURE__ */ (0,
|
|
1044
|
-
/* @__PURE__ */ (0,
|
|
1173
|
+
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: [
|
|
1174
|
+
/* @__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" }),
|
|
1175
|
+
/* @__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" }),
|
|
1176
|
+
/* @__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" }),
|
|
1177
|
+
/* @__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" })
|
|
1045
1178
|
] });
|
|
1046
1179
|
};
|
|
1047
1180
|
var google_default = SvgGoogle;
|
|
1048
1181
|
|
|
1049
1182
|
// src/theme/default/provider-logos/linkedin.svg
|
|
1050
1183
|
var React16 = __toESM(require("react"));
|
|
1051
|
-
var
|
|
1184
|
+
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
1052
1185
|
var SvgLinkedin = (props) => {
|
|
1053
1186
|
var _a, _b;
|
|
1054
|
-
return /* @__PURE__ */ (0,
|
|
1055
|
-
/* @__PURE__ */ (0,
|
|
1056
|
-
/* @__PURE__ */ (0,
|
|
1187
|
+
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: [
|
|
1188
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("rect", { x: 2, y: 2, fill: "#1275B1", rx: 14 }),
|
|
1189
|
+
/* @__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" })
|
|
1057
1190
|
] });
|
|
1058
1191
|
};
|
|
1059
1192
|
var linkedin_default = SvgLinkedin;
|
|
1060
1193
|
|
|
1061
1194
|
// src/theme/default/provider-logos/microsoft.svg
|
|
1062
1195
|
var React17 = __toESM(require("react"));
|
|
1063
|
-
var
|
|
1196
|
+
var import_jsx_runtime35 = require("react/jsx-runtime");
|
|
1064
1197
|
var SvgMicrosoft = (props) => {
|
|
1065
1198
|
var _a, _b;
|
|
1066
|
-
return /* @__PURE__ */ (0,
|
|
1067
|
-
/* @__PURE__ */ (0,
|
|
1068
|
-
/* @__PURE__ */ (0,
|
|
1069
|
-
/* @__PURE__ */ (0,
|
|
1070
|
-
/* @__PURE__ */ (0,
|
|
1199
|
+
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: [
|
|
1200
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("path", { fill: "#F35325", d: "M1 1h10v10H1z" }),
|
|
1201
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("path", { fill: "#81BC06", d: "M12 1h10v10H12z" }),
|
|
1202
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("path", { fill: "#05A6F0", d: "M1 12h10v10H1z" }),
|
|
1203
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)("path", { fill: "#FFBA08", d: "M12 12h10v10H12z" })
|
|
1071
1204
|
] });
|
|
1072
1205
|
};
|
|
1073
1206
|
var microsoft_default = SvgMicrosoft;
|
|
1074
1207
|
|
|
1075
1208
|
// src/theme/default/provider-logos/slack.svg
|
|
1076
1209
|
var React18 = __toESM(require("react"));
|
|
1077
|
-
var
|
|
1210
|
+
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
1078
1211
|
var SvgSlack = (props) => {
|
|
1079
1212
|
var _a, _b;
|
|
1080
|
-
return /* @__PURE__ */ (0,
|
|
1081
|
-
/* @__PURE__ */ (0,
|
|
1082
|
-
/* @__PURE__ */ (0,
|
|
1083
|
-
/* @__PURE__ */ (0,
|
|
1084
|
-
/* @__PURE__ */ (0,
|
|
1213
|
+
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: [
|
|
1214
|
+
/* @__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" }),
|
|
1215
|
+
/* @__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" }),
|
|
1216
|
+
/* @__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" }),
|
|
1217
|
+
/* @__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" })
|
|
1085
1218
|
] });
|
|
1086
1219
|
};
|
|
1087
1220
|
var slack_default = SvgSlack;
|
|
1088
1221
|
|
|
1089
1222
|
// src/theme/default/provider-logos/spotify.svg
|
|
1090
1223
|
var React19 = __toESM(require("react"));
|
|
1091
|
-
var
|
|
1224
|
+
var import_jsx_runtime37 = require("react/jsx-runtime");
|
|
1092
1225
|
var SvgSpotify = (props) => {
|
|
1093
1226
|
var _a, _b;
|
|
1094
|
-
return /* @__PURE__ */ (0,
|
|
1095
|
-
/* @__PURE__ */ (0,
|
|
1096
|
-
/* @__PURE__ */ (0,
|
|
1227
|
+
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: [
|
|
1228
|
+
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)("circle", { cx: 16, cy: 16, r: 14, fill: "#1ED760" }),
|
|
1229
|
+
/* @__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" })
|
|
1097
1230
|
] });
|
|
1098
1231
|
};
|
|
1099
1232
|
var spotify_default = SvgSpotify;
|
|
1100
1233
|
|
|
1101
1234
|
// src/theme/default/provider-logos/yandex.svg
|
|
1102
1235
|
var React20 = __toESM(require("react"));
|
|
1103
|
-
var
|
|
1236
|
+
var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
1104
1237
|
var SvgYandex = (props) => {
|
|
1105
1238
|
var _a, _b;
|
|
1106
|
-
return /* @__PURE__ */ (0,
|
|
1107
|
-
/* @__PURE__ */ (0,
|
|
1108
|
-
/* @__PURE__ */ (0,
|
|
1239
|
+
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: [
|
|
1240
|
+
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)("circle", { cx: 16, cy: 16, r: 14, fill: "#fff" }),
|
|
1241
|
+
/* @__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" })
|
|
1109
1242
|
] });
|
|
1110
1243
|
};
|
|
1111
1244
|
var yandex_default = SvgYandex;
|
|
@@ -1129,8 +1262,8 @@ var logos = {
|
|
|
1129
1262
|
var provider_logos_default = logos;
|
|
1130
1263
|
|
|
1131
1264
|
// src/theme/default/components/form/social.tsx
|
|
1132
|
-
var
|
|
1133
|
-
var
|
|
1265
|
+
var import_react_intl11 = require("react-intl");
|
|
1266
|
+
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
1134
1267
|
function extractProvider(context) {
|
|
1135
1268
|
if (context && typeof context === "object" && "provider" in context && typeof context.provider === "string") {
|
|
1136
1269
|
return context.provider;
|
|
@@ -1140,7 +1273,8 @@ function extractProvider(context) {
|
|
|
1140
1273
|
function DefaultButtonSocial({
|
|
1141
1274
|
attributes,
|
|
1142
1275
|
node,
|
|
1143
|
-
onClick
|
|
1276
|
+
onClick,
|
|
1277
|
+
showLabel: _showLabel
|
|
1144
1278
|
}) {
|
|
1145
1279
|
var _a, _b, _c;
|
|
1146
1280
|
const {
|
|
@@ -1151,13 +1285,13 @@ function DefaultButtonSocial({
|
|
|
1151
1285
|
} = attributes;
|
|
1152
1286
|
const {
|
|
1153
1287
|
flow: { ui }
|
|
1154
|
-
} = (0,
|
|
1155
|
-
const intl = (0,
|
|
1288
|
+
} = (0, import_elements_react11.useOryFlow)();
|
|
1289
|
+
const intl = (0, import_react_intl11.useIntl)();
|
|
1156
1290
|
const oidcNodeCount = (_a = ui.nodes.filter((node2) => node2.group === "oidc").length) != null ? _a : 0;
|
|
1157
1291
|
const Logo = provider_logos_default[attributes.value];
|
|
1158
|
-
const showLabel = oidcNodeCount % 3 !== 0 && oidcNodeCount % 4 !== 0;
|
|
1292
|
+
const showLabel = _showLabel != null ? _showLabel : oidcNodeCount % 3 !== 0 && oidcNodeCount % 4 !== 0;
|
|
1159
1293
|
const provider = (_c = extractProvider((_b = node.meta.label) == null ? void 0 : _b.context)) != null ? _c : "";
|
|
1160
|
-
return /* @__PURE__ */ (0,
|
|
1294
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
|
|
1161
1295
|
"button",
|
|
1162
1296
|
{
|
|
1163
1297
|
className: cn(
|
|
@@ -1170,14 +1304,14 @@ function DefaultButtonSocial({
|
|
|
1170
1304
|
...props,
|
|
1171
1305
|
onClick,
|
|
1172
1306
|
children: [
|
|
1173
|
-
/* @__PURE__ */ (0,
|
|
1307
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "w-5 h-5", children: Logo ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
1174
1308
|
Logo,
|
|
1175
1309
|
{
|
|
1176
1310
|
size: 20,
|
|
1177
1311
|
className: "object-fill w-full h-full"
|
|
1178
1312
|
}
|
|
1179
|
-
) : /* @__PURE__ */ (0,
|
|
1180
|
-
showLabel && node.meta.label ? /* @__PURE__ */ (0,
|
|
1313
|
+
) : /* @__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) }) }),
|
|
1314
|
+
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
|
|
1181
1315
|
]
|
|
1182
1316
|
}
|
|
1183
1317
|
);
|
|
@@ -1186,7 +1320,7 @@ function DefaultSocialButtonContainer({
|
|
|
1186
1320
|
children,
|
|
1187
1321
|
nodes
|
|
1188
1322
|
}) {
|
|
1189
|
-
return /* @__PURE__ */ (0,
|
|
1323
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
1190
1324
|
"div",
|
|
1191
1325
|
{
|
|
1192
1326
|
className: cn("grid gap-3", {
|
|
@@ -1201,29 +1335,29 @@ function DefaultSocialButtonContainer({
|
|
|
1201
1335
|
}
|
|
1202
1336
|
|
|
1203
1337
|
// src/theme/default/components/form/text.tsx
|
|
1204
|
-
var
|
|
1205
|
-
var
|
|
1206
|
-
var
|
|
1338
|
+
var import_elements_react12 = require("@ory/elements-react");
|
|
1339
|
+
var import_react_intl12 = require("react-intl");
|
|
1340
|
+
var import_jsx_runtime40 = require("react/jsx-runtime");
|
|
1207
1341
|
function DefaultText({ node, attributes }) {
|
|
1208
1342
|
var _a;
|
|
1209
|
-
const intl = (0,
|
|
1210
|
-
return /* @__PURE__ */ (0,
|
|
1211
|
-
/* @__PURE__ */ (0,
|
|
1212
|
-
(_a = attributes.text.context.secrets) == null ? void 0 : _a.map((text, index) => /* @__PURE__ */ (0,
|
|
1343
|
+
const intl = (0, import_react_intl12.useIntl)();
|
|
1344
|
+
return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_jsx_runtime40.Fragment, { children: [
|
|
1345
|
+
/* @__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) : "" }),
|
|
1346
|
+
(_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))
|
|
1213
1347
|
] });
|
|
1214
1348
|
}
|
|
1215
1349
|
|
|
1216
1350
|
// src/theme/default/assets/icons/arrow-left.svg
|
|
1217
1351
|
var React21 = __toESM(require("react"));
|
|
1218
|
-
var
|
|
1352
|
+
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
1219
1353
|
var SvgArrowLeft = (props) => {
|
|
1220
1354
|
var _a, _b;
|
|
1221
|
-
return /* @__PURE__ */ (0,
|
|
1355
|
+
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" }) });
|
|
1222
1356
|
};
|
|
1223
1357
|
var arrow_left_default = SvgArrowLeft;
|
|
1224
1358
|
|
|
1225
1359
|
// src/theme/default/components/card/current-identifier-button.tsx
|
|
1226
|
-
var
|
|
1360
|
+
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
1227
1361
|
function DefaultCurrentIdentifierButton({
|
|
1228
1362
|
attributes,
|
|
1229
1363
|
onClick,
|
|
@@ -1231,7 +1365,7 @@ function DefaultCurrentIdentifierButton({
|
|
|
1231
1365
|
href
|
|
1232
1366
|
}) {
|
|
1233
1367
|
const Element = onClick ? "button" : "a";
|
|
1234
|
-
return /* @__PURE__ */ (0,
|
|
1368
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
|
|
1235
1369
|
Element,
|
|
1236
1370
|
{
|
|
1237
1371
|
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",
|
|
@@ -1240,172 +1374,804 @@ function DefaultCurrentIdentifierButton({
|
|
|
1240
1374
|
href,
|
|
1241
1375
|
type,
|
|
1242
1376
|
children: [
|
|
1243
|
-
/* @__PURE__ */ (0,
|
|
1244
|
-
/* @__PURE__ */ (0,
|
|
1377
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)(arrow_left_default, { size: 16, className: "text-button-identifier-fg-subtle" }),
|
|
1378
|
+
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "text-sm font-medium leading-none text-button-identifier-fg-default", children: attributes.value })
|
|
1245
1379
|
]
|
|
1246
1380
|
}
|
|
1247
1381
|
) });
|
|
1248
1382
|
}
|
|
1249
1383
|
|
|
1250
|
-
// src/theme/default/components/
|
|
1251
|
-
var
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
}
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1384
|
+
// src/theme/default/components/form/section.tsx
|
|
1385
|
+
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
1386
|
+
var DefaultFormSection = ({ children }) => {
|
|
1387
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "flex flex-col w-80 md:w-[712px] lg:w-[802px] xl:w-[896px]", children });
|
|
1388
|
+
};
|
|
1389
|
+
var DefaultFormSectionContent = ({
|
|
1390
|
+
title,
|
|
1391
|
+
description,
|
|
1392
|
+
children
|
|
1393
|
+
}) => {
|
|
1394
|
+
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: [
|
|
1395
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "flex flex-col gap-2", children: [
|
|
1396
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("h3", { className: "font-medium text-dialog-fg-default", children: title }),
|
|
1397
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "text-sm text-dialog-fg-subtle", children: description })
|
|
1398
|
+
] }),
|
|
1399
|
+
children
|
|
1400
|
+
] });
|
|
1401
|
+
};
|
|
1402
|
+
var DefaultFormSectionFooter = ({ children }) => {
|
|
1403
|
+
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 });
|
|
1404
|
+
};
|
|
1405
|
+
|
|
1406
|
+
// src/theme/default/assets/icons/download.svg
|
|
1407
|
+
var React22 = __toESM(require("react"));
|
|
1408
|
+
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
1409
|
+
var SvgDownload = (props) => {
|
|
1410
|
+
var _a, _b;
|
|
1411
|
+
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" }) });
|
|
1412
|
+
};
|
|
1413
|
+
var download_default = SvgDownload;
|
|
1414
|
+
|
|
1415
|
+
// src/theme/default/assets/icons/eye.svg
|
|
1416
|
+
var React23 = __toESM(require("react"));
|
|
1417
|
+
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
1418
|
+
var SvgEye = (props) => {
|
|
1419
|
+
var _a, _b;
|
|
1420
|
+
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: [
|
|
1421
|
+
/* @__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" }),
|
|
1422
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("path", { stroke: "#64748B", d: "M21 12q-3.6 6-9 6t-9-6q3.6-6 9-6t9 6" })
|
|
1423
|
+
] }) });
|
|
1424
|
+
};
|
|
1425
|
+
var eye_default = SvgEye;
|
|
1426
|
+
|
|
1427
|
+
// src/theme/default/assets/icons/refresh.svg
|
|
1428
|
+
var React24 = __toESM(require("react"));
|
|
1429
|
+
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
1430
|
+
var SvgRefresh = (props) => {
|
|
1431
|
+
var _a, _b;
|
|
1432
|
+
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" }) });
|
|
1433
|
+
};
|
|
1434
|
+
var refresh_default = SvgRefresh;
|
|
1435
|
+
|
|
1436
|
+
// src/theme/default/components/settings/settings-recovery-codes.tsx
|
|
1437
|
+
var import_jsx_runtime47 = require("react/jsx-runtime");
|
|
1438
|
+
function DefaultSettingsRecoveryCodes({
|
|
1439
|
+
codes,
|
|
1440
|
+
regnerateButton,
|
|
1441
|
+
revealButton
|
|
1442
|
+
}) {
|
|
1443
|
+
const onDownload = () => {
|
|
1444
|
+
const element = document.createElement("a");
|
|
1445
|
+
const file = new Blob([codes.join("\n")], {
|
|
1446
|
+
type: "text/plain"
|
|
1447
|
+
});
|
|
1448
|
+
element.href = URL.createObjectURL(file);
|
|
1449
|
+
element.download = "recovery-codes.txt";
|
|
1450
|
+
document.body.appendChild(element);
|
|
1451
|
+
element.click();
|
|
1452
|
+
};
|
|
1453
|
+
const hasCodes = codes.length >= 1;
|
|
1454
|
+
return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1455
|
+
/* @__PURE__ */ (0, import_jsx_runtime47.jsx)(DefaultHorizontalDivider, {}),
|
|
1456
|
+
/* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex justify-end gap-4", children: [
|
|
1457
|
+
regnerateButton && /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1458
|
+
"button",
|
|
1459
|
+
{
|
|
1460
|
+
...regnerateButton.attributes,
|
|
1461
|
+
type: "submit",
|
|
1462
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1463
|
+
refresh_default,
|
|
1464
|
+
{
|
|
1465
|
+
size: 24,
|
|
1466
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
1467
|
+
}
|
|
1468
|
+
)
|
|
1469
|
+
}
|
|
1470
|
+
),
|
|
1471
|
+
revealButton && /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1472
|
+
"button",
|
|
1473
|
+
{
|
|
1474
|
+
...revealButton.attributes,
|
|
1475
|
+
type: "submit",
|
|
1476
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1477
|
+
eye_default,
|
|
1478
|
+
{
|
|
1479
|
+
size: 24,
|
|
1480
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
1481
|
+
}
|
|
1482
|
+
)
|
|
1483
|
+
}
|
|
1484
|
+
),
|
|
1485
|
+
hasCodes ? /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1486
|
+
download_default,
|
|
1487
|
+
{
|
|
1488
|
+
size: 24,
|
|
1489
|
+
onClick: onDownload,
|
|
1490
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
1491
|
+
}
|
|
1492
|
+
) : null
|
|
1493
|
+
] }),
|
|
1494
|
+
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
|
|
1495
|
+
] });
|
|
1496
|
+
}
|
|
1497
|
+
|
|
1498
|
+
// src/theme/default/assets/icons/qrcode.svg
|
|
1499
|
+
var React25 = __toESM(require("react"));
|
|
1500
|
+
var import_jsx_runtime48 = require("react/jsx-runtime");
|
|
1501
|
+
var SvgQrcode = (props) => {
|
|
1502
|
+
var _a, _b;
|
|
1503
|
+
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" }) });
|
|
1504
|
+
};
|
|
1505
|
+
var qrcode_default = SvgQrcode;
|
|
1506
|
+
|
|
1507
|
+
// src/theme/default/assets/icons/trash.svg
|
|
1508
|
+
var React26 = __toESM(require("react"));
|
|
1509
|
+
var import_jsx_runtime49 = require("react/jsx-runtime");
|
|
1510
|
+
var SvgTrash = (props) => {
|
|
1511
|
+
var _a, _b;
|
|
1512
|
+
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" }) });
|
|
1513
|
+
};
|
|
1514
|
+
var trash_default = SvgTrash;
|
|
1515
|
+
|
|
1516
|
+
// src/theme/default/components/settings/settings-top.tsx
|
|
1517
|
+
var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
1518
|
+
function DefaultSettingsTotp(props) {
|
|
1519
|
+
var _a;
|
|
1520
|
+
if ("totpUnlink" in props && props.totpUnlink) {
|
|
1521
|
+
const {
|
|
1522
|
+
type,
|
|
1523
|
+
autocomplete: _ignoredAutocomplete,
|
|
1524
|
+
label: _ignoredLabel,
|
|
1525
|
+
node_type: _ignoredNodeType,
|
|
1526
|
+
...buttonAttrs
|
|
1527
|
+
} = (_a = props.totpUnlink) == null ? void 0 : _a.attributes;
|
|
1528
|
+
return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-8", children: [
|
|
1529
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DefaultHorizontalDivider, {}) }),
|
|
1530
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "flex gap-6 items-center col-span-full", children: [
|
|
1531
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "size-8 aspect-square ", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(qrcode_default, { size: 32 }) }),
|
|
1532
|
+
/* @__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" }) }),
|
|
1533
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1534
|
+
"button",
|
|
1535
|
+
{
|
|
1536
|
+
type: type === "button" ? "button" : "submit",
|
|
1537
|
+
...buttonAttrs,
|
|
1538
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1539
|
+
trash_default,
|
|
1540
|
+
{
|
|
1541
|
+
size: 24,
|
|
1542
|
+
className: "text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
1543
|
+
}
|
|
1544
|
+
)
|
|
1545
|
+
}
|
|
1546
|
+
)
|
|
1547
|
+
] })
|
|
1548
|
+
] });
|
|
1549
|
+
}
|
|
1550
|
+
if ("totpSecret" in props) {
|
|
1551
|
+
return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-8", children: [
|
|
1552
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DefaultHorizontalDivider, {}) }),
|
|
1553
|
+
/* @__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)(
|
|
1554
|
+
DefaultImage,
|
|
1555
|
+
{
|
|
1556
|
+
node: props.totpImage,
|
|
1557
|
+
attributes: {
|
|
1558
|
+
...props.totpImage.attributes
|
|
1559
|
+
}
|
|
1560
|
+
}
|
|
1561
|
+
) }) }) }),
|
|
1562
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "flex flex-col gap-6", children: [
|
|
1563
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1564
|
+
DefaultLabel,
|
|
1565
|
+
{
|
|
1566
|
+
node: props.totpSecret,
|
|
1567
|
+
attributes: props.totpSecret.attributes,
|
|
1568
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1569
|
+
DefaultInput,
|
|
1570
|
+
{
|
|
1571
|
+
node: props.totpSecret,
|
|
1572
|
+
attributes: {
|
|
1573
|
+
disabled: true,
|
|
1574
|
+
name: "totp_secret_key",
|
|
1575
|
+
node_type: "input",
|
|
1576
|
+
type: "text",
|
|
1577
|
+
value: props.totpSecret.attributes.text.text
|
|
1578
|
+
}
|
|
1579
|
+
}
|
|
1580
|
+
)
|
|
1581
|
+
}
|
|
1582
|
+
),
|
|
1583
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1584
|
+
DefaultLabel,
|
|
1585
|
+
{
|
|
1586
|
+
attributes: props.totpInput.attributes,
|
|
1587
|
+
node: props.totpInput,
|
|
1588
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1589
|
+
DefaultInput,
|
|
1590
|
+
{
|
|
1591
|
+
node: props.totpInput,
|
|
1592
|
+
attributes: props.totpInput.attributes
|
|
1593
|
+
}
|
|
1594
|
+
)
|
|
1595
|
+
}
|
|
1596
|
+
)
|
|
1597
|
+
] })
|
|
1598
|
+
] });
|
|
1599
|
+
}
|
|
1600
|
+
}
|
|
1601
|
+
|
|
1602
|
+
// src/theme/default/components/settings/settings-oidc.tsx
|
|
1603
|
+
var import_react_hook_form5 = require("react-hook-form");
|
|
1604
|
+
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
1605
|
+
function DefaultSettingsOidc({
|
|
1606
|
+
linkButtons,
|
|
1607
|
+
unlinkButtons
|
|
1608
|
+
}) {
|
|
1609
|
+
const hasLinkButtons = linkButtons.length > 0;
|
|
1610
|
+
const hasUnlinkButtons = unlinkButtons.length > 0;
|
|
1611
|
+
const { setValue } = (0, import_react_hook_form5.useFormContext)();
|
|
1612
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1613
|
+
hasLinkButtons && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "flex gap-3 items-start [&>button]:w-[79px]", children: linkButtons.map((button) => {
|
|
1614
|
+
const attrs = button.attributes;
|
|
1615
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
1616
|
+
DefaultButtonSocial,
|
|
1617
|
+
{
|
|
1618
|
+
showLabel: false,
|
|
1619
|
+
node: button,
|
|
1620
|
+
attributes: attrs,
|
|
1621
|
+
onClick: () => {
|
|
1622
|
+
setValue("link", attrs.value);
|
|
1623
|
+
setValue("method", "oidc");
|
|
1624
|
+
}
|
|
1625
|
+
},
|
|
1626
|
+
attrs.value
|
|
1627
|
+
);
|
|
1628
|
+
}) }),
|
|
1629
|
+
hasUnlinkButtons && hasLinkButtons ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(DefaultHorizontalDivider, {}) : null,
|
|
1630
|
+
unlinkButtons.map((button) => {
|
|
1631
|
+
var _a, _b;
|
|
1632
|
+
const attrs = button.attributes;
|
|
1633
|
+
const provider = (_b = extractProvider((_a = button.meta.label) == null ? void 0 : _a.context)) != null ? _b : "";
|
|
1634
|
+
const Logo = attrs.value in provider_logos_default ? provider_logos_default[attrs.value] : provider_logos_default.generic;
|
|
1635
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex justify-between", children: [
|
|
1636
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex gap-6 items-center", children: [
|
|
1637
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Logo, { size: 32 }),
|
|
1638
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("p", { className: "text-dialog-fg-subtle text-sm font-medium", children: provider })
|
|
1639
|
+
] }),
|
|
1640
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
|
|
1641
|
+
"button",
|
|
1642
|
+
{
|
|
1643
|
+
...attrs,
|
|
1644
|
+
type: "submit",
|
|
1645
|
+
onClick: () => {
|
|
1646
|
+
setValue("unlink", attrs.value);
|
|
1647
|
+
setValue("method", "oidc");
|
|
1648
|
+
},
|
|
1649
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(trash_default, { className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover" })
|
|
1650
|
+
}
|
|
1651
|
+
)
|
|
1652
|
+
] }, attrs.value);
|
|
1653
|
+
})
|
|
1654
|
+
] });
|
|
1655
|
+
}
|
|
1656
|
+
|
|
1657
|
+
// src/theme/default/assets/icons/key.svg
|
|
1658
|
+
var React27 = __toESM(require("react"));
|
|
1659
|
+
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
1660
|
+
var SvgKey = (props) => {
|
|
1661
|
+
var _a, _b;
|
|
1662
|
+
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" }) });
|
|
1663
|
+
};
|
|
1664
|
+
var key_default = SvgKey;
|
|
1665
|
+
|
|
1666
|
+
// src/theme/default/components/settings/settings-webauthn.tsx
|
|
1667
|
+
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
1668
|
+
function DefaultSettingsWebauthn({
|
|
1669
|
+
nameInput,
|
|
1670
|
+
triggerButton,
|
|
1671
|
+
removeButtons
|
|
1672
|
+
}) {
|
|
1673
|
+
const hasRemoveButtons = removeButtons.length > 0;
|
|
1674
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1675
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex gap-3 items-end max-w-[60%]", children: [
|
|
1676
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "flex-1", children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1677
|
+
DefaultLabel,
|
|
1678
|
+
{
|
|
1679
|
+
node: nameInput,
|
|
1680
|
+
attributes: nameInput.attributes,
|
|
1681
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1682
|
+
DefaultInput,
|
|
1683
|
+
{
|
|
1684
|
+
node: nameInput,
|
|
1685
|
+
attributes: nameInput.attributes
|
|
1686
|
+
}
|
|
1687
|
+
)
|
|
1688
|
+
}
|
|
1689
|
+
) }),
|
|
1690
|
+
triggerButton ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1691
|
+
DefaultButton,
|
|
1692
|
+
{
|
|
1693
|
+
node: triggerButton,
|
|
1694
|
+
attributes: triggerButton.attributes,
|
|
1695
|
+
onClick: triggerButton.onClick
|
|
1696
|
+
}
|
|
1697
|
+
) : null
|
|
1698
|
+
] }),
|
|
1699
|
+
hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1700
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(DefaultHorizontalDivider, {}),
|
|
1701
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "flex flex-col gap-2", children: removeButtons.map((node, i) => {
|
|
1702
|
+
var _a, _b;
|
|
1703
|
+
const context = (_b = (_a = node.meta.label) == null ? void 0 : _a.context) != null ? _b : {};
|
|
1704
|
+
const addedAt = "added_at" in context ? context.added_at : null;
|
|
1705
|
+
const diaplyName = "display_name" in context ? context.display_name : null;
|
|
1706
|
+
const keyId = "value" in node.attributes ? node.attributes.value : null;
|
|
1707
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
|
|
1708
|
+
"div",
|
|
1709
|
+
{
|
|
1710
|
+
className: "flex justify-between gap-6",
|
|
1711
|
+
children: [
|
|
1712
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(key_default, { size: 32, className: "text-dialog-fg-default" }),
|
|
1713
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex-1 flex-col", children: [
|
|
1714
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("p", { className: "text-sm font-medium text-dialog-fg-subtle", children: diaplyName }),
|
|
1715
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "text-sm text-dialog-fg-mute", children: keyId })
|
|
1716
|
+
] }),
|
|
1717
|
+
addedAt && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("p", { className: "text-sm self-center text-dialog-fg-mute", children: new Date(addedAt).toLocaleDateString() }),
|
|
1718
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1719
|
+
"button",
|
|
1720
|
+
{
|
|
1721
|
+
...node.attributes,
|
|
1722
|
+
type: "submit",
|
|
1723
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover",
|
|
1724
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(trash_default, { size: 20 })
|
|
1725
|
+
}
|
|
1726
|
+
)
|
|
1727
|
+
]
|
|
1728
|
+
},
|
|
1729
|
+
`webauthn-remove-button-${i}`
|
|
1730
|
+
);
|
|
1731
|
+
}) })
|
|
1732
|
+
] }) : null
|
|
1733
|
+
] });
|
|
1734
|
+
}
|
|
1735
|
+
|
|
1736
|
+
// src/theme/default/components/settings/settings-passkey.tsx
|
|
1737
|
+
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
1738
|
+
function DefaultSettingsPasskey({
|
|
1739
|
+
triggerButton,
|
|
1740
|
+
removeButtons
|
|
1741
|
+
}) {
|
|
1742
|
+
const hasRemoveButtons = removeButtons.length > 0;
|
|
1743
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1744
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex gap-3 items-end max-w-[60%]", children: triggerButton ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1745
|
+
DefaultButton,
|
|
1746
|
+
{
|
|
1747
|
+
node: triggerButton,
|
|
1748
|
+
attributes: triggerButton.attributes,
|
|
1749
|
+
onClick: triggerButton.onClick
|
|
1750
|
+
}
|
|
1751
|
+
) : null }),
|
|
1752
|
+
hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1753
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(DefaultHorizontalDivider, {}),
|
|
1754
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex flex-col gap-2", children: removeButtons.map((node, i) => {
|
|
1755
|
+
var _a, _b;
|
|
1756
|
+
const context = (_b = (_a = node.meta.label) == null ? void 0 : _a.context) != null ? _b : {};
|
|
1757
|
+
const addedAt = "added_at" in context ? context.added_at : null;
|
|
1758
|
+
const diaplyName = "display_name" in context ? context.display_name : null;
|
|
1759
|
+
const keyId = "value" in node.attributes ? node.attributes.value : null;
|
|
1760
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
|
|
1761
|
+
"div",
|
|
1762
|
+
{
|
|
1763
|
+
className: "flex justify-between gap-6",
|
|
1764
|
+
children: [
|
|
1765
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(passkey_default, { size: 32, className: "text-dialog-fg-default" }),
|
|
1766
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex-1 flex-col", children: [
|
|
1767
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("p", { className: "text-sm font-medium text-dialog-fg-subtle", children: diaplyName }),
|
|
1768
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "text-sm text-dialog-fg-mute", children: keyId })
|
|
1769
|
+
] }),
|
|
1770
|
+
addedAt && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("p", { className: "text-sm self-center text-dialog-fg-mute", children: new Date(addedAt).toLocaleDateString() }),
|
|
1771
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1772
|
+
"button",
|
|
1773
|
+
{
|
|
1774
|
+
...node.attributes,
|
|
1775
|
+
type: "submit",
|
|
1776
|
+
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover",
|
|
1777
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(trash_default, { size: 20 })
|
|
1778
|
+
}
|
|
1779
|
+
)
|
|
1780
|
+
]
|
|
1781
|
+
},
|
|
1782
|
+
`webauthn-remove-button-${i}`
|
|
1783
|
+
);
|
|
1784
|
+
}) })
|
|
1785
|
+
] }) : null
|
|
1786
|
+
] });
|
|
1787
|
+
}
|
|
1788
|
+
|
|
1789
|
+
// src/theme/default/components/generic/page-header.tsx
|
|
1790
|
+
var import_elements_react14 = require("@ory/elements-react");
|
|
1791
|
+
|
|
1792
|
+
// src/theme/default/components/ui/user-menu.tsx
|
|
1793
|
+
var import_react_dropdown_menu = require("@radix-ui/react-dropdown-menu");
|
|
1794
|
+
var import_react5 = require("react");
|
|
1795
|
+
var import_elements_react13 = require("@ory/elements-react");
|
|
1796
|
+
|
|
1797
|
+
// src/util/client.ts
|
|
1798
|
+
var import_client_fetch9 = require("@ory/client-fetch");
|
|
1799
|
+
function frontendClient(sdkUrl, opts = {}) {
|
|
1800
|
+
const config = new import_client_fetch9.Configuration({
|
|
1801
|
+
...opts,
|
|
1802
|
+
basePath: sdkUrl,
|
|
1803
|
+
headers: {
|
|
1804
|
+
Accept: "application/json",
|
|
1805
|
+
...opts.headers
|
|
1806
|
+
}
|
|
1807
|
+
});
|
|
1808
|
+
return new import_client_fetch9.FrontendApi(config);
|
|
1809
|
+
}
|
|
1810
|
+
|
|
1811
|
+
// src/theme/default/assets/icons/logout.svg
|
|
1812
|
+
var React28 = __toESM(require("react"));
|
|
1813
|
+
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
1814
|
+
var SvgLogout = (props) => {
|
|
1815
|
+
var _a, _b;
|
|
1816
|
+
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" }) });
|
|
1817
|
+
};
|
|
1818
|
+
var logout_default = SvgLogout;
|
|
1819
|
+
|
|
1820
|
+
// src/theme/default/assets/icons/settings.svg
|
|
1821
|
+
var React29 = __toESM(require("react"));
|
|
1822
|
+
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
1823
|
+
var SvgSettings = (props) => {
|
|
1824
|
+
var _a, _b;
|
|
1825
|
+
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: [
|
|
1826
|
+
/* @__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" }),
|
|
1827
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)("path", { d: "M6 8a2 2 0 1 0 4 0 2 2 0 0 0-4 0" })
|
|
1828
|
+
] }) });
|
|
1829
|
+
};
|
|
1830
|
+
var settings_default = SvgSettings;
|
|
1831
|
+
|
|
1832
|
+
// src/theme/default/utils/user.ts
|
|
1833
|
+
var getUserInitials = (session) => {
|
|
1834
|
+
var _a, _b;
|
|
1835
|
+
const avatar = "";
|
|
1836
|
+
let primary = "";
|
|
1837
|
+
let secondary = "";
|
|
1838
|
+
if (!((_a = session == null ? void 0 : session.identity) == null ? void 0 : _a.traits)) {
|
|
1839
|
+
return {
|
|
1840
|
+
primary,
|
|
1841
|
+
secondary,
|
|
1842
|
+
avatar
|
|
1843
|
+
};
|
|
1844
|
+
}
|
|
1845
|
+
const traits = (_b = session.identity) == null ? void 0 : _b.traits;
|
|
1846
|
+
if (traits.email) {
|
|
1847
|
+
secondary = traits.email;
|
|
1848
|
+
}
|
|
1849
|
+
if (traits.name) {
|
|
1850
|
+
if (typeof traits.name === "string") {
|
|
1851
|
+
primary = traits.name;
|
|
1852
|
+
}
|
|
1853
|
+
if (traits.name.first && traits.name.last) {
|
|
1854
|
+
primary = traits.name.first + " " + traits.name.last;
|
|
1855
|
+
}
|
|
1281
1856
|
}
|
|
1857
|
+
if (primary === "") {
|
|
1858
|
+
primary = secondary;
|
|
1859
|
+
secondary = "";
|
|
1860
|
+
}
|
|
1861
|
+
return {
|
|
1862
|
+
primary,
|
|
1863
|
+
secondary,
|
|
1864
|
+
avatar
|
|
1865
|
+
};
|
|
1866
|
+
};
|
|
1867
|
+
|
|
1868
|
+
// src/theme/default/components/ui/dropdown-menu.tsx
|
|
1869
|
+
var import_react3 = require("react");
|
|
1870
|
+
var DropdownMenuPrimitive = __toESM(require("@radix-ui/react-dropdown-menu"));
|
|
1871
|
+
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
1872
|
+
var DropdownMenu = DropdownMenuPrimitive.Root;
|
|
1873
|
+
var DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
|
|
1874
|
+
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)(
|
|
1875
|
+
DropdownMenuPrimitive.Content,
|
|
1876
|
+
{
|
|
1877
|
+
ref,
|
|
1878
|
+
sideOffset,
|
|
1879
|
+
align: "end",
|
|
1880
|
+
className: cn(
|
|
1881
|
+
"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",
|
|
1882
|
+
"border border-dialog-border-default bg-dialog-bg-default rounded-border-radius-cards",
|
|
1883
|
+
className
|
|
1884
|
+
),
|
|
1885
|
+
...props
|
|
1886
|
+
}
|
|
1887
|
+
) }));
|
|
1888
|
+
DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
|
|
1889
|
+
var DropdownMenuItem = (0, import_react3.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
1890
|
+
DropdownMenuPrimitive.Item,
|
|
1891
|
+
{
|
|
1892
|
+
ref,
|
|
1893
|
+
className: cn(
|
|
1894
|
+
"relative flex cursor-pointer select-none items-center outline-none transition-colors data-[disabled]:pointer-events-none",
|
|
1895
|
+
"px-8 py-3 lg:py-4.5 text-sm gap-6",
|
|
1896
|
+
"first:border-0 border-t border-button-secondary-border-default hover:border-button-social-border-hover data-[disabled]:border-button-secondary-border-disabled",
|
|
1897
|
+
"text-button-secondary-fg-default bg-button-secondary-bg-default",
|
|
1898
|
+
"hover:text-button-secondary-fg-hover hover:bg-button-secondary-bg-hover",
|
|
1899
|
+
"data-[disabled]:text-button-secondary-fg-disabled data-[disabled]:bg-button-secondary-bg-disabled",
|
|
1900
|
+
inset && "pl-8",
|
|
1901
|
+
className
|
|
1902
|
+
),
|
|
1903
|
+
...props
|
|
1904
|
+
}
|
|
1905
|
+
));
|
|
1906
|
+
DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
|
|
1907
|
+
var DropdownMenuLabel = (0, import_react3.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
1908
|
+
DropdownMenuPrimitive.Label,
|
|
1909
|
+
{
|
|
1910
|
+
ref,
|
|
1911
|
+
className: cn(
|
|
1912
|
+
"px-2 py-1.5 text-sm font-semibold",
|
|
1913
|
+
inset && "pl-8",
|
|
1914
|
+
className
|
|
1915
|
+
),
|
|
1916
|
+
...props
|
|
1917
|
+
}
|
|
1918
|
+
));
|
|
1919
|
+
DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
|
|
1920
|
+
|
|
1921
|
+
// src/theme/default/components/ui/user-avater.tsx
|
|
1922
|
+
var import_react4 = require("react");
|
|
1923
|
+
|
|
1924
|
+
// src/theme/default/assets/icons/user.svg
|
|
1925
|
+
var React30 = __toESM(require("react"));
|
|
1926
|
+
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
1927
|
+
var SvgUser = (props) => {
|
|
1928
|
+
var _a, _b;
|
|
1929
|
+
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" }) });
|
|
1282
1930
|
};
|
|
1931
|
+
var user_default = SvgUser;
|
|
1932
|
+
|
|
1933
|
+
// src/theme/default/components/ui/user-avater.tsx
|
|
1934
|
+
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
1935
|
+
var UserAvatar = (0, import_react4.forwardRef)(
|
|
1936
|
+
({ initials, ...rest }, ref) => {
|
|
1937
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
1938
|
+
"button",
|
|
1939
|
+
{
|
|
1940
|
+
ref,
|
|
1941
|
+
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",
|
|
1942
|
+
...rest,
|
|
1943
|
+
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)(
|
|
1944
|
+
"img",
|
|
1945
|
+
{
|
|
1946
|
+
src: initials.avatar,
|
|
1947
|
+
alt: initials.primary,
|
|
1948
|
+
className: "w-full object-contain"
|
|
1949
|
+
}
|
|
1950
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(user_default, { size: 24, className: "text-button-primary-fg-default" }) })
|
|
1951
|
+
}
|
|
1952
|
+
);
|
|
1953
|
+
}
|
|
1954
|
+
);
|
|
1955
|
+
UserAvatar.displayName = "UserAvatar";
|
|
1956
|
+
|
|
1957
|
+
// src/theme/default/components/ui/user-menu.tsx
|
|
1958
|
+
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
1959
|
+
var UserMenu = ({ session }) => {
|
|
1960
|
+
const { config } = (0, import_elements_react13.useOryFlow)();
|
|
1961
|
+
const initials = getUserInitials(session);
|
|
1962
|
+
const [logoutFlow, setLogoutFlow] = (0, import_react5.useState)();
|
|
1963
|
+
const fetchLogoutFlow = (0, import_react5.useCallback)(async () => {
|
|
1964
|
+
const flow = await frontendClient(config.sdk.url).createBrowserLogoutFlow();
|
|
1965
|
+
setLogoutFlow(flow);
|
|
1966
|
+
}, [config.sdk.url]);
|
|
1967
|
+
(0, import_react5.useEffect)(() => {
|
|
1968
|
+
void fetchLogoutFlow();
|
|
1969
|
+
}, [fetchLogoutFlow]);
|
|
1970
|
+
return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(DropdownMenu, { children: [
|
|
1971
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(UserAvatar, { initials }) }),
|
|
1972
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(DropdownMenuContent, { children: [
|
|
1973
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(import_react_dropdown_menu.DropdownMenuLabel, { className: "px-5 py-4.5 flex gap-3", children: [
|
|
1974
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(UserAvatar, { disabled: true, initials }),
|
|
1975
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex flex-col text-sm leading-tight justify-center", children: [
|
|
1976
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "text-dialog-fg-default", children: initials.primary }),
|
|
1977
|
+
initials.secondary && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "text-dialog-fg-mute", children: initials.secondary })
|
|
1978
|
+
] })
|
|
1979
|
+
] }),
|
|
1980
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("a", { href: "/settings", children: [
|
|
1981
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(settings_default, { size: 16 }),
|
|
1982
|
+
" User settings"
|
|
1983
|
+
] }) }),
|
|
1984
|
+
/* @__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: [
|
|
1985
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(logout_default, { size: 16 }),
|
|
1986
|
+
" Logout"
|
|
1987
|
+
] }) })
|
|
1988
|
+
] })
|
|
1989
|
+
] });
|
|
1990
|
+
};
|
|
1991
|
+
|
|
1992
|
+
// src/theme/default/components/generic/page-header.tsx
|
|
1993
|
+
var import_client2 = require("@ory/elements-react/client");
|
|
1994
|
+
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
1995
|
+
var DefaultPageHeader = (_props) => {
|
|
1996
|
+
const { Card } = (0, import_elements_react14.useComponents)();
|
|
1997
|
+
const { session } = (0, import_client2.useSession)();
|
|
1998
|
+
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: [
|
|
1999
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "h-10 flex-1 relative", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(Card.Logo, {}) }),
|
|
2000
|
+
/* @__PURE__ */ (0, import_jsx_runtime61.jsx)(UserMenu, { session })
|
|
2001
|
+
] }) }) });
|
|
2002
|
+
};
|
|
2003
|
+
|
|
2004
|
+
// src/theme/default/components/default-components.tsx
|
|
2005
|
+
function getOryComponents(overrides) {
|
|
2006
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __, _$, _aa, _ba, _ca, _da, _ea, _fa, _ga, _ha;
|
|
2007
|
+
return {
|
|
2008
|
+
Card: {
|
|
2009
|
+
Root: (_b = (_a = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _a.Root) != null ? _b : DefaultCard,
|
|
2010
|
+
Footer: (_d = (_c = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _c.Footer) != null ? _d : DefaultCardFooter,
|
|
2011
|
+
Header: (_f = (_e = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _e.Header) != null ? _f : DefaultCardHeader,
|
|
2012
|
+
Content: (_h = (_g = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _g.Content) != null ? _h : DefaultCardContent,
|
|
2013
|
+
Logo: (_j = (_i = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _i.Logo) != null ? _j : DefaultCardLogo,
|
|
2014
|
+
Divider: (_l = (_k = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _k.Divider) != null ? _l : DefaultHorizontalDivider,
|
|
2015
|
+
AuthMethodListItem: (_n = (_m = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _m.AuthMethodListItem) != null ? _n : DefaultAuthMethodListItem,
|
|
2016
|
+
SettingsSection: (_p = (_o = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _o.SettingsSection) != null ? _p : DefaultFormSection,
|
|
2017
|
+
SettingsSectionContent: (_r = (_q = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _q.SettingsSectionContent) != null ? _r : DefaultFormSectionContent,
|
|
2018
|
+
SettingsSectionFooter: (_t = (_s = overrides == null ? void 0 : overrides.Card) == null ? void 0 : _s.SettingsSectionFooter) != null ? _t : DefaultFormSectionFooter
|
|
2019
|
+
},
|
|
2020
|
+
Node: {
|
|
2021
|
+
Button: (_v = (_u = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _u.Button) != null ? _v : DefaultButton,
|
|
2022
|
+
OidcButton: (_x = (_w = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _w.OidcButton) != null ? _x : DefaultButtonSocial,
|
|
2023
|
+
CurrentIdentifierButton: (_z = (_y = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _y.CurrentIdentifierButton) != null ? _z : DefaultCurrentIdentifierButton,
|
|
2024
|
+
Input: (_B = (_A = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _A.Input) != null ? _B : DefaultInput,
|
|
2025
|
+
CodeInput: (_D = (_C = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _C.CodeInput) != null ? _D : DefaultPinCodeInput,
|
|
2026
|
+
Image: (_F = (_E = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _E.Image) != null ? _F : DefaultImage,
|
|
2027
|
+
Label: (_H = (_G = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _G.Label) != null ? _H : DefaultLabel,
|
|
2028
|
+
Checkbox: (_J = (_I = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _I.Checkbox) != null ? _J : DefaultCheckbox,
|
|
2029
|
+
Text: (_L = (_K = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _K.Text) != null ? _L : DefaultText,
|
|
2030
|
+
Anchor: (_N = (_M = overrides == null ? void 0 : overrides.Node) == null ? void 0 : _M.Anchor) != null ? _N : DefaultLinkButton
|
|
2031
|
+
},
|
|
2032
|
+
Form: {
|
|
2033
|
+
Root: (_P = (_O = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _O.Root) != null ? _P : DefaultFormContainer,
|
|
2034
|
+
Group: (_R = (_Q = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _Q.Group) != null ? _R : DefaultGroupContainer,
|
|
2035
|
+
OidcRoot: (_T = (_S = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _S.OidcRoot) != null ? _T : DefaultSocialButtonContainer,
|
|
2036
|
+
RecoveryCodesSettings: (_V = (_U = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _U.RecoveryCodesSettings) != null ? _V : DefaultSettingsRecoveryCodes,
|
|
2037
|
+
TotpSettings: (_X = (_W = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _W.TotpSettings) != null ? _X : DefaultSettingsTotp,
|
|
2038
|
+
OidcSettings: (_Z = (_Y = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _Y.OidcSettings) != null ? _Z : DefaultSettingsOidc,
|
|
2039
|
+
WebauthnSettings: (_$ = (__ = overrides == null ? void 0 : overrides.Form) == null ? void 0 : __.WebauthnSettings) != null ? _$ : DefaultSettingsWebauthn,
|
|
2040
|
+
PasskeySettings: (_ba = (_aa = overrides == null ? void 0 : overrides.Form) == null ? void 0 : _aa.PasskeySettings) != null ? _ba : DefaultSettingsPasskey
|
|
2041
|
+
},
|
|
2042
|
+
Message: {
|
|
2043
|
+
Root: (_da = (_ca = overrides == null ? void 0 : overrides.Message) == null ? void 0 : _ca.Root) != null ? _da : DefaultMessageContainer,
|
|
2044
|
+
Content: (_fa = (_ea = overrides == null ? void 0 : overrides.Message) == null ? void 0 : _ea.Content) != null ? _fa : DefaultMessage
|
|
2045
|
+
},
|
|
2046
|
+
Page: {
|
|
2047
|
+
Header: (_ha = (_ga = overrides == null ? void 0 : overrides.Page) == null ? void 0 : _ga.Header) != null ? _ha : DefaultPageHeader
|
|
2048
|
+
}
|
|
2049
|
+
};
|
|
2050
|
+
}
|
|
1283
2051
|
|
|
1284
2052
|
// src/theme/default/flows/error.tsx
|
|
1285
|
-
var
|
|
2053
|
+
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
1286
2054
|
function Error2({
|
|
1287
2055
|
error,
|
|
1288
2056
|
children
|
|
1289
2057
|
}) {
|
|
1290
|
-
return /* @__PURE__ */ (0,
|
|
2058
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { children: JSON.stringify(error) || children });
|
|
1291
2059
|
}
|
|
1292
2060
|
|
|
1293
2061
|
// src/theme/default/flows/login.tsx
|
|
1294
|
-
var
|
|
1295
|
-
var
|
|
1296
|
-
var
|
|
1297
|
-
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
2062
|
+
var import_client_fetch10 = require("@ory/client-fetch");
|
|
2063
|
+
var import_elements_react15 = require("@ory/elements-react");
|
|
2064
|
+
var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
1298
2065
|
function Login({
|
|
1299
2066
|
flow,
|
|
1300
2067
|
config,
|
|
1301
2068
|
children,
|
|
1302
2069
|
components: flowOverrideComponents
|
|
1303
2070
|
}) {
|
|
1304
|
-
const components =
|
|
1305
|
-
return /* @__PURE__ */ (0,
|
|
1306
|
-
|
|
2071
|
+
const components = getOryComponents(flowOverrideComponents);
|
|
2072
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
2073
|
+
import_elements_react15.OryProvider,
|
|
1307
2074
|
{
|
|
1308
2075
|
config,
|
|
1309
2076
|
flow,
|
|
1310
|
-
flowType:
|
|
2077
|
+
flowType: import_client_fetch10.FlowType.Login,
|
|
1311
2078
|
components,
|
|
1312
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2079
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_elements_react15.OryTwoStepCard, {})
|
|
1313
2080
|
}
|
|
1314
2081
|
);
|
|
1315
2082
|
}
|
|
1316
2083
|
|
|
1317
2084
|
// src/theme/default/flows/recovery.tsx
|
|
1318
|
-
var
|
|
1319
|
-
var
|
|
1320
|
-
var
|
|
1321
|
-
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
2085
|
+
var import_client_fetch11 = require("@ory/client-fetch");
|
|
2086
|
+
var import_elements_react16 = require("@ory/elements-react");
|
|
2087
|
+
var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
1322
2088
|
function Recovery({
|
|
1323
2089
|
flow,
|
|
1324
2090
|
config,
|
|
1325
2091
|
children,
|
|
1326
2092
|
components: flowOverrideComponents
|
|
1327
2093
|
}) {
|
|
1328
|
-
const components =
|
|
1329
|
-
return /* @__PURE__ */ (0,
|
|
1330
|
-
|
|
2094
|
+
const components = getOryComponents(flowOverrideComponents);
|
|
2095
|
+
return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
|
|
2096
|
+
import_elements_react16.OryProvider,
|
|
1331
2097
|
{
|
|
1332
2098
|
config,
|
|
1333
2099
|
flow,
|
|
1334
|
-
flowType:
|
|
2100
|
+
flowType: import_client_fetch11.FlowType.Recovery,
|
|
1335
2101
|
components,
|
|
1336
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2102
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_elements_react16.OryTwoStepCard, {})
|
|
1337
2103
|
}
|
|
1338
2104
|
);
|
|
1339
2105
|
}
|
|
1340
2106
|
|
|
1341
2107
|
// src/theme/default/flows/registration.tsx
|
|
1342
|
-
var
|
|
1343
|
-
var
|
|
1344
|
-
var
|
|
1345
|
-
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
2108
|
+
var import_client_fetch12 = require("@ory/client-fetch");
|
|
2109
|
+
var import_elements_react17 = require("@ory/elements-react");
|
|
2110
|
+
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
1346
2111
|
function Registration({
|
|
1347
2112
|
flow,
|
|
1348
2113
|
children,
|
|
1349
2114
|
components: flowOverrideComponents,
|
|
1350
2115
|
config
|
|
1351
2116
|
}) {
|
|
1352
|
-
const components =
|
|
1353
|
-
return /* @__PURE__ */ (0,
|
|
1354
|
-
|
|
2117
|
+
const components = getOryComponents(flowOverrideComponents);
|
|
2118
|
+
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
2119
|
+
import_elements_react17.OryProvider,
|
|
1355
2120
|
{
|
|
1356
2121
|
config,
|
|
1357
2122
|
flow,
|
|
1358
|
-
flowType:
|
|
2123
|
+
flowType: import_client_fetch12.FlowType.Registration,
|
|
1359
2124
|
components,
|
|
1360
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2125
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_elements_react17.OryTwoStepCard, {})
|
|
1361
2126
|
}
|
|
1362
2127
|
);
|
|
1363
2128
|
}
|
|
1364
2129
|
|
|
1365
2130
|
// src/theme/default/flows/settings.tsx
|
|
1366
|
-
var
|
|
1367
|
-
var
|
|
1368
|
-
var
|
|
1369
|
-
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
2131
|
+
var import_client_fetch13 = require("@ory/client-fetch");
|
|
2132
|
+
var import_elements_react18 = require("@ory/elements-react");
|
|
2133
|
+
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
1370
2134
|
function Settings({
|
|
1371
2135
|
flow,
|
|
1372
2136
|
config,
|
|
1373
2137
|
children,
|
|
1374
2138
|
components: flowOverrideComponents
|
|
1375
2139
|
}) {
|
|
1376
|
-
const components =
|
|
1377
|
-
return /* @__PURE__ */ (0,
|
|
1378
|
-
|
|
2140
|
+
const components = getOryComponents(flowOverrideComponents);
|
|
2141
|
+
return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
|
|
2142
|
+
import_elements_react18.OryProvider,
|
|
1379
2143
|
{
|
|
1380
2144
|
config,
|
|
1381
2145
|
flow,
|
|
1382
|
-
flowType:
|
|
2146
|
+
flowType: import_client_fetch13.FlowType.Settings,
|
|
1383
2147
|
components,
|
|
1384
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2148
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)(import_jsx_runtime66.Fragment, { children: [
|
|
2149
|
+
/* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_elements_react18.HeadlessPageHeader, {}),
|
|
2150
|
+
/* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_elements_react18.OrySettingsCard, {})
|
|
2151
|
+
] })
|
|
1385
2152
|
}
|
|
1386
2153
|
);
|
|
1387
2154
|
}
|
|
1388
2155
|
|
|
1389
2156
|
// src/theme/default/flows/verification.tsx
|
|
1390
|
-
var
|
|
1391
|
-
var
|
|
1392
|
-
var
|
|
1393
|
-
var import_jsx_runtime47 = require("react/jsx-runtime");
|
|
2157
|
+
var import_client_fetch14 = require("@ory/client-fetch");
|
|
2158
|
+
var import_elements_react19 = require("@ory/elements-react");
|
|
2159
|
+
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
1394
2160
|
function Verification({
|
|
1395
2161
|
flow,
|
|
1396
2162
|
config,
|
|
1397
2163
|
children,
|
|
1398
2164
|
components: flowOverrideComponents
|
|
1399
2165
|
}) {
|
|
1400
|
-
const components =
|
|
1401
|
-
return /* @__PURE__ */ (0,
|
|
1402
|
-
|
|
2166
|
+
const components = getOryComponents(flowOverrideComponents);
|
|
2167
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
2168
|
+
import_elements_react19.OryProvider,
|
|
1403
2169
|
{
|
|
1404
2170
|
config,
|
|
1405
2171
|
flow,
|
|
1406
|
-
flowType:
|
|
2172
|
+
flowType: import_client_fetch14.FlowType.Verification,
|
|
1407
2173
|
components,
|
|
1408
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2174
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_elements_react19.OryTwoStepCard, {})
|
|
1409
2175
|
}
|
|
1410
2176
|
);
|
|
1411
2177
|
}
|
|
@@ -1421,10 +2187,10 @@ function Verification({
|
|
|
1421
2187
|
DefaultMessageContainer,
|
|
1422
2188
|
Error,
|
|
1423
2189
|
Login,
|
|
1424
|
-
OryDefaultComponents,
|
|
1425
2190
|
Recovery,
|
|
1426
2191
|
Registration,
|
|
1427
2192
|
Settings,
|
|
1428
|
-
Verification
|
|
2193
|
+
Verification,
|
|
2194
|
+
getOryComponents
|
|
1429
2195
|
});
|
|
1430
2196
|
//# sourceMappingURL=index.js.map
|