@ory/elements-react 1.0.0-next.17 → 1.0.0-next.18
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 +23 -0
- package/api-report/elements-react-client.api.json +144 -16
- package/api-report/elements-react-client.api.md +19 -8
- package/api-report/elements-react-theme.api.json +47 -0
- package/api-report/elements-react-theme.api.md +5 -2
- package/api-report/elements-react.api.json +7 -3
- package/api-report/elements-react.api.md +4 -2
- package/api-report/temp/elements-react-client.api.md +19 -8
- package/api-report/temp/elements-react-theme.api.md +5 -2
- package/api-report/temp/elements-react.api.md +4 -2
- package/dist/client/config.d.mts +21 -0
- package/dist/client/config.d.ts +21 -0
- package/dist/client/config.js +77 -0
- package/dist/client/config.js.map +1 -0
- package/dist/client/config.mjs +51 -0
- package/dist/client/config.mjs.map +1 -0
- package/dist/client/frontendClient.d.mts +3 -1
- package/dist/client/frontendClient.d.ts +3 -1
- package/dist/client/frontendClient.js +14 -2
- package/dist/client/frontendClient.js.map +1 -1
- package/dist/client/frontendClient.mjs +14 -2
- package/dist/client/frontendClient.mjs.map +1 -1
- package/dist/client/index.d.mts +3 -1
- package/dist/client/index.d.ts +3 -1
- package/dist/client/index.js +4 -0
- package/dist/client/index.js.map +1 -1
- package/dist/client/index.mjs +5 -0
- package/dist/client/index.mjs.map +1 -1
- package/dist/client/session-provider.d.mts +62 -0
- package/dist/client/session-provider.d.ts +62 -0
- package/dist/client/session-provider.js +96 -0
- package/dist/client/session-provider.js.map +1 -0
- package/dist/client/session-provider.mjs +71 -0
- package/dist/client/session-provider.mjs.map +1 -0
- package/dist/client/useSession.d.mts +22 -31
- package/dist/client/useSession.d.ts +22 -31
- package/dist/client/useSession.js +7 -49
- package/dist/client/useSession.js.map +1 -1
- package/dist/client/useSession.mjs +8 -49
- package/dist/client/useSession.mjs.map +1 -1
- package/dist/index.d.mts +5 -4
- package/dist/index.d.ts +5 -4
- package/dist/index.js +46 -24
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +49 -27
- package/dist/index.mjs.map +1 -1
- package/dist/theme/default/index.css +358 -251
- package/dist/theme/default/index.css.map +1 -1
- package/dist/theme/default/index.d.mts +4 -2
- package/dist/theme/default/index.d.ts +4 -2
- package/dist/theme/default/index.js +605 -531
- package/dist/theme/default/index.js.map +1 -1
- package/dist/theme/default/index.mjs +536 -463
- package/dist/theme/default/index.mjs.map +1 -1
- package/jest.config.ts +1 -1
- package/package.json +2 -1
- package/postcss.config.ts +1 -0
- package/tailwind.config.ts +14 -13
- package/tsconfig.json +4 -3
- package/variables-processed.json +385 -187
- package/.eslintrc.js +0 -63
|
@@ -36,6 +36,7 @@ __export(default_exports, {
|
|
|
36
36
|
DefaultCardContent: () => DefaultCardContent,
|
|
37
37
|
DefaultCardFooter: () => DefaultCardFooter,
|
|
38
38
|
DefaultCardHeader: () => DefaultCardHeader,
|
|
39
|
+
DefaultCardLayout: () => DefaultCardLayout,
|
|
39
40
|
DefaultCardLogo: () => DefaultCardLogo,
|
|
40
41
|
DefaultCurrentIdentifierButton: () => DefaultCurrentIdentifierButton,
|
|
41
42
|
DefaultFormContainer: () => DefaultFormContainer,
|
|
@@ -57,8 +58,8 @@ var import_jsx_runtime = require("react/jsx-runtime");
|
|
|
57
58
|
var SvgOryBadgeHorizontal = (props) => {
|
|
58
59
|
var _a, _b;
|
|
59
60
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("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: [
|
|
60
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { fill: "#
|
|
61
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { fill: "#
|
|
61
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { fill: "#0F172A", d: "M18.007 8h-1.71l2.007-3.996L16.296 0h1.711l1.145 2.301L20.327 0H22z" }),
|
|
62
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", { fill: "#0F172A", fillRule: "evenodd", d: "M12.902 4.86a2.47 2.47 0 0 0 1.796-2.365v-.038C14.687 1.097 13.592 0 12.245 0H9.037v1.44l1.208 1.985H9.04V8h1.51V4.949h.633L13.04 8h1.775zm-.876-1.431h.223c.52 0 .943-.427.943-.953a.95.95 0 0 0-.943-.952h-1.39zM4 0a4 4 0 1 0-.001 7.999A4 4 0 0 0 4 0M1.524 4a2.476 2.476 0 1 0 4.952 0 2.476 2.476 0 0 0-4.952 0", clipRule: "evenodd" })
|
|
62
63
|
] });
|
|
63
64
|
};
|
|
64
65
|
var ory_badge_horizontal_default = SvgOryBadgeHorizontal;
|
|
@@ -69,8 +70,8 @@ var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
|
69
70
|
var SvgOryBadgeVertical = (props) => {
|
|
70
71
|
var _a, _b;
|
|
71
72
|
return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("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: [
|
|
72
|
-
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { fill: "#
|
|
73
|
-
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { fill: "#
|
|
73
|
+
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { fill: "#0F172A", d: "M8 3.993v1.71L4.004 3.697 0 5.704V3.993l2.301-1.145L0 1.673V0z" }),
|
|
74
|
+
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { fill: "#0F172A", fillRule: "evenodd", d: "M4.86 9.099a2.47 2.47 0 0 0-2.365-1.797h-.038C1.097 7.313 0 8.408 0 9.755v3.208h1.44l1.985-1.208v1.204H8v-1.51H4.949v-.633L8 8.96V7.185zm-1.431.875v-.223a.95.95 0 0 0-.953-.943.95.95 0 0 0-.952.943v1.39zM0 18a4 4 0 1 0 8 0 4 4 0 0 0-8 0m4 2.476a2.476 2.476 0 1 0 0-4.952 2.476 2.476 0 0 0 0 4.952", clipRule: "evenodd" })
|
|
74
75
|
] });
|
|
75
76
|
};
|
|
76
77
|
var ory_badge_vertical_default = SvgOryBadgeVertical;
|
|
@@ -78,9 +79,9 @@ var ory_badge_vertical_default = SvgOryBadgeVertical;
|
|
|
78
79
|
// src/theme/default/components/card/badge.tsx
|
|
79
80
|
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
80
81
|
function Badge() {
|
|
81
|
-
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "
|
|
82
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(ory_badge_horizontal_default, { width: 22, height: 8, className: "
|
|
83
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(ory_badge_vertical_default, { width: 8, height: 22, className: "max-
|
|
82
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "absolute bg-ory-background-default p-2 font-bold max-sm:bottom-0 max-sm:left-8 max-sm:translate-y-full max-sm:rounded-b-md sm:right-0 sm:top-8 sm:translate-x-full sm:rounded-r-lg border-ory-border-default border max-sm:py-[7px] sm:pl-[7px]", children: [
|
|
83
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(ory_badge_horizontal_default, { width: 22, height: 8, className: "sm:hidden" }),
|
|
84
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(ory_badge_vertical_default, { width: 8, height: 22, className: "max-sm:hidden" })
|
|
84
85
|
] });
|
|
85
86
|
}
|
|
86
87
|
|
|
@@ -127,7 +128,7 @@ function LoginCardFooter() {
|
|
|
127
128
|
if (returnTo) {
|
|
128
129
|
registrationLink += `?return_to=${returnTo}`;
|
|
129
130
|
}
|
|
130
|
-
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("span", { className: "
|
|
131
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("span", { className: "font-normal leading-normal antialiased text-interface-foreground-default-primary", children: [
|
|
131
132
|
intl.formatMessage({
|
|
132
133
|
id: "login.registration-label",
|
|
133
134
|
defaultMessage: "No account?"
|
|
@@ -136,7 +137,7 @@ function LoginCardFooter() {
|
|
|
136
137
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
137
138
|
"a",
|
|
138
139
|
{
|
|
139
|
-
className: "text-
|
|
140
|
+
className: "text-button-link-brand-brand transition-colors hover:text-button-link-brand-brand-hover underline",
|
|
140
141
|
href: registrationLink,
|
|
141
142
|
children: intl.formatMessage({
|
|
142
143
|
id: "login.registration-button",
|
|
@@ -170,10 +171,10 @@ function RegistrationCardFooter() {
|
|
|
170
171
|
if (returnTo) {
|
|
171
172
|
loginLink += `?return_to=${returnTo}`;
|
|
172
173
|
}
|
|
173
|
-
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: "
|
|
174
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: "font-normal leading-normal antialiased", children: formState.current === "method_active" ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_jsx_runtime4.Fragment, { children: screenSelectionNode && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
174
175
|
"button",
|
|
175
176
|
{
|
|
176
|
-
className: "font-medium text-
|
|
177
|
+
className: "font-medium text-button-link-brand-brand hover:text-button-link-brand-brand-hover",
|
|
177
178
|
type: "submit",
|
|
178
179
|
onClick: handleScreenSelection,
|
|
179
180
|
children: intl.formatMessage({
|
|
@@ -190,7 +191,7 @@ function RegistrationCardFooter() {
|
|
|
190
191
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
191
192
|
"a",
|
|
192
193
|
{
|
|
193
|
-
className: "text-
|
|
194
|
+
className: "text-button-link-brand-brand transition-colors hover:text-button-link-brand-brand-hover underline",
|
|
194
195
|
href: loginLink,
|
|
195
196
|
children: intl.formatMessage({
|
|
196
197
|
id: "registration.login-button",
|
|
@@ -453,23 +454,24 @@ function DefaultCurrentIdentifierButton() {
|
|
|
453
454
|
"autocomplete",
|
|
454
455
|
"node_type"
|
|
455
456
|
]);
|
|
456
|
-
return /* @__PURE__ */ (0, import_jsx_runtime6.
|
|
457
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
457
458
|
"a",
|
|
458
459
|
{
|
|
459
|
-
className: "cursor-pointer
|
|
460
|
+
className: "group inline-flex max-w-full cursor-pointer items-center gap-1 self-start rounded-full border px-[11px] py-[5px] transition-colors border-button-identifier-border-border-default bg-button-identifier-background-default hover:border-button-identifier-border-border-hover hover:bg-button-identifier-background-hover",
|
|
460
461
|
...attributes,
|
|
461
462
|
href: initFlowUrl,
|
|
462
463
|
title: `Adjust ${nodeBackButton == null ? void 0 : nodeBackButton.attributes.value}`,
|
|
463
|
-
children: [
|
|
464
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "inline-flex min-h-5 items-center gap-2 overflow-hidden text-ellipsis", children: [
|
|
464
465
|
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
465
466
|
arrow_left_default,
|
|
466
467
|
{
|
|
467
468
|
size: 16,
|
|
468
|
-
|
|
469
|
+
stroke: "1",
|
|
470
|
+
className: "shrink-0 text-button-identifier-foreground-default group-hover:text-button-identifier-foreground-hover"
|
|
469
471
|
}
|
|
470
472
|
),
|
|
471
|
-
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "text-sm font-medium text-button-identifier-
|
|
472
|
-
]
|
|
473
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "overflow-hidden text-ellipsis text-nowrap text-sm font-medium text-button-identifier-foreground-default group-hover:text-button-identifier-foreground-hover", children: nodeBackButton == null ? void 0 : nodeBackButton.attributes.value })
|
|
474
|
+
] })
|
|
473
475
|
}
|
|
474
476
|
);
|
|
475
477
|
}
|
|
@@ -511,8 +513,8 @@ function InnerCardHeader({ title, text }) {
|
|
|
511
513
|
return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("header", { className: "flex flex-col gap-8 antialiased", children: [
|
|
512
514
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Card.Logo, {}),
|
|
513
515
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "flex flex-col gap-2", children: [
|
|
514
|
-
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)("h2", { className: "font-semibold
|
|
515
|
-
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)("p", { className: "
|
|
516
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)("h2", { className: "text-lg font-semibold leading-normal text-interface-foreground-default-primary", children: title }),
|
|
517
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)("p", { className: "leading-normal text-interface-foreground-default-secondary", children: text }),
|
|
516
518
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(DefaultCurrentIdentifierButton, {})
|
|
517
519
|
] })
|
|
518
520
|
] });
|
|
@@ -531,15 +533,21 @@ function DefaultCardLogo() {
|
|
|
531
533
|
if (flow.config.logoUrl) {
|
|
532
534
|
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("img", { src: flow.config.logoUrl, width: 100, height: 36, alt: "Logo" });
|
|
533
535
|
}
|
|
534
|
-
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("h1", { className: "text-xl font-semibold leading-normal text-
|
|
536
|
+
return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("h1", { className: "text-xl font-semibold leading-normal text-interface-foreground-default-primary", children: flow.config.name });
|
|
535
537
|
}
|
|
536
538
|
|
|
537
|
-
// src/theme/default/components/card/
|
|
539
|
+
// src/theme/default/components/card/layout.tsx
|
|
538
540
|
var import_jsx_runtime9 = require("react/jsx-runtime");
|
|
541
|
+
function DefaultCardLayout({ children }) {
|
|
542
|
+
return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("main", { className: "p-4 pb-8 flex items-center justify-center flex-col gap-8 min-h-screen", children });
|
|
543
|
+
}
|
|
544
|
+
|
|
545
|
+
// src/theme/default/components/card/index.tsx
|
|
546
|
+
var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
539
547
|
function DefaultCard({ children }) {
|
|
540
|
-
return /* @__PURE__ */ (0,
|
|
548
|
+
return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex flex-1 sm:items-center justify-center font-sans items-start w-full sm:w-[480px] sm:max-w-[480px]", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "relative grid grid-cols-1 gap-8 sm:rounded-cards sm:border border-form-border-default bg-form-background-default px-8 py-12 sm:px-12 sm:py-14 border-b w-full", children: [
|
|
541
549
|
children,
|
|
542
|
-
/* @__PURE__ */ (0,
|
|
550
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Badge, {})
|
|
543
551
|
] }) });
|
|
544
552
|
}
|
|
545
553
|
|
|
@@ -560,159 +568,159 @@ var import_elements_react5 = require("@ory/elements-react");
|
|
|
560
568
|
|
|
561
569
|
// src/theme/default/provider-logos/apple.svg
|
|
562
570
|
var React4 = __toESM(require("react"));
|
|
563
|
-
var
|
|
571
|
+
var import_jsx_runtime11 = require("react/jsx-runtime");
|
|
564
572
|
var SvgApple = (props) => {
|
|
565
573
|
var _a, _b;
|
|
566
|
-
return /* @__PURE__ */ (0,
|
|
574
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.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_runtime11.jsx)("path", { fill: "#283544", d: "M27.734 11.55c-.134.078-3.317 1.724-3.317 5.374.15 4.162 4.017 5.621 4.083 5.621-.066.078-.584 1.988-2.116 3.991C25.167 28.261 23.817 30 21.767 30c-1.95 0-2.65-1.15-4.9-1.15-2.416 0-3.1 1.15-4.95 1.15-2.05 0-3.5-1.832-4.782-3.541-1.667-2.236-3.083-5.746-3.133-9.116-.034-1.786.334-3.54 1.266-5.032 1.317-2.081 3.667-3.494 6.233-3.54 1.966-.063 3.716 1.257 4.916 1.257 1.15 0 3.3-1.258 5.733-1.258 1.05.001 3.85.296 5.584 2.78M16.25 8.414c-.35-1.631.616-3.262 1.516-4.302C18.917 2.854 20.734 2 22.3 2c.1 1.63-.534 3.23-1.666 4.395-1.017 1.258-2.767 2.205-4.383 2.019" }) });
|
|
567
575
|
};
|
|
568
576
|
var apple_default = SvgApple;
|
|
569
577
|
|
|
570
578
|
// src/theme/default/provider-logos/auth0.svg
|
|
571
579
|
var React5 = __toESM(require("react"));
|
|
572
|
-
var
|
|
580
|
+
var import_jsx_runtime12 = require("react/jsx-runtime");
|
|
573
581
|
var SvgAuth0 = (props) => {
|
|
574
582
|
var _a, _b;
|
|
575
|
-
return /* @__PURE__ */ (0,
|
|
583
|
+
return /* @__PURE__ */ (0, import_jsx_runtime12.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_runtime12.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" }) });
|
|
576
584
|
};
|
|
577
585
|
var auth0_default = SvgAuth0;
|
|
578
586
|
|
|
579
587
|
// src/theme/default/provider-logos/discord.svg
|
|
580
588
|
var React6 = __toESM(require("react"));
|
|
581
|
-
var
|
|
589
|
+
var import_jsx_runtime13 = require("react/jsx-runtime");
|
|
582
590
|
var SvgDiscord = (props) => {
|
|
583
591
|
var _a, _b;
|
|
584
|
-
return /* @__PURE__ */ (0,
|
|
585
|
-
/* @__PURE__ */ (0,
|
|
586
|
-
/* @__PURE__ */ (0,
|
|
592
|
+
return /* @__PURE__ */ (0, import_jsx_runtime13.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: [
|
|
593
|
+
/* @__PURE__ */ (0, import_jsx_runtime13.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" }),
|
|
594
|
+
/* @__PURE__ */ (0, import_jsx_runtime13.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" })
|
|
587
595
|
] });
|
|
588
596
|
};
|
|
589
597
|
var discord_default = SvgDiscord;
|
|
590
598
|
|
|
591
599
|
// src/theme/default/provider-logos/facebook.svg
|
|
592
600
|
var React7 = __toESM(require("react"));
|
|
593
|
-
var
|
|
601
|
+
var import_jsx_runtime14 = require("react/jsx-runtime");
|
|
594
602
|
var SvgFacebook = (props) => {
|
|
595
603
|
var _a, _b;
|
|
596
|
-
return /* @__PURE__ */ (0,
|
|
597
|
-
/* @__PURE__ */ (0,
|
|
598
|
-
/* @__PURE__ */ (0,
|
|
599
|
-
/* @__PURE__ */ (0,
|
|
604
|
+
return /* @__PURE__ */ (0, import_jsx_runtime14.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: [
|
|
605
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("g", { clipPath: "url(#facebook_svg__a)", children: [
|
|
606
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.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" }),
|
|
607
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.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" })
|
|
600
608
|
] }),
|
|
601
|
-
/* @__PURE__ */ (0,
|
|
609
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("clipPath", { id: "facebook_svg__a", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("rect", { fill: "#fff" }) }) })
|
|
602
610
|
] });
|
|
603
611
|
};
|
|
604
612
|
var facebook_default = SvgFacebook;
|
|
605
613
|
|
|
606
614
|
// src/theme/default/provider-logos/generic.svg
|
|
607
615
|
var React8 = __toESM(require("react"));
|
|
608
|
-
var
|
|
616
|
+
var import_jsx_runtime15 = require("react/jsx-runtime");
|
|
609
617
|
var SvgGeneric = (props) => {
|
|
610
618
|
var _a, _b;
|
|
611
|
-
return /* @__PURE__ */ (0,
|
|
612
|
-
/* @__PURE__ */ (0,
|
|
613
|
-
/* @__PURE__ */ (0,
|
|
614
|
-
/* @__PURE__ */ (0,
|
|
619
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.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: [
|
|
620
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("path", { stroke: "none", d: "M0 0h24v24H0z" }),
|
|
621
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)("path", { d: "M2 12a10 10 0 1 0 20 0 10 10 0 1 0-20 0" }),
|
|
622
|
+
/* @__PURE__ */ (0, import_jsx_runtime15.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" })
|
|
615
623
|
] });
|
|
616
624
|
};
|
|
617
625
|
var generic_default = SvgGeneric;
|
|
618
626
|
|
|
619
627
|
// src/theme/default/provider-logos/github.svg
|
|
620
628
|
var React9 = __toESM(require("react"));
|
|
621
|
-
var
|
|
629
|
+
var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
622
630
|
var SvgGithub = (props) => {
|
|
623
631
|
var _a, _b;
|
|
624
|
-
return /* @__PURE__ */ (0,
|
|
632
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.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_runtime16.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" }) });
|
|
625
633
|
};
|
|
626
634
|
var github_default = SvgGithub;
|
|
627
635
|
|
|
628
636
|
// src/theme/default/provider-logos/gitlab.svg
|
|
629
637
|
var React10 = __toESM(require("react"));
|
|
630
|
-
var
|
|
638
|
+
var import_jsx_runtime17 = require("react/jsx-runtime");
|
|
631
639
|
var SvgGitlab = (props) => {
|
|
632
640
|
var _a, _b;
|
|
633
|
-
return /* @__PURE__ */ (0,
|
|
634
|
-
/* @__PURE__ */ (0,
|
|
635
|
-
/* @__PURE__ */ (0,
|
|
636
|
-
/* @__PURE__ */ (0,
|
|
637
|
-
/* @__PURE__ */ (0,
|
|
641
|
+
return /* @__PURE__ */ (0, import_jsx_runtime17.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: [
|
|
642
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.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" }),
|
|
643
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.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" }),
|
|
644
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.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" }),
|
|
645
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.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" })
|
|
638
646
|
] });
|
|
639
647
|
};
|
|
640
648
|
var gitlab_default = SvgGitlab;
|
|
641
649
|
|
|
642
650
|
// src/theme/default/provider-logos/google.svg
|
|
643
651
|
var React11 = __toESM(require("react"));
|
|
644
|
-
var
|
|
652
|
+
var import_jsx_runtime18 = require("react/jsx-runtime");
|
|
645
653
|
var SvgGoogle = (props) => {
|
|
646
654
|
var _a, _b;
|
|
647
|
-
return /* @__PURE__ */ (0,
|
|
648
|
-
/* @__PURE__ */ (0,
|
|
649
|
-
/* @__PURE__ */ (0,
|
|
650
|
-
/* @__PURE__ */ (0,
|
|
651
|
-
/* @__PURE__ */ (0,
|
|
655
|
+
return /* @__PURE__ */ (0, import_jsx_runtime18.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: [
|
|
656
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("path", { fill: "#4285F4", d: "M30.001 16.31c0-1.15-.095-1.99-.301-2.861H16.287v5.195h7.873c-.159 1.291-1.016 3.236-2.92 4.542l-.027.174 4.24 3.22.294.029c2.699-2.443 4.254-6.036 4.254-10.298" }),
|
|
657
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("path", { fill: "#34A853", d: "M16.286 30c3.857 0 7.095-1.244 9.46-3.391l-4.507-3.423c-1.207.825-2.826 1.4-4.953 1.4A8.58 8.58 0 0 1 8.16 18.77l-.167.014-4.41 3.344-.058.157C5.874 26.858 10.7 30 16.286 30" }),
|
|
658
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("path", { fill: "#FBBC05", d: "M8.16 18.769a8.5 8.5 0 0 1-.476-2.77c0-.964.174-1.897.46-2.768l-.008-.185-4.465-3.399-.146.068A13.8 13.8 0 0 0 2.001 16c0 2.256.556 4.387 1.524 6.284z" }),
|
|
659
|
+
/* @__PURE__ */ (0, import_jsx_runtime18.jsx)("path", { fill: "#EB4335", d: "M16.286 7.413c2.683 0 4.492 1.136 5.524 2.085l4.032-3.858C23.366 3.384 20.143 2 16.286 2 10.7 2 5.874 5.142 3.524 9.715l4.62 3.516c1.158-3.375 4.365-5.818 8.142-5.818" })
|
|
652
660
|
] });
|
|
653
661
|
};
|
|
654
662
|
var google_default = SvgGoogle;
|
|
655
663
|
|
|
656
664
|
// src/theme/default/provider-logos/linkedin.svg
|
|
657
665
|
var React12 = __toESM(require("react"));
|
|
658
|
-
var
|
|
666
|
+
var import_jsx_runtime19 = require("react/jsx-runtime");
|
|
659
667
|
var SvgLinkedin = (props) => {
|
|
660
668
|
var _a, _b;
|
|
661
|
-
return /* @__PURE__ */ (0,
|
|
662
|
-
/* @__PURE__ */ (0,
|
|
663
|
-
/* @__PURE__ */ (0,
|
|
669
|
+
return /* @__PURE__ */ (0, import_jsx_runtime19.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: [
|
|
670
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)("rect", { x: 2, y: 2, fill: "#1275B1", rx: 14 }),
|
|
671
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.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" })
|
|
664
672
|
] });
|
|
665
673
|
};
|
|
666
674
|
var linkedin_default = SvgLinkedin;
|
|
667
675
|
|
|
668
676
|
// src/theme/default/provider-logos/microsoft.svg
|
|
669
677
|
var React13 = __toESM(require("react"));
|
|
670
|
-
var
|
|
678
|
+
var import_jsx_runtime20 = require("react/jsx-runtime");
|
|
671
679
|
var SvgMicrosoft = (props) => {
|
|
672
680
|
var _a, _b;
|
|
673
|
-
return /* @__PURE__ */ (0,
|
|
674
|
-
/* @__PURE__ */ (0,
|
|
675
|
-
/* @__PURE__ */ (0,
|
|
676
|
-
/* @__PURE__ */ (0,
|
|
677
|
-
/* @__PURE__ */ (0,
|
|
681
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.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: [
|
|
682
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)("path", { fill: "#F35325", d: "M1 1h10v10H1z" }),
|
|
683
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)("path", { fill: "#81BC06", d: "M12 1h10v10H12z" }),
|
|
684
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)("path", { fill: "#05A6F0", d: "M1 12h10v10H1z" }),
|
|
685
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)("path", { fill: "#FFBA08", d: "M12 12h10v10H12z" })
|
|
678
686
|
] });
|
|
679
687
|
};
|
|
680
688
|
var microsoft_default = SvgMicrosoft;
|
|
681
689
|
|
|
682
690
|
// src/theme/default/provider-logos/slack.svg
|
|
683
691
|
var React14 = __toESM(require("react"));
|
|
684
|
-
var
|
|
692
|
+
var import_jsx_runtime21 = require("react/jsx-runtime");
|
|
685
693
|
var SvgSlack = (props) => {
|
|
686
694
|
var _a, _b;
|
|
687
|
-
return /* @__PURE__ */ (0,
|
|
688
|
-
/* @__PURE__ */ (0,
|
|
689
|
-
/* @__PURE__ */ (0,
|
|
690
|
-
/* @__PURE__ */ (0,
|
|
691
|
-
/* @__PURE__ */ (0,
|
|
695
|
+
return /* @__PURE__ */ (0, import_jsx_runtime21.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: [
|
|
696
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.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" }),
|
|
697
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.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" }),
|
|
698
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.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" }),
|
|
699
|
+
/* @__PURE__ */ (0, import_jsx_runtime21.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" })
|
|
692
700
|
] });
|
|
693
701
|
};
|
|
694
702
|
var slack_default = SvgSlack;
|
|
695
703
|
|
|
696
704
|
// src/theme/default/provider-logos/spotify.svg
|
|
697
705
|
var React15 = __toESM(require("react"));
|
|
698
|
-
var
|
|
706
|
+
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
699
707
|
var SvgSpotify = (props) => {
|
|
700
708
|
var _a, _b;
|
|
701
|
-
return /* @__PURE__ */ (0,
|
|
702
|
-
/* @__PURE__ */ (0,
|
|
703
|
-
/* @__PURE__ */ (0,
|
|
709
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.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: [
|
|
710
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("circle", { cx: 16, cy: 16, r: 14, fill: "#1ED760" }),
|
|
711
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.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" })
|
|
704
712
|
] });
|
|
705
713
|
};
|
|
706
714
|
var spotify_default = SvgSpotify;
|
|
707
715
|
|
|
708
716
|
// src/theme/default/provider-logos/yandex.svg
|
|
709
717
|
var React16 = __toESM(require("react"));
|
|
710
|
-
var
|
|
718
|
+
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
711
719
|
var SvgYandex = (props) => {
|
|
712
720
|
var _a, _b;
|
|
713
|
-
return /* @__PURE__ */ (0,
|
|
714
|
-
/* @__PURE__ */ (0,
|
|
715
|
-
/* @__PURE__ */ (0,
|
|
721
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.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: [
|
|
722
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.jsx)("circle", { cx: 16, cy: 16, r: 14, fill: "#fff" }),
|
|
723
|
+
/* @__PURE__ */ (0, import_jsx_runtime23.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" })
|
|
716
724
|
] });
|
|
717
725
|
};
|
|
718
726
|
var yandex_default = SvgYandex;
|
|
@@ -737,7 +745,49 @@ var provider_logos_default = logos;
|
|
|
737
745
|
|
|
738
746
|
// src/theme/default/components/form/social.tsx
|
|
739
747
|
var import_react_intl3 = require("react-intl");
|
|
740
|
-
var
|
|
748
|
+
var import_react_hook_form2 = require("react-hook-form");
|
|
749
|
+
|
|
750
|
+
// src/theme/default/components/form/spinner.tsx
|
|
751
|
+
var import_jsx_runtime24 = require("react/jsx-runtime");
|
|
752
|
+
function Spinner({ className }) {
|
|
753
|
+
return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
|
|
754
|
+
"svg",
|
|
755
|
+
{
|
|
756
|
+
"aria-hidden": "true",
|
|
757
|
+
role: "status",
|
|
758
|
+
className: cn(
|
|
759
|
+
"absolute pointer-events-none inset-0 m-auto size-8 animate-spin",
|
|
760
|
+
className
|
|
761
|
+
),
|
|
762
|
+
viewBox: "0 0 34 34",
|
|
763
|
+
fill: "none",
|
|
764
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
765
|
+
children: [
|
|
766
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)("g", { clipPath: "url(#clip0_2572_1748)", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
767
|
+
"path",
|
|
768
|
+
{
|
|
769
|
+
d: "M23.364 10.6362C22.1053 9.37751 20.5016 8.52034 18.7558 8.17307C17.01 7.82581 15.2004 8.00404 13.5559 8.68523C11.9113 9.36641 10.5057 10.52 9.51678 12C8.52784 13.4801 8 15.2201 8 17.0001C8 18.7802 8.52784 20.5202 9.51678 22.0003C10.5057 23.4803 11.9113 24.6339 13.5559 25.3151C15.2004 25.9962 17.01 26.1745 18.7558 25.8272C20.5016 25.4799 22.1053 24.6228 23.364 23.3641",
|
|
770
|
+
stroke: "currentColor",
|
|
771
|
+
strokeLinecap: "round",
|
|
772
|
+
strokeLinejoin: "round"
|
|
773
|
+
}
|
|
774
|
+
) }),
|
|
775
|
+
/* @__PURE__ */ (0, import_jsx_runtime24.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("clipPath", { id: "clip0_2572_1748", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
|
|
776
|
+
"rect",
|
|
777
|
+
{
|
|
778
|
+
width: "24",
|
|
779
|
+
height: "24",
|
|
780
|
+
fill: "currentColor",
|
|
781
|
+
transform: "translate(17 0.029541) rotate(45)"
|
|
782
|
+
}
|
|
783
|
+
) }) })
|
|
784
|
+
]
|
|
785
|
+
}
|
|
786
|
+
);
|
|
787
|
+
}
|
|
788
|
+
|
|
789
|
+
// src/theme/default/components/form/social.tsx
|
|
790
|
+
var import_jsx_runtime25 = require("react/jsx-runtime");
|
|
741
791
|
function extractProvider(context) {
|
|
742
792
|
if (context && typeof context === "object" && "provider" in context && typeof context.provider === "string") {
|
|
743
793
|
return context.provider;
|
|
@@ -763,40 +813,36 @@ function DefaultButtonSocial({
|
|
|
763
813
|
flow: { ui }
|
|
764
814
|
} = (0, import_elements_react5.useOryFlow)();
|
|
765
815
|
const intl = (0, import_react_intl3.useIntl)();
|
|
816
|
+
const {
|
|
817
|
+
formState: { isSubmitting }
|
|
818
|
+
} = (0, import_react_hook_form2.useFormContext)();
|
|
766
819
|
const oidcNodeCount = (_a = ui.nodes.filter((node2) => node2.group === "oidc").length) != null ? _a : 0;
|
|
767
820
|
const Logo = logos2[attributes.value];
|
|
768
821
|
const showLabel = _showLabel != null ? _showLabel : oidcNodeCount % 3 !== 0 && oidcNodeCount % 4 !== 0;
|
|
769
822
|
const provider = (_c = extractProvider((_b = node.meta.label) == null ? void 0 : _b.context)) != null ? _c : "";
|
|
770
|
-
return /* @__PURE__ */ (0,
|
|
823
|
+
return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
|
|
771
824
|
"button",
|
|
772
825
|
{
|
|
773
|
-
className:
|
|
774
|
-
"gap-3 ring-1 ring-forms-border-default bg-button-secondary-bg-default hover:bg-button-secondary-bg-hover transition-colors rounded flex items-center justify-center py-2.5 px-4 md:py-4",
|
|
775
|
-
{ "py-2.5": showLabel }
|
|
776
|
-
),
|
|
826
|
+
className: "gap-3 border border-button-social-border-default bg-button-social-background-default hover:bg-button-social-background-hover transition-colors rounded flex items-center justify-center px-4 py-[13px] disabled:bg-button-social-background-disabled disabled:border-button-social-border-disabled disabled:text-button-social-foreground-disabled hover:text-button-social-foreground-disabled",
|
|
777
827
|
value: attributes.value,
|
|
778
828
|
type: "submit",
|
|
779
829
|
name: "provider",
|
|
780
830
|
...props,
|
|
781
831
|
onClick,
|
|
832
|
+
disabled: isSubmitting,
|
|
782
833
|
children: [
|
|
783
|
-
/* @__PURE__ */ (0,
|
|
784
|
-
|
|
785
|
-
{
|
|
786
|
-
size: 20
|
|
787
|
-
}
|
|
788
|
-
) : /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "rounded-full aspect-square border flex items-center justify-center text-xs", children: provider.slice(0, 2) }) }),
|
|
789
|
-
showLabel && node.meta.label ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "text-sm text-left leading-none font-medium text-forms-fg-default flex-grow", children: (0, import_elements_react5.uiTextToFormattedMessage)(node.meta.label, intl) }) : null
|
|
834
|
+
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: "size-5 relative", children: !isSubmitting ? Logo ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Logo, { size: 20 }) : /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: "flex aspect-square items-center justify-center rounded-full border text-xs", children: provider.slice(0, 2) }) : /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Spinner, { className: "size-5" }) }),
|
|
835
|
+
showLabel && node.meta.label ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: "grow text-left font-medium leading-none text-button-social-foreground-default", children: (0, import_elements_react5.uiTextToFormattedMessage)(node.meta.label, intl) }) : null
|
|
790
836
|
]
|
|
791
837
|
}
|
|
792
838
|
);
|
|
793
839
|
}
|
|
794
|
-
DefaultButtonSocial.WithLogos = (logos2) => (props) => /* @__PURE__ */ (0,
|
|
840
|
+
DefaultButtonSocial.WithLogos = (logos2) => (props) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(DefaultButtonSocial, { ...props, logos: logos2 });
|
|
795
841
|
function DefaultSocialButtonContainer({
|
|
796
842
|
children,
|
|
797
843
|
nodes
|
|
798
844
|
}) {
|
|
799
|
-
return /* @__PURE__ */ (0,
|
|
845
|
+
return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
800
846
|
"div",
|
|
801
847
|
{
|
|
802
848
|
className: cn("grid gap-3", {
|
|
@@ -811,14 +857,14 @@ function DefaultSocialButtonContainer({
|
|
|
811
857
|
}
|
|
812
858
|
|
|
813
859
|
// src/theme/default/components/form/index.tsx
|
|
814
|
-
var
|
|
860
|
+
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
815
861
|
function DefaultFormContainer({
|
|
816
862
|
children,
|
|
817
863
|
onSubmit,
|
|
818
864
|
action,
|
|
819
865
|
method
|
|
820
866
|
}) {
|
|
821
|
-
return /* @__PURE__ */ (0,
|
|
867
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
822
868
|
"form",
|
|
823
869
|
{
|
|
824
870
|
onSubmit,
|
|
@@ -835,7 +881,7 @@ function DefaultMessageContainer({ children }) {
|
|
|
835
881
|
if (!children || Array.isArray(children) && children.length === 0) {
|
|
836
882
|
return null;
|
|
837
883
|
}
|
|
838
|
-
return /* @__PURE__ */ (0,
|
|
884
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
839
885
|
"section",
|
|
840
886
|
{
|
|
841
887
|
className: cn(
|
|
@@ -847,14 +893,15 @@ function DefaultMessageContainer({ children }) {
|
|
|
847
893
|
}
|
|
848
894
|
function DefaultMessage({ message }) {
|
|
849
895
|
const intl = (0, import_react_intl4.useIntl)();
|
|
850
|
-
return /* @__PURE__ */ (0,
|
|
896
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
851
897
|
"span",
|
|
852
898
|
{
|
|
853
|
-
className: cn(
|
|
854
|
-
"
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
899
|
+
className: cn(
|
|
900
|
+
"leading-normal",
|
|
901
|
+
message.type === "error" && "text-interface-foreground-validation-danger",
|
|
902
|
+
message.type === "info" && "text-interface-foreground-default-secondary",
|
|
903
|
+
message.type === "success" && "text-interface-foreground-validation-success"
|
|
904
|
+
),
|
|
858
905
|
...(0, import_elements_react6.messageTestId)(message),
|
|
859
906
|
children: (0, import_elements_react6.uiTextToFormattedMessage)(message, intl)
|
|
860
907
|
}
|
|
@@ -866,37 +913,37 @@ var import_react_intl5 = require("react-intl");
|
|
|
866
913
|
|
|
867
914
|
// src/theme/default/assets/icons/code.svg
|
|
868
915
|
var React17 = __toESM(require("react"));
|
|
869
|
-
var
|
|
916
|
+
var import_jsx_runtime27 = require("react/jsx-runtime");
|
|
870
917
|
var SvgCode = (props) => {
|
|
871
918
|
var _a, _b;
|
|
872
|
-
return /* @__PURE__ */ (0,
|
|
919
|
+
return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 15 13", 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", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M6.333 10.666h-4A1.333 1.333 0 0 1 1 9.333V2.666m0 0a1.333 1.333 0 0 1 1.333-1.333h9.334A1.333 1.333 0 0 1 13 2.666m-12 0 6 4 6-4m0 0v4M12.333 12l1.334-1.334-1.334-1.333m-2 0L9 10.666 10.333 12" }) });
|
|
873
920
|
};
|
|
874
921
|
var code_default = SvgCode;
|
|
875
922
|
|
|
876
923
|
// src/theme/default/assets/icons/passkey.svg
|
|
877
924
|
var React18 = __toESM(require("react"));
|
|
878
|
-
var
|
|
925
|
+
var import_jsx_runtime28 = require("react/jsx-runtime");
|
|
879
926
|
var SvgPasskey = (props) => {
|
|
880
927
|
var _a, _b;
|
|
881
|
-
return /* @__PURE__ */ (0,
|
|
928
|
+
return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 13 14", 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_runtime28.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M10.602 3.667c.603 1 .86 2.171.733 3.333v.667a4 4 0 0 0 .533 2M3.335 6.333a2.667 2.667 0 0 1 5.333 0V7c0 1.442.468 2.846 1.334 4m-4-4.667v1.334A9.33 9.33 0 0 0 7.668 13M3.335 9a12 12 0 0 0 1.2 4m-3.267-1.333A14.7 14.7 0 0 1 .668 7v-.667a5.333 5.333 0 0 1 8-4.633" }) });
|
|
882
929
|
};
|
|
883
930
|
var passkey_default = SvgPasskey;
|
|
884
931
|
|
|
885
932
|
// src/theme/default/assets/icons/password.svg
|
|
886
933
|
var React19 = __toESM(require("react"));
|
|
887
|
-
var
|
|
934
|
+
var import_jsx_runtime29 = require("react/jsx-runtime");
|
|
888
935
|
var SvgPassword = (props) => {
|
|
889
936
|
var _a, _b;
|
|
890
|
-
return /* @__PURE__ */ (0,
|
|
937
|
+
return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 14 4", 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_runtime29.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M7 .667v2.667m-1.333-.667 2.666-1.333m-2.666 0 2.666 1.333m-6-2v2.667M1 2.667l2.667-1.333M1 1.334l2.667 1.333m8-2v2.667m-1.334-.667L13 1.334m-2.667 0L13 2.667" }) });
|
|
891
938
|
};
|
|
892
939
|
var password_default = SvgPassword;
|
|
893
940
|
|
|
894
941
|
// src/theme/default/assets/icons/webauthn.svg
|
|
895
942
|
var React20 = __toESM(require("react"));
|
|
896
|
-
var
|
|
943
|
+
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
897
944
|
var SvgWebauthn = (props) => {
|
|
898
945
|
var _a, _b;
|
|
899
|
-
return /* @__PURE__ */ (0,
|
|
946
|
+
return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 14 14", 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_runtime30.jsx)("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", d: "M9 5h.007m1.03-3.438 2.401 2.401a1.92 1.92 0 0 1 0 2.713l-1.762 1.762a1.92 1.92 0 0 1-2.713 0l-.2-.2-4.372 4.371a1.33 1.33 0 0 1-.826.386L2.448 13h-.781a.667.667 0 0 1-.662-.589L1 12.333v-.781c0-.313.11-.616.311-.856l.08-.087.276-.276H3V9h1.333V7.667l1.43-1.43-.201-.2a1.92 1.92 0 0 1 0-2.713l1.762-1.762a1.92 1.92 0 0 1 2.713 0" }) });
|
|
900
947
|
};
|
|
901
948
|
var webauthn_default = SvgWebauthn;
|
|
902
949
|
|
|
@@ -906,7 +953,7 @@ function isGroupImmediateSubmit(group) {
|
|
|
906
953
|
}
|
|
907
954
|
|
|
908
955
|
// src/theme/default/components/card/auth-methods.tsx
|
|
909
|
-
var
|
|
956
|
+
var import_jsx_runtime31 = require("react/jsx-runtime");
|
|
910
957
|
var iconsMap = {
|
|
911
958
|
code: code_default,
|
|
912
959
|
passkey: passkey_default,
|
|
@@ -919,20 +966,26 @@ function DefaultAuthMethodListItem({
|
|
|
919
966
|
}) {
|
|
920
967
|
const intl = (0, import_react_intl5.useIntl)();
|
|
921
968
|
const Icon = iconsMap[group] || null;
|
|
922
|
-
return /* @__PURE__ */ (0,
|
|
969
|
+
return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "w-full rounded px-2 py-1 hover:bg-interface-background-default-primary-hover", children: /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
|
|
923
970
|
"button",
|
|
924
971
|
{
|
|
925
|
-
className: "flex
|
|
972
|
+
className: "flex cursor-pointer gap-3 py-2 text-left items-start",
|
|
926
973
|
onClick,
|
|
927
974
|
type: isGroupImmediateSubmit(group) ? "submit" : "button",
|
|
928
975
|
id: `auth-method-list-item-${group}`,
|
|
929
976
|
"data-testid": "auth-method-list-item",
|
|
930
977
|
"aria-label": `Authenticate with ${group}`,
|
|
931
978
|
children: [
|
|
932
|
-
/* @__PURE__ */ (0,
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
979
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { className: "mt-1", children: Icon && /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
|
|
980
|
+
Icon,
|
|
981
|
+
{
|
|
982
|
+
size: 16,
|
|
983
|
+
className: "text-interface-foreground-brand-primary"
|
|
984
|
+
}
|
|
985
|
+
) }),
|
|
986
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("span", { className: "flex-1 leading-normal inline-flex flex-col", children: [
|
|
987
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { className: "text-interface-foreground-default-primary", children: intl.formatMessage({ id: `two-step.${group}.title` }) }),
|
|
988
|
+
/* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { className: "text-interface-foreground-default-secondary", children: intl.formatMessage({ id: `two-step.${group}.description` }) })
|
|
936
989
|
] })
|
|
937
990
|
]
|
|
938
991
|
}
|
|
@@ -942,83 +995,38 @@ function DefaultAuthMethodListItem({
|
|
|
942
995
|
// src/theme/default/components/form/button.tsx
|
|
943
996
|
var import_client_fetch5 = require("@ory/client-fetch");
|
|
944
997
|
var import_elements_react7 = require("@ory/elements-react");
|
|
945
|
-
var import_react_hook_form2 = require("react-hook-form");
|
|
946
|
-
var import_react_intl6 = require("react-intl");
|
|
947
|
-
|
|
948
|
-
// src/theme/default/components/form/spinner.tsx
|
|
949
|
-
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
950
|
-
function Spinner({ className }) {
|
|
951
|
-
return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
|
|
952
|
-
"svg",
|
|
953
|
-
{
|
|
954
|
-
"aria-hidden": "true",
|
|
955
|
-
role: "status",
|
|
956
|
-
className: cn(
|
|
957
|
-
"absolute pointer-events-none inset-0 mx-auto my-auto w-8 h-8 animate-spin",
|
|
958
|
-
className
|
|
959
|
-
),
|
|
960
|
-
viewBox: "0 0 34 34",
|
|
961
|
-
fill: "none",
|
|
962
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
963
|
-
children: [
|
|
964
|
-
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)("g", { clipPath: "url(#clip0_2572_1748)", children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
965
|
-
"path",
|
|
966
|
-
{
|
|
967
|
-
d: "M23.364 10.6362C22.1053 9.37751 20.5016 8.52034 18.7558 8.17307C17.01 7.82581 15.2004 8.00404 13.5559 8.68523C11.9113 9.36641 10.5057 10.52 9.51678 12C8.52784 13.4801 8 15.2201 8 17.0001C8 18.7802 8.52784 20.5202 9.51678 22.0003C10.5057 23.4803 11.9113 24.6339 13.5559 25.3151C15.2004 25.9962 17.01 26.1745 18.7558 25.8272C20.5016 25.4799 22.1053 24.6228 23.364 23.3641",
|
|
968
|
-
stroke: "currentColor",
|
|
969
|
-
strokeLinecap: "round",
|
|
970
|
-
strokeLinejoin: "round"
|
|
971
|
-
}
|
|
972
|
-
) }),
|
|
973
|
-
/* @__PURE__ */ (0, import_jsx_runtime30.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("clipPath", { id: "clip0_2572_1748", children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
974
|
-
"rect",
|
|
975
|
-
{
|
|
976
|
-
width: "24",
|
|
977
|
-
height: "24",
|
|
978
|
-
fill: "currentColor",
|
|
979
|
-
transform: "translate(17 0.029541) rotate(45)"
|
|
980
|
-
}
|
|
981
|
-
) }) })
|
|
982
|
-
]
|
|
983
|
-
}
|
|
984
|
-
);
|
|
985
|
-
}
|
|
986
|
-
|
|
987
|
-
// src/theme/default/components/form/button.tsx
|
|
988
|
-
var import_elements_react8 = require("@ory/elements-react");
|
|
989
998
|
var import_class_variance_authority = require("class-variance-authority");
|
|
990
|
-
var
|
|
999
|
+
var import_react_hook_form3 = require("react-hook-form");
|
|
1000
|
+
var import_react_intl6 = require("react-intl");
|
|
1001
|
+
var import_jsx_runtime32 = require("react/jsx-runtime");
|
|
991
1002
|
var buttonStyles = (0, import_class_variance_authority.cva)(
|
|
992
1003
|
[
|
|
993
|
-
"
|
|
994
|
-
"disabled:cursor-not-allowed loading:before:pointer-events-none
|
|
995
|
-
"transition-colors ease-linear
|
|
1004
|
+
"relative flex justify-center gap-3 overflow-hidden rounded leading-none ring-1 ring-inset font-medium",
|
|
1005
|
+
"disabled:cursor-not-allowed loading:cursor-wait loading:before:pointer-events-none",
|
|
1006
|
+
"transition-colors duration-100 ease-linear",
|
|
1007
|
+
"p-4 max-w-[488px]"
|
|
996
1008
|
],
|
|
997
1009
|
{
|
|
998
1010
|
variants: {
|
|
999
1011
|
intent: {
|
|
1000
1012
|
primary: [
|
|
1001
|
-
"bg-button-primary-
|
|
1002
|
-
"hover:bg-button-primary-
|
|
1003
|
-
"disabled:bg-button-primary-
|
|
1004
|
-
"loading:bg-button-primary-
|
|
1005
|
-
"loading:before:absolute loading:before:
|
|
1013
|
+
"bg-button-primary-background-default text-button-primary-foreground-default ring-button-primary-border-default",
|
|
1014
|
+
"hover:bg-button-primary-background-hover hover:text-button-primary-foreground-hover hover:ring-button-primary-border-hover",
|
|
1015
|
+
"disabled:bg-button-primary-background-disabled disabled:text-button-primary-foreground-disabled disabled:ring-button-primary-border-disabled",
|
|
1016
|
+
"loading:bg-button-primary-background-default loading:text-button-primary-foreground-default loading:ring-button-primary-border-default",
|
|
1017
|
+
"loading:before:absolute loading:before:inset-0 loading:before:bg-button-primary-background-default loading:before:opacity-80 loading:before:content-['']",
|
|
1018
|
+
"disabled:bg-button-primary-background-disabled disabled:text-button-primary-foreground-disabled disabled:ring-button-primary-border-disabled"
|
|
1006
1019
|
],
|
|
1007
1020
|
secondary: [
|
|
1008
|
-
"bg-button-secondary-
|
|
1009
|
-
"hover:bg-button-secondary-
|
|
1010
|
-
"disabled:bg-button-secondary-
|
|
1011
|
-
"loading:bg-button-secondary-
|
|
1012
|
-
"loading:before:absolute loading:before:
|
|
1021
|
+
"bg-button-secondary-background-default text-button-secondary-foreground-default ring-button-secondary-border-default",
|
|
1022
|
+
"hover:bg-button-secondary-background-hover hover:text-button-secondary-foreground-hover hover:ring-button-secondary-border-hover",
|
|
1023
|
+
"disabled:bg-button-secondary-background-disabled disabled:text-button-secondary-foreground-disabled disabled:ring-button-secondary-border-disabled",
|
|
1024
|
+
"loading:bg-button-secondary-background-default loading:text-button-secondary-foreground-default loading:ring-button-secondary-border-default",
|
|
1025
|
+
"loading:before:absolute loading:before:inset-0 loading:before:bg-button-secondary-background-default loading:before:opacity-80 loading:before:content-['']"
|
|
1013
1026
|
]
|
|
1014
1027
|
},
|
|
1015
|
-
size: {
|
|
1016
|
-
default: ["px-4 py-3"],
|
|
1017
|
-
large: ["px-4 py-4.5 max-md:py-3"]
|
|
1018
|
-
},
|
|
1019
1028
|
defaultVariants: {
|
|
1020
|
-
intent: "primary"
|
|
1021
|
-
size: "default"
|
|
1029
|
+
intent: "primary"
|
|
1022
1030
|
}
|
|
1023
1031
|
}
|
|
1024
1032
|
}
|
|
@@ -1042,14 +1050,12 @@ var DefaultButton = ({
|
|
|
1042
1050
|
} = attributes;
|
|
1043
1051
|
const intl = (0, import_react_intl6.useIntl)();
|
|
1044
1052
|
const label = (0, import_client_fetch5.getNodeLabel)(node);
|
|
1045
|
-
const { flowType } = (0, import_elements_react8.useOryFlow)();
|
|
1046
1053
|
const {
|
|
1047
1054
|
formState: { isSubmitting },
|
|
1048
1055
|
setValue
|
|
1049
|
-
} = (0,
|
|
1056
|
+
} = (0, import_react_hook_form3.useFormContext)();
|
|
1050
1057
|
const isPrimary = attributes.name === "method" || attributes.name.includes("passkey") || attributes.name.includes("webauthn") || attributes.name.includes("lookup_secret");
|
|
1051
|
-
|
|
1052
|
-
return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
|
|
1058
|
+
return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
|
|
1053
1059
|
"button",
|
|
1054
1060
|
{
|
|
1055
1061
|
...rest,
|
|
@@ -1066,14 +1072,13 @@ var DefaultButton = ({
|
|
|
1066
1072
|
}
|
|
1067
1073
|
},
|
|
1068
1074
|
className: buttonStyles({
|
|
1069
|
-
intent: isPrimary ? "primary" : "secondary"
|
|
1070
|
-
size: isSmall ? "default" : "large"
|
|
1075
|
+
intent: isPrimary ? "primary" : "secondary"
|
|
1071
1076
|
}),
|
|
1072
1077
|
disabled: (_a = rest.disabled) != null ? _a : true,
|
|
1073
1078
|
"data-loading": isSubmitting,
|
|
1074
1079
|
children: [
|
|
1075
|
-
isSubmitting ? /* @__PURE__ */ (0,
|
|
1076
|
-
label ? (0, import_elements_react7.uiTextToFormattedMessage)(label, intl) : ""
|
|
1080
|
+
isSubmitting ? /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(Spinner, {}) : null,
|
|
1081
|
+
label ? /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", { children: (0, import_elements_react7.uiTextToFormattedMessage)(label, intl) }) : ""
|
|
1077
1082
|
]
|
|
1078
1083
|
}
|
|
1079
1084
|
);
|
|
@@ -1082,9 +1087,8 @@ DefaultButton.displayName = "DefaultButton";
|
|
|
1082
1087
|
|
|
1083
1088
|
// src/theme/default/components/form/checkbox.tsx
|
|
1084
1089
|
var import_client_fetch6 = require("@ory/client-fetch");
|
|
1085
|
-
var
|
|
1086
|
-
var
|
|
1087
|
-
var import_react_hook_form3 = require("react-hook-form");
|
|
1090
|
+
var import_elements_react8 = require("@ory/elements-react");
|
|
1091
|
+
var import_react_hook_form4 = require("react-hook-form");
|
|
1088
1092
|
var import_react_intl8 = require("react-intl");
|
|
1089
1093
|
|
|
1090
1094
|
// src/theme/default/components/ui/checkbox-label.tsx
|
|
@@ -1139,7 +1143,7 @@ var uiTextToFormattedMessage4 = ({ id, context = {}, text }, intl) => {
|
|
|
1139
1143
|
};
|
|
1140
1144
|
|
|
1141
1145
|
// src/theme/default/components/ui/checkbox-label.tsx
|
|
1142
|
-
var
|
|
1146
|
+
var import_jsx_runtime33 = require("react/jsx-runtime");
|
|
1143
1147
|
var linkRegex = /\[([^\]]+)\]\(([^)]+)\)/g;
|
|
1144
1148
|
function computeLabelElements(labelText) {
|
|
1145
1149
|
const elements = [];
|
|
@@ -1155,13 +1159,13 @@ function computeLabelElements(labelText) {
|
|
|
1155
1159
|
elements.push(labelText.slice(lastIndex, matchStart));
|
|
1156
1160
|
}
|
|
1157
1161
|
elements.push(
|
|
1158
|
-
/* @__PURE__ */ (0,
|
|
1162
|
+
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
1159
1163
|
"a",
|
|
1160
1164
|
{
|
|
1161
1165
|
href: url,
|
|
1162
1166
|
target: "_blank",
|
|
1163
1167
|
rel: "noopener noreferrer",
|
|
1164
|
-
className: "text-
|
|
1168
|
+
className: "text-button-link-brand-brand hover:text-button-link-brand-brand-hover underline",
|
|
1165
1169
|
children: linkText
|
|
1166
1170
|
},
|
|
1167
1171
|
matchStart
|
|
@@ -1180,39 +1184,29 @@ function CheckboxLabel({ label }) {
|
|
|
1180
1184
|
return null;
|
|
1181
1185
|
}
|
|
1182
1186
|
const labelText = uiTextToFormattedMessage4(label, intl);
|
|
1183
|
-
return /* @__PURE__ */ (0,
|
|
1187
|
+
return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_jsx_runtime33.Fragment, { children: computeLabelElements(labelText) });
|
|
1184
1188
|
}
|
|
1185
1189
|
|
|
1186
1190
|
// src/theme/default/components/form/checkbox.tsx
|
|
1187
|
-
var
|
|
1191
|
+
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
1188
1192
|
function CheckboxSVG() {
|
|
1189
|
-
return /* @__PURE__ */ (0,
|
|
1193
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
1190
1194
|
"svg",
|
|
1191
1195
|
{
|
|
1192
|
-
className: "absolute
|
|
1196
|
+
className: "absolute hidden size-4 peer-checked:block fill-checkbox-foreground-checked",
|
|
1193
1197
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1194
1198
|
width: "16",
|
|
1195
1199
|
height: "16",
|
|
1196
1200
|
viewBox: "0 0 16 16",
|
|
1197
1201
|
fill: "none",
|
|
1198
|
-
children:
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
/* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
|
|
1207
|
-
"path",
|
|
1208
|
-
{
|
|
1209
|
-
fillRule: "evenodd",
|
|
1210
|
-
clipRule: "evenodd",
|
|
1211
|
-
d: "M11.6464 5.14645C11.8417 4.95118 12.1583 4.95118 12.3536 5.14645C12.5338 5.32669 12.5477 5.6103 12.3951 5.80645L12.3536 5.85355L7.35355 10.8536C7.17331 11.0338 6.8897 11.0477 6.69355 10.8951L6.64645 10.8536L4.14645 8.35355C3.95118 8.15829 3.95118 7.84171 4.14645 7.64645C4.32669 7.4662 4.6103 7.45234 4.80645 7.60485L4.85355 7.64645L7 9.7925L11.6464 5.14645Z",
|
|
1212
|
-
fill: "white"
|
|
1213
|
-
}
|
|
1214
|
-
)
|
|
1215
|
-
]
|
|
1202
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
1203
|
+
"path",
|
|
1204
|
+
{
|
|
1205
|
+
fillRule: "evenodd",
|
|
1206
|
+
clipRule: "evenodd",
|
|
1207
|
+
d: "M11.6464 5.14645C11.8417 4.95118 12.1583 4.95118 12.3536 5.14645C12.5338 5.32669 12.5477 5.6103 12.3951 5.80645L12.3536 5.85355L7.35355 10.8536C7.17331 11.0338 6.8897 11.0477 6.69355 10.8951L6.64645 10.8536L4.14645 8.35355C3.95118 8.15829 3.95118 7.84171 4.14645 7.64645C4.32669 7.4662 4.6103 7.45234 4.80645 7.60485L4.85355 7.64645L7 9.7925L11.6464 5.14645Z"
|
|
1208
|
+
}
|
|
1209
|
+
)
|
|
1216
1210
|
}
|
|
1217
1211
|
);
|
|
1218
1212
|
}
|
|
@@ -1232,82 +1226,75 @@ var DefaultCheckbox = ({
|
|
|
1232
1226
|
} = initialAttributes;
|
|
1233
1227
|
const intl = (0, import_react_intl8.useIntl)();
|
|
1234
1228
|
const label = (0, import_client_fetch6.getNodeLabel)(node);
|
|
1235
|
-
const
|
|
1236
|
-
const
|
|
1237
|
-
return /* @__PURE__ */ (0,
|
|
1238
|
-
"
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
"
|
|
1248
|
-
|
|
1249
|
-
...attributes,
|
|
1250
|
-
checked,
|
|
1251
|
-
value: 1,
|
|
1252
|
-
type: "checkbox",
|
|
1253
|
-
className: cn(
|
|
1254
|
-
"peer w-4 h-4 border appearance-none rounded-border-radius-buttons",
|
|
1255
|
-
!checked && "bg-forms-checkbox-bg-default border-forms-checkbox-border-default",
|
|
1256
|
-
checked && "bg-forms-checkbox-bg-checked border-forms-checkbox-border-checked"
|
|
1257
|
-
),
|
|
1258
|
-
...register(name, { value })
|
|
1259
|
-
}
|
|
1229
|
+
const { register } = (0, import_react_hook_form4.useForm)();
|
|
1230
|
+
const hasError = node.messages.some((m) => m.type === "error");
|
|
1231
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("label", { className: "flex items-start gap-3 self-stretch antialiased", children: [
|
|
1232
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("span", { className: "flex h-5 items-center", children: [
|
|
1233
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
1234
|
+
"input",
|
|
1235
|
+
{
|
|
1236
|
+
...attributes,
|
|
1237
|
+
value: 1,
|
|
1238
|
+
defaultChecked: Boolean(value),
|
|
1239
|
+
type: "checkbox",
|
|
1240
|
+
className: cn(
|
|
1241
|
+
"peer size-4 border appearance-none rounded-forms bg-checkbox-background-default border-checkbox-border-checkbox-border-default checked:bg-checkbox-background-checked checked:border-checkbox-border-checkbox-border-checked",
|
|
1242
|
+
hasError && "border-interface-border-validation-danger"
|
|
1260
1243
|
),
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1244
|
+
...register(name, { value })
|
|
1245
|
+
}
|
|
1246
|
+
),
|
|
1247
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)(CheckboxSVG, {})
|
|
1248
|
+
] }),
|
|
1249
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("span", { className: "flex flex-col", children: [
|
|
1250
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { className: "font-normal leading-tight text-interface-foreground-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(CheckboxLabel, { label }) }),
|
|
1251
|
+
node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
|
|
1252
|
+
"span",
|
|
1253
|
+
{
|
|
1254
|
+
className: cn(
|
|
1255
|
+
"mt-1",
|
|
1256
|
+
message.type === "error" ? "text-interface-foreground-validation-danger" : "text-interface-foreground-default-secondary"
|
|
1257
|
+
),
|
|
1258
|
+
...(0, import_elements_react8.messageTestId)(message),
|
|
1259
|
+
children: (0, import_elements_react8.uiTextToFormattedMessage)(message, intl)
|
|
1260
|
+
},
|
|
1261
|
+
message.id
|
|
1262
|
+
))
|
|
1263
|
+
] })
|
|
1264
|
+
] });
|
|
1278
1265
|
};
|
|
1279
1266
|
|
|
1280
1267
|
// src/theme/default/components/form/group-container.tsx
|
|
1281
|
-
var
|
|
1268
|
+
var import_jsx_runtime35 = require("react/jsx-runtime");
|
|
1282
1269
|
function DefaultGroupContainer({ children }) {
|
|
1283
|
-
return /* @__PURE__ */ (0,
|
|
1270
|
+
return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { className: "grid grid-cols-1 gap-8", children });
|
|
1284
1271
|
}
|
|
1285
1272
|
|
|
1286
1273
|
// src/theme/default/components/form/horizontal-divider.tsx
|
|
1287
|
-
var
|
|
1274
|
+
var import_jsx_runtime36 = require("react/jsx-runtime");
|
|
1288
1275
|
function DefaultHorizontalDivider() {
|
|
1289
|
-
return /* @__PURE__ */ (0,
|
|
1276
|
+
return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("hr", { className: "border-interface-border-default-primary" });
|
|
1290
1277
|
}
|
|
1291
1278
|
|
|
1292
1279
|
// src/theme/default/components/form/image.tsx
|
|
1293
|
-
var
|
|
1280
|
+
var import_jsx_runtime37 = require("react/jsx-runtime");
|
|
1294
1281
|
function DefaultImage({ attributes }) {
|
|
1295
|
-
return /* @__PURE__ */ (0,
|
|
1282
|
+
return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("figure", { children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("img", { ...attributes }) });
|
|
1296
1283
|
}
|
|
1297
1284
|
|
|
1298
1285
|
// src/theme/default/components/form/input.tsx
|
|
1299
1286
|
var import_client_fetch7 = require("@ory/client-fetch");
|
|
1300
|
-
var
|
|
1301
|
-
var
|
|
1287
|
+
var import_elements_react9 = require("@ory/elements-react");
|
|
1288
|
+
var import_react_hook_form5 = require("react-hook-form");
|
|
1302
1289
|
var import_react_intl9 = require("react-intl");
|
|
1303
|
-
var
|
|
1290
|
+
var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
1304
1291
|
var DefaultInput = ({
|
|
1305
1292
|
node,
|
|
1306
1293
|
attributes,
|
|
1307
1294
|
onClick
|
|
1308
1295
|
}) => {
|
|
1309
1296
|
const label = (0, import_client_fetch7.getNodeLabel)(node);
|
|
1310
|
-
const { register } = (0,
|
|
1297
|
+
const { register } = (0, import_react_hook_form5.useFormContext)();
|
|
1311
1298
|
const {
|
|
1312
1299
|
value,
|
|
1313
1300
|
autocomplete,
|
|
@@ -1317,17 +1304,17 @@ var DefaultInput = ({
|
|
|
1317
1304
|
...rest
|
|
1318
1305
|
} = attributes;
|
|
1319
1306
|
const intl = (0, import_react_intl9.useIntl)();
|
|
1320
|
-
const { flowType } = (0,
|
|
1307
|
+
const { flowType } = (0, import_elements_react9.useOryFlow)();
|
|
1321
1308
|
const formattedLabel = label ? intl.formatMessage(
|
|
1322
1309
|
{
|
|
1323
1310
|
id: "input.placeholder",
|
|
1324
1311
|
defaultMessage: "Enter your {placeholder}"
|
|
1325
1312
|
},
|
|
1326
1313
|
{
|
|
1327
|
-
placeholder: (0,
|
|
1314
|
+
placeholder: (0, import_elements_react9.uiTextToFormattedMessage)(label, intl)
|
|
1328
1315
|
}
|
|
1329
1316
|
) : "";
|
|
1330
|
-
return /* @__PURE__ */ (0,
|
|
1317
|
+
return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
1331
1318
|
"input",
|
|
1332
1319
|
{
|
|
1333
1320
|
...rest,
|
|
@@ -1336,10 +1323,14 @@ var DefaultInput = ({
|
|
|
1336
1323
|
autoComplete: autocomplete,
|
|
1337
1324
|
placeholder: formattedLabel,
|
|
1338
1325
|
className: cn(
|
|
1339
|
-
"antialiased
|
|
1340
|
-
"
|
|
1326
|
+
"antialiased rounded-forms border leading-tight transition-colors placeholder:h-[20px] placeholder:text-input-foreground-tertiary focus-visible:outline-none focus:ring-0",
|
|
1327
|
+
"bg-input-background-default border-input-border-default text-input-foreground-primary",
|
|
1328
|
+
"disabled:bg-input-background-disabled disabled:border-input-border-disabled disabled:text-input-foreground-disabled",
|
|
1329
|
+
"focus:border-input-border-focus focus-visible:border-input-border-focus",
|
|
1330
|
+
"hover:bg-input-background-hover hover:border-input-border-hover",
|
|
1331
|
+
"px-4 py-[13px]",
|
|
1341
1332
|
// The settings flow input fields are supposed to be dense, so we don't need the extra padding we want on the user flows.
|
|
1342
|
-
flowType === import_client_fetch7.FlowType.Settings
|
|
1333
|
+
flowType === import_client_fetch7.FlowType.Settings && "max-w-[488px]"
|
|
1343
1334
|
),
|
|
1344
1335
|
...register(name, { value })
|
|
1345
1336
|
}
|
|
@@ -1348,10 +1339,10 @@ var DefaultInput = ({
|
|
|
1348
1339
|
|
|
1349
1340
|
// src/theme/default/components/form/label.tsx
|
|
1350
1341
|
var import_client_fetch8 = require("@ory/client-fetch");
|
|
1351
|
-
var
|
|
1352
|
-
var
|
|
1342
|
+
var import_elements_react10 = require("@ory/elements-react");
|
|
1343
|
+
var import_react_hook_form6 = require("react-hook-form");
|
|
1353
1344
|
var import_react_intl10 = require("react-intl");
|
|
1354
|
-
var
|
|
1345
|
+
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
1355
1346
|
function findResendNode(nodes) {
|
|
1356
1347
|
return nodes.find(
|
|
1357
1348
|
(n) => "name" in n.attributes && (n.attributes.name === "email" && n.attributes.type === "submit" || n.attributes.name === "resend")
|
|
@@ -1365,9 +1356,9 @@ function DefaultLabel({
|
|
|
1365
1356
|
}) {
|
|
1366
1357
|
const intl = (0, import_react_intl10.useIntl)();
|
|
1367
1358
|
const label = (0, import_client_fetch8.getNodeLabel)(node);
|
|
1368
|
-
const { Message } = (0,
|
|
1369
|
-
const { config, flowType, flow } = (0,
|
|
1370
|
-
const { setValue, formState } = (0,
|
|
1359
|
+
const { Message } = (0, import_elements_react10.useComponents)();
|
|
1360
|
+
const { config, flowType, flow } = (0, import_elements_react10.useOryFlow)();
|
|
1361
|
+
const { setValue, formState } = (0, import_react_hook_form6.useFormContext)();
|
|
1371
1362
|
const isPassword = attributes.type === "password";
|
|
1372
1363
|
const resendNode = findResendNode(flow.ui.nodes);
|
|
1373
1364
|
const handleResend = () => {
|
|
@@ -1376,80 +1367,80 @@ function DefaultLabel({
|
|
|
1376
1367
|
}
|
|
1377
1368
|
};
|
|
1378
1369
|
const fieldError = formState.errors[attributes.name];
|
|
1379
|
-
return /* @__PURE__ */ (0,
|
|
1380
|
-
label && /* @__PURE__ */ (0,
|
|
1381
|
-
/* @__PURE__ */ (0,
|
|
1370
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "flex flex-col gap-1 antialiased", children: [
|
|
1371
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("span", { className: "inline-flex justify-between", children: [
|
|
1372
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
1382
1373
|
"label",
|
|
1383
1374
|
{
|
|
1384
|
-
...(0,
|
|
1385
|
-
className: "
|
|
1375
|
+
...(0, import_elements_react10.messageTestId)(label),
|
|
1376
|
+
className: "leading-normal text-input-foreground-primary",
|
|
1386
1377
|
htmlFor: attributes.name,
|
|
1387
1378
|
...rest,
|
|
1388
|
-
children: (0,
|
|
1379
|
+
children: (0, import_elements_react10.uiTextToFormattedMessage)(label, intl)
|
|
1389
1380
|
}
|
|
1390
1381
|
),
|
|
1391
1382
|
isPassword && config.project.recovery_enabled && flowType === import_client_fetch8.FlowType.Login && // TODO: make it possible to override with a custom component
|
|
1392
|
-
/* @__PURE__ */ (0,
|
|
1383
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
1393
1384
|
"a",
|
|
1394
1385
|
{
|
|
1395
1386
|
href: config.project.recovery_ui_url,
|
|
1396
|
-
className: "text-
|
|
1387
|
+
className: "text-button-link-brand-brand transition-colors hover:text-button-link-brand-brand-hover underline",
|
|
1397
1388
|
children: intl.formatMessage({
|
|
1398
1389
|
id: "forms.label.forgot-password",
|
|
1399
1390
|
defaultMessage: "Forgot password?"
|
|
1400
1391
|
})
|
|
1401
1392
|
}
|
|
1402
1393
|
),
|
|
1403
|
-
(resendNode == null ? void 0 : resendNode.attributes.node_type) === "input" && /* @__PURE__ */ (0,
|
|
1394
|
+
(resendNode == null ? void 0 : resendNode.attributes.node_type) === "input" && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
1404
1395
|
"button",
|
|
1405
1396
|
{
|
|
1406
1397
|
type: "submit",
|
|
1407
1398
|
name: resendNode.attributes.name,
|
|
1408
1399
|
value: resendNode.attributes.value,
|
|
1409
1400
|
onClick: handleResend,
|
|
1410
|
-
className: "text-
|
|
1401
|
+
className: "cursor-pointer text-button-link-brand-brand transition-colors hover:text-button-link-brand-brand-hover underline",
|
|
1411
1402
|
children: intl.formatMessage({ id: "identities.messages.1070008" })
|
|
1412
1403
|
}
|
|
1413
1404
|
)
|
|
1414
1405
|
] }),
|
|
1415
1406
|
children,
|
|
1416
|
-
node.messages.map((message) => /* @__PURE__ */ (0,
|
|
1417
|
-
fieldError && (0, import_client_fetch8.instanceOfUiText)(fieldError) && /* @__PURE__ */ (0,
|
|
1407
|
+
node.messages.map((message) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Message.Content, { message }, message.id)),
|
|
1408
|
+
fieldError && (0, import_client_fetch8.instanceOfUiText)(fieldError) && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Message.Content, { message: fieldError })
|
|
1418
1409
|
] });
|
|
1419
1410
|
}
|
|
1420
1411
|
|
|
1421
1412
|
// src/theme/default/components/form/link-button.tsx
|
|
1422
1413
|
var import_client_fetch9 = require("@ory/client-fetch");
|
|
1423
|
-
var
|
|
1424
|
-
var
|
|
1414
|
+
var import_elements_react11 = require("@ory/elements-react");
|
|
1415
|
+
var import_react = require("react");
|
|
1425
1416
|
var import_react_intl11 = require("react-intl");
|
|
1426
|
-
var
|
|
1427
|
-
var DefaultLinkButton = (0,
|
|
1417
|
+
var import_jsx_runtime40 = require("react/jsx-runtime");
|
|
1418
|
+
var DefaultLinkButton = (0, import_react.forwardRef)(({ attributes, node }, ref) => {
|
|
1428
1419
|
const intl = (0, import_react_intl11.useIntl)();
|
|
1429
1420
|
const label = (0, import_client_fetch9.getNodeLabel)(node);
|
|
1430
|
-
return /* @__PURE__ */ (0,
|
|
1421
|
+
return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
1431
1422
|
"a",
|
|
1432
1423
|
{
|
|
1433
1424
|
...attributes,
|
|
1434
1425
|
ref,
|
|
1435
|
-
title: label ? (0,
|
|
1426
|
+
title: label ? (0, import_elements_react11.uiTextToFormattedMessage)(label, intl) : "",
|
|
1436
1427
|
className: cn(
|
|
1437
|
-
"antialiased rounded cursor-pointer text-center border
|
|
1428
|
+
"antialiased rounded cursor-pointer text-center border gap-3 leading-none bg-button-primary-background-default hover:bg-button-primary-background-hover transition-colors text-button-primary-foreground-default hover:text-button-primary-foreground-hover p-4 font-medium"
|
|
1438
1429
|
),
|
|
1439
|
-
children: label ? (0,
|
|
1430
|
+
children: label ? (0, import_elements_react11.uiTextToFormattedMessage)(label, intl) : ""
|
|
1440
1431
|
}
|
|
1441
1432
|
);
|
|
1442
1433
|
});
|
|
1443
1434
|
DefaultLinkButton.displayName = "DefaultLinkButton";
|
|
1444
1435
|
|
|
1445
1436
|
// src/theme/default/components/form/pin-code-input.tsx
|
|
1446
|
-
var
|
|
1437
|
+
var import_react_hook_form7 = require("react-hook-form");
|
|
1447
1438
|
|
|
1448
1439
|
// src/theme/default/components/form/shadcn/otp-input.tsx
|
|
1449
1440
|
var import_input_otp = require("input-otp");
|
|
1450
1441
|
var React21 = __toESM(require("react"));
|
|
1451
|
-
var
|
|
1452
|
-
var InputOTP = React21.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ (0,
|
|
1442
|
+
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
1443
|
+
var InputOTP = React21.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
1453
1444
|
import_input_otp.OTPInput,
|
|
1454
1445
|
{
|
|
1455
1446
|
ref,
|
|
@@ -1462,24 +1453,25 @@ var InputOTP = React21.forwardRef(({ className, containerClassName, ...props },
|
|
|
1462
1453
|
}
|
|
1463
1454
|
));
|
|
1464
1455
|
InputOTP.displayName = "InputOTP";
|
|
1465
|
-
var InputOTPGroup = React21.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0,
|
|
1456
|
+
var InputOTPGroup = React21.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { ref, className: cn("flex items-center", className), ...props }));
|
|
1466
1457
|
InputOTPGroup.displayName = "InputOTPGroup";
|
|
1467
1458
|
var InputOTPSlot = React21.forwardRef(({ index, className, ...props }, ref) => {
|
|
1468
1459
|
const inputOTPContext = React21.useContext(import_input_otp.OTPInputContext);
|
|
1469
1460
|
const { char, hasFakeCaret, isActive } = inputOTPContext.slots[index];
|
|
1470
|
-
return /* @__PURE__ */ (0,
|
|
1461
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(
|
|
1471
1462
|
"div",
|
|
1472
1463
|
{
|
|
1473
1464
|
ref,
|
|
1474
1465
|
className: cn(
|
|
1475
|
-
"
|
|
1476
|
-
|
|
1466
|
+
"rounded-forms border border-solid bg-input-background-default py-[15px] text-center focus-visible:outline-none w-full",
|
|
1467
|
+
"relative flex items-center justify-center transition-all leading-none",
|
|
1468
|
+
isActive ? "border-input-border-focus" : "border-input-border-default",
|
|
1477
1469
|
className
|
|
1478
1470
|
),
|
|
1479
1471
|
...props,
|
|
1480
1472
|
children: [
|
|
1481
|
-
char,
|
|
1482
|
-
hasFakeCaret && /* @__PURE__ */ (0,
|
|
1473
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)("span", { className: "inline-block size-4", children: char }),
|
|
1474
|
+
hasFakeCaret && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: "h-4 w-px animate-caret-blink bg-interface-background-brand-primary duration-700" }) })
|
|
1483
1475
|
]
|
|
1484
1476
|
}
|
|
1485
1477
|
);
|
|
@@ -1487,66 +1479,97 @@ var InputOTPSlot = React21.forwardRef(({ index, className, ...props }, ref) => {
|
|
|
1487
1479
|
InputOTPSlot.displayName = "InputOTPSlot";
|
|
1488
1480
|
|
|
1489
1481
|
// src/theme/default/components/form/pin-code-input.tsx
|
|
1490
|
-
var
|
|
1482
|
+
var import_elements_react12 = require("@ory/elements-react");
|
|
1483
|
+
var import_client_fetch10 = require("@ory/client-fetch");
|
|
1484
|
+
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
1491
1485
|
var DefaultPinCodeInput = ({ attributes }) => {
|
|
1492
|
-
const { setValue, watch } = (0,
|
|
1486
|
+
const { setValue, watch } = (0, import_react_hook_form7.useFormContext)();
|
|
1493
1487
|
const { maxlength, name } = attributes;
|
|
1494
1488
|
const elements = maxlength != null ? maxlength : 6;
|
|
1489
|
+
const { flowType } = (0, import_elements_react12.useOryFlow)();
|
|
1495
1490
|
const handleInputChange = (v) => {
|
|
1496
1491
|
setValue(name, v);
|
|
1497
1492
|
};
|
|
1498
1493
|
const value = watch(name);
|
|
1499
|
-
return /* @__PURE__ */ (0,
|
|
1494
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
1500
1495
|
InputOTP,
|
|
1501
1496
|
{
|
|
1502
1497
|
maxLength: maxlength != null ? maxlength : 6,
|
|
1503
1498
|
onChange: handleInputChange,
|
|
1504
1499
|
name,
|
|
1505
1500
|
value,
|
|
1506
|
-
children: /* @__PURE__ */ (0,
|
|
1507
|
-
|
|
1501
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
|
|
1502
|
+
InputOTPGroup,
|
|
1508
1503
|
{
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1504
|
+
className: cn(
|
|
1505
|
+
"w-full flex gap-2 justify-stretch",
|
|
1506
|
+
// The settings flow input fields are supposed to be dense, so we don't need the extra padding we want on the user flows.
|
|
1507
|
+
flowType === import_client_fetch10.FlowType.Settings && "max-w-[488px]"
|
|
1508
|
+
),
|
|
1509
|
+
children: [...Array(elements)].map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(InputOTPSlot, { index }, index))
|
|
1510
|
+
}
|
|
1511
|
+
)
|
|
1514
1512
|
}
|
|
1515
1513
|
);
|
|
1516
1514
|
};
|
|
1517
1515
|
|
|
1518
1516
|
// src/theme/default/components/form/section.tsx
|
|
1519
|
-
var
|
|
1520
|
-
var DefaultFormSection = ({
|
|
1521
|
-
|
|
1517
|
+
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
1518
|
+
var DefaultFormSection = ({
|
|
1519
|
+
children,
|
|
1520
|
+
nodes: _nodes,
|
|
1521
|
+
...rest
|
|
1522
|
+
}) => {
|
|
1523
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
1524
|
+
"form",
|
|
1525
|
+
{
|
|
1526
|
+
className: "flex w-full max-w-screen-sm flex-col md:max-w-[712px] lg:max-w-[802px] xl:max-w-[896px] px-4",
|
|
1527
|
+
...rest,
|
|
1528
|
+
children
|
|
1529
|
+
}
|
|
1530
|
+
);
|
|
1522
1531
|
};
|
|
1523
1532
|
var DefaultFormSectionContent = ({
|
|
1524
1533
|
title,
|
|
1525
1534
|
description,
|
|
1526
1535
|
children
|
|
1527
1536
|
}) => {
|
|
1528
|
-
return /* @__PURE__ */ (0,
|
|
1529
|
-
/* @__PURE__ */ (0,
|
|
1530
|
-
/* @__PURE__ */ (0,
|
|
1531
|
-
/* @__PURE__ */ (0,
|
|
1537
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "flex flex-col gap-8 rounded-t-xl border border-b-0 border-interface-border-default-primary bg-interface-background-default-primary px-6 py-8", children: [
|
|
1538
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "flex flex-col gap-2", children: [
|
|
1539
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("h3", { className: "font-medium text-interface-foreground-default-primary", children: title }),
|
|
1540
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "text-interface-foreground-default-secondary", children: description })
|
|
1532
1541
|
] }),
|
|
1533
1542
|
children
|
|
1534
1543
|
] });
|
|
1535
1544
|
};
|
|
1536
|
-
var DefaultFormSectionFooter = ({
|
|
1537
|
-
|
|
1545
|
+
var DefaultFormSectionFooter = ({
|
|
1546
|
+
children,
|
|
1547
|
+
text
|
|
1548
|
+
}) => {
|
|
1549
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
|
|
1550
|
+
"div",
|
|
1551
|
+
{
|
|
1552
|
+
className: cn(
|
|
1553
|
+
"flex min-h-[72px] items-center justify-between gap-2 rounded-b-xl border border-interface-border-default-primary bg-interface-background-default-secondary px-6 py-4 text-interface-foreground-default-tertiary"
|
|
1554
|
+
),
|
|
1555
|
+
children: [
|
|
1556
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { children: text }),
|
|
1557
|
+
children
|
|
1558
|
+
]
|
|
1559
|
+
}
|
|
1560
|
+
);
|
|
1538
1561
|
};
|
|
1539
1562
|
|
|
1540
1563
|
// src/theme/default/components/form/text.tsx
|
|
1541
1564
|
var import_elements_react13 = require("@ory/elements-react");
|
|
1542
1565
|
var import_react_intl12 = require("react-intl");
|
|
1543
|
-
var
|
|
1566
|
+
var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
1544
1567
|
function DefaultText({ node, attributes }) {
|
|
1545
1568
|
var _a;
|
|
1546
1569
|
const intl = (0, import_react_intl12.useIntl)();
|
|
1547
|
-
return /* @__PURE__ */ (0,
|
|
1548
|
-
/* @__PURE__ */ (0,
|
|
1549
|
-
(_a = attributes.text.context.secrets) == null ? void 0 : _a.map((text, index) => /* @__PURE__ */ (0,
|
|
1570
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_jsx_runtime44.Fragment, { children: [
|
|
1571
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)("p", { "data-testid": `node/text/${attributes.id}/label`, children: node.meta.label ? (0, import_elements_react13.uiTextToFormattedMessage)(node.meta.label, intl) : "" }),
|
|
1572
|
+
(_a = attributes.text.context.secrets) == null ? void 0 : _a.map((text, index) => /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("pre", { "data-testid": `node/text/lookup_secret_codes/text`, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("code", { children: text ? (0, import_elements_react13.uiTextToFormattedMessage)(text, intl) : "" }) }, index))
|
|
1550
1573
|
] });
|
|
1551
1574
|
}
|
|
1552
1575
|
|
|
@@ -1555,13 +1578,13 @@ var import_elements_react15 = require("@ory/elements-react");
|
|
|
1555
1578
|
|
|
1556
1579
|
// src/theme/default/components/ui/user-menu.tsx
|
|
1557
1580
|
var import_react_dropdown_menu = require("@radix-ui/react-dropdown-menu");
|
|
1558
|
-
var
|
|
1581
|
+
var import_react4 = require("react");
|
|
1559
1582
|
var import_elements_react14 = require("@ory/elements-react");
|
|
1560
1583
|
|
|
1561
1584
|
// src/util/client.ts
|
|
1562
|
-
var
|
|
1585
|
+
var import_client_fetch11 = require("@ory/client-fetch");
|
|
1563
1586
|
function frontendClient(sdkUrl, opts = {}) {
|
|
1564
|
-
const config = new
|
|
1587
|
+
const config = new import_client_fetch11.Configuration({
|
|
1565
1588
|
...opts,
|
|
1566
1589
|
basePath: sdkUrl,
|
|
1567
1590
|
headers: {
|
|
@@ -1569,37 +1592,40 @@ function frontendClient(sdkUrl, opts = {}) {
|
|
|
1569
1592
|
...opts.headers
|
|
1570
1593
|
}
|
|
1571
1594
|
});
|
|
1572
|
-
return new
|
|
1595
|
+
return new import_client_fetch11.FrontendApi(config);
|
|
1573
1596
|
}
|
|
1574
1597
|
|
|
1575
1598
|
// src/theme/default/assets/icons/logout.svg
|
|
1576
1599
|
var React22 = __toESM(require("react"));
|
|
1577
|
-
var
|
|
1600
|
+
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
1578
1601
|
var SvgLogout = (props) => {
|
|
1579
1602
|
var _a, _b;
|
|
1580
|
-
return /* @__PURE__ */ (0,
|
|
1603
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.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_runtime45.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" }) });
|
|
1581
1604
|
};
|
|
1582
1605
|
var logout_default = SvgLogout;
|
|
1583
1606
|
|
|
1584
1607
|
// src/theme/default/assets/icons/settings.svg
|
|
1585
1608
|
var React23 = __toESM(require("react"));
|
|
1586
|
-
var
|
|
1609
|
+
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
1587
1610
|
var SvgSettings = (props) => {
|
|
1588
1611
|
var _a, _b;
|
|
1589
|
-
return /* @__PURE__ */ (0,
|
|
1590
|
-
/* @__PURE__ */ (0,
|
|
1591
|
-
/* @__PURE__ */ (0,
|
|
1612
|
+
return /* @__PURE__ */ (0, import_jsx_runtime46.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_runtime46.jsxs)("g", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
1613
|
+
/* @__PURE__ */ (0, import_jsx_runtime46.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" }),
|
|
1614
|
+
/* @__PURE__ */ (0, import_jsx_runtime46.jsx)("path", { d: "M6 8a2 2 0 1 0 4 0 2 2 0 0 0-4 0" })
|
|
1592
1615
|
] }) });
|
|
1593
1616
|
};
|
|
1594
1617
|
var settings_default = SvgSettings;
|
|
1595
1618
|
|
|
1596
1619
|
// src/theme/default/utils/user.ts
|
|
1620
|
+
function isTraitsIndexable(traits) {
|
|
1621
|
+
return typeof traits === "object" && traits !== null;
|
|
1622
|
+
}
|
|
1597
1623
|
var getUserInitials = (session) => {
|
|
1598
1624
|
var _a, _b;
|
|
1599
1625
|
const avatar = "";
|
|
1600
1626
|
let primary = "";
|
|
1601
1627
|
let secondary = "";
|
|
1602
|
-
if (!((_a = session == null ? void 0 : session.identity) == null ? void 0 : _a.traits)) {
|
|
1628
|
+
if (!((_a = session == null ? void 0 : session.identity) == null ? void 0 : _a.traits) || !isTraitsIndexable(session.identity.traits)) {
|
|
1603
1629
|
return {
|
|
1604
1630
|
primary,
|
|
1605
1631
|
secondary,
|
|
@@ -1607,14 +1633,14 @@ var getUserInitials = (session) => {
|
|
|
1607
1633
|
};
|
|
1608
1634
|
}
|
|
1609
1635
|
const traits = (_b = session.identity) == null ? void 0 : _b.traits;
|
|
1610
|
-
if (traits.email) {
|
|
1636
|
+
if (traits.email && typeof traits.email === "string") {
|
|
1611
1637
|
secondary = traits.email;
|
|
1612
1638
|
}
|
|
1613
1639
|
if (traits.name) {
|
|
1614
1640
|
if (typeof traits.name === "string") {
|
|
1615
1641
|
primary = traits.name;
|
|
1616
1642
|
}
|
|
1617
|
-
if (traits.name.first && traits.name.last) {
|
|
1643
|
+
if (typeof traits.name === "object" && traits.name && traits.name.first && traits.name.last) {
|
|
1618
1644
|
primary = traits.name.first + " " + traits.name.last;
|
|
1619
1645
|
}
|
|
1620
1646
|
}
|
|
@@ -1630,12 +1656,12 @@ var getUserInitials = (session) => {
|
|
|
1630
1656
|
};
|
|
1631
1657
|
|
|
1632
1658
|
// src/theme/default/components/ui/dropdown-menu.tsx
|
|
1633
|
-
var
|
|
1659
|
+
var import_react2 = require("react");
|
|
1634
1660
|
var DropdownMenuPrimitive = __toESM(require("@radix-ui/react-dropdown-menu"));
|
|
1635
|
-
var
|
|
1661
|
+
var import_jsx_runtime47 = require("react/jsx-runtime");
|
|
1636
1662
|
var DropdownMenu = DropdownMenuPrimitive.Root;
|
|
1637
1663
|
var DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
|
|
1638
|
-
var DropdownMenuContent = (0,
|
|
1664
|
+
var DropdownMenuContent = (0, import_react2.forwardRef)(({ className, sideOffset = 16, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1639
1665
|
DropdownMenuPrimitive.Content,
|
|
1640
1666
|
{
|
|
1641
1667
|
ref,
|
|
@@ -1643,24 +1669,24 @@ var DropdownMenuContent = (0, import_react3.forwardRef)(({ className, sideOffset
|
|
|
1643
1669
|
align: "end",
|
|
1644
1670
|
className: cn(
|
|
1645
1671
|
"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",
|
|
1646
|
-
"border border-
|
|
1672
|
+
"border border-interface-border-default-primary bg-interface-background-default-primary rounded-cards",
|
|
1647
1673
|
className
|
|
1648
1674
|
),
|
|
1649
1675
|
...props
|
|
1650
1676
|
}
|
|
1651
1677
|
) }));
|
|
1652
1678
|
DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
|
|
1653
|
-
var DropdownMenuItem = (0,
|
|
1679
|
+
var DropdownMenuItem = (0, import_react2.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1654
1680
|
DropdownMenuPrimitive.Item,
|
|
1655
1681
|
{
|
|
1656
1682
|
ref,
|
|
1657
1683
|
className: cn(
|
|
1658
1684
|
"relative flex cursor-pointer select-none items-center outline-none transition-colors data-[disabled]:pointer-events-none",
|
|
1659
1685
|
"px-8 py-3 lg:py-4.5 text-sm gap-6",
|
|
1660
|
-
"first:border-0 border-t border-button-secondary-border-default hover:border-button-social-border-hover
|
|
1661
|
-
"text-button-secondary-
|
|
1662
|
-
"hover:text-button-secondary-
|
|
1663
|
-
"data-[disabled]:text-button-secondary-
|
|
1686
|
+
"first:border-0 border-t border-button-secondary-border-default hover:border-button-social-border-hover",
|
|
1687
|
+
"text-button-secondary-foreground-default bg-button-secondary-background-default",
|
|
1688
|
+
"hover:text-button-secondary-foreground-hover hover:bg-button-secondary-background-hover",
|
|
1689
|
+
"data-[disabled]:text-button-secondary-foreground-disabled data-[disabled]:bg-button-secondary-background-disabled",
|
|
1664
1690
|
inset && "pl-8",
|
|
1665
1691
|
className
|
|
1666
1692
|
),
|
|
@@ -1668,7 +1694,7 @@ var DropdownMenuItem = (0, import_react3.forwardRef)(({ className, inset, ...pro
|
|
|
1668
1694
|
}
|
|
1669
1695
|
));
|
|
1670
1696
|
DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
|
|
1671
|
-
var DropdownMenuLabel = (0,
|
|
1697
|
+
var DropdownMenuLabel = (0, import_react2.forwardRef)(({ className, inset, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
|
|
1672
1698
|
DropdownMenuPrimitive.Label,
|
|
1673
1699
|
{
|
|
1674
1700
|
ref,
|
|
@@ -1683,35 +1709,41 @@ var DropdownMenuLabel = (0, import_react3.forwardRef)(({ className, inset, ...pr
|
|
|
1683
1709
|
DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
|
|
1684
1710
|
|
|
1685
1711
|
// src/theme/default/components/ui/user-avater.tsx
|
|
1686
|
-
var
|
|
1712
|
+
var import_react3 = require("react");
|
|
1687
1713
|
|
|
1688
1714
|
// src/theme/default/assets/icons/user.svg
|
|
1689
1715
|
var React24 = __toESM(require("react"));
|
|
1690
|
-
var
|
|
1716
|
+
var import_jsx_runtime48 = require("react/jsx-runtime");
|
|
1691
1717
|
var SvgUser = (props) => {
|
|
1692
1718
|
var _a, _b;
|
|
1693
|
-
return /* @__PURE__ */ (0,
|
|
1719
|
+
return /* @__PURE__ */ (0, import_jsx_runtime48.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_runtime48.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" }) });
|
|
1694
1720
|
};
|
|
1695
1721
|
var user_default = SvgUser;
|
|
1696
1722
|
|
|
1697
1723
|
// src/theme/default/components/ui/user-avater.tsx
|
|
1698
|
-
var
|
|
1699
|
-
var UserAvatar = (0,
|
|
1724
|
+
var import_jsx_runtime49 = require("react/jsx-runtime");
|
|
1725
|
+
var UserAvatar = (0, import_react3.forwardRef)(
|
|
1700
1726
|
({ initials, ...rest }, ref) => {
|
|
1701
|
-
return /* @__PURE__ */ (0,
|
|
1727
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
1702
1728
|
"button",
|
|
1703
1729
|
{
|
|
1704
1730
|
ref,
|
|
1705
|
-
className: "
|
|
1731
|
+
className: "relative flex size-10 items-center justify-center overflow-hidden rounded-full bg-button-primary-background-default hover:bg-button-primary-background-hover",
|
|
1706
1732
|
...rest,
|
|
1707
|
-
children: /* @__PURE__ */ (0,
|
|
1733
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", { className: "relative flex size-full items-center justify-center", children: initials.avatar ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
1708
1734
|
"img",
|
|
1709
1735
|
{
|
|
1710
1736
|
src: initials.avatar,
|
|
1711
1737
|
alt: initials.primary,
|
|
1712
1738
|
className: "w-full object-contain"
|
|
1713
1739
|
}
|
|
1714
|
-
) : /* @__PURE__ */ (0,
|
|
1740
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
1741
|
+
user_default,
|
|
1742
|
+
{
|
|
1743
|
+
size: 24,
|
|
1744
|
+
className: "text-button-primary-foreground-default"
|
|
1745
|
+
}
|
|
1746
|
+
) })
|
|
1715
1747
|
}
|
|
1716
1748
|
);
|
|
1717
1749
|
}
|
|
@@ -1719,34 +1751,34 @@ var UserAvatar = (0, import_react4.forwardRef)(
|
|
|
1719
1751
|
UserAvatar.displayName = "UserAvatar";
|
|
1720
1752
|
|
|
1721
1753
|
// src/theme/default/components/ui/user-menu.tsx
|
|
1722
|
-
var
|
|
1754
|
+
var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
1723
1755
|
var UserMenu = ({ session }) => {
|
|
1724
1756
|
const { config } = (0, import_elements_react14.useOryFlow)();
|
|
1725
1757
|
const initials = getUserInitials(session);
|
|
1726
|
-
const [logoutFlow, setLogoutFlow] = (0,
|
|
1727
|
-
const fetchLogoutFlow = (0,
|
|
1758
|
+
const [logoutFlow, setLogoutFlow] = (0, import_react4.useState)();
|
|
1759
|
+
const fetchLogoutFlow = (0, import_react4.useCallback)(async () => {
|
|
1728
1760
|
const flow = await frontendClient(config.sdk.url).createBrowserLogoutFlow();
|
|
1729
1761
|
setLogoutFlow(flow);
|
|
1730
1762
|
}, [config.sdk.url]);
|
|
1731
|
-
(0,
|
|
1763
|
+
(0, import_react4.useEffect)(() => {
|
|
1732
1764
|
void fetchLogoutFlow();
|
|
1733
1765
|
}, [fetchLogoutFlow]);
|
|
1734
|
-
return /* @__PURE__ */ (0,
|
|
1735
|
-
/* @__PURE__ */ (0,
|
|
1736
|
-
/* @__PURE__ */ (0,
|
|
1737
|
-
/* @__PURE__ */ (0,
|
|
1738
|
-
/* @__PURE__ */ (0,
|
|
1739
|
-
/* @__PURE__ */ (0,
|
|
1740
|
-
/* @__PURE__ */ (0,
|
|
1741
|
-
initials.secondary && /* @__PURE__ */ (0,
|
|
1766
|
+
return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(DropdownMenu, { children: [
|
|
1767
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(UserAvatar, { initials }) }),
|
|
1768
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(DropdownMenuContent, { children: [
|
|
1769
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_react_dropdown_menu.DropdownMenuLabel, { className: "flex gap-3 px-5 py-4.5", children: [
|
|
1770
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(UserAvatar, { disabled: true, initials }),
|
|
1771
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "flex flex-col justify-center text-sm leading-tight", children: [
|
|
1772
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "text-interface-foreground-default-primary leading-tight font-medium", children: initials.primary }),
|
|
1773
|
+
initials.secondary && /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "text-interface-foreground-default-tertiary leading-tight", children: initials.secondary })
|
|
1742
1774
|
] })
|
|
1743
1775
|
] }),
|
|
1744
|
-
/* @__PURE__ */ (0,
|
|
1745
|
-
/* @__PURE__ */ (0,
|
|
1776
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("a", { href: "/settings", children: [
|
|
1777
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(settings_default, { size: 16 }),
|
|
1746
1778
|
" User settings"
|
|
1747
1779
|
] }) }),
|
|
1748
|
-
/* @__PURE__ */ (0,
|
|
1749
|
-
/* @__PURE__ */ (0,
|
|
1780
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DropdownMenuItem, { asChild: true, disabled: !(logoutFlow == null ? void 0 : logoutFlow.logout_url), children: /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("a", { href: logoutFlow == null ? void 0 : logoutFlow.logout_url, children: [
|
|
1781
|
+
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(logout_default, { size: 16 }),
|
|
1750
1782
|
" Logout"
|
|
1751
1783
|
] }) })
|
|
1752
1784
|
] })
|
|
@@ -1755,39 +1787,39 @@ var UserMenu = ({ session }) => {
|
|
|
1755
1787
|
|
|
1756
1788
|
// src/theme/default/components/generic/page-header.tsx
|
|
1757
1789
|
var import_client2 = require("@ory/elements-react/client");
|
|
1758
|
-
var
|
|
1790
|
+
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
1759
1791
|
var DefaultPageHeader = (_props) => {
|
|
1760
1792
|
const { Card } = (0, import_elements_react15.useComponents)();
|
|
1761
1793
|
const { session } = (0, import_client2.useSession)();
|
|
1762
|
-
return /* @__PURE__ */ (0,
|
|
1763
|
-
/* @__PURE__ */ (0,
|
|
1764
|
-
/* @__PURE__ */ (0,
|
|
1794
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "mt-16 flex w-full max-w-[896px] flex-col gap-3", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "flex flex-col gap-12", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex max-h-10 flex-1 justify-between gap-2", children: [
|
|
1795
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "relative h-10 flex-1", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Card.Logo, {}) }),
|
|
1796
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)(UserMenu, { session })
|
|
1765
1797
|
] }) }) });
|
|
1766
1798
|
};
|
|
1767
1799
|
|
|
1768
1800
|
// src/theme/default/assets/icons/trash.svg
|
|
1769
1801
|
var React25 = __toESM(require("react"));
|
|
1770
|
-
var
|
|
1802
|
+
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
1771
1803
|
var SvgTrash = (props) => {
|
|
1772
1804
|
var _a, _b;
|
|
1773
|
-
return /* @__PURE__ */ (0,
|
|
1805
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.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_runtime52.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" }) });
|
|
1774
1806
|
};
|
|
1775
1807
|
var trash_default = SvgTrash;
|
|
1776
1808
|
|
|
1777
1809
|
// src/theme/default/components/settings/settings-oidc.tsx
|
|
1778
|
-
var
|
|
1779
|
-
var
|
|
1810
|
+
var import_react_hook_form8 = require("react-hook-form");
|
|
1811
|
+
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
1780
1812
|
function DefaultSettingsOidc({
|
|
1781
1813
|
linkButtons,
|
|
1782
1814
|
unlinkButtons
|
|
1783
1815
|
}) {
|
|
1784
1816
|
const hasLinkButtons = linkButtons.length > 0;
|
|
1785
1817
|
const hasUnlinkButtons = unlinkButtons.length > 0;
|
|
1786
|
-
const { setValue } = (0,
|
|
1787
|
-
return /* @__PURE__ */ (0,
|
|
1788
|
-
hasLinkButtons && /* @__PURE__ */ (0,
|
|
1818
|
+
const { setValue } = (0, import_react_hook_form8.useFormContext)();
|
|
1819
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1820
|
+
hasLinkButtons && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "flex items-start gap-3 [&>button]:w-[79px]", children: linkButtons.map((button) => {
|
|
1789
1821
|
const attrs = button.attributes;
|
|
1790
|
-
return /* @__PURE__ */ (0,
|
|
1822
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1791
1823
|
DefaultButtonSocial,
|
|
1792
1824
|
{
|
|
1793
1825
|
showLabel: false,
|
|
@@ -1801,18 +1833,18 @@ function DefaultSettingsOidc({
|
|
|
1801
1833
|
attrs.value
|
|
1802
1834
|
);
|
|
1803
1835
|
}) }),
|
|
1804
|
-
hasUnlinkButtons && hasLinkButtons ? /* @__PURE__ */ (0,
|
|
1836
|
+
hasUnlinkButtons && hasLinkButtons ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(DefaultHorizontalDivider, {}) : null,
|
|
1805
1837
|
unlinkButtons.map((button) => {
|
|
1806
1838
|
var _a, _b;
|
|
1807
1839
|
const attrs = button.attributes;
|
|
1808
1840
|
const provider = (_b = extractProvider((_a = button.meta.label) == null ? void 0 : _a.context)) != null ? _b : "";
|
|
1809
1841
|
const Logo = attrs.value in provider_logos_default ? provider_logos_default[attrs.value] : provider_logos_default.generic;
|
|
1810
|
-
return /* @__PURE__ */ (0,
|
|
1811
|
-
/* @__PURE__ */ (0,
|
|
1812
|
-
/* @__PURE__ */ (0,
|
|
1813
|
-
/* @__PURE__ */ (0,
|
|
1842
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex justify-between", children: [
|
|
1843
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex items-center gap-6", children: [
|
|
1844
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(Logo, { size: 32 }),
|
|
1845
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary", children: provider })
|
|
1814
1846
|
] }),
|
|
1815
|
-
/* @__PURE__ */ (0,
|
|
1847
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1816
1848
|
"button",
|
|
1817
1849
|
{
|
|
1818
1850
|
...attrs,
|
|
@@ -1821,7 +1853,13 @@ function DefaultSettingsOidc({
|
|
|
1821
1853
|
setValue("unlink", attrs.value);
|
|
1822
1854
|
setValue("method", "oidc");
|
|
1823
1855
|
},
|
|
1824
|
-
children: /* @__PURE__ */ (0,
|
|
1856
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1857
|
+
trash_default,
|
|
1858
|
+
{
|
|
1859
|
+
className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover",
|
|
1860
|
+
size: 24
|
|
1861
|
+
}
|
|
1862
|
+
)
|
|
1825
1863
|
}
|
|
1826
1864
|
)
|
|
1827
1865
|
] }, attrs.value);
|
|
@@ -1830,47 +1868,62 @@ function DefaultSettingsOidc({
|
|
|
1830
1868
|
}
|
|
1831
1869
|
|
|
1832
1870
|
// src/theme/default/components/settings/settings-passkey.tsx
|
|
1833
|
-
var
|
|
1871
|
+
var import_elements_react16 = require("@ory/elements-react");
|
|
1872
|
+
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
1834
1873
|
function DefaultSettingsPasskey({
|
|
1835
1874
|
triggerButton,
|
|
1836
1875
|
removeButtons
|
|
1837
1876
|
}) {
|
|
1877
|
+
const { Node } = (0, import_elements_react16.useComponents)();
|
|
1838
1878
|
const hasRemoveButtons = removeButtons.length > 0;
|
|
1839
|
-
return /* @__PURE__ */ (0,
|
|
1840
|
-
/* @__PURE__ */ (0,
|
|
1841
|
-
|
|
1879
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1880
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex max-w-[60%] items-end gap-3", children: triggerButton && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1881
|
+
Node.Button,
|
|
1842
1882
|
{
|
|
1843
1883
|
node: triggerButton,
|
|
1844
1884
|
attributes: triggerButton.attributes,
|
|
1845
1885
|
onClick: triggerButton.onClick
|
|
1846
1886
|
}
|
|
1847
|
-
)
|
|
1848
|
-
hasRemoveButtons ? /* @__PURE__ */ (0,
|
|
1849
|
-
/* @__PURE__ */ (0,
|
|
1850
|
-
/* @__PURE__ */ (0,
|
|
1887
|
+
) }),
|
|
1888
|
+
hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1889
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(DefaultHorizontalDivider, {}),
|
|
1890
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "flex flex-col gap-2", children: removeButtons.map((node, i) => {
|
|
1851
1891
|
var _a, _b;
|
|
1852
1892
|
const context = (_b = (_a = node.meta.label) == null ? void 0 : _a.context) != null ? _b : {};
|
|
1853
1893
|
const addedAt = "added_at" in context ? context.added_at : null;
|
|
1854
|
-
const
|
|
1894
|
+
const displayName = "display_name" in context ? context.display_name : null;
|
|
1855
1895
|
const keyId = "value" in node.attributes ? node.attributes.value : null;
|
|
1856
|
-
return /* @__PURE__ */ (0,
|
|
1896
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
|
|
1857
1897
|
"div",
|
|
1858
1898
|
{
|
|
1859
1899
|
className: "flex justify-between gap-6",
|
|
1860
1900
|
children: [
|
|
1861
|
-
/* @__PURE__ */ (0,
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1901
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1902
|
+
passkey_default,
|
|
1903
|
+
{
|
|
1904
|
+
size: 32,
|
|
1905
|
+
className: "text-interface-foreground-default-primary"
|
|
1906
|
+
}
|
|
1907
|
+
),
|
|
1908
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex-1 flex-col", children: [
|
|
1909
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary", children: displayName }),
|
|
1910
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "text-sm text-interface-foreground-default-tertiary", children: keyId })
|
|
1865
1911
|
] }),
|
|
1866
|
-
addedAt && /* @__PURE__ */ (0,
|
|
1867
|
-
|
|
1912
|
+
addedAt && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("p", { className: "self-center text-sm text-interface-foreground-default-tertiary", children: new Intl.DateTimeFormat(void 0, {
|
|
1913
|
+
dateStyle: "long"
|
|
1914
|
+
}).format(new Date(addedAt)) }),
|
|
1915
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1868
1916
|
"button",
|
|
1869
1917
|
{
|
|
1870
1918
|
...node.attributes,
|
|
1871
1919
|
type: "submit",
|
|
1872
|
-
|
|
1873
|
-
|
|
1920
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1921
|
+
trash_default,
|
|
1922
|
+
{
|
|
1923
|
+
className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover",
|
|
1924
|
+
size: 24
|
|
1925
|
+
}
|
|
1926
|
+
)
|
|
1874
1927
|
}
|
|
1875
1928
|
)
|
|
1876
1929
|
]
|
|
@@ -1884,36 +1937,36 @@ function DefaultSettingsPasskey({
|
|
|
1884
1937
|
|
|
1885
1938
|
// src/theme/default/assets/icons/download.svg
|
|
1886
1939
|
var React26 = __toESM(require("react"));
|
|
1887
|
-
var
|
|
1940
|
+
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
1888
1941
|
var SvgDownload = (props) => {
|
|
1889
1942
|
var _a, _b;
|
|
1890
|
-
return /* @__PURE__ */ (0,
|
|
1943
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.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_runtime55.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" }) });
|
|
1891
1944
|
};
|
|
1892
1945
|
var download_default = SvgDownload;
|
|
1893
1946
|
|
|
1894
1947
|
// src/theme/default/assets/icons/eye.svg
|
|
1895
1948
|
var React27 = __toESM(require("react"));
|
|
1896
|
-
var
|
|
1949
|
+
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
1897
1950
|
var SvgEye = (props) => {
|
|
1898
1951
|
var _a, _b;
|
|
1899
|
-
return /* @__PURE__ */ (0,
|
|
1900
|
-
/* @__PURE__ */ (0,
|
|
1901
|
-
/* @__PURE__ */ (0,
|
|
1952
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.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_runtime56.jsxs)("g", { strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
1953
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)("path", { stroke: "currentColor", d: "M10 12a2 2 0 1 0 4 0 2 2 0 0 0-4 0" }),
|
|
1954
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)("path", { stroke: "#64748B", d: "M21 12q-3.6 6-9 6t-9-6q3.6-6 9-6t9 6" })
|
|
1902
1955
|
] }) });
|
|
1903
1956
|
};
|
|
1904
1957
|
var eye_default = SvgEye;
|
|
1905
1958
|
|
|
1906
1959
|
// src/theme/default/assets/icons/refresh.svg
|
|
1907
1960
|
var React28 = __toESM(require("react"));
|
|
1908
|
-
var
|
|
1961
|
+
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
1909
1962
|
var SvgRefresh = (props) => {
|
|
1910
1963
|
var _a, _b;
|
|
1911
|
-
return /* @__PURE__ */ (0,
|
|
1964
|
+
return /* @__PURE__ */ (0, import_jsx_runtime57.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_runtime57.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" }) });
|
|
1912
1965
|
};
|
|
1913
1966
|
var refresh_default = SvgRefresh;
|
|
1914
1967
|
|
|
1915
1968
|
// src/theme/default/components/settings/settings-recovery-codes.tsx
|
|
1916
|
-
var
|
|
1969
|
+
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
1917
1970
|
function DefaultSettingsRecoveryCodes({
|
|
1918
1971
|
codes,
|
|
1919
1972
|
regnerateButton,
|
|
@@ -1930,63 +1983,66 @@ function DefaultSettingsRecoveryCodes({
|
|
|
1930
1983
|
element.click();
|
|
1931
1984
|
};
|
|
1932
1985
|
const hasCodes = codes.length >= 1;
|
|
1933
|
-
return /* @__PURE__ */ (0,
|
|
1934
|
-
/* @__PURE__ */ (0,
|
|
1935
|
-
/* @__PURE__ */ (0,
|
|
1936
|
-
regnerateButton && /* @__PURE__ */ (0,
|
|
1986
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
1987
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsx)(DefaultHorizontalDivider, {}),
|
|
1988
|
+
/* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex justify-end gap-4", children: [
|
|
1989
|
+
regnerateButton && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
1937
1990
|
"button",
|
|
1938
1991
|
{
|
|
1939
1992
|
...regnerateButton.attributes,
|
|
1940
1993
|
type: "submit",
|
|
1941
|
-
children: /* @__PURE__ */ (0,
|
|
1994
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
1942
1995
|
refresh_default,
|
|
1943
1996
|
{
|
|
1944
1997
|
size: 24,
|
|
1945
|
-
className: "
|
|
1998
|
+
className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover"
|
|
1946
1999
|
}
|
|
1947
2000
|
)
|
|
1948
2001
|
}
|
|
1949
2002
|
),
|
|
1950
|
-
revealButton && /* @__PURE__ */ (0,
|
|
2003
|
+
revealButton && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
1951
2004
|
"button",
|
|
1952
2005
|
{
|
|
1953
2006
|
...revealButton.attributes,
|
|
1954
2007
|
type: "submit",
|
|
1955
|
-
children: /* @__PURE__ */ (0,
|
|
2008
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
1956
2009
|
eye_default,
|
|
1957
2010
|
{
|
|
1958
2011
|
size: 24,
|
|
1959
|
-
className: "
|
|
2012
|
+
className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover"
|
|
1960
2013
|
}
|
|
1961
2014
|
)
|
|
1962
2015
|
}
|
|
1963
2016
|
),
|
|
1964
|
-
hasCodes
|
|
2017
|
+
hasCodes && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("button", { onClick: onDownload, type: "button", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
|
|
1965
2018
|
download_default,
|
|
1966
2019
|
{
|
|
1967
2020
|
size: 24,
|
|
1968
|
-
|
|
1969
|
-
className: "cursor-pointer text-links-link-mute-default hover:text-links-link-mute-hover"
|
|
2021
|
+
className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover"
|
|
1970
2022
|
}
|
|
1971
|
-
)
|
|
2023
|
+
) })
|
|
1972
2024
|
] }),
|
|
1973
|
-
hasCodes ? /* @__PURE__ */ (0,
|
|
2025
|
+
hasCodes ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "rounded-general p-6 bg-interface-background-default-secondary border-interface-border-default-primary", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "grid grid-cols-5 flex-wrap gap-4 text-sm text-interface-foreground-default-primary", children: codes.map((code) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("p", { children: code }, code)) }) }) : null
|
|
1974
2026
|
] });
|
|
1975
2027
|
}
|
|
1976
2028
|
|
|
2029
|
+
// src/theme/default/components/settings/settings-top.tsx
|
|
2030
|
+
var import_elements_react17 = require("@ory/elements-react");
|
|
2031
|
+
|
|
1977
2032
|
// src/theme/default/assets/icons/qrcode.svg
|
|
1978
2033
|
var React29 = __toESM(require("react"));
|
|
1979
|
-
var
|
|
2034
|
+
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
1980
2035
|
var SvgQrcode = (props) => {
|
|
1981
2036
|
var _a, _b;
|
|
1982
|
-
return /* @__PURE__ */ (0,
|
|
2037
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.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_runtime59.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" }) });
|
|
1983
2038
|
};
|
|
1984
2039
|
var qrcode_default = SvgQrcode;
|
|
1985
2040
|
|
|
1986
2041
|
// src/theme/default/components/settings/settings-top.tsx
|
|
1987
|
-
var
|
|
2042
|
+
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
1988
2043
|
function DefaultSettingsTotp(props) {
|
|
1989
2044
|
var _a;
|
|
2045
|
+
const { Node, Card } = (0, import_elements_react17.useComponents)();
|
|
1990
2046
|
if ("totpUnlink" in props && props.totpUnlink) {
|
|
1991
2047
|
const {
|
|
1992
2048
|
type,
|
|
@@ -1995,21 +2051,21 @@ function DefaultSettingsTotp(props) {
|
|
|
1995
2051
|
node_type: _ignoredNodeType,
|
|
1996
2052
|
...buttonAttrs
|
|
1997
2053
|
} = (_a = props.totpUnlink) == null ? void 0 : _a.attributes;
|
|
1998
|
-
return /* @__PURE__ */ (0,
|
|
1999
|
-
/* @__PURE__ */ (0,
|
|
2000
|
-
/* @__PURE__ */ (0,
|
|
2001
|
-
/* @__PURE__ */ (0,
|
|
2002
|
-
/* @__PURE__ */ (0,
|
|
2003
|
-
/* @__PURE__ */ (0,
|
|
2054
|
+
return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "grid grid-cols-1 gap-8 md:grid-cols-2", children: [
|
|
2055
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Card.Divider, {}) }),
|
|
2056
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "col-span-full flex items-center gap-6", children: [
|
|
2057
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "aspect-square size-8 ", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(qrcode_default, { size: 32 }) }),
|
|
2058
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "mr-auto flex flex-col", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-primary", children: "Authenticator app" }) }),
|
|
2059
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
|
|
2004
2060
|
"button",
|
|
2005
2061
|
{
|
|
2006
2062
|
type: type === "button" ? "button" : "submit",
|
|
2007
2063
|
...buttonAttrs,
|
|
2008
|
-
children: /* @__PURE__ */ (0,
|
|
2064
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
|
|
2009
2065
|
trash_default,
|
|
2010
2066
|
{
|
|
2011
|
-
|
|
2012
|
-
|
|
2067
|
+
className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover",
|
|
2068
|
+
size: 24
|
|
2013
2069
|
}
|
|
2014
2070
|
)
|
|
2015
2071
|
}
|
|
@@ -2018,10 +2074,10 @@ function DefaultSettingsTotp(props) {
|
|
|
2018
2074
|
] });
|
|
2019
2075
|
}
|
|
2020
2076
|
if ("totpSecret" in props) {
|
|
2021
|
-
return /* @__PURE__ */ (0,
|
|
2022
|
-
/* @__PURE__ */ (0,
|
|
2023
|
-
/* @__PURE__ */ (0,
|
|
2024
|
-
|
|
2077
|
+
return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "grid grid-cols-1 gap-8 md:grid-cols-2", children: [
|
|
2078
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "col-span-full", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(DefaultHorizontalDivider, {}) }),
|
|
2079
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "flex justify-center rounded-cards bg-interface-background-default-secondary p-8", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "aspect-square h-44 rounded bg-[white]", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "-m-3 antialiased mix-blend-multiply", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
|
|
2080
|
+
Node.Image,
|
|
2025
2081
|
{
|
|
2026
2082
|
node: props.totpImage,
|
|
2027
2083
|
attributes: {
|
|
@@ -2029,14 +2085,14 @@ function DefaultSettingsTotp(props) {
|
|
|
2029
2085
|
}
|
|
2030
2086
|
}
|
|
2031
2087
|
) }) }) }),
|
|
2032
|
-
/* @__PURE__ */ (0,
|
|
2033
|
-
/* @__PURE__ */ (0,
|
|
2034
|
-
|
|
2088
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex flex-col gap-6", children: [
|
|
2089
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
|
|
2090
|
+
Node.Label,
|
|
2035
2091
|
{
|
|
2036
2092
|
node: props.totpSecret,
|
|
2037
2093
|
attributes: props.totpSecret.attributes,
|
|
2038
|
-
children: /* @__PURE__ */ (0,
|
|
2039
|
-
|
|
2094
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
|
|
2095
|
+
Node.Input,
|
|
2040
2096
|
{
|
|
2041
2097
|
node: props.totpSecret,
|
|
2042
2098
|
attributes: {
|
|
@@ -2050,13 +2106,13 @@ function DefaultSettingsTotp(props) {
|
|
|
2050
2106
|
)
|
|
2051
2107
|
}
|
|
2052
2108
|
),
|
|
2053
|
-
/* @__PURE__ */ (0,
|
|
2054
|
-
|
|
2109
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
|
|
2110
|
+
Node.Label,
|
|
2055
2111
|
{
|
|
2056
2112
|
attributes: props.totpInput.attributes,
|
|
2057
2113
|
node: props.totpInput,
|
|
2058
|
-
children: /* @__PURE__ */ (0,
|
|
2059
|
-
|
|
2114
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
|
|
2115
|
+
Node.Input,
|
|
2060
2116
|
{
|
|
2061
2117
|
node: props.totpInput,
|
|
2062
2118
|
attributes: props.totpInput.attributes
|
|
@@ -2069,32 +2125,36 @@ function DefaultSettingsTotp(props) {
|
|
|
2069
2125
|
}
|
|
2070
2126
|
}
|
|
2071
2127
|
|
|
2128
|
+
// src/theme/default/components/settings/settings-webauthn.tsx
|
|
2129
|
+
var import_elements_react18 = require("@ory/elements-react");
|
|
2130
|
+
|
|
2072
2131
|
// src/theme/default/assets/icons/key.svg
|
|
2073
2132
|
var React30 = __toESM(require("react"));
|
|
2074
|
-
var
|
|
2133
|
+
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
2075
2134
|
var SvgKey = (props) => {
|
|
2076
2135
|
var _a, _b;
|
|
2077
|
-
return /* @__PURE__ */ (0,
|
|
2136
|
+
return /* @__PURE__ */ (0, import_jsx_runtime61.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_runtime61.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" }) });
|
|
2078
2137
|
};
|
|
2079
2138
|
var key_default = SvgKey;
|
|
2080
2139
|
|
|
2081
2140
|
// src/theme/default/components/settings/settings-webauthn.tsx
|
|
2082
|
-
var
|
|
2141
|
+
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
2083
2142
|
function DefaultSettingsWebauthn({
|
|
2084
2143
|
nameInput,
|
|
2085
2144
|
triggerButton,
|
|
2086
2145
|
removeButtons
|
|
2087
2146
|
}) {
|
|
2147
|
+
const { Node, Card } = (0, import_elements_react18.useComponents)();
|
|
2088
2148
|
const hasRemoveButtons = removeButtons.length > 0;
|
|
2089
|
-
return /* @__PURE__ */ (0,
|
|
2090
|
-
/* @__PURE__ */ (0,
|
|
2091
|
-
/* @__PURE__ */ (0,
|
|
2092
|
-
|
|
2149
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
2150
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "flex max-w-[60%] items-end gap-3", children: [
|
|
2151
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "flex-1", children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
2152
|
+
Node.Label,
|
|
2093
2153
|
{
|
|
2094
2154
|
node: nameInput,
|
|
2095
2155
|
attributes: nameInput.attributes,
|
|
2096
|
-
children: /* @__PURE__ */ (0,
|
|
2097
|
-
|
|
2156
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
2157
|
+
Node.Input,
|
|
2098
2158
|
{
|
|
2099
2159
|
node: nameInput,
|
|
2100
2160
|
attributes: nameInput.attributes
|
|
@@ -2102,8 +2162,8 @@ function DefaultSettingsWebauthn({
|
|
|
2102
2162
|
)
|
|
2103
2163
|
}
|
|
2104
2164
|
) }),
|
|
2105
|
-
triggerButton ? /* @__PURE__ */ (0,
|
|
2106
|
-
|
|
2165
|
+
triggerButton ? /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
2166
|
+
Node.Button,
|
|
2107
2167
|
{
|
|
2108
2168
|
node: triggerButton,
|
|
2109
2169
|
attributes: triggerButton.attributes,
|
|
@@ -2111,32 +2171,45 @@ function DefaultSettingsWebauthn({
|
|
|
2111
2171
|
}
|
|
2112
2172
|
) : null
|
|
2113
2173
|
] }),
|
|
2114
|
-
hasRemoveButtons ? /* @__PURE__ */ (0,
|
|
2115
|
-
/* @__PURE__ */ (0,
|
|
2116
|
-
/* @__PURE__ */ (0,
|
|
2174
|
+
hasRemoveButtons ? /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "flex flex-col gap-8", children: [
|
|
2175
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)(Card.Divider, {}),
|
|
2176
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "flex flex-col gap-2", children: removeButtons.map((node, i) => {
|
|
2117
2177
|
var _a, _b;
|
|
2118
2178
|
const context = (_b = (_a = node.meta.label) == null ? void 0 : _a.context) != null ? _b : {};
|
|
2119
2179
|
const addedAt = "added_at" in context ? context.added_at : null;
|
|
2120
2180
|
const diaplyName = "display_name" in context ? context.display_name : null;
|
|
2121
2181
|
const keyId = "value" in node.attributes ? node.attributes.value : null;
|
|
2122
|
-
return /* @__PURE__ */ (0,
|
|
2182
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
|
|
2123
2183
|
"div",
|
|
2124
2184
|
{
|
|
2125
2185
|
className: "flex justify-between gap-6",
|
|
2126
2186
|
children: [
|
|
2127
|
-
/* @__PURE__ */ (0,
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2187
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
2188
|
+
key_default,
|
|
2189
|
+
{
|
|
2190
|
+
size: 32,
|
|
2191
|
+
className: "text-interface-foreground-default-primary"
|
|
2192
|
+
}
|
|
2193
|
+
),
|
|
2194
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "flex-1 flex-col", children: [
|
|
2195
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)("p", { className: "text-sm font-medium text-interface-foreground-default-secondary", children: diaplyName }),
|
|
2196
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "text-sm text-interface-foreground-default-tertiary", children: keyId })
|
|
2131
2197
|
] }),
|
|
2132
|
-
addedAt && /* @__PURE__ */ (0,
|
|
2133
|
-
|
|
2198
|
+
addedAt && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("p", { className: "self-center text-sm text-interface-foreground-default-tertiary", children: new Intl.DateTimeFormat(void 0, {
|
|
2199
|
+
dateStyle: "long"
|
|
2200
|
+
}).format(new Date(addedAt)) }),
|
|
2201
|
+
/* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
2134
2202
|
"button",
|
|
2135
2203
|
{
|
|
2136
2204
|
...node.attributes,
|
|
2137
2205
|
type: "submit",
|
|
2138
|
-
|
|
2139
|
-
|
|
2206
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
|
|
2207
|
+
trash_default,
|
|
2208
|
+
{
|
|
2209
|
+
className: "text-button-link-default-secondary hover:text-button-link-default-secondary-hover",
|
|
2210
|
+
size: 24
|
|
2211
|
+
}
|
|
2212
|
+
)
|
|
2140
2213
|
}
|
|
2141
2214
|
)
|
|
2142
2215
|
]
|
|
@@ -2196,18 +2269,18 @@ function getOryComponents(overrides) {
|
|
|
2196
2269
|
}
|
|
2197
2270
|
|
|
2198
2271
|
// src/theme/default/flows/error.tsx
|
|
2199
|
-
var
|
|
2272
|
+
var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
2200
2273
|
function Error2({
|
|
2201
2274
|
error,
|
|
2202
2275
|
children
|
|
2203
2276
|
}) {
|
|
2204
|
-
return /* @__PURE__ */ (0,
|
|
2277
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { children: JSON.stringify(error) || children });
|
|
2205
2278
|
}
|
|
2206
2279
|
|
|
2207
2280
|
// src/theme/default/flows/login.tsx
|
|
2208
|
-
var
|
|
2209
|
-
var
|
|
2210
|
-
var
|
|
2281
|
+
var import_client_fetch12 = require("@ory/client-fetch");
|
|
2282
|
+
var import_elements_react19 = require("@ory/elements-react");
|
|
2283
|
+
var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
2211
2284
|
function Login({
|
|
2212
2285
|
flow,
|
|
2213
2286
|
config,
|
|
@@ -2215,22 +2288,22 @@ function Login({
|
|
|
2215
2288
|
components: flowOverrideComponents
|
|
2216
2289
|
}) {
|
|
2217
2290
|
const components = getOryComponents(flowOverrideComponents);
|
|
2218
|
-
return /* @__PURE__ */ (0,
|
|
2219
|
-
|
|
2291
|
+
return /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
|
|
2292
|
+
import_elements_react19.OryProvider,
|
|
2220
2293
|
{
|
|
2221
2294
|
config,
|
|
2222
2295
|
flow,
|
|
2223
|
-
flowType:
|
|
2296
|
+
flowType: import_client_fetch12.FlowType.Login,
|
|
2224
2297
|
components,
|
|
2225
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2298
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(import_elements_react19.OryTwoStepCard, {})
|
|
2226
2299
|
}
|
|
2227
2300
|
);
|
|
2228
2301
|
}
|
|
2229
2302
|
|
|
2230
2303
|
// src/theme/default/flows/recovery.tsx
|
|
2231
|
-
var
|
|
2232
|
-
var
|
|
2233
|
-
var
|
|
2304
|
+
var import_client_fetch13 = require("@ory/client-fetch");
|
|
2305
|
+
var import_elements_react20 = require("@ory/elements-react");
|
|
2306
|
+
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
2234
2307
|
function Recovery({
|
|
2235
2308
|
flow,
|
|
2236
2309
|
config,
|
|
@@ -2238,22 +2311,22 @@ function Recovery({
|
|
|
2238
2311
|
components: flowOverrideComponents
|
|
2239
2312
|
}) {
|
|
2240
2313
|
const components = getOryComponents(flowOverrideComponents);
|
|
2241
|
-
return /* @__PURE__ */ (0,
|
|
2242
|
-
|
|
2314
|
+
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
2315
|
+
import_elements_react20.OryProvider,
|
|
2243
2316
|
{
|
|
2244
2317
|
config,
|
|
2245
2318
|
flow,
|
|
2246
|
-
flowType:
|
|
2319
|
+
flowType: import_client_fetch13.FlowType.Recovery,
|
|
2247
2320
|
components,
|
|
2248
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2321
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_elements_react20.OryTwoStepCard, {})
|
|
2249
2322
|
}
|
|
2250
2323
|
);
|
|
2251
2324
|
}
|
|
2252
2325
|
|
|
2253
2326
|
// src/theme/default/flows/registration.tsx
|
|
2254
|
-
var
|
|
2255
|
-
var
|
|
2256
|
-
var
|
|
2327
|
+
var import_client_fetch14 = require("@ory/client-fetch");
|
|
2328
|
+
var import_elements_react21 = require("@ory/elements-react");
|
|
2329
|
+
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
2257
2330
|
function Registration({
|
|
2258
2331
|
flow,
|
|
2259
2332
|
children,
|
|
@@ -2261,22 +2334,22 @@ function Registration({
|
|
|
2261
2334
|
config
|
|
2262
2335
|
}) {
|
|
2263
2336
|
const components = getOryComponents(flowOverrideComponents);
|
|
2264
|
-
return /* @__PURE__ */ (0,
|
|
2265
|
-
|
|
2337
|
+
return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
|
|
2338
|
+
import_elements_react21.OryProvider,
|
|
2266
2339
|
{
|
|
2267
2340
|
config,
|
|
2268
2341
|
flow,
|
|
2269
|
-
flowType:
|
|
2342
|
+
flowType: import_client_fetch14.FlowType.Registration,
|
|
2270
2343
|
components,
|
|
2271
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2344
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(import_elements_react21.OryTwoStepCard, {})
|
|
2272
2345
|
}
|
|
2273
2346
|
);
|
|
2274
2347
|
}
|
|
2275
2348
|
|
|
2276
2349
|
// src/theme/default/flows/settings.tsx
|
|
2277
|
-
var
|
|
2278
|
-
var
|
|
2279
|
-
var
|
|
2350
|
+
var import_client_fetch15 = require("@ory/client-fetch");
|
|
2351
|
+
var import_elements_react22 = require("@ory/elements-react");
|
|
2352
|
+
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
2280
2353
|
function Settings({
|
|
2281
2354
|
flow,
|
|
2282
2355
|
config,
|
|
@@ -2284,25 +2357,25 @@ function Settings({
|
|
|
2284
2357
|
components: flowOverrideComponents
|
|
2285
2358
|
}) {
|
|
2286
2359
|
const components = getOryComponents(flowOverrideComponents);
|
|
2287
|
-
return /* @__PURE__ */ (0,
|
|
2288
|
-
|
|
2360
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
2361
|
+
import_elements_react22.OryProvider,
|
|
2289
2362
|
{
|
|
2290
2363
|
config,
|
|
2291
2364
|
flow,
|
|
2292
|
-
flowType:
|
|
2365
|
+
flowType: import_client_fetch15.FlowType.Settings,
|
|
2293
2366
|
components,
|
|
2294
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2295
|
-
/* @__PURE__ */ (0,
|
|
2296
|
-
/* @__PURE__ */ (0,
|
|
2367
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(import_jsx_runtime67.Fragment, { children: [
|
|
2368
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_elements_react22.HeadlessPageHeader, {}),
|
|
2369
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_elements_react22.OrySettingsCard, {})
|
|
2297
2370
|
] })
|
|
2298
2371
|
}
|
|
2299
2372
|
);
|
|
2300
2373
|
}
|
|
2301
2374
|
|
|
2302
2375
|
// src/theme/default/flows/verification.tsx
|
|
2303
|
-
var
|
|
2304
|
-
var
|
|
2305
|
-
var
|
|
2376
|
+
var import_client_fetch16 = require("@ory/client-fetch");
|
|
2377
|
+
var import_elements_react23 = require("@ory/elements-react");
|
|
2378
|
+
var import_jsx_runtime68 = require("react/jsx-runtime");
|
|
2306
2379
|
function Verification({
|
|
2307
2380
|
flow,
|
|
2308
2381
|
config,
|
|
@@ -2310,14 +2383,14 @@ function Verification({
|
|
|
2310
2383
|
components: flowOverrideComponents
|
|
2311
2384
|
}) {
|
|
2312
2385
|
const components = getOryComponents(flowOverrideComponents);
|
|
2313
|
-
return /* @__PURE__ */ (0,
|
|
2314
|
-
|
|
2386
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
2387
|
+
import_elements_react23.OryProvider,
|
|
2315
2388
|
{
|
|
2316
2389
|
config,
|
|
2317
2390
|
flow,
|
|
2318
|
-
flowType:
|
|
2391
|
+
flowType: import_client_fetch16.FlowType.Verification,
|
|
2319
2392
|
components,
|
|
2320
|
-
children: children != null ? children : /* @__PURE__ */ (0,
|
|
2393
|
+
children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(import_elements_react23.OryTwoStepCard, {})
|
|
2321
2394
|
}
|
|
2322
2395
|
);
|
|
2323
2396
|
}
|
|
@@ -2328,6 +2401,7 @@ function Verification({
|
|
|
2328
2401
|
DefaultCardContent,
|
|
2329
2402
|
DefaultCardFooter,
|
|
2330
2403
|
DefaultCardHeader,
|
|
2404
|
+
DefaultCardLayout,
|
|
2331
2405
|
DefaultCardLogo,
|
|
2332
2406
|
DefaultCurrentIdentifierButton,
|
|
2333
2407
|
DefaultFormContainer,
|